From 0ca21ebbb7887d99544110a8553ffaf6a3f33ddd Mon Sep 17 00:00:00 2001 From: michele Date: Mon, 8 Apr 2024 14:49:51 +0200 Subject: [PATCH] Michele: Modifiche property Model + modifiche label Dati azienda --- Models/DatiAzienda.cs | 8 +++++++- Models/DatiAziendaTable.cs | 6 +++--- Views/DatiAzienda/Create.cshtml | 14 +++++++++----- Views/DatiAzienda/Edit.cshtml | 11 +++++++---- Views/DatiAzienda/Index.cshtml | 2 +- 5 files changed, 27 insertions(+), 14 deletions(-) diff --git a/Models/DatiAzienda.cs b/Models/DatiAzienda.cs index d62cdd4..1706b21 100644 --- a/Models/DatiAzienda.cs +++ b/Models/DatiAzienda.cs @@ -1,22 +1,28 @@ -namespace VirtualTask.Models +using System.ComponentModel.DataAnnotations; + +namespace VirtualTask.Models { public class DatiAzienda { /// azienda public string? azienda { get; set; } + [Display(Name = "Tecnico")] /// tecnico public string? tecnico { get; set; } + [Display(Name = "Ragione Sociale")] /// Denominazione public string? ragsoc { get; set; } /// url del logo esposto public string? url_logo { get; set; } + [Display(Name = "Intestazione Logo")] /// logo public IFormFile? logo { get; set; } + [Display(Name = "Testo")] /// testo azienda rapportino public string? testo_buono { get; set; } } diff --git a/Models/DatiAziendaTable.cs b/Models/DatiAziendaTable.cs index 8334fa8..a2b45aa 100644 --- a/Models/DatiAziendaTable.cs +++ b/Models/DatiAziendaTable.cs @@ -13,7 +13,7 @@ namespace VirtualTask.Models public string? tecnico { get; set; } [Required] - [Display(Name = "Rag. Sociale")] + [Display(Name = "Ragione Sociale")] public string? ragsoc { get; set; } [Display(Name = "Url")] @@ -21,12 +21,12 @@ namespace VirtualTask.Models public string? url_logo { get; set; } [Required] - [Display(Name = "Logo")] + [Display(Name = "Intestazione Logo")] /// logo public byte[]? logo { get; set; } [Required] - [Display(Name = "Testo Rapportino")] + [Display(Name = "Testo")] /// testo azienda rapportino public string? testo_buono { get; set; } diff --git a/Views/DatiAzienda/Create.cshtml b/Views/DatiAzienda/Create.cshtml index e840b42..3d5fefe 100644 --- a/Views/DatiAzienda/Create.cshtml +++ b/Views/DatiAzienda/Create.cshtml @@ -1,7 +1,7 @@ @model VirtualTask.Models.DatiAzienda @{ - ViewData["Title"] = "Nuova azienda"; + ViewData["Title"] = "Nuova Intestazione Buoni Intervento"; Layout = "~/Views/Shared/_LayoutAreaRiservata.cshtml"; }
@@ -15,26 +15,30 @@ @Html.HiddenFor(x => x.azienda) @Html.HiddenFor(x => x.url_logo)
- +
@Html.DropDownListFor(x =>x.tecnico,(IEnumerable)ViewBag.AllTecnici,new {@class = "form-control"})
+
 
- +
+
 
- +
+
 
- +
@**@
+
 
Torna alla lista diff --git a/Views/DatiAzienda/Edit.cshtml b/Views/DatiAzienda/Edit.cshtml index d4dbb32..a792f53 100644 --- a/Views/DatiAzienda/Edit.cshtml +++ b/Views/DatiAzienda/Edit.cshtml @@ -17,17 +17,19 @@ @Html.HiddenFor(x => x.logo)
- +
@Html.DropDownListFor(x => x.tecnico,(IEnumerable)ViewBag.AllTecnici, new {@class = "form-control"})
+
 
- +
+
 
- +
@{ byte[] appo = Model.logo; var base64 = Convert.ToBase64String(appo); @@ -37,8 +39,9 @@
+
 
- +
diff --git a/Views/DatiAzienda/Index.cshtml b/Views/DatiAzienda/Index.cshtml index f50cf65..3ca2905 100644 --- a/Views/DatiAzienda/Index.cshtml +++ b/Views/DatiAzienda/Index.cshtml @@ -1,7 +1,7 @@ @model IEnumerable @{ - ViewData["Title"] = "Dati Azienda"; + ViewData["Title"] = "Intestazione Buoni Intervento"; Layout = "~/Views/Shared/_LayoutAreaRiservata.cshtml"; }