Example #1
0
        public ActionResult Create([Bind(Include = "ENTDATE,CONO,JOBNO,SYSGENBool,PRFALLOCBool,CASENO,CASECODE,ITEMTYPE,ITEMDESC,ITEMSPEC,TAXRATE,ITEMAMT1,TAXAMT1,NETAMT1,ITEMAMT2,TAXAMT2,NETAMT2,ITEMAMT,TAXAMT,NETAMT,SYSGEN,PRFALLOC,PRFNO,PRFID,STAMP")] CSBILL cSBILL)
        {
            if (ModelState.IsValid)
            {
                SALASTNO serialTbl = db.SALASTNOes.Find("CSBILL");
                if (serialTbl != null)
                {
                    try
                    {
                        string prefix  = serialTbl.LASTPFIX;
                        int    MaxNo   = serialTbl.LASTNOMAX;
                        bool   AutoGen = serialTbl.AUTOGEN == "Y";
                        serialTbl.LASTNO = serialTbl.LASTNO + 1;
                        cSBILL.BILLNO    = serialTbl.LASTNO.ToString("D10");


                        serialTbl.STAMP           = serialTbl.STAMP + 1;
                        db.Entry(serialTbl).State = EntityState.Modified;
                        db.CSBILLs.Add(cSBILL);
                        db.SaveChanges();
                        return(RedirectToAction("Index"));
                    }
                    catch (Exception e)
                    {
                        ModelState.AddModelError(string.Empty, e.Message);
                    }
                    finally
                    {
                        View("Edit", cSBILL);
                    }
                }
            }

            return(CallView("Edit", cSBILL));
        }
