DS7_HYRD
hanxuntao 1 year ago
parent f244c0d642
commit cf6cc6c024

@ -178,7 +178,7 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
if (worktype== "SALEORDER") strSql.Append(" and ch_fee.IsCrmOrderFee=1 ");
else if (worktype != "") strSql.Append(" and isnull(ch_fee.IsCrmOrderFee,0)=0 ");
if (worktype == "BLAUDIT") strSql.Append(" and wu.TYPENO=602 ");
else if (worktype == "FEEAUDIT") strSql.Append(" and (wu.TYPENO=1 or wu.TYPENO=3 or wu.TYPENO=11 or wu.TYPENO=13 or wu.TYPENO=101 or wu.TYPENO=103 or wu.TYPENO=104 or wu.TYPENO=106 or wu.TYPENO=107 or wu.TYPENO=109 or wu.TYPENO=204 or wu.TYPENO=206 or wu.TYPENO=301 or wu.TYPENO=303 or wu.TYPENO=304 or wu.TYPENO=601) ");
else if (worktype == "FEEAUDIT") strSql.Append(" and (wu.TYPENO=1 or wu.TYPENO=3 or wu.TYPENO=11 or wu.TYPENO=13 or wu.TYPENO=101 or wu.TYPENO=103 or wu.TYPENO=104 or wu.TYPENO=106 or wu.TYPENO=107 or wu.TYPENO=109 or wu.TYPENO=111 or wu.TYPENO=112 or wu.TYPENO=204 or wu.TYPENO=206 or wu.TYPENO=301 or wu.TYPENO=303 or wu.TYPENO=304 or wu.TYPENO=601) ");
}
@ -1017,10 +1017,14 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
{
WorkFlowName = "BulkFeeAudit";
}
if (optype == "op_other" || optype == "tmswlpchead" || optype == "opctnbscard" || optype == "import_main")
if (optype == "op_other" || optype == "opctnbscard" || optype == "import_main")
{
WorkFlowName = "FeeOpOpOtherRecvPayAudit";
}
if (optype == "tmswlpchead")
{
WorkFlowName = "OpTruckRecvPayAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeAudit";
@ -3018,10 +3022,15 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
} if (optype == "op_Bulk")
{
WorkFlowName = "BulkFeeModify";
} if (optype == "op_other" || optype == "tMsWlPcHead" || optype == "OpCtnBsCard")
} if (optype == "op_other" || optype == "OpCtnBsCard")
{
WorkFlowName = "FeeOpOtherModifyAudit";
} if (optype == "op_railway")
}
if (optype.ToLower() == "tmswlpchead")
{
WorkFlowName = "OpTruckModifyAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeModify";
}
@ -3317,10 +3326,15 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
} if (optype == "op_Bulk")
{
WorkFlowName = "BulkFeeModify";
} if (optype == "op_other" || optype == "tMsWlPcHead" || optype == "OpCtnBsCard")
} if (optype == "op_other"|| optype == "OpCtnBsCard")
{
WorkFlowName = "FeeOpOtherModifyAudit";
} if (optype == "op_railway")
}
if (optype.ToLower() == "tmswlpchead")
{
WorkFlowName = "OpTruckModifyAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeModify";
}
@ -3578,10 +3592,14 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
{
WorkFlowName = "BulkFeeModify";
}
if (optype == "op_other" || optype == "tMsWlPcHead" || optype == "OpCtnBsCard")
if (optype == "op_other" || optype == "OpCtnBsCard")
{
WorkFlowName = "FeeOpOtherModifyAudit";
}
if (optype.ToLower() == "tmswlpchead")
{
WorkFlowName = "OpTruckModifyAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeModify";
@ -3840,10 +3858,15 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
} if (optype == "op_Bulk")
{
WorkFlowName = "BulkFeeModify";
} if (optype == "op_other" || optype == "tMsWlPcHead" || optype == "OpCtnBsCard")
} if (optype == "op_other" || optype == "OpCtnBsCard")
{
WorkFlowName = "FeeOpOtherModifyAudit";
} if (optype == "op_railway")
}
if (optype.ToLower() == "tmswlpchead")
{
WorkFlowName = "OpTruckModifyAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeModify";
}
@ -4002,10 +4025,15 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
} if (optype == "op_bulk")
{
WorkFlowName = "BulkFeeModify";
} if (optype == "op_other" || optype == "tMsWlPcHead" || optype == "OpCtnBsCard")
} if (optype == "op_other" || optype == "OpCtnBsCard")
{
WorkFlowName = "FeeOpOtherModifyAudit";
} if (optype == "op_railway")
}
if (optype.ToLower() == "tmswlpchead")
{
WorkFlowName = "OpTruckModifyAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeModify";
}
@ -4192,10 +4220,15 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
} if (optype == "op_bulk")
{
WorkFlowName = "BulkFeeModify";
} if (optype == "op_other" || optype == "tMsWlPcHead" || optype == "OpCtnBsCard")
} if (optype == "op_other"|| optype == "OpCtnBsCard")
{
WorkFlowName = "FeeOpOtherModifyAudit";
} if (optype == "op_railway")
}
if (optype.ToLower() == "tmswlpchead")
{
WorkFlowName = "OpTruckModifyAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeModify";
}
@ -4385,10 +4418,15 @@ namespace DSWeb.MvcShipping.DAL.Chfee_AuditDAL
} if (optype == "op_bulk")
{
WorkFlowName = "BulkFeeModify";
} if (optype == "op_other" || optype == "tMsWlPcHead" || optype == "OpCtnBsCard")
} if (optype == "op_other" || optype == "OpCtnBsCard")
{
WorkFlowName = "FeeOpOtherModifyAudit";
} if (optype == "op_railway")
}
if (optype.ToLower() == "tmswlpchead")
{
WorkFlowName = "OpTruckModifyAudit";
}
if (optype == "op_railway")
{
WorkFlowName = "RailwayFeeModify";
}

