Files
2021-03-26 17:17:28 +01:00

88 lines
1.8 KiB
C#

using GPW_data;
using SteamWare;
using System;
using System.Configuration;
using System.Web.UI;
namespace GPW_Smart.WebUserControls
{
public partial class cmp_info : System.Web.UI.UserControl
{
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
lblInstallation.Text = licenzeGPW.installazione;
lblApplication.Text = licenzeGPW.applicazione;
lblNumLic.Text = string.Format("{1} ({0} disp)", licenzeGPW.licenzeAttive, licenzeGPW.licenzeDb);
lblNumLic.ToolTip = "licenze valide (licenze su db)";
lblExpiryDate.Text = licenzeGPW.scadenzaLicenza.ToShortDateString();
lblAuthKey.Text = licenzeGPW.authKey;
}
}
public string cssCheckClass
{
get
{
string answ = "";
if (licenzeGPW.scadenzaLicenza >= DateTime.Now)
{
answ = "border-success";
}
else
{
answ = "border-danger";
}
return answ;
}
}
public string hashEmail
{
get
{
return memLayer.ML.StringSessionObj("hashEmail");
}
}
public string email
{
get
{
return memLayer.ML.StringSessionObj("email");
}
}
public string cognomeNome
{
get
{
return memLayer.ML.StringSessionObj("cognomeNome");
}
}
public string IP
{
get
{
return Request.UserHostName;
}
}
public string versione
{
get
{
return string.Format("{0} v.{1}", ConfigurationManager.AppSettings.Get("appName"), System.Reflection.Assembly.GetExecutingAssembly().GetName().Version);
}
}
public string copyRight
{
get
{
return string.Format("{0}", ConfigurationManager.AppSettings.Get("copyRight"));
}
}
}
}