コード例 #1
0
        /// <summary>
        /// 主表保存
        /// </summary>
        /// <returns></returns>
        public string MAINEdit()
        {
            string _tbxAD_ID = tbxAD_ID.Text.ToString();

            try
            {
                var    model    = new Adjust00(x => x.AD_ID == _tbxAD_ID);
                var    OlUser   = OnlineUsersBll.GetInstence().GetModelForCache(x => x.UserHashKey == Session[OnlineUsersTable.UserHashKey].ToString());
                string _SHOP_ID = ddlSHOP_NAME.SelectedValue;
                if (String.IsNullOrEmpty(_tbxAD_ID))
                {
                    model.SetIsNew(true);
                    model.CRT_DATETIME = DateTime.Now;
                    model.CRT_USER_ID  = OlUser.Manager_LoginName;
                    DataTable dt = new DataTable();
                    dt        = (DataTable)SPs.Get_ORDER_SEED(_SHOP_ID, "Adjust00").ExecuteDataTable();
                    _tbxAD_ID = dt.Rows[0]["PLANE_ID"].ToString();
                    //var model = Purchase00.SingleOrDefault(x => x.Purchase_ID == _Pur00_id);
                }
                model.SHOP_ID    = _SHOP_ID;
                model.AD_ID      = _tbxAD_ID.ToString();
                model.STATUS     = ConvertHelper.Cint(ddlStatus.SelectedValue);
                model.INPUT_DATE = ConvertHelper.StringToDatetime(dpINPUT_DATE.SelectedDate.ToString());

                model.ADJUST_TYPE  = ConvertHelper.Cint(ddlADJUST_TYPE.SelectedValue);
                model.STOCK_ID     = ddlSTOCK_ID.SelectedValue;
                model.USER_ID      = OlUser.Manager_LoginName;
                model.APP_USER     = OlUser.Manager_LoginName;
                model.APP_DATETIME = DateTime.Now;

                model.RELATE_ID = tbxRELATE_ID.Text;
                model.Memo      = tbxMemo.Text;
                model.LOCKED    = ConvertHelper.StringToByte(ckLOCKED.Checked ? "1" : "0");

                model.MOD_DATETIME = DateTime.Now;
                model.MOD_USER_ID  = OlUser.Manager_LoginName;
                model.LAST_UPDATE  = DateTime.Now;
                model.Trans_STATUS = 0;
                Adjust00Bll.GetInstence().Save(this, model);
            }
            catch (Exception err)
            {
                return(err.Message);
            }
            return("");
        }
コード例 #2
0
 /// <summary>
 /// 初始化
 /// </summary>
 public override void Init()
 {
     bll = Adjust00Bll.GetInstence();
     //throw new NotImplementedException();
 }
コード例 #3
0
 public void SearchOrder()
 {
     //int type = ConvertHelper.Cint(FilterDateRadio.SelectedValue);
     Adjust00Bll.GetInstence().BindGrid(Grid1, 0, 0, InquiryCondition(), sortList);
     //TAKEIN10Bll.GetInstence().BindOrderGrid(st, et, type, Grid1);
 }