Esempio n. 1
0
        public Model.GeneralReturns PeerDeliverBill(Model.M_PeerDeliverBill.Request S)
        {
            Model.GeneralReturns gr = new Model.GeneralReturns();
            if (String.IsNullOrEmpty(S.billcode) || String.IsNullOrEmpty(S.KD_com) || String.IsNullOrEmpty(S.scan_emp) || String.IsNullOrEmpty(S.scan_site))
            {
                gr.MsgText = "缺少必要参数";
                return(gr);
            }

            if (new Regex("^[0-9]*$").IsMatch(S.billcode))
            {
                if (new DAL.Dal_PeerDeliverBill().PeerHandIn(S))
                {
                    gr.State = true;
                }
                else
                {
                    gr.MsgText = "无法交单";
                }
            }
            else
            {
                gr.MsgText = "请输入正确的单号";
            }

            return(gr);
        }
 public bool PeerHandIn(Model.M_PeerDeliverBill.Request S)
 {
     return(Common.Config.StartSqlSugar <bool>((db) =>
     {
         return db.Insertable <pmw_PeerDeliverBill>(new pmw_PeerDeliverBill
         {
             billcode = S.billcode,
             CusName = S.KD_com,
             createTime = DateTime.Now,
             scan_emp = S.scan_emp,
             scan_site = S.scan_site
         }).ExecuteCommand() > 0;
     }));
 }
Esempio n. 3
0
 private Model.GeneralReturns PeerDeliverBill(Model.M_PeerDeliverBill.Request S)
 {
     return(new BLL.Bll_PeerDeliverBill().PeerDeliverBill(S));
 }