diff --git a/DSWeb/Areas/Account/Controllers/Chfee_invoiceapplicationController.cs b/DSWeb/Areas/Account/Controllers/Chfee_invoiceapplicationController.cs
index fdc8d98e..2e1a9ddf 100644
--- a/DSWeb/Areas/Account/Controllers/Chfee_invoiceapplicationController.cs
+++ b/DSWeb/Areas/Account/Controllers/Chfee_invoiceapplicationController.cs
@@ -78,7 +78,17 @@ namespace DSWeb.Areas.Account.Controllers
public ContentResult GetAuditDataList(int start, int limit, string sort, string condition, string isaudit)
{
- var dataList = ChinvoiceapplicationDAL.GetAuditDataList(condition, Convert.ToString(Session["USERID"]), isaudit, Convert.ToString(Session["COMPANYID"]), sort);
+ var dataList = ChinvoiceapplicationDAL.GetAuditDataList(start, limit,condition, Convert.ToString(Session["USERID"]), isaudit, Convert.ToString(Session["COMPANYID"]), sort);
+ //var list = dataList.Skip(start).Take(limit);
+ var list = dataList;
+
+ var json = JsonConvert.Serialize(new { Success = true, Message = "查询成功", totalCount = dataList.Count, data = list }); //list.ToList()
+ return new ContentResult() { Content = json };
+ }
+
+ public ContentResult GetAuditDataList_App(int start, int limit, string sort, string condition, string isaudit, string userid, string companyid)
+ {
+ var dataList = ChinvoiceapplicationDAL.GetAuditDataList(start, limit, condition, userid, isaudit, companyid, sort);
var list = dataList.Skip(start).Take(limit);
var json = JsonConvert.Serialize(new { Success = true, Message = "查询成功", totalCount = dataList.Count, data = list.ToList() });
diff --git a/DSWeb/Areas/Account/Controllers/Chfee_payapplicationController.cs b/DSWeb/Areas/Account/Controllers/Chfee_payapplicationController.cs
index 26005e46..832e2ea0 100644
--- a/DSWeb/Areas/Account/Controllers/Chfee_payapplicationController.cs
+++ b/DSWeb/Areas/Account/Controllers/Chfee_payapplicationController.cs
@@ -145,94 +145,7 @@ namespace DSWeb.Areas.Account.Controllers
return new ContentResult() { Content = json };
}
- ///
- /// 用于提供给app的查询入口
- /// 需传入userid
- ///
- ///
- ///
- ///
- ///
-
- /*
-
- public class AppParam {
- public string userid { get; set; }
- public string formname { get; set; }
- public string isaudit { get; set; }
- public string condition { get; set; }
-
- }
-
-
-
- public ContentResult AppInterface()
- {
- StreamReader sr = new StreamReader(Request.InputStream, Encoding.UTF8);
- var strJson = new StringBuilder();
- string line = null;
- while (((line = sr.ReadLine())) != null)
- {
- strJson.Append(line);
- }
- var appparam = JsonConvert.Deserialize(strJson.ToString());
-
- var cdc = new CommonDataContext();
-
- string userid = appparam.userid;
- string formname = appparam.formname;
- string isaudit = appparam.isaudit;
- string condition = appparam.condition;
-
- var userlist = cdc.VW_user.Where(x => x.USERID == userid).ToList();
-
-
-
- if (userlist == null || userlist.Count == 0)
- {
- var json0 = JsonConvert.Serialize(new { Success = false, Message = "没有找到用户" });
- return new ContentResult() { Content = json0 };
- }
-
- var json = JsonConvert.Serialize(new { Success = true, Message = "未找到查询方法" });
-
- var user = userlist[0];
-
- if (formname == "查询列表") {
-
- var dataList = ChpayapplicationDAL.GetAuditDataList(condition, user.USERID, isaudit, user.SHOWNAME, user.COMPANYID, null);
- var json1 = JsonConvert.Serialize(new { Success = true, Message = "查询成功", data = dataList.ToList() });
- return new ContentResult() { Content = json1 };
- }
- if (formname == "查询明细")
- {
- var dataList = ChpayapplicationDAL.GetBodyAuditList(0, 9999, condition, "");
- var json1 = JsonConvert.Serialize(new { Success = true, Message = "查询成功", data = dataList.ToList() });
- return new ContentResult() { Content = json1 };
- }
- if (formname == "审批通过")
- {
- var audithead = ChpayapplicationDAL.GetData(condition, user.USERID, user.SHOWNAME, user.COMPANYID);
- var bodyList = new List() { audithead };
-
- DBResult result = ChpayapplicationDAL.AuditList(bodyList, Convert.ToString(Session["USERID"]));
-
- return BasicDataRefDAL.GetContentResult(result);
- }
- if (formname == "驳回")
- {
- var audithead = ChpayapplicationDAL.GetData(condition, user.USERID, user.SHOWNAME, user.COMPANYID);
- var bodyList = new List() { audithead };
-
- DBResult result = ChpayapplicationDAL.AuditBackList(bodyList, user.USERID, isaudit);
-
- var jsonRespose = new JsonResponse { Success = result.Success, Message = result.Message };
- return new ContentResult() { Content = JsonConvert.Serialize(jsonRespose) };
- }
- return new ContentResult() { Content = json };
- }
- */
public ContentResult GetData(string handle, string condition)
{
ChPayapplication head = null;
diff --git a/DSWeb/Areas/Account/DAL/Chfee_invoiceapplication/Chfee_InvoiceapplicationDAL.cs b/DSWeb/Areas/Account/DAL/Chfee_invoiceapplication/Chfee_InvoiceapplicationDAL.cs
index b6121cf1..e2d5b229 100644
--- a/DSWeb/Areas/Account/DAL/Chfee_invoiceapplication/Chfee_InvoiceapplicationDAL.cs
+++ b/DSWeb/Areas/Account/DAL/Chfee_invoiceapplication/Chfee_InvoiceapplicationDAL.cs
@@ -2943,11 +2943,27 @@ namespace DSWeb.Areas.Account.DAL.Chfee_Invoiceapplication
#region 发票审核列表
- static public List GetAuditDataList(string strCondition, string userid, string isaudit,string companyid,string sort = null)
+ static public List GetAuditDataList(int start,int limit, string strCondition, string userid, string isaudit,string companyid,string sort = null)
{
var strSql = new StringBuilder();
- strSql.Append(" SELECT i.GID,i.BILLNO,i.BILLSTATUS,i.CUSTOMERNAME,i.ACTUALCUSTOMERNAME,i.CURRENCY,i.INVOICENO,i.INVOICECUSTNAME,i.INVOICECATEGORY ");
+
+ strSql.Append(@"SELECT * from (SELECT row_number() over (");
+
+ var sortstring = DatasetSort.Getsortstring(sort);
+ if (!string.IsNullOrEmpty(sortstring))
+ {
+ strSql.Append(" order by " + sortstring);
+ }
+ else
+ {
+ strSql.Append(" order by APPLYTIME desc ");
+ }
+ strSql.Append(@") as num , ");
+
+ //strSql.Append(" SELECT ");
+
+ strSql.Append(" i.GID,i.BILLNO,i.BILLSTATUS,i.CUSTOMERNAME,i.ACTUALCUSTOMERNAME,i.CURRENCY,i.INVOICENO,i.INVOICECUSTNAME,i.INVOICECATEGORY ");
strSql.Append(" ,i.BSNO,i.MBLNO,i.VESSELVOYAGE,i.POL,i.POD,i.ETD,i.APPLYAMOUNT,i.INVAMOUNT,i.AMOUNTCAPITAL,i.OTCURRAMOUNT");
strSql.Append(" ,i.APPLICANT,i.APPLYTIME,i.ENTERTIME,i.OPERATOR,i.OPERATETIME,i.RECVCURR,i.FEEAMOUNT ");
strSql.Append(" ,i.REMARK,i.SHENREMARK,i.COMPANYID,i.ISAPPLY,i.CUSTRATENO,i.CUSTADDRTEL,i.CUSTBANK,i.RATE,'' INVOICENOREF,null INVDATE ");
@@ -2959,12 +2975,12 @@ namespace DSWeb.Areas.Account.DAL.Chfee_Invoiceapplication
strSql.Append(",PUSHMODE,PUSHMOBILE,PUSHEMAIL,dbo.F_getEnumValue(0,80002,i.PUSHMODE) as PUSHMODEREF,'' as NOSTL");
strSql.Append(" FROM ch_fee_invoiceapplication i left join workflow_using wu on wu.bsno=i.billno where 1=1 ");
+
if (isaudit=="1")
strSql.Append(" and i.BILLSTATUS=2 and dbo.[GetUsingStep](wu.WORKFLOWID,wu.currentid,'" + userid + "',wu.stepno)>0 ");
else if (isaudit == "2")
// strSql.Append(" and i.BILLSTATUS=0 AND I.BILLNO IN (select distinct billno from workflow_do where auditor='" + userid + "' ) ");
strSql.Append(" and i.BILLSTATUS=0 ");
-
else if (isaudit == "")
{
var rangstr = GetRangDAListStr("", userid,"", companyid);
@@ -2981,16 +2997,19 @@ namespace DSWeb.Areas.Account.DAL.Chfee_Invoiceapplication
strSql.Append(" and " + strCondition);
}
- var sortstring = DatasetSort.Getsortstring(sort);
- if (!string.IsNullOrEmpty(sortstring))
- {
- strSql.Append(" order by " + sortstring);
- }
- else
- {
- strSql.Append(" order by APPLYTIME desc ");
+ //var sortstring = DatasetSort.Getsortstring(sort);
+ //if (!string.IsNullOrEmpty(sortstring))
+ //{
+ // strSql.Append(" order by " + sortstring);
+ //}
+ //else
+ //{
+ // strSql.Append(" order by APPLYTIME desc ");
+ //}
+
+ strSql.Append(@")as t ");
+ strSql.Append(string.Format("where t.num>{0} and t.num<={1} ", start, start + limit));
- }
return SetData(strSql);
}
diff --git a/DSWeb/Areas/CommMng/Controllers/DSWEBAPPInterfaceController.cs b/DSWeb/Areas/CommMng/Controllers/DSWEBAPPInterfaceController.cs
index bdc394bd..267cb310 100644
--- a/DSWeb/Areas/CommMng/Controllers/DSWEBAPPInterfaceController.cs
+++ b/DSWeb/Areas/CommMng/Controllers/DSWEBAPPInterfaceController.cs
@@ -187,7 +187,7 @@ namespace DSWeb.Areas.CommMng.Controllers
}
///
- /// 付费发票审核
+ /// 往来单位审批
///
///
public ContentResult InfoClientAuditInterface()
@@ -256,6 +256,77 @@ namespace DSWeb.Areas.CommMng.Controllers
}
return new ContentResult() { Content = json };
}
+
+ ///
+ /// 发票申请审批
+ ///
+ ///
+ public ContentResult InvApplicationAuditInterface()
+ {
+ StreamReader sr = new StreamReader(Request.InputStream, Encoding.UTF8);
+ var strJson = new StringBuilder();
+ string line = null;
+ while (((line = sr.ReadLine())) != null)
+ {
+ strJson.Append(line);
+ }
+ var appparam = JsonConvert.Deserialize(strJson.ToString());
+
+ var cdc = new CommonDataContext();
+
+ string userid = appparam.userid;
+ string formname = appparam.formname;
+ string isaudit = appparam.isaudit;
+ string condition = appparam.condition;
+
+ var userlist = cdc.VW_user.Where(x => x.USERID == userid).ToList();
+
+
+ if (userlist == null || userlist.Count == 0)
+ {
+ var json0 = JsonConvert.Serialize(new { Success = false, Message = "没有找到用户" });
+ return new ContentResult() { Content = json0 };
+ }
+
+ var json = JsonConvert.Serialize(new { Success = true, Message = "未找到查询方法" });
+
+ var user = userlist[0];
+
+ if (formname == "查询列表")
+ {
+
+ var dataList = ChpayapplicationDAL.GetAuditDataList(condition, user.USERID, isaudit, user.SHOWNAME, user.COMPANYID, null);
+ var json1 = JsonConvert.Serialize(new { Success = true, Message = "查询成功", data = dataList.ToList() });
+ return new ContentResult() { Content = json1 };
+ }
+ if (formname == "查询明细")
+ {
+ var dataList = ChpayapplicationDAL.GetBodyAuditList(0, 9999, condition, "");
+ var json1 = JsonConvert.Serialize(new { Success = true, Message = "查询成功", data = dataList.ToList() });
+ return new ContentResult() { Content = json1 };
+ }
+ if (formname == "审批通过")
+ {
+ var audithead = ChpayapplicationDAL.GetData(condition, user.USERID, user.SHOWNAME, user.COMPANYID);
+ var bodyList = new List() { audithead };
+
+ DBResult result = ChpayapplicationDAL.AuditList(bodyList, user.USERID);
+
+ return BasicDataRefDAL.GetContentResult(result);
+ }
+ if (formname == "驳回")
+ {
+ var audithead = ChpayapplicationDAL.GetData(condition, user.USERID, user.SHOWNAME, user.COMPANYID);
+ var bodyList = new List() { audithead };
+
+ DBResult result = ChpayapplicationDAL.AuditBackList(bodyList, user.USERID, isaudit);
+
+ var jsonRespose = new JsonResponse { Success = result.Success, Message = result.Message };
+ return new ContentResult() { Content = JsonConvert.Serialize(jsonRespose) };
+ }
+ return new ContentResult() { Content = json };
+ }
+
}
}
\ No newline at end of file
diff --git a/DSWeb/Areas/SoftMng/Controllers/ExportController.cs b/DSWeb/Areas/SoftMng/Controllers/ExportController.cs
index 38f93cea..18ce4393 100644
--- a/DSWeb/Areas/SoftMng/Controllers/ExportController.cs
+++ b/DSWeb/Areas/SoftMng/Controllers/ExportController.cs
@@ -3714,8 +3714,6 @@ string swcn = "2020030084935", string swpw = "8a5889ea8e53b257e2a3ba053979ee64"
if (port_decMergeListVoList.Count > 0)
{
-
-
foreach (var port_decMergeListVo in port_decMergeListVoList)
{
diff --git a/DSWeb/DSWeb.csproj.user b/DSWeb/DSWeb.csproj.user
index a8615099..c976d660 100644
--- a/DSWeb/DSWeb.csproj.user
+++ b/DSWeb/DSWeb.csproj.user
@@ -2,7 +2,7 @@
ShowAllFiles
- 配置文件1
+ H:\DS7_dev\DSWeb\Properties\PublishProfiles\FolderProfile.pubxml
true
Debug|Any CPU