@ -4861,7 +4861,7 @@ Ext.extend(Shipping.MsChfeeAudit, Ext.Panel, {
this.BillSql = this.BillSql + " and ch_fee.IsCrmOrderFee=1 "
else if (this.worktype != '') this.BillSql = this.BillSql + " and isnull(ch_fee.IsCrmOrderFee,0)=0 "
if (this.worktype == 'BLAUDIT') this.BillSql = this.BillSql + " and wu.TYPENO=602 "
else if (this.worktype == 'FEEAUDIT') this.BillSql = this.BillSql + " and (wu.TYPENO=1 or wu.TYPENO=3 or wu.TYPENO=11 or wu.TYPENO=13 or wu.TYPENO=101 or wu.TYPENO=103 or wu.TYPENO=104 or wu.TYPENO=106 or wu.TYPENO=107 or wu.TYPENO=109 or wu.TYPENO=204 or wu.TYPENO=206 or wu.TYPENO=301 or wu.TYPENO=303 or wu.TYPENO=304 or wu.TYPENO=601) "
else if (this.worktype == 'FEEAUDIT') this.BillSql = this.BillSql + " and (wu.TYPENO=1 or wu.TYPENO=3 or wu.TYPENO=11 or wu.TYPENO=13 or wu.TYPENO=101 or wu.TYPENO=103 or wu.TYPENO=104 or wu.TYPENO=106 or wu.TYPENO=107 or wu.TYPENO=109 or wu.TYPENO=111 or wu.TYPENO=112 or wu.TYPENO=204 or wu.TYPENO=206 or wu.TYPENO=301 or wu.TYPENO=303 or wu.TYPENO=304 or wu.TYPENO=601) "
this.BillSql = this.BillSql+ " and isnull((power(2,(ST.STEPNO)) & wu.stepno),0)>0 and st.AUDITOR='" + userid + "' and (ch_fee.FEESTATUS=2 or ch_fee.FEESTATUS=3 or ch_fee.FEESTATUS=4)) ";
@ -6689,7 +6689,7 @@ Ext.extend(Shipping.MsChfeeAudit, Ext.Panel, {
var StrAudit = " EXISTS (select 1 from ch_fee left join workflow_using wu on wu.bsno=ch_fee.GID left join workflow_step st "
StrAudit = StrAudit + " on (st.WORKFLOWID=wu.WORKFLOWID and st.GROUPID=WU.CurrentID) where v_op_bill.BSNO=ch_fee.BSNO "
if (this.worktype == 'BLAUDIT') StrAudit = StrAudit + " and wu.TYPENO=602 "
else if (this.worktype == 'FEEAUDIT') StrAudit = StrAudit + " and (wu.TYPENO=1 or wu.TYPENO=3 or wu.TYPENO=11 or wu.TYPENO=13 or wu.TYPENO=101 or wu.TYPENO=103 or wu.TYPENO=104 or wu.TYPENO=106 or wu.TYPENO=107 or wu.TYPENO=109 or wu.TYPENO=204 or wu.TYPENO=206 or wu.TYPENO=301 or wu.TYPENO=303 or wu.TYPENO=304 or wu.TYPENO=601) "
else if (this.worktype == 'FEEAUDIT') StrAudit = StrAudit + " and (wu.TYPENO=1 or wu.TYPENO=3 or wu.TYPENO=11 or wu.TYPENO=13 or wu.TYPENO=101 or wu.TYPENO=103 or wu.TYPENO=104 or wu.TYPENO=106 or wu.TYPENO=107 or wu.TYPENO=109 or wu.TYPENO=111 or wu.TYPENO=112 or wu.TYPENO=204 or wu.TYPENO=206 or wu.TYPENO=301 or wu.TYPENO=303 or wu.TYPENO=304 or wu.TYPENO=601) "
StrAudit = StrAudit+ " and isnull((power(2,(ST.STEPNO)) & wu.stepno),0)>0 and st.AUDITOR='" + userid + "' and (ch_fee.FEESTATUS=2 or ch_fee.FEESTATUS=3 or ch_fee.FEESTATUS=4)"
StrAudit = StrAudit+ feestr + " ) ";

@ -101,6 +101,11 @@ namespace DSWeb.MvcShipping.Controllers
{
return View();
}
public ActionResult AddFeePLIndex()
{
return View();
}
public ContentResult GetDataList(int start, int limit, string sort, string condition, string billtype, int ortype)
@ -1068,7 +1073,23 @@ namespace DSWeb.MvcShipping.Controllers
var jsonRespose = new JsonResponse { Success = result.Success, Message = result.Message };
return new ContentResult() { Content = JsonConvert.Serialize(jsonRespose) };
}
public ContentResult modify(string data, string modifydata)
{
var bodyList = JsonConvert.Deserialize<List<MsOpSubSeaOrder>>(data);
var amodifydata = JsonConvert.Deserialize<MsOpSubSeaArrival>(modifydata);
var result = new DBResult();
if (bodyList != null)
{
result = MsOpSubSeaOrderDAL.Modify(bodyList, amodifydata, Convert.ToString(Session["COMPANYID"]));
}
var jsonRespose = new JsonResponse
{
Success = result.Success,
Message = result.Message,
};
return new ContentResult() { Content = JsonConvert.Serialize(jsonRespose) };
}
[HttpPost]
public ContentResult ImportDetail()

@ -471,6 +471,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaiDAL
var strSql = new StringBuilder();
strSql.Append("SELECT * ");
strSql.Append(",CASE WHEN ISNULL(TTLINVDR,0)=0 THEN '未开票' WHEN ISNULL(TTLINVDR,0)=ISNULL(TTLDR,0) THEN '已开票' WHEN ISNULL(TTLINVDR,0)!=ISNULL(TTLDR,0) THEN '部分开票' END DRINVSTATUS ");
strSql.Append(",CASE WHEN ISNULL(TTLINVCR,0)=0 THEN '未开票' WHEN ISNULL(TTLINVCR,0)=ISNULL(TTLCR,0) THEN '已开票' WHEN ISNULL(TTLINVCR,0)!=ISNULL(TTLCR,0) THEN '部分开票' END CRINVSTATUS ");
strSql.Append(",CASE WHEN ISNULL(TTLDUIDR,0)=0 THEN '未对账' WHEN ISNULL(TTLDUIDR,0)=ISNULL(TTLDR,0) THEN '已对账' WHEN ISNULL(TTLDUIDR,0)!=ISNULL(TTLDR,0) THEN '部分对账' END DRDUISTATUS ");
strSql.Append(",APPLYCOUNT ISAPPLY,AMENDCOUNT AMEND from (");
strSql.Append("SELECT ");

@ -90,7 +90,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSubSeaOrderDAL
//
var strSql = new StringBuilder();
strSql.Append("SELECT ORDNO,BSNO,ORSTATUS,ORTYPE,ORREASON,BSDATE,MBLNO,HBLNO,CUSTOMERNAME");
strSql.Append("SELECT ORDNO,B.BSNO,ORSTATUS,ORTYPE,ORREASON,BSDATE,MBLNO,HBLNO,CUSTOMERNAME");
strSql.Append(",SHIPPER,CONSIGNEE,NOTIFYPARTY,VESSEL,VOYNO,ETD,ETA,PlACERECEIPT,PORTLOADID,PORTLOAD,PORTDISCHARGEID,PORTDISCHARGE");
strSql.Append(",PLACEDELIVERYID,PLACEDELIVERY,DESTINATIONID,DESTINATION,NOBILL,ISSUETYPE,ISSUEDATE,ISSUEPLACE,BLFRT");
strSql.Append(",PREPARDAT,PAYABLEAT,[SERVICE],MARKS,NOPKGS,[DESCRIPTION],GOODSNAME,GROSSWEIGHT,MEASUREMENT,PKGS,KINDPKGS");
@ -1439,8 +1439,101 @@ namespace DSWeb.MvcShipping.DAL.MsOpSubSeaOrderDAL
return result;
}
#region 批量修改
public static DBResult Modify(List<MsOpSubSeaOrder> bodyList, MsOpSubSeaArrival modifydata, string companyid)
{
var result = new DBResult();
string errstr = "";
int i = 0;
Database db = DatabaseFactory.CreateDatabase();
using (var conn = db.CreateConnection())
{
conn.Open();
var tran = conn.BeginTransaction();
try
{
var strSql = new StringBuilder();
strSql.Append("update op_sub_seaorder_arrival set bsno=bsno ");
if (modifydata.OFFICEADDR != "" && modifydata.OFFICEADDR != null)
strSql.Append(",OFFICEADDR=@OFFICEADDR");
strSql.Append(" where ORDNO=@ORDNO ");
var cmdupdate =
db.GetSqlStringCommand(strSql.ToString());
if (bodyList != null)
{
foreach (var enumValue in bodyList)
{
if (modifydata.AMOUNTUSD !=0)
{
var cmdUpdateFee = db.GetSqlStringCommand("update ch_fee set EXCHANGERATE=" + modifydata.AMOUNTUSD.ToString() + " where CURRENCY='USD' AND BSNO='" + enumValue.ORDNO + "'");
db.ExecuteNonQuery(cmdUpdateFee, tran);
}
var isPost = true;
if (isPost)
{
cmdupdate.Parameters.Clear();
if (modifydata.OFFICEADDR != "" && modifydata.OFFICEADDR != null)
db.AddInParameter(cmdupdate, "@OFFICEADDR", DbType.String, modifydata.OFFICEADDR);
//if (modifydata.AIRLINES != "" && modifydata.AIRLINES != null)
// db.AddInParameter(cmdupdate, "@AIRLINES", DbType.String, modifydata.AIRLINES);
db.AddInParameter(cmdupdate, "@ORDNO", DbType.String, enumValue.ORDNO);
db.ExecuteNonQuery(cmdupdate, tran);
i = i + 1;
}
}
}
tran.Commit();
}
catch (Exception)
{
tran.Rollback();
result.Success = false;
result.Message = "修改出现错误,请重试或联系系统管理员";
return result;
}
}
result.Success = true;
result.Message = "修改成功" + i.ToString() + "票";
if (errstr != "")
{
result.Message = result.Message + "(其中" + errstr + " 无法修改)";
}
return result;
}
#endregion
#region 集装箱动态
static public List<MsOpOrderCtnStatus> GetCtnStatusList(string strCondition,string billtype,string companyid)
{

@ -554,20 +554,20 @@ namespace DSWeb.MvcShipping.DAL.MsUerAuthority
try
{
var cmdUpdate =
db.GetSqlStringCommand(
@"update user_authority_range_op set VISIBLERANGE=@VISIBLERANGE,MODIFIEDUSER=@MODIFIEDUSER,MODIFIEDTIME=@MODIFIEDTIME where GID=@GID ");
var cmdUpdateop =
var cmdInsertOp =
db.GetSqlStringCommand(
@"update user_authority_range_op set OPERATERANGE=@OPERATERANGE,MODIFIEDUSER=@MODIFIEDUSER,MODIFIEDTIME=@MODIFIEDTIME where GID=@GID ");
@"if (select GID from user_authority_range_op where USERID=@USERID and OPID=@OPID AND AUTHORITYID=@AUTHORITYID) is null "
+ " insert into user_authority_range_op (GID,USERID,AUTHORITYID,OPID,VISIBLERANGE,OPERATERANGE,CREATEUSER,CREATETIME)"
+ " values (@GID,@USERID,@AUTHORITYID,@OPID,@VISIBLERANGE,@OPERATERANGE,@CREATEUSER,@CREATETIME) else "
+ "update user_authority_range_op set OPERATERANGE=@OPERATERANGE,MODIFIEDUSER=@MODIFIEDUSER,MODIFIEDTIME=@MODIFIEDTIME where USERID=@USERID and OPID=@OPID AND AUTHORITYID=@AUTHORITYID");
var cmdInsert =
var cmdInsertVs =
db.GetSqlStringCommand(
@"insert into user_authority_range_op (GID,USERID,AUTHORITYID,OPID,VISIBLERANGE,OPERATERANGE,CREATEUSER,CREATETIME)
values (@GID,@USERID,@AUTHORITYID,@OPID,@VISIBLERANGE,@OPERATERANGE,@CREATEUSER,@CREATETIME) ");
@"if (select GID from user_authority_range_op where USERID=@USERID and OPID=@OPID AND AUTHORITYID=@AUTHORITYID) is null "
+ " insert into user_authority_range_op (GID,USERID,AUTHORITYID,OPID,VISIBLERANGE,OPERATERANGE,CREATEUSER,CREATETIME)"
+ " values (@GID,@USERID,@AUTHORITYID,@OPID,@VISIBLERANGE,@OPERATERANGE,@CREATEUSER,@CREATETIME) else "
+ "update user_authority_range_op set VISIBLERANGE=@VISIBLERANGE,MODIFIEDUSER=@MODIFIEDUSER,MODIFIEDTIME=@MODIFIEDTIME where USERID=@USERID and OPID=@OPID AND AUTHORITYID=@AUTHORITYID");
@ -576,59 +576,133 @@ namespace DSWeb.MvcShipping.DAL.MsUerAuthority
foreach (var enumValue in bodyList)
{
if (enumValue.GID == "")
if (rtype == "OP")
{
cmdInsert.Parameters.Clear();
db.AddInParameter(cmdInsert, "@GID", DbType.String, Guid.NewGuid().ToString());
db.AddInParameter(cmdInsert, "@USERID", DbType.String, enumValue.USERID);
db.AddInParameter(cmdInsert, "@AUTHORITYID", DbType.String, enumValue.AUTHORITYID);
db.AddInParameter(cmdInsert, "@OPID", DbType.String, enumValue.OPID);
if (enumValue.VISIBLERANGE)
db.AddInParameter(cmdInsert, "@VISIBLERANGE", DbType.String, "1");
else
db.AddInParameter(cmdInsert, "@VISIBLERANGE", DbType.String, "0");
cmdInsertOp.Parameters.Clear();
db.AddInParameter(cmdInsertOp, "@OPID", DbType.String, enumValue.OPID);
db.AddInParameter(cmdInsertOp, "@AUTHORITYID", DbType.String, enumValue.AUTHORITYID);
db.AddInParameter(cmdInsertOp, "@USERID", DbType.String, enumValue.USERID);
db.AddInParameter(cmdInsertOp, "@GID", DbType.String, Guid.NewGuid().ToString());
if (enumValue.OPERATERANGE)
db.AddInParameter(cmdInsert, "@OPERATERANGE", DbType.String, "1");
db.AddInParameter(cmdInsertOp, "@OPERATERANGE", DbType.String, "1");
else
db.AddInParameter(cmdInsert, "@OPERATERANGE", DbType.String, "0");
db.AddInParameter(cmdInsert, "@CREATEUSER", DbType.String, userid);
db.AddInParameter(cmdInsert, "@CREATETIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
db.ExecuteNonQuery(cmdInsert, tran);
db.AddInParameter(cmdInsertOp, "@OPERATERANGE", DbType.String, "0");
if (enumValue.VISIBLERANGE)
db.AddInParameter(cmdInsertOp, "@VISIBLERANGE", DbType.String, "1");
else
db.AddInParameter(cmdInsertOp, "@VISIBLERANGE", DbType.String, "0");
//db.AddInParameter(cmdInsertOp, "@VISIBLERANGE", DbType.String, "0");
db.AddInParameter(cmdInsertOp, "@CREATEUSER", DbType.String, userid);
db.AddInParameter(cmdInsertOp, "@CREATETIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
db.AddInParameter(cmdInsertOp, "@MODIFIEDUSER", DbType.String, userid);
db.AddInParameter(cmdInsertOp, "@MODIFIEDTIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
db.ExecuteNonQuery(cmdInsertOp, tran);
}
else
{
if (rtype == "OP")
{
cmdUpdateop.Parameters.Clear();
db.AddInParameter(cmdUpdateop, "@GID", DbType.String, enumValue.GID);
else {
cmdInsertVs.Parameters.Clear();
db.AddInParameter(cmdInsertVs, "@OPID", DbType.String, enumValue.OPID);
db.AddInParameter(cmdInsertVs, "@AUTHORITYID", DbType.String, enumValue.AUTHORITYID);
db.AddInParameter(cmdInsertVs, "@USERID", DbType.String, enumValue.USERID);
db.AddInParameter(cmdInsertVs, "@GID", DbType.String, Guid.NewGuid().ToString());
if (enumValue.OPERATERANGE)
db.AddInParameter(cmdUpdateop, "@OPERATERANGE", DbType.String, "1");
db.AddInParameter(cmdInsertVs, "@OPERATERANGE", DbType.String, "1");
else
db.AddInParameter(cmdUpdateop, "@OPERATERANGE", DbType.String, "0");
db.AddInParameter(cmdUpdateop, "@MODIFIEDUSER", DbType.String, userid);
db.AddInParameter(cmdUpdateop, "@MODIFIEDTIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
db.ExecuteNonQuery(cmdUpdateop, tran);
}
if (rtype == "VS")
{
cmdUpdate.Parameters.Clear();
db.AddInParameter(cmdUpdate, "@GID", DbType.String, enumValue.GID);
db.AddInParameter(cmdInsertVs, "@OPERATERANGE", DbType.String, "0");
if (enumValue.VISIBLERANGE)
db.AddInParameter(cmdUpdate, "@VISIBLERANGE", DbType.String, "1");
db.AddInParameter(cmdInsertVs, "@VISIBLERANGE", DbType.String, "1");
else
db.AddInParameter(cmdUpdate, "@VISIBLERANGE", DbType.String, "0");
db.AddInParameter(cmdUpdate, "@MODIFIEDUSER", DbType.String, userid);
db.AddInParameter(cmdUpdate, "@MODIFIEDTIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
db.ExecuteNonQuery(cmdUpdate, tran);
db.AddInParameter(cmdInsertVs, "@VISIBLERANGE", DbType.String, "0");
//db.AddInParameter(cmdInsertOp, "@VISIBLERANGE", DbType.String, "0");
db.AddInParameter(cmdInsertVs, "@CREATEUSER", DbType.String, userid);
db.AddInParameter(cmdInsertVs, "@CREATETIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
db.AddInParameter(cmdInsertVs, "@MODIFIEDUSER", DbType.String, userid);
db.AddInParameter(cmdInsertVs, "@MODIFIEDTIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
db.ExecuteNonQuery(cmdInsertVs, tran);
}
}
}
}
//var cmdUpdate =
// db.GetSqlStringCommand(
// @"update user_authority_range_op set VISIBLERANGE=@VISIBLERANGE,MODIFIEDUSER=@MODIFIEDUSER,MODIFIEDTIME=@MODIFIEDTIME where GID=@GID ");
//var cmdUpdateop =
// db.GetSqlStringCommand(
// @"update user_authority_range_op set OPERATERANGE=@OPERATERANGE,MODIFIEDUSER=@MODIFIEDUSER,MODIFIEDTIME=@MODIFIEDTIME where GID=@GID ");
//var cmdInsert =
// db.GetSqlStringCommand(
// @"insert into user_authority_range_op (GID,USERID,AUTHORITYID,OPID,VISIBLERANGE,OPERATERANGE,CREATEUSER,CREATETIME)
// values (@GID,@USERID,@AUTHORITYID,@OPID,@VISIBLERANGE,@OPERATERANGE,@CREATEUSER,@CREATETIME) ");
//if (bodyList != null)
//{
// foreach (var enumValue in bodyList)
// {
// if (enumValue.GID == "")
// {
// cmdInsert.Parameters.Clear();
// db.AddInParameter(cmdInsert, "@GID", DbType.String, Guid.NewGuid().ToString());
// db.AddInParameter(cmdInsert, "@USERID", DbType.String, enumValue.USERID);
// db.AddInParameter(cmdInsert, "@AUTHORITYID", DbType.String, enumValue.AUTHORITYID);
// db.AddInParameter(cmdInsert, "@OPID", DbType.String, enumValue.OPID);
// if (enumValue.VISIBLERANGE)
// db.AddInParameter(cmdInsert, "@VISIBLERANGE", DbType.String, "1");
// else
// db.AddInParameter(cmdInsert, "@VISIBLERANGE", DbType.String, "0");
// if (enumValue.OPERATERANGE)
// db.AddInParameter(cmdInsert, "@OPERATERANGE", DbType.String, "1");
// else
// db.AddInParameter(cmdInsert, "@OPERATERANGE", DbType.String, "0");
// db.AddInParameter(cmdInsert, "@CREATEUSER", DbType.String, userid);
// db.AddInParameter(cmdInsert, "@CREATETIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
// db.ExecuteNonQuery(cmdInsert, tran);
// }
// else
// {
// if (rtype == "OP")
// {
// cmdUpdateop.Parameters.Clear();
// db.AddInParameter(cmdUpdateop, "@GID", DbType.String, enumValue.GID);
// if (enumValue.OPERATERANGE)
// db.AddInParameter(cmdUpdateop, "@OPERATERANGE", DbType.String, "1");
// else
// db.AddInParameter(cmdUpdateop, "@OPERATERANGE", DbType.String, "0");
// db.AddInParameter(cmdUpdateop, "@MODIFIEDUSER", DbType.String, userid);
// db.AddInParameter(cmdUpdateop, "@MODIFIEDTIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
// db.ExecuteNonQuery(cmdUpdateop, tran);
// }
// if (rtype == "VS")
// {
// cmdUpdate.Parameters.Clear();
// db.AddInParameter(cmdUpdate, "@GID", DbType.String, enumValue.GID);
// if (enumValue.VISIBLERANGE)
// db.AddInParameter(cmdUpdate, "@VISIBLERANGE", DbType.String, "1");
// else
// db.AddInParameter(cmdUpdate, "@VISIBLERANGE", DbType.String, "0");
// db.AddInParameter(cmdUpdate, "@MODIFIEDUSER", DbType.String, userid);
// db.AddInParameter(cmdUpdate, "@MODIFIEDTIME", DbType.String, DateTime.Now.ToString("yyyy-MM-dd"));
// db.ExecuteNonQuery(cmdUpdate, tran);
// }
// }
// }
//}
tran.Commit();

@ -0,0 +1,58 @@
<%@ Page Title="" Language="C#" MasterPageFile="~/Areas/MvcShipping/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>
<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeBasicModel.js"></script>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsOpSubSeaOrder/MsOpSubSeaOrderModel.js"></script>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsChFee/FeeMode.js"></script>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsChFee/FeeComm.js"></script>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsChFee/FeeAudit.js"></script>
<%-- <script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsChFee/FeeDrCrGrid.js"></script> --%>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsFeeTemplate/FeeTemplateMode.js"></script>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsOpSubSeaOrder/FeeTemplatePLAdd.js"></script>
<script type="text/javascript"">
Ext.onReady(function () {
Ext.QuickTips.init();
Ext.form.Field.prototype.msgTarget = 'side';
var panelIndex = null;
panelIndex = new Shipping.FeeTemplatePLAdd({
region: 'center',
layout: 'border'
});
var view = new Ext.Viewport({
layout: 'border',
renderTo: 'viewport',
border: false,
autoScroll:true,
items: [{
region: 'center',
layout: 'fit',
items: [panelIndex]
}]
});
});
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="head" runat="server">
<div id="viewport" ></div>
</asp:Content>

@ -33,6 +33,7 @@
DEPTNAME = '<%= Session["DEPTNAME"] %>';
}
getSessgion5();
var strLANGUAGES = "en-us";
</script>

@ -33,6 +33,7 @@
DEPTNAME = '<%= Session["DEPTNAME"] %>';
}
getSessgion5();
var strLANGUAGES = "en-us";
</script>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsChFee/Zi_en-us.js"></script>

@ -33,6 +33,7 @@
DEPTNAME = '<%= Session["DEPTNAME"] %>';
}
getSessgion5();
var strLANGUAGES = "en-us";
</script>
<script type="text/javascript" src="../../../../Areas/MvcShipping/Viewsjs/MsChFee/Zi_en-us.js"></script>

@ -601,9 +601,11 @@ Ext.extend(Shipping.FeeTemplatePLAdd, Ext.Panel, {
if (parentWin) {
var ret = parentWin.OprationSwap();
_thisfeetemppl.BillType = ret[4];
_thisfeetemppl.OrType = ret[5];
_thisfeetemppl.strbsno = ret[6];
_thisfeetemppl.storeBodyAddList.load({
params: { start: 0, limit: 1000, sort: '', condition: _thisfeetemppl.strbsno },
params: { start: 0, limit: 1000, sort: '', condition: _thisfeetemppl.strbsno, billtype: _thisfeetemppl.BillType, ortype: _thisfeetemppl.OrType },
waitMsg: "正在查询数据...",
callback: function (r, options, success) {
if (success) {

@ -13,6 +13,7 @@ Ext.extend(Shipping.MsOpSubSeaeImportAIndex, Ext.Panel, {
isShowAdvancedQuery: 0, //是否显示高级查询面板
IsAudit: false,
BillType: 1,
sqlcontext: '',
OrType:1,
@ -212,12 +213,13 @@ Ext.extend(Shipping.MsOpSubSeaeImportAIndex, Ext.Panel, {
header: 'KINDPKGS',
width: 60
}];
this.GridCheckBoxModel = Ext.create('Ext.selection.CheckboxModel');
//定义Grid
this.gridList = new Ext.grid.GridPanel({
store: this.storeList,
enableHdMenu: false,
region: 'center',
selModel: this.GridCheckBoxModel,
loadMask: { msg: "LoadingWait..." },
trackMouseOver: true,
disableSelection: false,
@ -420,6 +422,17 @@ Ext.extend(Shipping.MsOpSubSeaeImportAIndex, Ext.Panel, {
}],
scope: this
}, {
text: "Batch fee Add",
handler: function (button, event) {
this.onPiLiangAddFeeTemplate();
},
scope: this
}, {
text: "Batch Edit", //"业务批量修改",
handler: function (menu, event) {
_this.winModifyShow.show();
}
}, '-', {
text: "Save Display List",
id: "btntest",
@ -460,6 +473,123 @@ Ext.extend(Shipping.MsOpSubSeaeImportAIndex, Ext.Panel, {
Ext.apply(store.proxy.extraParams, { condition: sql, billtype: this.BillType, ortype: this.OrType });
}, this);
this.StoreOfficeAddr = Ext.create('DsExt.ux.RefTableStore', {
model: 'MsSubSeaOrderYard',
proxy: { url: '/MvcShipping/MsOpSubSeaOrder/GetArrivalYardList' }
});
this.StoreOfficeAddr.load({ params: { condition: "" } });
this.comboxOfficeAddr = Ext.create('DsExt.ux.RefTableCombox', {
store: this.StoreOfficeAddr,
name: 'OFFICEADDRID',
fieldLabel: '搬入場所',
valueField: 'YARDCODE',
displayField: 'YARDCODE',
listeners: {
scope: this,
'select': function (combo, records, eOpts) {
if (records.length > 0) {
var selectrecords = DsStoreQueryBy(this.StoreOfficeAddr, 'YARDCODE', combo.value);
if (selectrecords.getCount() > 0) {
var selectdata = selectrecords.getAt(0).data;
this.formModify.getForm().findField('OFFICEADDR').setValue(selectdata.DESCRIP);
} else {
this.formModify.getForm().findField('OFFICEADDR').setValue('');
}
}
}
}
});
this.formModify = Ext.widget('form', {
region: 'north',
frame: true,
bodyPadding: 5,
fieldDefaults: {
margins: '2 2 2 2',
labelAlign: 'right',
flex: 1,
labelWidth: 70,
msgTarget: 'qtip'
},
items: [
{//fieldset 1
xtype: 'fieldset',
defaultType: 'textfield',
layout: 'anchor',
defaults: {
anchor: '100%'
},
items: [{
xtype: 'container',
layout: 'hbox',
defaultType: 'textfield',
items: [ {
fieldLabel: '美元汇率',
name: 'AMOUNTUSD'
}
]
}, {
xtype: 'container',
layout: 'anchor',
flex: 1,
defaultType: 'textfield',
items: [
this.comboxOfficeAddr,
{
xtype: 'textareafield',
fieldLabel: '&nbsp&nbsp',
grow: true,
height: 50,
name: 'OFFICEADDR',
anchor: '100%'
}
]
}
]//end items(fieldset 1)
}//end fieldset 1
]//end root items
}); //end this.formEdit
me = this;
this.winModifyShow = Ext.create('Ext.window.Window', {
title: "批量修改",
width: 820,
//height : 120,
//plain : true,
iconCls: "addicon",
resizable: false,
// 是否可以拖动
// draggable:false,
collapsible: true, // 允许缩放条
closeAction: 'close',
closable: true,
modal: 'true',
buttonAlign: "center",
bodyStyle: "padding:0 0 0 0",
items: [this.formModify],
buttons: [{
text: "确认修改",
minWidth: 70,
handler: function () {
me.onModifyClick()
}
}, {
text: "关闭",
minWidth: 70,
handler: function () {
me.winModifyShow.close();
}
}]
});
}, //end initUIComponents
@ -467,6 +597,7 @@ Ext.extend(Shipping.MsOpSubSeaeImportAIndex, Ext.Panel, {
onRefreshClick: function (button, event) {
//var girdcolums = this.gridList.getColumnMode();
var sql = this.getCondition();
this.sqlcontext = sql;
this.storeList.load({
params: { start: 0, limit: this.PageSize, sort: '', condition: sql, billtype: this.BillType, ortype: this.OrType },
waitMsg: "Data being queried...",
@ -627,8 +758,70 @@ Ext.extend(Shipping.MsOpSubSeaeImportAIndex, Ext.Panel, {
},
onModifyClick: function (menu, event) {
var GidStr = '';
var records = this.GridCheckBoxModel.selected.items;
if (records.length == 0) {
Ext.Msg.show({ title: '提示', msg: '请先选择要修改的业务!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
return;
}
var bodyAddDatas = [];
for (var i = 0; i < records.length; i++) {
var rec = records[i];
bodyAddDatas.push(rec);
}
var data = this.formModify.getForm().getValues();
_this = this;
if (bodyAddDatas.length == 0) {
Ext.Msg.show({ title: '提示', msg: '没有要修改的业务!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
return;
} else {
var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas);
Ext.Ajax.request({
waitMsg: '正在更新...',
url: '/MvcShipping/MsOpSubSeaOrder/modify',
params: {
data: jsonbodyAddDatas,
modifydata: Ext.JSON.encode(data)
},
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.show({ title: '提示', msg: result.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
_this.onRefreshClick();
_this.winModifyShow.close();
}
onPiLiangAddFeeTemplate: function (menu, event, type) {
} else {
Ext.MessageBox.alert('请求出现错误,请重试', response.responseText);
}
},
scope: this
});
}
},
onPiLiangAddFeeTemplate: function () {
var selections = this.GridCheckBoxModel.selected.items;
if (selections.length == 0) {

@ -1539,6 +1539,7 @@ Ext.extend(Shipping.RptCwGenlegAccitemsIndex, Ext.Panel, {
ACCDATEend: ACCDATEend,
strCbHSKM: strCbHSKM,
strCURRENCY: strCURRENCY,
strCbJZFS: strCbJZFS,
printstr: 'true'
},
callback: function (options, success, response) {

@ -2861,6 +2861,7 @@
<Content Include="Areas\MvcShipping\Views\MsOpSeaePre\Index.aspx" />
<Content Include="Areas\MvcShipping\Views\MsOpSeaePre\ModifyEdit.aspx" />
<Content Include="Areas\MvcShipping\Views\MsOpSeaePre\ModifyHisEdit.aspx" />
<Content Include="Areas\MvcShipping\Views\MsOpSubSeaOrder\AddFeePLIndex.aspx" />
<Content Include="Areas\MvcShipping\Views\MsRptChInvTotal\BsCrView.aspx" />
<Content Include="Areas\MvcShipping\Views\MsRptCwBaoXiao\Index.aspx" />
<Content Include="Areas\MvcShipping\Views\MsRptFeeSettleStatus\ZnjIndex.aspx" />

@ -55,7 +55,7 @@ namespace JobCreateFee
var strSqlBs = new StringBuilder();
strSqlBs.Clear();
strSqlBs.Append("select B.BSNO,B.MBLNO,B.CUSTOMERNAME,B.CARRIER,B.FORWARDER,B.CUSTOMSER,B.SHIPAGENCY,B.YARD,B.AGENTID,B.OP ");
strSqlBs.Append(" from v_op_bs B where ISNULL(FEESTATUS,0)=0 ");
strSqlBs.Append(" from v_op_bs B where ISNULL(FEESTATUS,0)=0 AND OPLB='" + enumFeeproject.OPTYPE + "' ");
if (!string.IsNullOrEmpty(enumFeeproject.PROJECTTYPE))
{
strSqlBs.Append(" AND not EXISTS (SELECT 1 FROM op_auto_fee_detail D WHERE D.BSNO=B.BSNO AND D.FEEGROUP='" + enumFeeproject.PROJECTTYPE + "' AND D.FEETYPE=" + enumFeeproject.FEETYPE + ") ");

Loading…
Cancel
Save