Example #2
0
        public ActionResult Create([Bind(Include = "CONO,SDATE,COSTAT,FILETYPE,FILELOC,SEALLOC,EDATE,ROWNO,STAMP")] CSCOSTAT cSCOSTAT)
        {
            if (ModelState.IsValid)
            {
                int lastRowNo = 0;
                try
                {
                    lastRowNo = db.CSCOSTATs.Where(m => m.CONO == cSCOSTAT.CONO).Max(n => n.ROWNO);
                }
                catch (Exception e) { lastRowNo = -1; }
                finally { };

                cSCOSTAT.STAMP = 1;
                cSCOSTAT.EDATE = cSCOSTAT.SDATE.AddDays(30000);
                cSCOSTAT.ROWNO = lastRowNo + 1;

                db.CSCOSTATs.Add(cSCOSTAT);

                UpdatePreviousRow(cSCOSTAT);

                db.SaveChanges();
                //return RedirectToAction("Details","CSCOMSTRs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSCOSTAT.CONO) });
                return(new RedirectResult(Url.Action("Details", "CSCOMSTRs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSCOSTAT.CONO) }) + "#Status"));
            }

            return(View(cSCOSTAT));
        }
Example #3
0
        public ActionResult Create([Bind(Include = "CONO,AGMNO,LASTFYE,FYETOFILE,FILEDFYE,AGMLAST,AGMEXT,REMINDER1,REMINDER2,REMINDER3,AGMDATE,AGMFILED,REM,STAMP,CIRCDATE")] CSCOAGM cSCOAGM)
        {
            if (ModelState.IsValid)
            {
                cSCOAGM.STAMP = 0;
                try
                {
                    db.CSCOAGMs.Add(cSCOAGM);
                    db.SaveChanges();
                    //return RedirectToAction("Details", "CSCOMSTRs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSCOAGM.CONO) });
                    return(new RedirectResult(Url.Action("Details", "CSCOMSTRs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSCOAGM.CONO) }) + "#AGM"));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }

            cSCOAGM.CSCOMSTR = db.CSCOMSTRs.Find(cSCOAGM.CONO);
            return(View(cSCOAGM));
        }
Example #4
0
        public ActionResult Create([Bind(Include = "PRSCODE,CTRYCODE,REGTYPE,REGNO,REM,STAMP")] CSPRSREG cSPRSREG)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    cSPRSREG.STAMP = 0;
                    db.CSPRSREGs.Add(cSPRSREG);
                    db.SaveChanges();
                    return(RedirectToAction("Edit", "CSPRs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSPRSREG.PRSCODE) }));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }
            ViewBag.PRSCODE  = MyHtmlHelpers.ConvertByteStrToId(cSPRSREG.PRSCODE);
            ViewBag.REGTYPE  = new SelectList(db.HKREGTYPEs.Select(x => new { REGTYPE = x.REGTYPE, REGDESC = x.CTRYOPR + " | " + x.REGTYPE }), "REGTYPE", "REGDESC");
            ViewBag.CTRYCODE = new SelectList(db.HKCTRies.OrderBy(x => x.CTRYCODE), "CTRYCODE", "CTRYDESC", cSPRSREG.CTRYCODE);
            return(View(cSPRSREG));
        }
Example #5
0
        public ActionResult Create([Bind(Include = "GRPCODE,CONO,STAMP")] CSGRPD cSGRPD)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    cSGRPD.STAMP = 0;
                    db.CSGRPDs.Add(cSGRPD);
                    db.SaveChanges();
                    return(RedirectToAction("Index", "CSGRPMs"));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }

            ViewBag.CONO = new SelectList(db.CSCOMSTRs, "CONO", "CONAME", cSGRPD.CONO);
            return(View(cSGRPD));
        }
Example #6
0
        public ActionResult Create([Bind(Include = "CONO,PRSCODE,DESIG,REM,STAMP")] CSCOPIC cSCOPIC)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    cSCOPIC.STAMP = 0;
                    db.CSCOPICs.Add(cSCOPIC);
                    db.SaveChanges();
                    return(new RedirectResult(Url.Action("Edit", "CSCOMSTRs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSCOPIC.CONO) }) + "#Contact"));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }
            cSCOPIC.CSCOMSTR = db.CSCOMSTRs.Find(cSCOPIC.CONO);
            ViewBag.PRSCODE  = new SelectList(db.CSPRS.Where(x => x.HKCONST.CONSTTYPE == "Individual").OrderBy(x => x.PRSNAME), "PRSCODE", "PRSNAME", cSCOPIC.PRSCODE);
            return(View(cSCOPIC));
        }
Example #7
0
        public ActionResult Create([Bind(Include = "COSTAT,BLANKFILE,FILENOPFIX,FILENOFR,FILENOTO,BLANKSEAL,SEALNOFR,SEALNOTO,STAMP")] CSSTAT cSSTAT)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    cSSTAT.STAMP = 0;
                    db.CSSTATs.Add(cSSTAT);
                    db.SaveChanges();
                    return(RedirectToAction("Index"));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }
            ViewBag.BlankFile = cSSTAT.blanklist;
            ViewBag.BlankSeal = cSSTAT.blanklist;
            return(View(cSSTAT));
        }
Example #8
0
        public ActionResult Create([Bind(Include = "CASECODE,DOCINVID,DOCINVDESC,DOCINVQTY,STAMP")] CSCASEDOC cSCASEDOC)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    cSCASEDOC.STAMP = 0;
                    db.CSCASEDOCs.Add(cSCASEDOC);
                    db.SaveChanges();
                    return(RedirectToAction("Index"));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }

            return(View(cSCASEDOC));
        }
Example #9
0
        public ActionResult Create([Bind(Include = "CASECODE,FEEID,ITEMTYPE,ITEMDESC,ITEMSPEC,TAXRATE,ITEMAMT1,TAXAMT1,NETAMT1,ITEMAMT2,TAXAMT2,NETAMT2,ITEMAMT,TAXAMT,NETAMT,STAMP")] CSCASEFEE cSCASEFEE)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    db.CSCASEFEEs.Add(cSCASEFEE);
                    db.SaveChanges();
                    return(new RedirectResult(Url.Action("Details", "CSCASEs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSCASEFEE.CASECODE) }) + "#CASEFEE"));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }

            ViewBag.ITEMTYPE = new SelectList(db.CSITEMs, "ITEMTYPE", "ITEMDESC", cSCASEFEE.ITEMTYPE);
            return(View(cSCASEFEE));
        }
Example #10
0
        public ActionResult Create([Bind(Include = "SOURCE,SOURCENO,SOURCEID,CONO,JOBNO,CASENO,CASECODE,DUEDATE,ENTDATE,TRTYPE,TRDESC,TRITEM1,TRITEM2,TRITEM,TRTAX1,TRTAX2,TRTAX,TRAMT1,TRAMT2,TRAMT,TRSIGN,TRSITEM1,TRSITEM2,TRSITEM,TRSTAX1,TRSTAX2,TRSTAX,TRSAMT1,TRSAMT2,TRSAMT,TRITEMOS1,TRITEMOS2,TRITEMOS,TRTAXOS1,TRTAXOS2,TRTAXOS,TROS1,TROS2,TROS,APPTYPE,APPNO,APPID,APPITEM1,APPITEM2,APPITEM,APPTAX1,APPTAX2,APPTAX,APPAMT1,APPAMT2,APPAMT,REM,COMPLETE,COMPLETED,SEQNO,REFCNT,STAMP")] CSTRANM cSTRANM)
        {
            if (ModelState.IsValid)
            {
                cSTRANM.STAMP = 0;
                try
                {
                    db.CSTRANMs.Add(cSTRANM);
                    db.SaveChanges();
                    return(RedirectToAction("Index"));
                }
                catch (DbEntityValidationException dbEx)
                {
                    foreach (var validationErrors in dbEx.EntityValidationErrors)
                    {
                        foreach (var validationError in validationErrors.ValidationErrors)
                        {
                            //string message = string.Format("{0}:{1}",
                            //    validationErrors.Entry.Entity.ToString(),
                            //   validationError.ErrorMessage);
                            // raise a new exception nesting
                            // the current instance as InnerException
                            ModelState.AddModelError(validationError.PropertyName, validationError.ErrorMessage);
                        }
                    }
                }
                catch (DbUpdateException ex)
                {
                    UpdateException updateException = (UpdateException)ex.InnerException;
                    if (updateException != null)
                    {
                        if (updateException.InnerException != null)
                        {
                            var sqlException = (FirebirdSql.Data.FirebirdClient.FbException)updateException.InnerException;

                            foreach (var error in sqlException.Errors)
                            {
                                if (error.Message != null)
                                {
                                    ModelState.AddModelError(string.Empty, error.Message);
                                }
                            }
                        }
                        else
                        {
                            ModelState.AddModelError(string.Empty, updateException.Message);
                        }
                    }
                    else
                    {
                        ModelState.AddModelError(string.Empty, updateException.Message);
                    }
                }
            }

            return(View(cSTRANM));
        }
Example #11
0
        public ActionResult Create([Bind(Include = "SOURCE,SOURCENO,SOURCEID,CONO,JOBNO,CASENO,CASECODE,DUEDATE,ENTDATE,TRTYPE,TRDESC,TRITEM1,TRITEM2,TRITEM,TRTAX1,TRTAX2,TRTAX,TRAMT1,TRAMT2,TRAMT,TRSIGN,TRSITEM1,TRSITEM2,TRSITEM,TRSTAX1,TRSTAX2,TRSTAX,TRSAMT1,TRSAMT2,TRSAMT,TRITEMOS1,TRITEMOS2,TRITEMOS,TRTAXOS1,TRTAXOS2,TRTAXOS,TROS1,TROS2,TROS,APPTYPE,APPNO,APPID,APPITEM1,APPITEM2,APPITEM,APPTAX1,APPTAX2,APPTAX,APPAMT1,APPAMT2,APPAMT,REM,COMPLETE,COMPLETED,SEQNO,REFCNT,STAMP")] CSTRANM cSTRANM)
        {
            if (ModelState.IsValid)
            {
                db.CSTRANMs.Add(cSTRANM);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSTRANM));
        }
Example #12
0
        public ActionResult Create([Bind(Include = "PRCODE,PRDESC,STAMP")] CSPR1 cSPR1)
        {
            if (ModelState.IsValid)
            {
                db.CSPR1.Add(cSPR1);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSPR1));
        }
Example #13
0
        public ActionResult Create([Bind(Include = "CONAME,CONO,COREGNO,ENTDATE,PARTICULARS,PARTICULARS1,PARTICULARS2,SOURCE,SOURCENO,TRAMT,TROS,MINAMT,MAXAMT")] V_CSTRAN_OSTD v_CSTRAN_OSTD)
        {
            if (ModelState.IsValid)
            {
                db.V_CSTRAN_OSTD.Add(v_CSTRAN_OSTD);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(v_CSTRAN_OSTD));
        }
Example #14
0
        public ActionResult Create([Bind(Include = "BKCODE,BKDESC,STAMP")] CSBK cSBK)
        {
            if (ModelState.IsValid)
            {
                db.CSBKs.Add(cSBK);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSBK));
        }
Example #15
0
        public ActionResult Create([Bind(Include = "CONO,LASTCODE,LASTDESC,LASTPFIX,LASTNO,LASTWD,AUTOGEN,STAMP")] CSCOLASTNO cSCOLASTNO)
        {
            if (ModelState.IsValid)
            {
                db.CSCOLASTNOes.Add(cSCOLASTNO);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSCOLASTNO));
        }
Example #16
0
        public ActionResult Create([Bind(Include = "CONAME,COREGNO,COADDR1,COADDR2,COADDR3,COADDR4,COPHONE1,COPHONE2,COFAX1,COFAX2,COWEB,CTRYOPR,ACCMETHOD,STAMP")] SACOMP sACOMP)
        {
            if (ModelState.IsValid)
            {
                db.SACOMPs.Add(sACOMP);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(sACOMP));
        }
Example #17
0
        public ActionResult Create([Bind(Include = "TRNO,TRID,VDATE,CLCODE,CNNO,CNDATE,ITEMDESC,CRMAPCODE,BRANCHCODE,UNITCODE,PRJCODE,STAFFCODE,CURRCODE,ITEMAMT,STAMP")] APCND aPCND)
        {
            if (ModelState.IsValid)
            {
                db.APCNDs.Add(aPCND);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(aPCND));
        }
Example #18
0
        public ActionResult Create([Bind(Include = "CASECODE,DOCINVID,DOCINVDESC,DOCINVQTY,STAMP")] CSCASEDOC cSCASEDOC)
        {
            if (ModelState.IsValid)
            {
                db.CSCASEDOCs.Add(cSCASEDOC);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSCASEDOC));
        }
Example #19
0
        public ActionResult Create([Bind(Include = "CONAME,CONO,AGMNO,LASTFYE,FYETOFILE,FILEDFYE,AGMLAST,AGMEXT,REMINDER1,REMINDER2,REMINDER3,AGMDATE,AGMFILED,REM,STAMP,CIRCDATE,REMINDER4")] V_CSCOAGM v_CSCOAGM)
        {
            if (ModelState.IsValid)
            {
                db.V_CSCOAGM.Add(v_CSCOAGM);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(v_CSCOAGM));
        }
Example #20
0
        public ActionResult Create([Bind(Include = "CASECODE,CASEDESC,MAPSFIX,STAMP")] CSCASE cSCASE)
        {
            if (ModelState.IsValid)
            {
                db.CSCASEs.Add(cSCASE);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSCASE));
        }
Example #21
0
        public ActionResult Create([Bind(Include = "CONAME,CONO,ARNO,LASTAR,ARTOFILE,FILEDAR,REMINDER1,REM,STAMP,SUBMITAR,REMINDER2")] V_CSCOAR v_CSCOAR)
        {
            if (ModelState.IsValid)
            {
                db.V_CSCOAR.Add(v_CSCOAR);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(v_CSCOAR));
        }
Example #22
0
        public ActionResult Create([Bind(Include = "CONO,EFFDATE,AK,REM,ENDDATE,ROWNO,STAMP")] CSCOAK cSCOAK)
        {
            if (ModelState.IsValid)
            {
                db.CSCOAKs.Add(cSCOAK);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSCOAK));
        }
