68 lines
2.2 KiB
C#
68 lines
2.2 KiB
C#
using SteamWare;
|
|
using System;
|
|
using System.Web.UI;
|
|
|
|
namespace MoonPro.WebUserControls
|
|
{
|
|
public partial class mod_AnPro_DettArt : SteamWare.UserControl
|
|
{
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
if (!Page.IsPostBack)
|
|
{
|
|
mod_righePag.numRowPag = Convert.ToInt32(memLayer.ML.CRI("_righeDataGridMed") / 2);
|
|
grView.PageSize = mod_righePag.numRowPag;
|
|
}
|
|
mod_righePag.eh_newNum += Mod_righePag_eh_newNum;
|
|
}
|
|
/// <summary>
|
|
/// aggiorno numero righe da mostrare
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void Mod_righePag_eh_newNum(object sender, EventArgs e)
|
|
{
|
|
grView.PageSize = mod_righePag.numRowPag;
|
|
}
|
|
/// <summary>
|
|
/// aggiorna visualizzazione
|
|
/// </summary>
|
|
/// <param name="IdxMacchina">Macchina</param>
|
|
/// <param name="CodArticolo">Articolo</param>
|
|
/// <param name="OdlChiusi">Si/No ODL già conclusi</param>
|
|
/// <param name="OdlAperti">Si/No ODL in corso</param>
|
|
/// <param name="OdlNew">Si/No ODL da attrezzare</param>
|
|
public void doUpdate(string IdxMacchina, string CodArticolo, bool OdlChiusi, bool OdlAperti, bool OdlNew)
|
|
{
|
|
hfIdxMacchina.Value = IdxMacchina;
|
|
hfCodArticolo.Value = CodArticolo;
|
|
hfClosed.Value = OdlChiusi.ToString();
|
|
hfOpen.Value = OdlAperti.ToString();
|
|
hfNew.Value = OdlNew.ToString();
|
|
grView.DataBind();
|
|
}
|
|
/// <summary>
|
|
/// formato grafico post verifica qta > 0
|
|
/// </summary>
|
|
/// <param name="qty"></param>
|
|
/// <returns></returns>
|
|
public string cssFromQty(object qty)
|
|
{
|
|
string answ = "";
|
|
if (Convert.ToInt32(qty) >= 0)
|
|
{
|
|
answ = "valOk";
|
|
}
|
|
else
|
|
{
|
|
answ = "valKo";
|
|
}
|
|
return answ;
|
|
}
|
|
|
|
public string cssByStato(object stato)
|
|
{
|
|
return string.Format("css_{0}", stato); ;
|
|
}
|
|
}
|
|
} |