michele: controllo email
This commit is contained in:
parent
3ca93847c9
commit
a90d7ff2e8
@ -463,7 +463,6 @@ namespace VirtualTask.Controllers
|
|||||||
helper.SetStringValue("errMsg", errMes);
|
helper.SetStringValue("errMsg", errMes);
|
||||||
return RedirectToAction("Error");
|
return RedirectToAction("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion DELETE
|
#endregion DELETE
|
||||||
@ -509,6 +508,7 @@ namespace VirtualTask.Controllers
|
|||||||
}
|
}
|
||||||
return seriale;
|
return seriale;
|
||||||
}
|
}
|
||||||
|
|
||||||
private async void updateSeriale(Progressivo p)
|
private async void updateSeriale(Progressivo p)
|
||||||
{
|
{
|
||||||
SessionHelper helper = new SessionHelper(this);
|
SessionHelper helper = new SessionHelper(this);
|
||||||
@ -840,31 +840,31 @@ namespace VirtualTask.Controllers
|
|||||||
update.val_prog = p;
|
update.val_prog = p;
|
||||||
update.tipo_prog = _sercomm;
|
update.tipo_prog = _sercomm;
|
||||||
update.azienda = tenant;
|
update.azienda = tenant;
|
||||||
UpdateSeriale(update);
|
updateSeriale(update);
|
||||||
}
|
}
|
||||||
return seriale;
|
return seriale;
|
||||||
}
|
}
|
||||||
|
|
||||||
private async void UpdateSeriale(Progressivo p)
|
//private async void UpdateSeriale(Progressivo p)
|
||||||
{
|
//{
|
||||||
SessionHelper helper = new SessionHelper(this);
|
// SessionHelper helper = new SessionHelper(this);
|
||||||
token = helper.GetStringValue("tok");
|
// token = helper.GetStringValue("tok");
|
||||||
apiUrl = helper.GetStringValue("apiUrl");
|
// apiUrl = helper.GetStringValue("apiUrl");
|
||||||
tenant = helper.GetStringValue("tenant");
|
// tenant = helper.GetStringValue("tenant");
|
||||||
urlBase = apiUrl + "progressivo/mod";
|
// urlBase = apiUrl + "progressivo/mod";
|
||||||
urlBase = urlBase + "?token=" + token;
|
// urlBase = urlBase + "?token=" + token;
|
||||||
|
|
||||||
client = new HttpClient();
|
// client = new HttpClient();
|
||||||
|
|
||||||
var stringPayload = JsonConvert.SerializeObject(p);
|
// var stringPayload = JsonConvert.SerializeObject(p);
|
||||||
var httpContent = new StringContent(stringPayload, Encoding.UTF8, "application/json");
|
// var httpContent = new StringContent(stringPayload, Encoding.UTF8, "application/json");
|
||||||
var httpResponse = await client.PostAsync(urlBase, httpContent);
|
// var httpResponse = await client.PostAsync(urlBase, httpContent);
|
||||||
|
|
||||||
if (httpResponse.Content != null)
|
// if (httpResponse.Content != null)
|
||||||
{
|
// {
|
||||||
var responseContent = await httpResponse.Content.ReadAsStringAsync();
|
// var responseContent = await httpResponse.Content.ReadAsStringAsync();
|
||||||
}
|
// }
|
||||||
}
|
//}
|
||||||
|
|
||||||
#endregion altri metodi
|
#endregion altri metodi
|
||||||
|
|
||||||
|
|||||||
@ -19,6 +19,7 @@ namespace VirtualTask.Models
|
|||||||
|
|
||||||
[Display(Name = "Email")]
|
[Display(Name = "Email")]
|
||||||
[StringLength(254)]
|
[StringLength(254)]
|
||||||
|
[RegularExpression("^[a-zA-Z0-9_\\.-]+@([a-zA-Z0-9-]+\\.)+[a-zA-Z]{2,6}$", ErrorMessage = "formato campo Email non valido")]
|
||||||
/// <summary>email</summary>
|
/// <summary>email</summary>
|
||||||
public string? an_email { get; set; }
|
public string? an_email { get; set; }
|
||||||
|
|
||||||
@ -49,6 +50,7 @@ namespace VirtualTask.Models
|
|||||||
|
|
||||||
[Display(Name = "Pec")]
|
[Display(Name = "Pec")]
|
||||||
[StringLength(254)]
|
[StringLength(254)]
|
||||||
|
[RegularExpression("^[a-zA-Z0-9_\\.-]+@([a-zA-Z0-9-]+\\.)+[a-zA-Z]{2,6}$", ErrorMessage = "formato campo Email non valido")]
|
||||||
/// <summary>pec</summary>
|
/// <summary>pec</summary>
|
||||||
public string? an_empec { get; set; }
|
public string? an_empec { get; set; }
|
||||||
|
|
||||||
|
|||||||
@ -5,14 +5,17 @@ namespace VirtualTask.Models
|
|||||||
public class AziendaRif
|
public class AziendaRif
|
||||||
{
|
{
|
||||||
[Display(Name = "Azienda")]
|
[Display(Name = "Azienda")]
|
||||||
|
[StringLength(5)]
|
||||||
/// <summary>azienda</summary>
|
/// <summary>azienda</summary>
|
||||||
public string? piazihoc { get; set; }
|
public string? piazihoc { get; set; }
|
||||||
|
|
||||||
[Display(Name = "Cod. Tecnico")]
|
[Display(Name = "Cod. Tecnico")]
|
||||||
|
[StringLength(15)]
|
||||||
/// <summary>tecnico</summary>
|
/// <summary>tecnico</summary>
|
||||||
public string? picodtec { get; set; }
|
public string? picodtec { get; set; }
|
||||||
|
|
||||||
[Display(Name = "tecnico")]
|
[Display(Name = "tecnico")]
|
||||||
|
[StringLength(5)]
|
||||||
/// <summary>tecnico</summary>
|
/// <summary>tecnico</summary>
|
||||||
public string? pirifazi { get; set; }
|
public string? pirifazi { get; set; }
|
||||||
|
|
||||||
|
|||||||
@ -11,7 +11,6 @@ namespace VirtualTask.Models
|
|||||||
|
|
||||||
[StringLength(15)]
|
[StringLength(15)]
|
||||||
[Display(Name = "Codice"), Required(ErrorMessage = "Inserire codice chiamata")]
|
[Display(Name = "Codice"), Required(ErrorMessage = "Inserire codice chiamata")]
|
||||||
|
|
||||||
public string? cccodice { get; set; }
|
public string? cccodice { get; set; }
|
||||||
|
|
||||||
[StringLength(50)]
|
[StringLength(50)]
|
||||||
|
|||||||
@ -11,19 +11,16 @@ namespace VirtualTask.Models
|
|||||||
|
|
||||||
public string? lacodazi { get; set; }
|
public string? lacodazi { get; set; }
|
||||||
|
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[StringLength(15)]
|
[StringLength(15)]
|
||||||
[Display(Name = "Codice Commessa")]
|
[Display(Name = "Codice Commessa")]
|
||||||
public string? lacodcom { get; set; }
|
public string? lacodcom { get; set; }
|
||||||
|
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[StringLength(40)]
|
[StringLength(40)]
|
||||||
[Display(Name = "Fase Commessa")]
|
[Display(Name = "Fase Commessa")]
|
||||||
public string? ladeslav { get; set; }
|
public string? ladeslav { get; set; }
|
||||||
|
|
||||||
|
|
||||||
[Display(Name = "Data fine commessa")]
|
[Display(Name = "Data fine commessa")]
|
||||||
public DateTime? ladatchi { get; set; }
|
public DateTime? ladatchi { get; set; }
|
||||||
|
|
||||||
|
|||||||
@ -62,11 +62,9 @@ namespace VirtualTask.Models
|
|||||||
/// <summary> Provincia </summary>
|
/// <summary> Provincia </summary>
|
||||||
[Display(Name = "Provincia")]
|
[Display(Name = "Provincia")]
|
||||||
[StringLength(2)]
|
[StringLength(2)]
|
||||||
|
|
||||||
public string? improvin { get; set; }
|
public string? improvin { get; set; }
|
||||||
|
|
||||||
[Display(Name = "Cliente"), Required(ErrorMessage = "Selezionare un cliente")]
|
[Display(Name = "Cliente"), Required(ErrorMessage = "Selezionare un cliente")]
|
||||||
|
|
||||||
/// <summary> cliente associato </summary>
|
/// <summary> cliente associato </summary>
|
||||||
public string? imultcli { get; set; }
|
public string? imultcli { get; set; }
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user