Example #23
0
        public ActionResult Create([Bind(Include = "TAXCODE,TAXDESC,TAXTYPE,TAXRCODE,TAXRATE,EFFECTIVE_START,EFFECTIVE_END,ACTIVE_FLAG,STAMP")] CSTAXTYPE cSTAXTYPE)
        {
            if (ModelState.IsValid)
            {
                db.CSTAXTYPEs.Add(cSTAXTYPE);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cSTAXTYPE));
        }
Example #24
0
        public ActionResult Create([Bind(Include = "USERID,USERNAME,PW,CRDATE,EXPDAYS,LUDATE,EXUSER,MAXSESSION,USERTYPE,PWMINCHAR,PWRECYCLE,PWFAILLOCK,USERLOCK,STAMP")] SAUSERM sAUSERM)
        {
            if (ModelState.IsValid)
            {
                db.SAUSERMs.Add(sAUSERM);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(sAUSERM));
        }
Example #25
0
        public ActionResult Create([Bind(Include = "CASECODE,FEEID,ITEMTYPE,ITEMDESC,ITEMSPEC,TAXRATE,ITEMAMT1,TAXAMT1,NETAMT1,ITEMAMT2,TAXAMT2,NETAMT2,ITEMAMT,TAXAMT,NETAMT,STAMP")] CSCASEFEE cSCASEFEE)
        {
            if (ModelState.IsValid)
            {
                db.CSCASEFEEs.Add(cSCASEFEE);
                db.SaveChanges();
                return(new RedirectResult(Url.Action("Details", "CSCASEs", new { id = MyHtmlHelpers.ConvertIdToByteStr(cSCASEFEE.CASECODE) }) + "#CASEFEE"));
            }

            ViewBag.ITEMTYPE = new SelectList(db.CSITEMs, "ITEMTYPE", "ITEMDESC", cSCASEFEE.ITEMTYPE);
            return(View(cSCASEFEE));
        }
