|
|
@ -16,6 +16,8 @@ using DSWeb.MvcShipping.DAL.MsSysBillNoSet;
|
|
|
|
using HcUtility.Core;
|
|
|
|
using HcUtility.Core;
|
|
|
|
using DSWeb.MvcShipping.Models.MsChFee;
|
|
|
|
using DSWeb.MvcShipping.Models.MsChFee;
|
|
|
|
using DSWeb.MvcShipping.DAL.MsChFeeDAL;
|
|
|
|
using DSWeb.MvcShipping.DAL.MsChFeeDAL;
|
|
|
|
|
|
|
|
using DSWeb.Common.DB;
|
|
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
|
|
|
|
|
|
namespace DSWeb.Areas.MvcShipping.DAL.MsOp_InternalTrade
|
|
|
|
namespace DSWeb.Areas.MvcShipping.DAL.MsOp_InternalTrade
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -165,6 +167,9 @@ namespace DSWeb.Areas.MvcShipping.DAL.MsOp_InternalTrade
|
|
|
|
var PreCUSTNO = "";
|
|
|
|
var PreCUSTNO = "";
|
|
|
|
var BSNO = "";
|
|
|
|
var BSNO = "";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var cdc = new CommonDataContext();
|
|
|
|
|
|
|
|
var alluser = cdc.User.Where(x => 1 == 1).ToList();
|
|
|
|
|
|
|
|
|
|
|
|
Database db = DatabaseFactory.CreateDatabase();
|
|
|
|
Database db = DatabaseFactory.CreateDatabase();
|
|
|
|
var cmdInsert =
|
|
|
|
var cmdInsert =
|
|
|
|
db.GetSqlStringCommand(
|
|
|
|
db.GetSqlStringCommand(
|
|
|
@ -198,9 +203,9 @@ namespace DSWeb.Areas.MvcShipping.DAL.MsOp_InternalTrade
|
|
|
|
headData.SetValue("FEESTATUS","0");
|
|
|
|
headData.SetValue("FEESTATUS","0");
|
|
|
|
headData.SetValue("BSDATE", _date);
|
|
|
|
headData.SetValue("BSDATE", _date);
|
|
|
|
headData.SetValue("CREATOR", username);
|
|
|
|
headData.SetValue("CREATOR", username);
|
|
|
|
headData.SetValue("OP", username);
|
|
|
|
headData.SetValue("OP", userid);
|
|
|
|
headData.SetValue("DOC", username);
|
|
|
|
headData.SetValue("DOC", userid);
|
|
|
|
headData.SetValue("CUSTSERVICE", username);
|
|
|
|
headData.SetValue("CUSTSERVICE", userid);
|
|
|
|
headData.SetValue("CORPID", companyid);
|
|
|
|
headData.SetValue("CORPID", companyid);
|
|
|
|
headData.SetValue("SALECORPID", companyid);
|
|
|
|
headData.SetValue("SALECORPID", companyid);
|
|
|
|
headData.DbOperationType = DbOperationType.DbotIns;
|
|
|
|
headData.DbOperationType = DbOperationType.DbotIns;
|
|
|
@ -208,8 +213,18 @@ namespace DSWeb.Areas.MvcShipping.DAL.MsOp_InternalTrade
|
|
|
|
CUSTOMERNAME = Convert.ToString(row["委托单位"]);
|
|
|
|
CUSTOMERNAME = Convert.ToString(row["委托单位"]);
|
|
|
|
headData.SetValue("CUSTOMERNAME", CUSTOMERNAME);
|
|
|
|
headData.SetValue("CUSTOMERNAME", CUSTOMERNAME);
|
|
|
|
headData.SetValue("MBLNO", Convert.ToString(row["主提单号"]));
|
|
|
|
headData.SetValue("MBLNO", Convert.ToString(row["主提单号"]));
|
|
|
|
headData.SetValue("OP", Convert.ToString(row["操作"]));
|
|
|
|
|
|
|
|
headData.SetValue("SALE", Convert.ToString(row["销售"]));
|
|
|
|
var 操作 = alluser.FirstOrDefault(x => x.SHOWNAME == Convert.ToString(row["操作"]));
|
|
|
|
|
|
|
|
if (操作 == null) 操作 = alluser.FirstOrDefault(x => x.GID == userid);
|
|
|
|
|
|
|
|
headData.SetValue("OP", 操作.GID);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var 销售 = alluser.FirstOrDefault(x => x.SHOWNAME == Convert.ToString(row["销售"]));
|
|
|
|
|
|
|
|
if (销售 == null) 销售 = alluser.FirstOrDefault(x => x.GID == userid);
|
|
|
|
|
|
|
|
headData.SetValue("SALE", 销售.GID);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//headData.SetValue("OP", Convert.ToString(row["操作"]));
|
|
|
|
|
|
|
|
//headData.SetValue("SALE", Convert.ToString(row["销售"]));
|
|
|
|
|
|
|
|
|
|
|
|
CARRIER = Convert.ToString(row["船公司"]);
|
|
|
|
CARRIER = Convert.ToString(row["船公司"]);
|
|
|
|
headData.SetValue("CARRIER", CARRIER);
|
|
|
|
headData.SetValue("CARRIER", CARRIER);
|
|
|
|
headData.SetValue("VESSEL", Convert.ToString(row["船名"]));
|
|
|
|
headData.SetValue("VESSEL", Convert.ToString(row["船名"]));
|
|
|
|