DS7_JinGang
dengyu 1 year ago
commit 4517264358

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<NameOfLastUsedPublishProfile>FolderProfile</NameOfLastUsedPublishProfile>
<UseIISExpress>true</UseIISExpress>
<Use64BitIISExpress />

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<UseIISExpress>true</UseIISExpress>
<Use64BitIISExpress />
<IISExpressSSLPort />

@ -417,6 +417,16 @@ namespace DSWeb.Areas.Account.Controllers
var jsonRespose = new JsonResponse { Success = result.Success, Message = result.Message };
return new ContentResult() { Content = JsonConvert.Serialize(jsonRespose) };
}
public ContentResult AllAudit(string condition, string isaudit)
{
var dataList = ChinvoicehexiaoDAL.GetAuditDataList(condition, Convert.ToString(Session["USERID"]), isaudit, Convert.ToString(Session["SHOWNAME"]), Convert.ToString(Session["COMPANYID"]),null);
DBResult result = ChinvoicehexiaoDAL.AuditList(dataList, Convert.ToString(Session["USERID"]));
var jsonRespose = new JsonResponse { Success = result.Success, Message = result.Message };
return new ContentResult() { Content = JsonConvert.Serialize(jsonRespose) };
}
public ContentResult AuditBackList(string data)
{

@ -14,6 +14,10 @@ Ext.extend(Shipping.MsChInvoicehexiaoAudit, Ext.Panel, {
initUIComponents: function () {
this.sqlcontext = "";
_this = this;
//定义数据集
this.storeList = Ext.create('Ext.data.Store', {
pageSize: this.PageSize,
@ -30,6 +34,24 @@ Ext.extend(Shipping.MsChInvoicehexiaoAudit, Ext.Panel, {
}
});
this.Pagenum = Ext.create('Ext.form.field.Number', {
name: 'bottles',
fieldLabel: '每页记录数',//每页记录数
labelAlign: 'right',
value: this.PageSize,
maxValue: 100000,
width: 180,
minValue: 0,
listeners: {
specialkey: function (field, e) {
if (e.getKey() == e.ENTER) {
_this.onRefreshClick();
}
}
}
});
//定义Grid
this.gridList = new Ext.grid.GridPanel({
store: this.storeList,
@ -195,12 +217,12 @@ Ext.extend(Shipping.MsChInvoicehexiaoAudit, Ext.Panel, {
}
],
// paging bar on the bottom
bbar: Ext.create('Ext.PagingToolbar', {
bbar: [ Ext.create('Ext.PagingToolbar', {
store: this.storeList,
displayInfo: true,
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
emptyMsg: "没有数据"
})
}), this.Pagenum]
});
@ -641,6 +663,13 @@ Ext.extend(Shipping.MsChInvoicehexiaoAudit, Ext.Panel, {
},
scope: this
}, '-', {
text: '全部审核通过', //全部审核通过
iconCls: "btnadd",
handler: function (button, event) {
this.onAllAuditClick();
},
scope: this
},
'-',
{
@ -703,7 +732,7 @@ Ext.extend(Shipping.MsChInvoicehexiaoAudit, Ext.Panel, {
_this = this;
this.gridList.getSelectionModel().on('select', function (model, record, index) {
var billno = record.data.BILLNO;
@ -771,6 +800,53 @@ Ext.extend(Shipping.MsChInvoicehexiaoAudit, Ext.Panel, {
}
}, this);
},
onAllAuditClick: function (menu, event) {
if (this.storeList.length == 0) {
Ext.Msg.show({ title: '提示', msg: '请先选择需审核的单据!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
return;
}
_this = this;
Ext.MessageBox.confirm('提示', '确定审核查询出的所有业务吗?', function (btn) {
if (btn == 'yes') {
Ext.Msg.wait('正在操作数据...');
Ext.Ajax.request({
waitMsg: '正在操作数据...',
url: '/Account/Chfee_Invoicehexiao/AllAudit',
params: {
condition: _this.sqlcontext,
isaudit: _this.isAudit
},
callback: function (options, success, response) {
if (success) {
var result = Ext.JSON.decode(response.responseText);
if (!result.Success) {
Ext.Msg.show({
title: '提示',
msg: result.Message,
icon: Ext.MessageBox.ERROR,
buttons: Ext.Msg.OK
});
return;
} else {
Ext.Msg.hide();
_this.onRefreshClick();
}
} else {
Ext.MessageBox.alert('服务器响应出错', response.responseText);
}
},
scope: this
});
}
}, this);
},
onAuditBackClick: function () {
@ -832,6 +908,9 @@ Ext.extend(Shipping.MsChInvoicehexiaoAudit, Ext.Panel, {
onRefreshClick: function (button, event) {
var sql = this.getCondition();
this.sqlcontext = sql;
this.PageSize = this.Pagenum.getValue();
this.storeList.pageSize = this.PageSize;
this.storeList.load({
params: { start: 0, limit: this.PageSize, sort: '', condition: sql, isaudit: this.isAudit },
waitMsg: "正在查询数据...",

@ -1513,6 +1513,22 @@ Ext.extend(Shipping.ChPayapplicationAudit, Ext.Panel, {
this.onExportClick(button, event);
},
scope: this
}, {
text: Zi.LAN.xswork, //显示工作流
id: "btnShowMap",
iconCls: 'btnexportexcel',
handler: function (button, event) {
var selections = this.gridList.getSelectionModel().getSelection();
var record = selections[0];
var bsno = record.data.BILLNO;
var openSet = "height=700, width=1024, toolbar=no, menubar=no,scrollbars=1, resizable=1,location=no, status=no,Top= " + (screen.height - 750) / 2 + ",Left= " + (screen.width - 1100) / 2
var openType = "_blank";
var openUrl = "";
openUrl = "../../Account/Chfee_payapplication/Map?bsno=" + bsno;
window.open(openUrl, openType, openSet);
},
scope: this
}
]
});

@ -162,6 +162,8 @@ namespace DSWeb.MvcShipping.Controllers
}
if (opstatus == "add")
{
if (string.IsNullOrEmpty(headData.VOID)) headData.VOID = Guid.NewGuid().ToString();
DBResult re = code_vessel.InsertVessel(headData);
if (re.Success == false)
{
@ -178,10 +180,15 @@ namespace DSWeb.MvcShipping.Controllers
{
headData.DbOperationType = DbOperationType.DbotDel;
}
if (headData.ETD == "") headData.ETD = null;
if (headData.ETA == "") headData.ETA = null;
if (headData.CLOSEDOCDATE == "") headData.CLOSEDOCDATE = null;
if (headData.ATD == "") headData.ATD = null;
if (headData.CLOSEDOCDATE == "") headData.CLOSEDOCDATE = null;
var modb = new ModelObjectDB();
modb.Save(headData);
DBResult result=modb.Save(headData);
var GID = headData.DM_ID;
DBResult result = code_vessel.InsertVoyno(headData);
//DBResult result = code_vessel.InsertVoyno(headData);
var jRespose = new JsonResponse
{
Success = result.Success,

@ -69,6 +69,19 @@ namespace DSWeb.MvcShipping.Controllers
#region 提单签发
public ContentResult GetDataList ( int start, int limit, string sort, string condition )
{
var rangstr = MsOp_BLISSUEDAL.GetRangDAStr("OpBLISSUEList", Convert.ToString(Session["USERID"]), Convert.ToString(Session["SHOWNAME"]), Convert.ToString(Session["COMPANYID"]));
if (!string.IsNullOrEmpty(rangstr))
{
if (!string.IsNullOrEmpty(condition))
{
condition = condition + " and " + rangstr;
}
else
{
condition = rangstr;
}
}
var recordcount = 0;
var dataList = MsOp_BLISSUEDAL.GetDataList(condition, start,limit,out recordcount, sort, Convert.ToString(Session["COMPANYID"]));

@ -3575,6 +3575,8 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeDAL
if (modifydata.SALEDEPT != "" && modifydata.SALEDEPT != null)
strSql.Append(",SALEDEPT=@SALEDEPT");
if (modifydata.SALECORPID != "" && modifydata.SALECORPID != null)
strSql.Append(",SALECORPID=@SALECORPID");
if (modifydata.CLOSINGDATE != "" && modifydata.CLOSINGDATE != null)
strSql.Append(",CLOSINGDATE=@CLOSINGDATE");
if (modifydata.CLOSEDOCDATE != "" && modifydata.CLOSEDOCDATE != null)
@ -3816,8 +3818,20 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeDAL
if (ACCDATESAMEETD == "1")
{
var ACCDATE = Convert.ToDateTime(modifydata.ETD).ToString("yyyy-MM");
db.AddInParameter(cmdupdate, "@ACCDATE", DbType.String, ACCDATE);
var nowperiod = ChMonthCloseDAL.ChMonthCloseDAL.GetData("", companyid);
if (nowperiod.CLOSEDAY != 0)
{
var day = Convert.ToDateTime(modifydata.ETD).Day;
if (day > nowperiod.CLOSEDAY) {
var ACCDATE = Convert.ToDateTime(modifydata.ETD).AddMonths(1).ToString("yyyy-MM");
db.AddInParameter(cmdupdate, "@ACCDATE", DbType.String, ACCDATE);
}
}
else
{
var ACCDATE = Convert.ToDateTime(modifydata.ETD).ToString("yyyy-MM");
db.AddInParameter(cmdupdate, "@ACCDATE", DbType.String, ACCDATE);
}
}
@ -3835,6 +3849,8 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeDAL
}
if (modifydata.SALEDEPT != "" && modifydata.SALEDEPT != null)
db.AddInParameter(cmdupdate, "@SALEDEPT", DbType.String, modifydata.SALEDEPT);
if (modifydata.SALECORPID != "" && modifydata.SALECORPID != null)
db.AddInParameter(cmdupdate, "@SALECORPID", DbType.String, modifydata.SALECORPID);
if (modifydata.AGENT != "" && modifydata.AGENT != null)
db.AddInParameter(cmdupdate, "@AGENT", DbType.String, modifydata.AGENT);
if (modifydata.SHIPAGENCY != "" && modifydata.SHIPAGENCY != null)

@ -16296,9 +16296,11 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeEdiPortDAL
#region 各种单号、付款方式代码
if (!string.IsNullOrEmpty(bill.MBLNO))
r.WriteLine("RFF+BN:" + bill.MBLNO + "'");
{
r.WriteLine("RFF+BN:" + bill.MBLNO + "'");
//icount++;
icount++;
}
@ -16693,7 +16695,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeEdiPortDAL
r.WriteLine("TMD+3'");
r.WriteLine("MEA+AAE+WT+KGM:" + Math.Round(ctn.KGS, 3) + "'");
r.WriteLine("MEA+AAE+AAW+MTQ:" + Math.Round(ctn.CBM, 3) + "'");
icount = icount + 3;
icount = icount + 5;
if (bill.CARGOID == "R")
{
@ -16754,7 +16756,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeEdiPortDAL
var OpBill = new MsOpSeaeBill();
var bsno = "";
r.WriteLine("UNB+UNOC:2+" + ftpset.SENDCODE + ":ZZZ+" + ftpset.RECEIVECODE + ":ZZZ+" + DateTime.Now.ToString("yyMMdd:HHmm") + "+" + headData[0].CUSTNO + "'");
icount++;
foreach (var bill in headData)
{
T_ALL_DA T_ALL_DA = new EntityDA.T_ALL_DA();
@ -16813,6 +16815,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeEdiPortDAL
{
r.WriteLine("TSR+30+2'");
}
icount++;
#endregion
#region edi备注
@ -16976,6 +16979,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeEdiPortDAL
else
{
r.WriteLine("RFF+BN:" + bill.MBLNO + "'");
icount++;
}
if (isbill != 1)
@ -17509,6 +17513,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeEdiPortDAL
r.WriteLine("EQD+CN+" + ctn.CNTRNO + "+" + GetCtnEDICode(ctn.CTNALL, "EVERGREEN") + "+1'");
else
r.WriteLine("EQD+CN+" + ctn.CNTRNO + "+" + GetCtnEDICode(ctn.CTNALL, "EVERGREEN") + "+2'");
icount++;
r.WriteLine("TMD+3'");
icount++;
r.WriteLine("MEA+WT+AAL+KGM:" + Math.Round(ctn.KGS, 3) + "'");

@ -85,8 +85,8 @@ namespace DSWeb.Areas.MvcShipping.DAL.MsOp_BLISSUE
strSql.Append(" left join v_op_blissuelist_Detail sp on sp.BSNO=B.BSNO ");
//2018年2月8日15:57:08 鼎世 李进举 提单管理不显示iscancel=12的数据
strSql.Append(" where (B.OPTYPE='主票' and B.iscancel<>1 and B.iscancel<>2 and B.MBLNO<>'' or (B.OPTYPE='分票' and B.HBLNO<>'') ) ");
if (!string.IsNullOrEmpty(corpid))
strSql.Append(" AND CORPID='" + corpid + "'");
//if (!string.IsNullOrEmpty(corpid))
// strSql.Append(" AND CORPID='" + corpid + "'");
var sortstring = DatasetSort.Getsortstring(sort);
@ -3474,6 +3474,111 @@ namespace DSWeb.Areas.MvcShipping.DAL.MsOp_BLISSUE
}
public static string GetRangDAStr(string tb, string userid, string username, string companyid)
{
string str = "";
var strSql = new StringBuilder();
strSql.Append("SELECT ");
strSql.Append(" VISIBLERANGE,OPERATERANGE,AUTHORITYID,VSSQL ");
strSql.Append(" from VW_User_Authority ");
strSql.Append(" where [NAME]='" + tb + "' and USERID='" + userid + "' and ISDELETE=0");
string visiblerange = "4";
string operaterange = "4";
string AUTHORITYID = "";
string VSSQL = "";
Database db = DatabaseFactory.CreateDatabase();
using (IDataReader reader = db.ExecuteReader(CommandType.Text, strSql.ToString()))
{
while (reader.Read())
{
visiblerange = Convert.ToString(reader["VISIBLERANGE"]);
operaterange = Convert.ToString(reader["OPERATERANGE"]);
AUTHORITYID = Convert.ToString(reader["AUTHORITYID"]);
VSSQL = Convert.ToString(reader["VSSQL"]);
break;
}
reader.Close();
}
if (visiblerange == "4")
{
str = "1=1";
}
else if (visiblerange == "3")
{
str = " ( B.OP='" + username + "' OR B.CUSTSERVICE='" + username + "' OR B.DOC='" + username + "' )";
}
else if (visiblerange == "2")
{
var rangeDa = new RangeDA();
var deptid = rangeDa.GetDEPTGID(userid);
str = $" exists(select 1 from vw_user where deptgid='{deptid}' and SHOWNAME in(B.OP,B.CUSTSERVICE,B.DOC)) ";
}
else if (visiblerange == "1")
{
str = " (UPPER(B.Corpid)='" + companyid + "') ";
}
else if (visiblerange == "5")
{
str = " ob.OPNAME in (select SHOWNAME from vw_user where COMPANYID IN (select COMPANYID from user_authority_range_company where userid='" + userid + "' and AUTHORITYID='" + AUTHORITYID + "' and VISIBLERANGE=1)) ";
//var userstr = new StringBuilder();
//userstr.Append(" select COMPANYID from user_authority_range_company where userid='" + userid + "' and AUTHORITYID='" + AUTHORITYID + "' and VISIBLERANGE=1");
//Database userdb = DatabaseFactory.CreateDatabase();
//using (IDataReader reader = userdb.ExecuteReader(CommandType.Text, userstr.ToString()))
//{
// str = "";
// while (reader.Read())
// {
// if (str == "")
// {
// str = " (COMPANYID='" + Convert.ToString(reader["COMPANYID"]) + "'";
// }
// else
// {
// str = str + " or COMPANYID='" + Convert.ToString(reader["COMPANYID"]) + "'";
// };
// }
// str = str + ")";
// reader.Close();
//}
}
else if (visiblerange == "6")
{
str = " EXISTS (select 1 from user_authority_range_op P left join [user] u on (u.GID=P.OPID) where (B.OP=U.SHOWNAMEOR B.CUSTSERVICE=U.SHOWNAME OR B.DOC=U.SHOWNAME ) AND P.userid='" + userid + "' and P.AUTHORITYID='" + AUTHORITYID + "' and P.VISIBLERANGE=1) ";
}
else if (visiblerange == "0")
{
str = " 1=1 ";
}
VSSQL = VSSQL.Trim();
if (!string.IsNullOrEmpty(VSSQL))
{
if (!string.IsNullOrEmpty(str))
{
str = str + " and (" + VSSQL + ") ";
}
else
{
str = " (" + VSSQL + ") ";
}
}
return str;
}
}
}

@ -27,12 +27,12 @@ namespace DSWeb.Areas.MvcShipping.Models.MsCodeVesselSetModel
private string _entreportref;
private string _vessel;
private string _atd;
private string _closedocdate;
/// <summary>
///
/// </summary>
[ModelDB]
public string VOID
private string _closedocdate;
/// <summary>
///
/// </summary>
[ModelDB(MDBType = ModelDBOprationType.All, IsPrimary = true)]
public string VOID
{
set{ _void=value;}
get{return _void;}
@ -45,7 +45,7 @@ namespace DSWeb.Areas.MvcShipping.Models.MsCodeVesselSetModel
set{ _vsid=value;}
get{return _vsid;}
}
[ModelDB]
//[ModelDB]
public string DM_ID { get; set; }
/// <summary>
/// 航次
@ -158,6 +158,11 @@ namespace DSWeb.Areas.MvcShipping.Models.MsCodeVesselSetModel
get { return _closedocdate; }
}
#endregion Model
}
#endregion Model
public code_voynoModel()
{
TableName = "code_voyno";
}
}
}

@ -698,7 +698,7 @@ Ext.extend(Shipping.AireHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
IsAdvancedpay: "False",
Sort: newsort,
IsInvoice: "0",
@ -770,7 +770,7 @@ Ext.extend(Shipping.AireHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
ISACC: "0",
IsAdvancedpay: "False",
Sort: newsort,

@ -689,7 +689,7 @@ Ext.extend(Shipping.AiriHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
ISACC: "0",
IsAdvancedpay: "False",
Sort: newsort,
@ -758,7 +758,7 @@ Ext.extend(Shipping.AiriHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
ISACC: "0",
IsAdvancedpay: "False",
Sort: newsort,

@ -742,7 +742,7 @@ Ext.extend(Shipping.SeaeHistryFee, Ext.Panel, {
this.gridList.getSelectionModel().on('select', function (model, record, index) {
//alert(record.data.BillNo);
var bsno = record.data.BSNO;
this.storeBodyChFee.load({ params: { billno: bsno, type: this.feeType, optype: 'op_Seae'} });
this.storeBodyChFee.load({ params: { billno: bsno, type: this.feeType, optype: 'op_Seae', condition: " FeeType=" + this.feeType+" and exists (select 1 from v_op_bill b where b.BSNO=ch_fee.BSNO and b.PARENTID='" + bsno + "')" }} );
}, this);
//#endregion
@ -946,7 +946,7 @@ Ext.extend(Shipping.SeaeHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
ISACC: "0",
IsAdvancedpay: "False",
Sort: newsort,
@ -1035,7 +1035,7 @@ Ext.extend(Shipping.SeaeHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
ISACC:"0",
IsAdvancedpay: "False",
Sort: newsort,

@ -7687,6 +7687,21 @@ Ext.extend(Shipping.MsOpSeaeIndex, Ext.Panel, {
});
this.storeSaleCompany = Ext.create('DsExt.ux.RefTableStore', {
model: 'MsCompanysEntity',
proxy: { url: '/MvcShipping/MsCompanys/GetNoPicDataList' }
});
this.storeSaleCompany.load({ params: { condition: "" } });
this.comboxSaleCompany = Ext.create('DsExt.ux.RefTableCombox', {
fieldLabel: Zi.LAN.SALECOMPANY, //'委托分公司',
store: this.storeSaleCompany,
forceSelection: true,
name: 'SALECORPID',
valueField: 'GID',
displayField: 'NAME'
});
this.formModify = Ext.widget('form', {
region: 'north',
frame: true,
@ -7905,7 +7920,14 @@ Ext.extend(Shipping.MsOpSeaeIndex, Ext.Panel, {
]
}
}, {
xtype: 'container',
layout: 'hbox',
defaultType: 'textfield',
items: [this.comboxSaleCompany, { xtype: 'hiddenfield' }, { xtype: 'hiddenfield' }, { xtype: 'hiddenfield' }
]
}
]//end items(fieldset 1)
}//end fieldset 1
]//end root items

@ -757,7 +757,7 @@ Ext.extend(Shipping.SeaiHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
ISACC: "0",
IsAdvancedpay: "False",
Sort: newsort,
@ -828,7 +828,7 @@ Ext.extend(Shipping.SeaiHistryFee, Ext.Panel, {
EnterDate: myDate,
DebitNo: '',
IsDebit: "0",
IsOpen: "0",
IsOpen: memberyf.data.IsOpen,
ISACC: "0",
IsAdvancedpay: "False",
Sort: newsort,

@ -4,7 +4,7 @@
<ProjectView>ShowAllFiles</ProjectView>
<NameOfLastUsedPublishProfile>配置文件1</NameOfLastUsedPublishProfile>
<UseIISExpress>true</UseIISExpress>
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<Use64BitIISExpress />
<IISExpressSSLPort />
<IISExpressAnonymousAuthentication />

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<UseIISExpress>true</UseIISExpress>
<Use64BitIISExpress />
<IISExpressSSLPort />

@ -52,7 +52,7 @@ namespace JobCreateFee
jobjTemp.page = 1;
jobjTemp.limit = 10000;
jobjTemp.BsType =Convert.ToInt16(bsType);
jobjTemp.COMNAME = companyName;
jobjTemp.Name = companyName;
var starttimestr = File.ReadAllText(CfgFilePath);
if (!string.IsNullOrEmpty(starttimestr)) {
long startts = DataTableToJsonHelper.ConvertDateTimeToInt(Convert.ToDateTime(starttimestr));
@ -90,7 +90,7 @@ namespace JobCreateFee
sql = sql + "," + returndata.price + ",'" + returndata.sendtype + "'," + returndata.ctnrCount + ",'" + returndata.ctnrInfo + "')";
SqlCommand cmd = new SqlCommand(sql, dbcon);
cmd.ExecuteNonQuery();
if (BS.BSNO != "" && BS.FEESTATUS != "提交财务" && BS.FEESTATUS != "费用封帐" && BS.BSSTATUS != "应付完毕")
if (!string.IsNullOrEmpty(BS.BSNO) && BS.FEESTATUS != "提交财务" && BS.FEESTATUS != "费用封帐" && BS.BSSTATUS != "应付完毕")
{
if (Convert.ToDecimal(returndata.price) != 0 && !string.IsNullOrEmpty(CustName) && !string.IsNullOrEmpty(FeeName))
{
@ -198,7 +198,7 @@ namespace JobCreateFee
public int BsType { get; set; }
public long starttime { get; set; }
public long endtime { get; set; }
public string COMNAME { get; set; }
//public string COMNAME { get; set; }
public string Name { get; set; }
}

@ -119,7 +119,8 @@ namespace JobCreateFee
string FinalDestCountry = "";
string ETD = "";
string MhLane = "";
var CtnList = new List<Ctn>();
string D6LANE = "";
var CtnList = new List<Ctn>();
var CtnSumList = new List<Ctn>();
@ -168,7 +169,7 @@ namespace JobCreateFee
POLID = GetMHPortid(POL, dbmh);
PODID = GetMHPortid(POD, dbmh);
FinalDestID = GetMHPortid(FinalDest, dbmh);
D6LANE=DS6LANE(MhLane, dbcon);
}
@ -383,7 +384,7 @@ namespace JobCreateFee
strSqlUpdateD6.Append(",卸货港=@POD,目的地=@DEST,运输条款=@TermsCode,付费方式=@PaymentTypeDescription,货物描述=@ShipperDescription,唛头=@MarksNumbers");
strSqlUpdateD6.Append(",件数=@PKGS,重量=@KGS,尺码=@CBM,运输方式=@HarmonizedCode,包装=@PackageType,件数包装=@PKGSKIND,货物重量=@GOODKGS,货物尺码=@GOODCBM,集装箱=@CTNSTR");
strSqlUpdateD6.Append(",装港代码=@POLID,卸货代码=@PODID,目的地代码=@FinalDestID");
strSqlUpdateD6.Append(",发货人代码=@SHIPPER,收货人代码=@CONSIGNEE,通知人代码=@NOTIFYPARTY,开船日期=@ETD,船公司航线=@MHLANE where AS_ID='" + BSNO + "'");
strSqlUpdateD6.Append(",发货人代码=@SHIPPER,收货人代码=@CONSIGNEE,通知人代码=@NOTIFYPARTY,开船日期=@ETD,船公司航线=@MHLANE,航线=@LANE where AS_ID='" + BSNO + "'");
}
else
@ -393,7 +394,7 @@ namespace JobCreateFee
strSqlUpdateD6.Append(",件数=@PKGS,重量=@KGS,尺码=@CBM,运输方式=@HarmonizedCode,包装=@PackageType,件数包装=@PKGSKIND,货物重量=@GOODKGS,货物尺码=@GOODCBM,集装箱=@CTNSTR");
strSqlUpdateD6.Append(",装港代码=@POLID,卸货代码=@PODID,目的地代码=@FinalDestID");
strSqlUpdateD6.Append(",发货人代码=@SHIPPER,收货人代码=@CONSIGNEE,通知人代码=@NOTIFYPARTY,开船日期=@ETD,船公司航线=@MHLANE "+ ctnUpdatestr + " where 编号='" + BSNO + "'");
strSqlUpdateD6.Append(",发货人代码=@SHIPPER,收货人代码=@CONSIGNEE,通知人代码=@NOTIFYPARTY,开船日期=@ETD,航线=@LANE,船公司航线=@MHLANE " + ctnUpdatestr + " where 编号='" + BSNO + "'");
}
dbcon.Open();
log.Debug($"更新业务信息{strSqlUpdateD6.ToString()}");
@ -427,6 +428,8 @@ namespace JobCreateFee
cmdUpdateD6.Parameters.AddWithValue("@NOTIFYPARTY", NOTIFYPARTY);
cmdUpdateD6.Parameters.AddWithValue("@ETD", ETD);
cmdUpdateD6.Parameters.AddWithValue("@MHLANE", MhLane);
cmdUpdateD6.Parameters.AddWithValue("@LANE", D6LANE);
cmdUpdateD6.ExecuteNonQuery();
dbcon.Close();
}
@ -458,6 +461,26 @@ namespace JobCreateFee
}
}
static public string DS6LANE(string VESSEL, SqlConnection dbcon)
{
var result = "";
var strSql = new StringBuilder();
strSql.Append("SELECT top 1 航线 from t_code_trade_msc where MSC航线名称='" + VESSEL + "' ");
SqlDataAdapter adapter = new SqlDataAdapter(strSql.ToString(), dbcon);
DataTable table = new DataTable();
adapter.Fill(table);
if (table.Rows.Count > 0)
{
foreach (DataRow row in table.Rows)
{
result = row["航线"].ToString();
}
}
return result;
}
public static List<CtnTypeCode> GetCtnCodeList(SqlConnection dbcon)
{
var strSql = new StringBuilder();

@ -81,7 +81,7 @@ namespace JobCreateFee
bool guadanok = true;
try
{
guadanok = Guadan(mblno, bsno, "Seaway挂单", swbfile, conn, connFile, out tarpath, true);
guadanok = Guadan(mblno, bsno, "提单留底", swbfile, conn, connFile, out tarpath, true);
}
catch (Exception ex)
{

Loading…
Cancel
Save