Example #1
0
 public ActionResult KeihiSetteiEntry(KeihiSetteiModel Kmodel)
 {
     if (string.IsNullOrWhiteSpace(Kmodel.Mode))
     {
         Kmodel.Mode = "New";
     }
     return(View(Kmodel));
 }
Example #2
0
        public string M_Keihi_ExistsCheck([FromBody] KeihiSetteiModel Kmodel)
        {
            if (Kmodel == null)
            {
                Kmodel = new KeihiSetteiModel();
            }
            KeihiSettei_BL Ubl = new KeihiSettei_BL();

            return(Ubl.M_Keihi_ExistsCheck(Kmodel));
        }
Example #3
0
        public string M_Keihi_Select_Entry([FromBody] KeihiSetteiModel Kmodel)
        {
            if (Kmodel == null)
            {
                Kmodel = new KeihiSetteiModel();
            }
            KeihiSettei_BL Ubl = new KeihiSettei_BL();

            return(Ubl.M_Keihi_Select_Entry(Kmodel));
        }
Example #4
0
        public string M_Keihi_ExistsCheck(KeihiSetteiModel Kmodel)
        {
            BaseDL bdl = new BaseDL();

            Kmodel.Sqlprms    = new SqlParameter[1];
            Kmodel.Sqlprms[0] = new SqlParameter("@CostCD", SqlDbType.VarChar)
            {
                Value = (object)Kmodel.CostCD ?? DBNull.Value
            };
            return(bdl.SelectJson("M_Keihi_ExistsCheck", Kmodel.Sqlprms));
        }
Example #5
0
        public string M_Keihi_Select_Entry(KeihiSetteiModel Kmodel)
        {
            BaseDL bdl = new BaseDL();

            Kmodel.Sqlprms    = new SqlParameter[1];
            Kmodel.Sqlprms[0] = new SqlParameter("@CostCD", SqlDbType.VarChar)
            {
                Value = Kmodel.CostCD
            };

            return(bdl.SelectJson("M_Keihi_Select_Entry", Kmodel.Sqlprms));
        }
Example #6
0
        public string Keihi_CUD([FromBody] KeihiSetteiModel Kmodel)
        {
            KeihiSettei_BL Ubl = new KeihiSettei_BL();

            return(Ubl.Keihi_CUD(Kmodel));
        }
Example #7
0
        public string Keihi_CUD(KeihiSetteiModel Kmodel)
        {
            BaseDL bdl = new BaseDL();

            if (Kmodel.Mode.Equals("New"))
            {
                Kmodel.SPName     = "M_Keihi_Insert";
                Kmodel.Sqlprms    = new SqlParameter[6];
                Kmodel.Sqlprms[0] = new SqlParameter("@CostCD", SqlDbType.VarChar)
                {
                    Value = Kmodel.CostCD
                };
                Kmodel.Sqlprms[1] = new SqlParameter("@CostName", SqlDbType.VarChar)
                {
                    Value = Kmodel.CostName
                };
                Kmodel.Sqlprms[2] = new SqlParameter("@KanjoCD", SqlDbType.VarChar)
                {
                    Value = Kmodel.KanjoCD
                };
                Kmodel.Sqlprms[3] = new SqlParameter("@HojoCD", SqlDbType.VarChar)
                {
                    Value = Kmodel.HojoCD
                };
                Kmodel.Sqlprms[4] = new SqlParameter("@Accounting", SqlDbType.TinyInt)
                {
                    Value = Kmodel.Accounting
                };
                Kmodel.Sqlprms[5] = new SqlParameter("@Allocation", SqlDbType.TinyInt)
                {
                    Value = Kmodel.Allocation
                };
            }
            else if (Kmodel.Mode.Equals("Edit"))
            {
                Kmodel.SPName     = "M_Keihi_Update";
                Kmodel.Sqlprms    = new SqlParameter[6];
                Kmodel.Sqlprms[0] = new SqlParameter("@CostCD", SqlDbType.VarChar)
                {
                    Value = Kmodel.CostCD
                };
                Kmodel.Sqlprms[1] = new SqlParameter("@CostName", SqlDbType.VarChar)
                {
                    Value = Kmodel.CostName
                };
                Kmodel.Sqlprms[2] = new SqlParameter("@KanjoCD", SqlDbType.VarChar)
                {
                    Value = Kmodel.KanjoCD
                };
                Kmodel.Sqlprms[3] = new SqlParameter("@HojoCD", SqlDbType.VarChar)
                {
                    Value = Kmodel.HojoCD
                };
                Kmodel.Sqlprms[4] = new SqlParameter("@Accounting", SqlDbType.TinyInt)
                {
                    Value = Kmodel.Accounting
                };
                Kmodel.Sqlprms[5] = new SqlParameter("@Allocation", SqlDbType.TinyInt)
                {
                    Value = Kmodel.Allocation
                };
            }
            else if (Kmodel.Mode.Equals("Delete"))
            {
                Kmodel.SPName     = "M_Keihi_Delete";
                Kmodel.Sqlprms    = new SqlParameter[1];
                Kmodel.Sqlprms[0] = new SqlParameter("@CostCD", SqlDbType.VarChar)
                {
                    Value = Kmodel.CostCD
                };
            }
            return(bdl.SelectJson(Kmodel.SPName, Kmodel.Sqlprms));
        }