DS7_JinGang
dengyu 1 year ago
parent 16a3b3932b
commit 14b3da6f3e

@ -34,11 +34,20 @@ namespace DSWeb.Service.Output
string USERID = ConfigurationManager.AppSettings["USERID"]; string USERID = ConfigurationManager.AppSettings["USERID"];
string USERNAME = ConfigurationManager.AppSettings["USERNAME"]; string USERNAME = ConfigurationManager.AppSettings["USERNAME"];
List<string> NoReadMessage = new List<string> {
"获取报关数据查询数据列表为空"
};
public class ReadRtn public class ReadRtn
{ {
//{"message":"正在查询中","status":"0"} //{"message":"正在查询中","status":"0"}
public bool? status { get; set; } = true; public bool? status { get; set; } = true;
//ds7当中 如果读取未返回则在返回消息中包含 status=false; //ds7当中 如果读取未返回则在返回消息中包含 status=false;
public string message { get; set; }
} }
public void Execute(IJobExecutionContext context) public void Execute(IJobExecutionContext context)
@ -108,10 +117,18 @@ namespace DSWeb.Service.Output
if (_rtn.status == false) if (_rtn.status == false)
{ {
log.Debug("错误rtn=" + rtn); log.Debug("错误rtn=" + rtn);
if (NoReadMessage.Exists(x=>x == _rtn.message))
{
}
else
{
//错误 重新读取 //错误 重新读取
cdc.OP_LOGICINFO.Add(readrec); cdc.OP_LOGICINFO.Add(readrec);
cdc.SaveChanges(); cdc.SaveChanges();
} }
}
else { else {
//删除这条 //删除这条
if (readrec.PROPVALUE == "结关") { if (readrec.PROPVALUE == "结关") {

@ -55,7 +55,16 @@ namespace DSWeb.Service.Output
var nolist = new List<string>(); var nolist = new List<string>();
if (needreadList1 != null && needreadList1.Count > 0) { if (needreadList1 != null && needreadList1.Count > 0) {
var currList = cdc.OP_LOGICINFO.Where(x => x.PROPNAME == "定时读取单一窗口").ToList();
foreach (var item in needreadList1) { foreach (var item in needreadList1) {
if (currList != null && currList.Count > 0) {
if (currList.Exists(x => x.BSNO == item.GID)) {
continue;
}
}
var newrec = new OP_LOGICINFO_md(); var newrec = new OP_LOGICINFO_md();
newrec.PROPNAME = "定时读取单一窗口"; newrec.PROPNAME = "定时读取单一窗口";
newrec.BSNO = item.GID; newrec.BSNO = item.GID;

@ -26,6 +26,7 @@ using DSWeb.TruckMng.Helper.Repository;
using DSWeb.MvcShipping.DAL.MsInfoClient; using DSWeb.MvcShipping.DAL.MsInfoClient;
using DSWeb.Areas.MvcShipping.Models.Message.VGM; using DSWeb.Areas.MvcShipping.Models.Message.VGM;
using DSWeb.Common.DB; using DSWeb.Common.DB;
using NPOI.SS.Formula.Functions;
namespace DSWeb.MvcShipping.Controllers namespace DSWeb.MvcShipping.Controllers
{ {
@ -206,6 +207,15 @@ namespace DSWeb.MvcShipping.Controllers
} }
/// <summary>
/// 主分单保存
/// </summary>
/// <param name="opstatus"></param>
/// <param name="data"></param>
/// <param name="CargoBody"></param>
/// <param name="CargoDelBody"></param>
/// <param name="BSNO"></param>
/// <returns></returns>
private DBResult DoSave ( string opstatus, string data, string CargoBody, string CargoDelBody, out string BSNO ) private DBResult DoSave ( string opstatus, string data, string CargoBody, string CargoDelBody, out string BSNO )
{ {
@ -216,6 +226,21 @@ namespace DSWeb.MvcShipping.Controllers
if (headData.BLTYPE == "国内分单" && string.IsNullOrWhiteSpace( headData.HBLNO)) if (headData.BLTYPE == "国内分单" && string.IsNullOrWhiteSpace( headData.HBLNO))
{ {
////增加判断 如果主单号与现存的其它分单主单号一样 禁止保存
//var condition = $" B.BLTYPE='国内分单' and B.MBLNO='{headData.MBLNO}' and B.MBLNO<>'' and B.BSNO<>'{headData.BSNO}'";
//if (opstatus == "add")
//{
// condition = $" B.BLTYPE='国内分单' and B.MBLNO='{headData.MBLNO}' and B.MBLNO<>'' ";
//}
//var oldhead = MsOpAirnDAL.GetData(condition);
//if (!string.IsNullOrWhiteSpace(oldhead.MBLNO)) {
// //当前存在一个主单号相同的分单 不允许保存
// result.SetErrorInfo("主单号与现有业务重复,不允许保存!");
// BSNO = "";
// return result;
//}
headData.HBLNO = PubSysDAL.GetBillNo("0201"); headData.HBLNO = PubSysDAL.GetBillNo("0201");
//headData.CREATETIME = DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss"); //headData.CREATETIME = DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss");
} }

@ -244,10 +244,11 @@ Ext.extend(Shipping.OPWMSCHANGEIndex, Ext.Panel, {
this.onRefreshClick(); this.onRefreshClick();
this.storeList.on('beforeload', function (store) { //this.storeList.on('beforeload', function (store) {
var sql = this.getCondition(); // var CUSTOMNO = this.BsNo;
Ext.apply(store.proxy.extraParams, { condition: sql });
}, this); // Ext.apply(store.proxy.extraParams, { CUSTOMNO: CUSTOMNO });
//}, this);
}, //end initUIComponents }, //end initUIComponents

Loading…
Cancel
Save