示例#1
0
        public static HORep_ManageResultString SaveHOReplenishment(NameValueCollection querystring, NameValueCollection formdata)
        {
            int     intParser;
            decimal decimalParser;

            var HORep = new HORep_CVForReplenishment();

            HORep.ID = Int32.TryParse(querystring.Get("intIDDisHOReplenishment"), out intParser) ? intParser : 0;
            HORep.TransactionDate = querystring.Get("TransactionDate");
            HORep.intIDMasPayee   = Int32.TryParse(querystring.Get("intIDMasPayee"), out intParser) ? intParser : 0;
            HORep.intIDMasCOAIndividualSubsidiaryRF  = Int32.TryParse(querystring.Get("intIDMasCOAIndividualSubsidiaryRF"), out intParser) ? intParser : 0;
            HORep.intIDMasCOAIndividualSubsidiaryCiB = Int32.TryParse(querystring.Get("intIDMasCOAIndividualSubsidiaryCiB"), out intParser) ? intParser : 0;
            HORep.strCheckNo     = querystring.Get("strCheckNo");
            HORep.CheckDate      = querystring.Get("CheckDate");
            HORep.curAmount      = Decimal.TryParse(querystring.Get("curAmount"), out decimalParser) ? decimalParser : 0;
            HORep.strParticulars = querystring.Get("strParticulars");

            UserProfile userprofile = WebCommon.GetUserProfile();

            HORep.intIDSecUser = int.Parse(userprofile.UserId.ToString());

            var HORepDetails = new List <HORep_CVForReplenishmentDetail>();

            string strData1 = formdata[0].ToString().Substring(formdata[0].ToString().IndexOf("],[") + 1, formdata[0].Length - formdata[0].ToString().IndexOf("],[") - 1);

            HORepDetails = (List <HORep_CVForReplenishmentDetail>)HORepDetails.ToClass(strData1);

            DataTable tblHORepDetails = new DataTable();

            tblHORepDetails.TableName = "tblHORepDetails";

            tblHORepDetails.Columns.Add("tblType", typeof(string));
            tblHORepDetails.Columns.Add("intIDtblType", typeof(int));
            tblHORepDetails.Columns.Add("ReferenceNo", typeof(int));
            tblHORepDetails.Columns.Add("intIDPayee", typeof(int));
            tblHORepDetails.Columns.Add("TransactionDate", typeof(DateTime));
            tblHORepDetails.Columns.Add("strCheckNo", typeof(string));
            tblHORepDetails.Columns.Add("curAmount", typeof(decimal));
            tblHORepDetails.Columns.Add("strParticulars", typeof(string));
            tblHORepDetails.Columns.Add("sysReferenceNo", typeof(string));

            foreach (var item in HORepDetails)
            {
                tblHORepDetails.Rows.Add(
                    item.tblType,
                    item.intIDtblType,
                    item.ReferenceNo,
                    item.intIDPayee,
                    item.TransactionDate,
                    item.CheckNo,
                    item.curAmount,
                    item.Particulars,
                    item.sysReferenceNo
                    );
            }

            return(HOReplenishmentDAL.SaveHOReplenishment(HORep, tblHORepDetails));
        }
示例#2
0
        public static List <HORep_Payee> GetPayee(NameValueCollection querystring)
        {
            //int branchID = Int32.TryParse(querystring.Get("branchID"), out branchID) ? branchID : 0;
            //int liasonID = Int32.TryParse(querystring.Get("liasonID"), out  liasonID) ? liasonID : 0;
            //string dateFrom = querystring.Get("DateFrom");
            //string dateTo = querystring.Get("DateTo");
            //int intIDLtoStatus = Int32.TryParse(querystring.Get("intIDLtoStatus"), out intIDLtoStatus) ? intIDLtoStatus : 0;

            return(HOReplenishmentDAL.GetPayee());
        }
示例#3
0
 public static List <HORep_CVForReplenishmentDetail> GetPendingForReplenishment(NameValueCollection querystring)
 {
     return(HOReplenishmentDAL.GetPendingForReplenishment());
 }
示例#4
0
 public static List <HORep_CiBBankAccount> GetCiBBankAccount(NameValueCollection querystring)
 {
     return(HOReplenishmentDAL.GetCiBBankAccount());
 }
示例#5
0
        public static List <HORep_LedgerEntry> GetHOReplenishmentLedgerEntry(NameValueCollection querystring)
        {
            int intIDDisHOReplenishment = int.Parse(querystring.Get("intIDDisHOReplenishment"));

            return(HOReplenishmentDAL.GetHOReplenishmentLedgerEntry(intIDDisHOReplenishment));
        }
示例#6
0
        public static List <HORep_CVForReplenishmentDetail> GetHOReplenishmentDetail(NameValueCollection querystring)
        {
            int intIDDisHOReplenishment = int.Parse(querystring.Get("intIDDisHOReplenishment"));

            return(HOReplenishmentDAL.GetHOReplenishmentDetail(intIDDisHOReplenishment));
        }
示例#7
0
        public static List <HORep_CVForReplenishment> SearchHOReplenishment(NameValueCollection querystring)
        {
            string strCriteria = querystring.Get("criteria");

            return(HOReplenishmentDAL.SearchHOReplenishment(strCriteria));
        }