diff --git a/server/AyaNova/Controllers/CustomerController.cs b/server/AyaNova/Controllers/CustomerController.cs index 8eaaf289..295a7d85 100644 --- a/server/AyaNova/Controllers/CustomerController.cs +++ b/server/AyaNova/Controllers/CustomerController.cs @@ -142,7 +142,7 @@ namespace AyaNova.Api.Controllers return StatusCode(403, new ApiNotAuthorizedResponse()); if (!ModelState.IsValid) return BadRequest(new ApiErrorResponse(ModelState)); - return Ok(ApiOkResponse.Response(await ct.Customer.AsNoTracking().Where(x => x.Id == id).Select(x => x.PopUpNotes).FirstOrDefaultAsync())); + return Ok(ApiOkResponse.Response(await ct.Customer.AsNoTracking().Where(x => x.Id == id).Select(x => x.AlertNotes).FirstOrDefaultAsync())); } /// diff --git a/server/AyaNova/Controllers/VendorController.cs b/server/AyaNova/Controllers/VendorController.cs index 8b211a6f..386c4946 100644 --- a/server/AyaNova/Controllers/VendorController.cs +++ b/server/AyaNova/Controllers/VendorController.cs @@ -165,7 +165,7 @@ namespace AyaNova.Api.Controllers return StatusCode(403, new ApiNotAuthorizedResponse()); if (!ModelState.IsValid) return BadRequest(new ApiErrorResponse(ModelState)); - return Ok(ApiOkResponse.Response(await ct.Vendor.AsNoTracking().Where(x => x.Id == id).Select(x => x.PopUpNotes).FirstOrDefaultAsync())); + return Ok(ApiOkResponse.Response(await ct.Vendor.AsNoTracking().Where(x => x.Id == id).Select(x => x.AlertNotes).FirstOrDefaultAsync())); } diff --git a/server/AyaNova/DataList/CustomerDataList.cs b/server/AyaNova/DataList/CustomerDataList.cs index 3dca8725..875f6a8a 100644 --- a/server/AyaNova/DataList/CustomerDataList.cs +++ b/server/AyaNova/DataList/CustomerDataList.cs @@ -63,10 +63,10 @@ namespace AyaNova.DataList FieldDefinitions.Add(new DataListFieldDefinition { - TKey = "CustomerPopUpNotes", - FieldKey = "customerpopupnotes", + TKey = "CustomerAlertNotes", + FieldKey = "CustomerAlertNotes", UiFieldDataType = (int)UiFieldDataType.Text, - SqlValueColumnName = "acustomer.popupnotes" + SqlValueColumnName = "acustomer.alertnotes" }); FieldDefinitions.Add(new DataListFieldDefinition diff --git a/server/AyaNova/DataList/VendorDataList.cs b/server/AyaNova/DataList/VendorDataList.cs index 1574269a..23f4ba6a 100644 --- a/server/AyaNova/DataList/VendorDataList.cs +++ b/server/AyaNova/DataList/VendorDataList.cs @@ -57,6 +57,14 @@ namespace AyaNova.DataList SqlValueColumnName = "avendor.webaddress" }); + FieldDefinitions.Add(new DataListFieldDefinition + { + TKey = "VendorAlertNotes", + FieldKey = "VendorAlertNotes", + UiFieldDataType = (int)UiFieldDataType.Text, + SqlValueColumnName = "avendor.alertnotes" + }); + FieldDefinitions.Add(new DataListFieldDefinition { TKey = "VendorAccountNumber", diff --git a/server/AyaNova/biz/CustomerBiz.cs b/server/AyaNova/biz/CustomerBiz.cs index 566af5e8..1614fbf1 100644 --- a/server/AyaNova/biz/CustomerBiz.cs +++ b/server/AyaNova/biz/CustomerBiz.cs @@ -222,7 +222,7 @@ namespace AyaNova.Biz .AddText(obj.Wiki) .AddText(obj.Tags) .AddText(obj.WebAddress) - .AddText(obj.PopUpNotes) + .AddText(obj.AlertNotes) .AddText(obj.TechNotes) .AddText(obj.AccountNumber) .AddText(obj.Phone1) diff --git a/server/AyaNova/biz/FormFieldReference.cs b/server/AyaNova/biz/FormFieldReference.cs index 4f827f9b..a39b5fe9 100644 --- a/server/AyaNova/biz/FormFieldReference.cs +++ b/server/AyaNova/biz/FormFieldReference.cs @@ -139,7 +139,7 @@ namespace AyaNova.Biz //l.Add(new FormField { TKey = "UsesBanking", FieldKey = "UsesBanking" }); l.Add(new FormField { TKey = "CustomerNotes", FieldKey = "Notes" }); l.Add(new FormField { TKey = "CustomerTechNotes", FieldKey = "TechNotes" }); - l.Add(new FormField { TKey = "AlertNotes", FieldKey = "PopUpNotes" }); + l.Add(new FormField { TKey = "AlertNotes", FieldKey = "AlertNotes" }); l.Add(new FormField { TKey = "Tags", FieldKey = "Tags" }); l.Add(new FormField { TKey = "Wiki", FieldKey = "Wiki" }); l.Add(new FormField { TKey = "Attachments", FieldKey = "Attachments" }); @@ -779,7 +779,7 @@ namespace AyaNova.Biz l.Add(new FormField { TKey = "VendorContact", FieldKey = "Contact" }); l.Add(new FormField { TKey = "VendorNotes", FieldKey = "Notes" }); l.Add(new FormField { TKey = "VendorContactNotes", FieldKey = "ContactNotes" }); - l.Add(new FormField { TKey = "AlertNotes", FieldKey = "PopUpNotes" }); + l.Add(new FormField { TKey = "AlertNotes", FieldKey = "AlertNotes" }); l.Add(new FormField { TKey = "Tags", FieldKey = "Tags" }); l.Add(new FormField { TKey = "Wiki", FieldKey = "Wiki" }); l.Add(new FormField { TKey = "Attachments", FieldKey = "Attachments" }); diff --git a/server/AyaNova/biz/PMBiz.cs b/server/AyaNova/biz/PMBiz.cs index aeef4d6b..b311cc86 100644 --- a/server/AyaNova/biz/PMBiz.cs +++ b/server/AyaNova/biz/PMBiz.cs @@ -859,9 +859,9 @@ namespace AyaNova.Biz await ItemPopulateVizFields(v, populateForReporting); } - //popup Alert notes + //Alert notes //Customer notes first then others below - var custInfo = await ct.Customer.AsNoTracking().Where(x => x.Id == o.CustomerId).Select(x => new { AlertViz = x.PopUpNotes, x.TechNotes, CustomerViz = x.Name }).FirstOrDefaultAsync(); + var custInfo = await ct.Customer.AsNoTracking().Where(x => x.Id == o.CustomerId).Select(x => new { AlertViz = x.AlertNotes, x.TechNotes, CustomerViz = x.Name }).FirstOrDefaultAsync(); if (!string.IsNullOrWhiteSpace(custInfo.AlertViz)) { o.AlertViz = $"{await Translate("Customer")} - {await Translate("AlertNotes")}\n{custInfo.AlertViz}\n\n"; diff --git a/server/AyaNova/biz/PurchaseOrderBiz.cs b/server/AyaNova/biz/PurchaseOrderBiz.cs index ce51ef44..dba4fdec 100644 --- a/server/AyaNova/biz/PurchaseOrderBiz.cs +++ b/server/AyaNova/biz/PurchaseOrderBiz.cs @@ -142,6 +142,7 @@ namespace AyaNova.Biz var vnd = await ct.Vendor.AsNoTracking().Where(x => x.Id == po.VendorId).FirstOrDefaultAsync(); po.VendorViz = vnd.Name; + po.VendorAlertNotesViz = vnd.AlertNotes; if (forReporting) { po.VendorAddressViz = vnd.Address; @@ -164,7 +165,7 @@ namespace AyaNova.Biz po.VendorContactViz = vnd.Contact; po.VendorContactNotesViz = vnd.ContactNotes; - po.VendorPopUpNotesViz = vnd.PopUpNotes; + po.VendorAccountNumberViz = vnd.AccountNumber; } diff --git a/server/AyaNova/biz/QuoteBiz.cs b/server/AyaNova/biz/QuoteBiz.cs index 68589d95..cb5d91df 100644 --- a/server/AyaNova/biz/QuoteBiz.cs +++ b/server/AyaNova/biz/QuoteBiz.cs @@ -838,9 +838,9 @@ namespace AyaNova.Biz await ItemPopulateVizFields(v, populateForReporting); } - //popup Alert notes + //Alert notes //Customer notes first then others below - var custInfo = await ct.Customer.AsNoTracking().Where(x => x.Id == o.CustomerId).Select(x => new { AlertViz = x.PopUpNotes, x.TechNotes, CustomerViz = x.Name }).FirstOrDefaultAsync(); + var custInfo = await ct.Customer.AsNoTracking().Where(x => x.Id == o.CustomerId).Select(x => new { AlertViz = x.AlertNotes, x.TechNotes, CustomerViz = x.Name }).FirstOrDefaultAsync(); if (!string.IsNullOrWhiteSpace(custInfo.AlertViz)) { o.AlertViz = $"{await Translate("Customer")} - {await Translate("AlertNotes")}\n{custInfo.AlertViz}\n\n"; diff --git a/server/AyaNova/biz/VendorBiz.cs b/server/AyaNova/biz/VendorBiz.cs index 919ca5d4..1aa244a7 100644 --- a/server/AyaNova/biz/VendorBiz.cs +++ b/server/AyaNova/biz/VendorBiz.cs @@ -206,7 +206,7 @@ namespace AyaNova.Biz .AddText(obj.WebAddress) .AddText(obj.Contact) .AddText(obj.ContactNotes) - .AddText(obj.PopUpNotes) + .AddText(obj.AlertNotes) .AddText(obj.AccountNumber) .AddText(obj.Phone1) .AddText(obj.Phone2) diff --git a/server/AyaNova/biz/WorkOrderBiz.cs b/server/AyaNova/biz/WorkOrderBiz.cs index 036e2820..ae6c770d 100644 --- a/server/AyaNova/biz/WorkOrderBiz.cs +++ b/server/AyaNova/biz/WorkOrderBiz.cs @@ -953,9 +953,9 @@ namespace AyaNova.Biz await ItemPopulateVizFields(v, populateForReporting); } - //popup Alert notes + //Alert notes //Customer notes first then others below - var custInfo = await ct.Customer.AsNoTracking().Where(x => x.Id == o.CustomerId).Select(x => new { AlertViz = x.PopUpNotes, x.TechNotes, CustomerViz = x.Name }).FirstOrDefaultAsync(); + var custInfo = await ct.Customer.AsNoTracking().Where(x => x.Id == o.CustomerId).Select(x => new { AlertViz = x.AlertNotes, x.TechNotes, CustomerViz = x.Name }).FirstOrDefaultAsync(); if (!string.IsNullOrWhiteSpace(custInfo.AlertViz)) { o.AlertViz = $"{await Translate("Customer")} - {await Translate("AlertNotes")}\n{custInfo.AlertViz}\n\n"; diff --git a/server/AyaNova/models/Customer.cs b/server/AyaNova/models/Customer.cs index c9a1fd07..1b9b4291 100644 --- a/server/AyaNova/models/Customer.cs +++ b/server/AyaNova/models/Customer.cs @@ -27,7 +27,7 @@ namespace AyaNova.Models //cant use these due to import v7 malformed shit adn can't be arsed to deal with that //[Url] public string WebAddress { get; set; } - public string PopUpNotes { get; set; } + public string AlertNotes { get; set; } public bool BillHeadOffice { get; set; } public long? HeadOfficeId { get; set; } [NotMapped] diff --git a/server/AyaNova/models/PurchaseOrder.cs b/server/AyaNova/models/PurchaseOrder.cs index b403ed24..a1a49db2 100644 --- a/server/AyaNova/models/PurchaseOrder.cs +++ b/server/AyaNova/models/PurchaseOrder.cs @@ -127,7 +127,7 @@ namespace AyaNova.Models public string VendorEmailAddressViz { get; set; } [NotMapped] - public string VendorPopUpNotesViz { get; set; } + public string VendorAlertNotesViz { get; set; } [NotMapped] public string VendorAccountNumberViz { get; set; } diff --git a/server/AyaNova/models/Vendor.cs b/server/AyaNova/models/Vendor.cs index 622dc337..a4541861 100644 --- a/server/AyaNova/models/Vendor.cs +++ b/server/AyaNova/models/Vendor.cs @@ -25,7 +25,7 @@ namespace AyaNova.Models public string Contact { get; set; } public string ContactNotes { get; set; } - public string PopUpNotes { get; set; } + public string AlertNotes { get; set; } public string WebAddress { get; set; } public string AccountNumber { get; set; } public string Phone1 { get; set; } diff --git a/server/AyaNova/resource/de.json b/server/AyaNova/resource/de.json index 14b19120..e8eaa97b 100644 --- a/server/AyaNova/resource/de.json +++ b/server/AyaNova/resource/de.json @@ -65,7 +65,7 @@ "CustomerPhone3": "Home", "CustomerPhone4": "Mobile", "CustomerPhone5": "Pager", - "CustomerPopUpNotes": "Popup-Notizen", + "CustomerAlertNotes": "Warnhinweise", "CustomerTechNotes": "Planbare Benutzer - Anmerkungen", "CustomerGroupDescription": "Beschreibung", "CustomerGroupList": "Kundengruppen", @@ -2094,7 +2094,7 @@ "PasswordResetMessageBody": "Hallo {user_name},\n\nIhr Online-Konto für den Dienst steht Ihnen nach dem Festlegen Ihres Kennworts zur Verfügung.\nSie können den Kennwort für die nächsten 48 Stunden über den folgenden Link festlegen.\n\nStellen Sie Ihr Kennwort ein: {action_link}\n\nWenn Sie kein Zurücksetzen des Kontos oder Kennworts angefordert haben, ignorieren Sie diese E-Mail.\n\nDanke,\n{registered_to}", "SendPasswordResetCode": "E-Mail zum Zurücksetzen des Passworts senden", "CopyToClipboard": "In die Zwischenablage kopieren", - "VendorPopUpNotes": "Popup-Notizen", + "VendorAlertNotes": "Warnhinweise", "EraseMultipleObjectsWarning": "Warnung: Sie sind dabei, mehrere Objekte dauerhaft zu löschen.\nBist du sicher?", "Errors": "Fehler", "BatchDeleteJob": "Batch-Löschauftrag", diff --git a/server/AyaNova/resource/en.json b/server/AyaNova/resource/en.json index 391bb3e9..a764d83a 100644 --- a/server/AyaNova/resource/en.json +++ b/server/AyaNova/resource/en.json @@ -65,7 +65,7 @@ "CustomerPhone3": "Home", "CustomerPhone4": "Mobile", "CustomerPhone5": "Pager", - "CustomerPopUpNotes": "Alert notes", + "CustomerAlertNotes": "Alert notes", "CustomerTechNotes": "Scheduleable User Notes", "CustomerGroupDescription": "Description", "CustomerGroupList": "Customer Groups", @@ -2094,7 +2094,7 @@ "PasswordResetMessageBody": "Hello {user_name},\n\nYour online account for service is available to you after you set your password.\nYou can use the following link for the next 48 hours to set your password.\n\nSet your password: {action_link}\n\nIf you did not request an account or password reset, please ignore this email.\n\nThanks,\n{registered_to}", "SendPasswordResetCode": "Send password reset email", "CopyToClipboard": "Copy to clipboard", - "VendorPopUpNotes": "Alert notes", + "VendorAlertNotes": "Alert notes", "EraseMultipleObjectsWarning": "Warning: you are about to permanently erase multiple objects.\r\nAre you sure?", "Errors": "Errors", "BatchDeleteJob": "Batch delete job", diff --git a/server/AyaNova/resource/es.json b/server/AyaNova/resource/es.json index 1d76ad9e..5b2d7c7b 100644 --- a/server/AyaNova/resource/es.json +++ b/server/AyaNova/resource/es.json @@ -65,7 +65,7 @@ "CustomerPhone3": "Home", "CustomerPhone4": "Mobile", "CustomerPhone5": "Pager", - "CustomerPopUpNotes": "Notas emergentes", + "CustomerAlertNotes": "Notas emergentes", "CustomerTechNotes": "Notas usuario programable", "CustomerGroupDescription": "Descripción", "CustomerGroupList": "Grupos de clientes", @@ -2094,7 +2094,7 @@ "PasswordResetMessageBody": "Hola, {user_name}:\n\nTu cuenta en línea para el servicio estará disponible después de que establezcas tu contraseña.\nPuedes usar el siguiente enlace durante las próximas 48 horas para establecer tu contraseña.\n\nConfigura tu contraseña: {action_link}\n\nSi no solicitó un restablecimiento de cuenta o contraseña, ignore este correo electrónico.\n\nGracias,\n{registered_to}", "SendPasswordResetCode": "Enviar correo electrónico de restablecimiento de contraseña", "CopyToClipboard": "Copiar al Portapapeles", - "VendorPopUpNotes": "Notas emergentes", + "VendorAlertNotes": "Notas emergentes", "EraseMultipleObjectsWarning": "Advertencia: está a punto de borrar de forma permanente varios objetos.\n¿Estás seguro?", "Errors": "Errores", "BatchDeleteJob": "Trabajo de eliminación por lotes", diff --git a/server/AyaNova/resource/fr.json b/server/AyaNova/resource/fr.json index 3b83538c..8374484f 100644 --- a/server/AyaNova/resource/fr.json +++ b/server/AyaNova/resource/fr.json @@ -65,7 +65,7 @@ "CustomerPhone3": "Home", "CustomerPhone4": "Mobile", "CustomerPhone5": "Pager", - "CustomerPopUpNotes": "Notes contextuelles", + "CustomerAlertNotes": "Notes contextuelles", "CustomerTechNotes": "Notes d'utilisateur programmable", "CustomerGroupDescription": "Description", "CustomerGroupList": "Groupes de clients", @@ -2094,7 +2094,7 @@ "PasswordResetMessageBody": "Bonjour {user_name},\n\nVotre compte de service en ligne est disponible une fois que vous avez défini votre mot de passe.\nVous pouvez utiliser le lien suivant pendant les 48 prochaines heures pour définir votre mot de passe.\n\nDéfinissez votre mot de passe: {action_link}\n\nSi vous n'avez pas demandé de réinitialisation de compte ou de mot de passe, veuillez ignorer cet e-mail.\n\nMerci,\n{registered_to}", "SendPasswordResetCode": "Envoyer un e-mail de réinitialisation du mot de passe", "CopyToClipboard": "Copier dans le Presse-papiers", - "VendorPopUpNotes": "Notes contextuelles", + "VendorAlertNotes": "Notes contextuelles", "EraseMultipleObjectsWarning": "Attention: vous êtes sur le point d'effacer définitivement plusieurs objets.\nÊtes-vous sûr?", "Errors": "les erreurs", "BatchDeleteJob": "Tâche de suppression par lots", diff --git a/server/AyaNova/util/AySchema.cs b/server/AyaNova/util/AySchema.cs index 14b53b65..c7669f0b 100644 --- a/server/AyaNova/util/AySchema.cs +++ b/server/AyaNova/util/AySchema.cs @@ -599,7 +599,7 @@ $BODY$ LANGUAGE PLPGSQL STABLE"); //CUSTOMER await ExecQueryAsync("CREATE TABLE acustomer (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL UNIQUE, active BOOL NOT NULL, " + "notes TEXT, wiki TEXT, customfields TEXT, tags VARCHAR(255) ARRAY, " - + "webaddress TEXT, popupnotes TEXT, billheadoffice BOOL, technotes TEXT, accountnumber TEXT, contractexpires TIMESTAMP NULL, contractid BIGINT NULL REFERENCES acontract(id), " + + "webaddress TEXT, alertnotes TEXT, billheadoffice BOOL, technotes TEXT, accountnumber TEXT, contractexpires TIMESTAMP NULL, contractid BIGINT NULL REFERENCES acontract(id), " + "phone1 TEXT, phone2 TEXT, phone3 TEXT, phone4 TEXT, phone5 TEXT, emailaddress TEXT, " + "postaddress TEXT, postcity TEXT, postregion TEXT, postcountry TEXT, postcode TEXT, address TEXT, city TEXT, region TEXT, country TEXT, latitude DECIMAL(9,6), longitude DECIMAL(9,6), " + "CONSTRAINT chk_contract_valid CHECK((contractid IS NULL) OR (contractid IS NOT NULL AND contractexpires IS NOT NULL)) " @@ -646,7 +646,7 @@ $BODY$ LANGUAGE PLPGSQL STABLE"); //VENDOR await ExecQueryAsync("CREATE TABLE avendor (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL UNIQUE, active BOOL NOT NULL, " - + "notes TEXT, wiki TEXT, customfields TEXT, tags VARCHAR(255) ARRAY, webaddress TEXT, popupnotes TEXT, accountnumber TEXT, " + + "notes TEXT, wiki TEXT, customfields TEXT, tags VARCHAR(255) ARRAY, webaddress TEXT, alertnotes TEXT, accountnumber TEXT, " + "contact TEXT, contactnotes TEXT, phone1 TEXT, phone2 TEXT, phone3 TEXT, phone4 TEXT, phone5 TEXT, emailaddress TEXT, " + "postaddress TEXT, postcity TEXT, postregion TEXT, postcountry TEXT, postcode TEXT, address TEXT, city TEXT, region TEXT, country TEXT, latitude DECIMAL(9,6), longitude DECIMAL(9,6))"); await ExecQueryAsync("ALTER TABLE auser ADD FOREIGN KEY (vendorid) REFERENCES avendor(id)");