Exemple #1
0
        public ActionResult DailyVisitEntry(string dvPartyName, string dvVisitDetail, string dvEstCost, string dvNextFollowUp, string dvRemark)//(clsVisitSchMst oCls)
        {
            clsDailyVisitEntry oCls = new clsDailyVisitEntry();

            oCls.dvCompCode    = SessionMaster.CompCode;
            oCls.dvPartyName   = dvPartyName.Substring(0, dvPartyName.LastIndexOf('-'));
            oCls.dvMobile      = dvPartyName.Substring(dvPartyName.LastIndexOf('-') + 1, dvPartyName.Length - dvPartyName.LastIndexOf('-') - 1);
            oCls.dvVisitDetail = dvVisitDetail;
            if (dvEstCost != "")
            {
                oCls.dvEstCost = decimal.Parse(dvEstCost);
            }
            if (dvNextFollowUp != "")
            {
                oCls.dvNextFollowUp = Convert.ToDateTime(dvNextFollowUp);
            }
            oCls.dvRemark = dvRemark;

            List <clsDailyVisitEntry> aData = oSubmit.InsDailyVisitEntry(oCls);

            return(RedirectToAction("DailyVisitEntry", new { aType = aData[0].aType, aMsg = aData[0].aMsg, MenCode = Request.QueryString["MenCode"] }));
        }