using Email.Data;
using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace Email.Data.Migrations
{
    /// <inheritdoc />
    public partial class AddFallbackStringTemplates : Migration
    {
        /// <inheritdoc />
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.match.fallback-na", "en", "N/A", "Fallback when a match email field (job label or URL) has no value"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.match.fallback-na", "ro", "N/A", "Fallback când un câmp al emailului de potrivire (etichetă job sau URL) nu are valoare"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.match.subject-fallback-label", "en", "Job", "Fallback job label used in match email subject when no specific label is available"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.match.subject-fallback-label", "ro", "Job", "Etichetă fallback pentru subiectul emailului de potrivire când nu există o etichetă specifică"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.notification.unknown-ip", "en", "Unknown", "Fallback IP address label in operator notification emails"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.notification.unknown-ip", "ro", "Necunoscut", "Etichetă fallback pentru adresa IP în emailurile de notificare operator"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.search-results.keywords-empty", "en", "none detected", "Text shown in job search results email when no CV keywords were extracted"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.search-results.keywords-empty", "ro", "niciunul detectat", "Text afișat în emailul cu rezultatele căutării când nu au fost extrase cuvinte cheie din CV"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.search-results.providers-empty", "en", "none", "Text shown in job search results email when no providers were searched"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.search-results.providers-empty", "ro", "niciunul", "Text afișat în emailul cu rezultatele căutării când nu au fost căutați furnizori"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.search-results.location-empty", "en", "-", "Fallback location display in job search results email scan summary"]);

            migrationBuilder.InsertData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                columns: ["Key", "Language", "Value", "Description"],
                values: ["email.search-results.location-empty", "ro", "-", "Afișaj fallback pentru locație în sumarului de scanare al emailului cu rezultatele căutării"]);
        }

        /// <inheritdoc />
        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.match.fallback-na", "en"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.match.fallback-na", "ro"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.match.subject-fallback-label", "en"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.match.subject-fallback-label", "ro"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.notification.unknown-ip", "en"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.notification.unknown-ip", "ro"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.search-results.keywords-empty", "en"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.search-results.keywords-empty", "ro"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.search-results.providers-empty", "en"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.search-results.providers-empty", "ro"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.search-results.location-empty", "en"]);

            migrationBuilder.DeleteData(
                schema: MigrationConstants.SchemaName,
                table: "Templates",
                keyColumns: ["Key", "Language"],
                keyValues: ["email.search-results.location-empty", "ro"]);
        }
    }
}
