Beispiel #1
0
 public Model.GeneralReturns kd_jd(Model.M_KD_jd.Request S)
 {
     Model.GeneralReturns genRet = new Model.GeneralReturns();
     if (string.IsNullOrEmpty(S.billcode) || string.IsNullOrEmpty(S.KD_com) || string.IsNullOrEmpty(S.scan_emp) || string.IsNullOrEmpty(S.scan_site))
     {
         genRet.MsgText = "缺少必要参数";
         return(genRet);
     }
     if (new DAL.Dal_KD_jd().IsHandBill(S.billcode))
     {
         genRet.MsgText = "已交单";
     }
     else
     {
         if (new DAL.Dal_KD_jd().DeliveryBillCode(S))
         {
             pmw_bill_tips billInfo = new DAL.Dal_KD_jd().billTips(S.billcode);
             if (billInfo != null)
             {
                 string billTipsStr = billInfo.billcode + ":" + billInfo.bill_type + "备注:" + billInfo.memo;
                 if (!String.IsNullOrEmpty(billTipsStr))
                 {
                     genRet.MsgText = billTipsStr;
                 }
             }
             genRet.State = true;
         }
         else
         {
             genRet.MsgText = "交单失败";
         }
     }
     return(genRet);
 }
Beispiel #2
0
 /// <summary>
 /// 交单
 /// </summary>
 /// <param name="S"></param>
 /// <returns></returns>
 public bool DeliveryBillCode(Model.M_KD_jd.Request S)
 {
     return(Common.Config.StartSqlSugar <bool>((db) =>
     {
         return db.Insertable <tab_kd_jd>(new tab_kd_jd
         {
             kd_com = S.KD_com,
             billcode = S.billcode,
             emp = S.scan_emp,
             createtime = DateTime.Now,
             wavehouse = S.scan_site
         }).ExecuteCommand() > 0;
     }));
 }
Beispiel #3
0
 private Model.GeneralReturns KD_jd(Model.M_KD_jd.Request S)
 {
     return(new BLL.Bll_KD_jd().kd_jd(S));
 }