File manager - Edit - G:/PleskVhosts/indiaminerals.in/tlt.INFOFIXDEVELOPERS.COM/admin/godwnhamali.aspx.cs
Back
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using WebApp.LIBS; using Business; namespace WebApp.admin { public partial class godwnhamali : BasePageClass { protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { fromDate.Text = Common.DateTimeNow().AddDays(-30).ToString("dd/MM/yyyy"); ToDate.Text = Common.DateTimeNow().ToString("dd/MM/yyyy"); if (fromDate.Text.Length > 0 && ToDate.Text.Length > 0) { var fdate = Common.DateConvertMultimatch(fromDate.Text); var tdate = Common.DateConvertMultimatch(ToDate.Text); int CompId = SiteSession.CompnayId; var sale = Global.Context.ExecuteStoreQuery<hamalimodal>("select LocationName,SUM(isnull(Hamali,0)) as Hamali from (select Location.LocationName,isnull(Hamali,0) as Hamali from Sale,Location where Sale.LocationId=Location.LocationId and [Date] between '" + fdate.ToString("dd-MMM-yyyy") + "' and '" + tdate.ToString("dd-MMM-yyyy") + "' and CompnayId=" + CompId + " and len(ISNULL(CalcFormula,''))>0 union all select Location.LocationName, isnull(Hamali,0) as Hamali from Salerate,Location where Salerate.LocationId=Location.LocationId and [Date] between '" + fdate.ToString("dd-MMM-yyyy") + "' and '" + tdate.ToString("dd-MMM-yyyy") + "' and CompnayId=" + CompId + " and len(ISNULL(CalcFormula,''))>0) as x group by LocationName ").ToList(); Common.BindControl(gvcompnay, sale.ToList().OrderByDescending(p => p.LocationName).ToList()); try { gvcompnay.FooterRow.Cells[2].Text = sale.Sum(p => (p.Hamali.HasValue ? p.Hamali.Value : 0.00m)).ToString(); } catch { } } } } protected void savecompnay_Click(object sender, EventArgs e) { if (fromDate.Text.Length > 0 && ToDate.Text.Length > 0) { var fdate = Common.DateConvertMultimatch(fromDate.Text); var tdate = Common.DateConvertMultimatch(ToDate.Text); int CompId = SiteSession.CompnayId; var sale = Global.Context.ExecuteStoreQuery<hamalimodal>("select LocationName,SUM(isnull(Hamali,0)) as Hamali from (select Location.LocationName,isnull(Hamali,0) as Hamali from Sale,Location where Sale.LocationId=Location.LocationId and [Date] between '" + fdate.ToString("dd-MMM-yyyy") + "' and '" + tdate.ToString("dd-MMM-yyyy") + "' and CompnayId=" + CompId + " and len(ISNULL(CalcFormula,''))>0 union all select Location.LocationName, isnull(Hamali,0) as Hamali from Salerate,Location where Salerate.LocationId=Location.LocationId and [Date] between '" + fdate.ToString("dd-MMM-yyyy") + "' and '" + tdate.ToString("dd-MMM-yyyy") + "' and CompnayId=" + CompId + " and len(ISNULL(CalcFormula,''))>0) as x group by LocationName ").ToList(); Common.BindControl(gvcompnay, sale.ToList().OrderByDescending(p => p.LocationName).ToList()); try { gvcompnay.FooterRow.Cells[2].Text = sale.Sum(p => (p.Hamali.HasValue ? p.Hamali.Value : 0.00m)).ToString(); } catch { } } } } }
| ver. 1.4 |
Github
|
.
| PHP 7.3.33 | Generation time: 0.04 |
proxy
|
phpinfo
|
Settings