Example #26
0
        public ActionResult Create([Bind(Include = "CONO,PRSCODE,MVTYPE,MVNO,MVID,INMVTYPE,INMVNO,INMVID,OUTMVTYPE,OUTMVNO,OUTMVID,MVDATE,SHAREAMT,STAMP")] CSCOSHEQD cSCOSHEQD)
        {
            if (ModelState.IsValid)
            {
                db.CSCOSHEQDs.Add(cSCOSHEQD);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.CONO = new SelectList(db.CSCOSHes, "CONO", "REM", cSCOSHEQD.CONO);
            return(View(cSCOSHEQD));
        }
Example #27
0
        public ActionResult Create([Bind(Include = "CONO,REFNO,REFDATE,DEEDDATE,PRSCODE,SECUREAMT,ISSUEAMT,DEBCOND,DEBINFO,REM,STAMP")] CSCODEB cSCODEB)
        {
            if (ModelState.IsValid)
            {
                db.CSCODEBs.Add(cSCODEB);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.PRSCODE = new SelectList(db.CSPRS, "PRSCODE", "CONSTCODE", cSCODEB.PRSCODE);
            return(View(cSCODEB));
        }
Example #28
0
        public ActionResult Create([Bind(Include = "CONO,CONOPARENT,ADATE,RDATE,ENDDATE,REM,ROWNO,STAMP")] CSCOPARENT cSCOPARENT)
        {
            if (ModelState.IsValid)
            {
                db.CSCOPARENTs.Add(cSCOPARENT);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.CONOPARENT = new SelectList(db.CSCOMSTRs, "CONO", "INCCTRY", cSCOPARENT.CONOPARENT);
            return(View(cSCOPARENT));
        }
Example #29
0
        public ActionResult Create([Bind(Include = "CONO,FEECODE,FEEAMT,FEEMTH,FEETYPE,LASTTOUCH,STAMP")] CSCOFEE cSCOFEE)
        {
            if (ModelState.IsValid)
            {
                db.CSCOFEEs.Add(cSCOFEE);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.FEECODE = new SelectList(db.CSCASEs, "CASECODE", "CASEDESC", cSCOFEE.FEECODE);
            return(View(cSCOFEE));
        }
Example #30
0
        public ActionResult Create([Bind(Include = "CONO,PRSCODE,ADATE,RDATE,ENDDATE,REM,ROWNO,STAMP")] CSCOAGT cSCOAGT)
        {
            if (ModelState.IsValid)
            {
                db.CSCOAGTs.Add(cSCOAGT);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.PRSCODE = new SelectList(db.CSPRS, "PRSCODE", "CONSTCODE", cSCOAGT.PRSCODE);
            return(View(cSCOAGT));
        }