代码提交
This commit is contained in:
parent
8b968e1c25
commit
d6676fcb70
|
|
@ -14,6 +14,8 @@ using WX.CRM.Model.Enum;
|
||||||
using WX.CRM.Model.MAP;
|
using WX.CRM.Model.MAP;
|
||||||
using WX.CRM.BLL.Application.UserComBox;
|
using WX.CRM.BLL.Application.UserComBox;
|
||||||
using WX.CRM.Model.QueryMap;
|
using WX.CRM.Model.QueryMap;
|
||||||
|
using System.Data.OracleClient;
|
||||||
|
using WX.CRM.DAL;
|
||||||
|
|
||||||
namespace WX.CRM.BLL.Ord
|
namespace WX.CRM.BLL.Ord
|
||||||
{
|
{
|
||||||
|
|
@ -97,7 +99,7 @@ namespace WX.CRM.BLL.Ord
|
||||||
/// <param name="userComboDto"></param>
|
/// <param name="userComboDto"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
private IQueryable<ORD_SERVICEMEMO> GetQuery(IQueryable<ORD_SERVICEMEMO> queryData, WX.CRM.Model.Entity.crmContext db,
|
private IQueryable<ORD_SERVICEMEMO> GetQuery(IQueryable<ORD_SERVICEMEMO> queryData, WX.CRM.Model.Entity.crmContext db,
|
||||||
string memoId, string stime, string etime,string resid, decimal MemoType, decimal MemoSubtype, string content, QueryUserComboDto userComboDto)
|
string memoId, string stime, string etime, string resid, decimal MemoType, decimal MemoSubtype, string content, QueryUserComboDto userComboDto)
|
||||||
{
|
{
|
||||||
if (!string.IsNullOrEmpty(memoId))
|
if (!string.IsNullOrEmpty(memoId))
|
||||||
{
|
{
|
||||||
|
|
@ -120,7 +122,7 @@ namespace WX.CRM.BLL.Ord
|
||||||
queryData = queryData.Where(a => a.CTIME <= dt2);
|
queryData = queryData.Where(a => a.CTIME <= dt2);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!string.IsNullOrWhiteSpace(resid))
|
if (!string.IsNullOrWhiteSpace(resid))
|
||||||
queryData = queryData.Where(a => a.RESID == resid);
|
queryData = queryData.Where(a => a.RESID == resid);
|
||||||
|
|
||||||
if (MemoType != 0)
|
if (MemoType != 0)
|
||||||
|
|
@ -158,9 +160,9 @@ namespace WX.CRM.BLL.Ord
|
||||||
}
|
}
|
||||||
queryData = (from a in queryData
|
queryData = (from a in queryData
|
||||||
join b in db.BAS_INNERUSERGROUP on a.INNERUSERID equals b.INNERUSERID
|
join b in db.BAS_INNERUSERGROUP on a.INNERUSERID equals b.INNERUSERID
|
||||||
//join g in db.BAS_INNERGROUP on b.GID equals g.GID
|
//join g in db.BAS_INNERGROUP on b.GID equals g.GID
|
||||||
where ALLdeptIDS.Contains(b.DEPTID.Value) || ALLgidS.Contains(b.GID.Value)
|
where ALLdeptIDS.Contains(b.DEPTID.Value) || ALLgidS.Contains(b.GID.Value)
|
||||||
select a);
|
select a);
|
||||||
}
|
}
|
||||||
else if (userComboDto.companyId.HasValue)
|
else if (userComboDto.companyId.HasValue)
|
||||||
{
|
{
|
||||||
|
|
@ -183,7 +185,7 @@ namespace WX.CRM.BLL.Ord
|
||||||
using (var db = new WX.CRM.Model.Entity.crmContext())
|
using (var db = new WX.CRM.Model.Entity.crmContext())
|
||||||
{
|
{
|
||||||
var queryData = db.ORD_SERVICEMEMO.AsQueryable();
|
var queryData = db.ORD_SERVICEMEMO.AsQueryable();
|
||||||
queryData = GetQuery(queryData, db, memoId, stime, etime,resid, MemoType, MemoSubtype, null, userComboDto);
|
queryData = GetQuery(queryData, db, memoId, stime, etime, resid, MemoType, MemoSubtype, null, userComboDto);
|
||||||
//return queryData.Select(m => m.RESID).Distinct().ToList();
|
//return queryData.Select(m => m.RESID).Distinct().ToList();
|
||||||
//var q =
|
//var q =
|
||||||
//from p in queryData
|
//from p in queryData
|
||||||
|
|
@ -401,7 +403,7 @@ namespace WX.CRM.BLL.Ord
|
||||||
#endregion
|
#endregion
|
||||||
#region 获取所有的工单
|
#region 获取所有的工单
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 获取所有工单的前十五条数据
|
/// 获取所有工单的前第一条数据
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="ResId"></param>
|
/// <param name="ResId"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
|
|
@ -580,6 +582,49 @@ namespace WX.CRM.BLL.Ord
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public Dictionary<string, LastServerMemoInfo> GetLastServerMemo(IEnumerable<string> resids)
|
||||||
|
{
|
||||||
|
using (var db = new crmContext())
|
||||||
|
{
|
||||||
|
if (resids == null || !resids.Any())
|
||||||
|
return new Dictionary<string, LastServerMemoInfo>();
|
||||||
|
|
||||||
|
// 修改点1:将SqlParameter改为OracleParameter
|
||||||
|
var parameters = resids.Select((r, i) => new OracleParameter($":p{i}", r)).ToArray();
|
||||||
|
var inClause = string.Join(",", parameters.Select(p => p.ParameterName));
|
||||||
|
|
||||||
|
var sql = $@"
|
||||||
|
SELECT s.RESID, s.INNERUSERID, s.CTIME
|
||||||
|
FROM ORD_SERVICEMEMO s
|
||||||
|
WHERE s.MEMOID IN (
|
||||||
|
SELECT MAX(s2.MEMOID)
|
||||||
|
FROM ORD_SERVICEMEMO s2
|
||||||
|
WHERE s2.RESID IN ({inClause})
|
||||||
|
GROUP BY s2.RESID
|
||||||
|
)";
|
||||||
|
|
||||||
|
// 修改点2:移除不必要的类型转换
|
||||||
|
//return db.Database.SqlQuery<LastServerMemoResult>(sql, parameters)
|
||||||
|
// .ToDictionary(
|
||||||
|
// k => k.RESID,
|
||||||
|
// v => new LastServerMemoInfo
|
||||||
|
// {
|
||||||
|
// UserId = v.INNERUSERID,
|
||||||
|
// Ctime = v.CTIME
|
||||||
|
// });
|
||||||
|
var list = OracleHelper.DataQueray(CommandType.Text, sql, parameters).Tables[0].ToList<LastServerMemoResult>();
|
||||||
|
return list.ToDictionary(
|
||||||
|
k => k.RESID,
|
||||||
|
v => new LastServerMemoInfo
|
||||||
|
{
|
||||||
|
UserId = v.INNERUSERID,
|
||||||
|
Ctime = v.CTIME
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
#region addtoRedis
|
#region addtoRedis
|
||||||
private void AddToRedis(ORD_MEMOCONTENT entry, CACHE_ORD_MEMO cacheOrd, bool result = true)
|
private void AddToRedis(ORD_MEMOCONTENT entry, CACHE_ORD_MEMO cacheOrd, bool result = true)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
using System.Collections.Generic;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
using WX.CRM.Common;
|
using WX.CRM.Common;
|
||||||
using WX.CRM.Model.MAP;
|
using WX.CRM.Model.MAP;
|
||||||
|
|
||||||
|
|
@ -19,5 +20,21 @@ namespace WX.CRM.IBLL.Ord
|
||||||
List<WX.CRM.Model.Entity.ORD_SERVICEMEMO> GetNoCallTimeByMemoId(decimal[] MemoIds);
|
List<WX.CRM.Model.Entity.ORD_SERVICEMEMO> GetNoCallTimeByMemoId(decimal[] MemoIds);
|
||||||
List<WX.CRM.Model.Entity.ORD_SERVICEMEMO> GetHgServiceMemo(decimal Memoid, decimal memosubtypeId);
|
List<WX.CRM.Model.Entity.ORD_SERVICEMEMO> GetHgServiceMemo(decimal Memoid, decimal memosubtypeId);
|
||||||
WX.CRM.Model.Entity.ORD_SERVICEMEMO GetHgServiceModel(decimal Memoid);
|
WX.CRM.Model.Entity.ORD_SERVICEMEMO GetHgServiceModel(decimal Memoid);
|
||||||
|
Dictionary<string, LastServerMemoInfo> GetLastServerMemo(IEnumerable<string> resids);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 新增结果包装类
|
||||||
|
public class LastServerMemoInfo
|
||||||
|
{
|
||||||
|
public decimal? UserId { get; set; }
|
||||||
|
public DateTime? Ctime { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
// 保持原有查询结果类不变
|
||||||
|
public class LastServerMemoResult
|
||||||
|
{
|
||||||
|
public string RESID { get; set; }
|
||||||
|
public decimal? INNERUSERID { get; set; }
|
||||||
|
public DateTime? CTIME { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,153 @@
|
||||||
|
using Ninject;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Configuration;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Web;
|
||||||
|
using System.Web.Mvc;
|
||||||
|
using WX.CRM.BLL.Util;
|
||||||
|
using WX.CRM.Common;
|
||||||
|
using WX.CRM.Common.Layui;
|
||||||
|
using WX.CRM.IBLL.Ord;
|
||||||
|
using WX.CRM.IBLL.Wx;
|
||||||
|
using WX.CRM.Model.DTO;
|
||||||
|
using WX.CRM.Model.QueryMap;
|
||||||
|
using WX.CRM.WebHelper;
|
||||||
|
|
||||||
|
namespace WX.CRM.WEB.Controllers.Res
|
||||||
|
{
|
||||||
|
public class TranUserController : Controller
|
||||||
|
{
|
||||||
|
[Inject]
|
||||||
|
public CACHE_BL _cache { get; set; }
|
||||||
|
[Inject]
|
||||||
|
public IWX_SZZYMIDPRODUCT _midProduct { get; set; }
|
||||||
|
[Inject]
|
||||||
|
public IORD_SERVICEMEMO_Q _ordServerMemo { get; set; }
|
||||||
|
|
||||||
|
[HttpGet]
|
||||||
|
public ActionResult Index()
|
||||||
|
{
|
||||||
|
var data = new List<SelectListItem>();
|
||||||
|
var list = _midProduct.GetList();
|
||||||
|
foreach (var item in list)
|
||||||
|
{
|
||||||
|
data.Add(new SelectListItem() { Text = item.MIDPRODUCTNAME, Value = item.MIDPRODUCTID.ToString() });
|
||||||
|
}
|
||||||
|
ViewBag.midproductList = data;
|
||||||
|
return View();
|
||||||
|
}
|
||||||
|
[HttpPost]
|
||||||
|
public JsonResult Index(WxTranUserQueryDTO dto)
|
||||||
|
{
|
||||||
|
//LogHelper.Info($"WxTranUserQueryDTO=>{dto.ToJson()}");
|
||||||
|
|
||||||
|
var layUidata = new LayuiData<WxTranUserResultDTO>();
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var host = _cache.GetValue_Parameter("Core_ZxdService_Api");
|
||||||
|
var url = $"{host}/TranUserHandler.ashx";
|
||||||
|
|
||||||
|
// 使用列表收集非空参数
|
||||||
|
var parameters = new List<string>();
|
||||||
|
parameters.Add($"action={dto.action}");
|
||||||
|
if (!string.IsNullOrEmpty(dto.umid)) parameters.Add($"umid={dto.umid}");
|
||||||
|
if (dto.starttime.HasValue) parameters.Add($"starttime={dto.starttime}");
|
||||||
|
if (dto.endtime.HasValue) parameters.Add($"endtime={dto.endtime}");
|
||||||
|
if (!string.IsNullOrEmpty(dto.midproductId)) parameters.Add($"MidProductId={dto.midproductId}");
|
||||||
|
if (!string.IsNullOrEmpty(dto.subProductId)) parameters.Add($"SubProductId={dto.subProductId}");
|
||||||
|
if (!string.IsNullOrEmpty(dto.txt_eid)) parameters.Add($"Eid={dto.txt_eid}");
|
||||||
|
if (!string.IsNullOrEmpty(dto.txt_groupIds)) parameters.Add($"Gid={dto.txt_groupIds}");
|
||||||
|
if (!string.IsNullOrEmpty(dto.txt_deptId)) parameters.Add($"DeptId={dto.txt_deptId}");
|
||||||
|
parameters.Add($"page={dto.page}");
|
||||||
|
parameters.Add($"limit={dto.limit}");
|
||||||
|
|
||||||
|
var para = string.Join("&", parameters);
|
||||||
|
|
||||||
|
// 删除原来的 umid 判断代码(已整合到参数列表)
|
||||||
|
LogHelper.Info($"请求url=>{url}?{para}");
|
||||||
|
|
||||||
|
var result = Utility.GetData(url, para, Encoding.UTF8);
|
||||||
|
var data = result.ToObject<LayuiData<WxTranUserResultDTO>>();
|
||||||
|
|
||||||
|
var resids = data.data.Select(p => p.ResId).Distinct();
|
||||||
|
var dic = _ordServerMemo.GetLastServerMemo(resids);
|
||||||
|
|
||||||
|
foreach (var item in data.data)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(item.Eids))
|
||||||
|
{
|
||||||
|
var eidArr = item.Eids.Split(';');
|
||||||
|
var eidandname = string.Empty;
|
||||||
|
if(eidArr.Any())
|
||||||
|
{
|
||||||
|
foreach (var eid in eidArr)
|
||||||
|
{
|
||||||
|
eidandname += InnerUserHelper.Instance.GetEidAndNameByEid(Convert.ToDecimal(eid)) + ";";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
eidandname = InnerUserHelper.Instance.GetEidAndNameByEid(Convert.ToDecimal(item.Eids));
|
||||||
|
}
|
||||||
|
item.Eids = eidandname;
|
||||||
|
}
|
||||||
|
if (dic.TryGetValue(item.ResId, out LastServerMemoInfo memo))
|
||||||
|
{
|
||||||
|
item.LastServiceTime = memo.Ctime == null ? string.Empty : memo.Ctime.ToString();
|
||||||
|
item.LastServiceEid = InnerUserHelper.Instance.GetEidAndTrueName(memo.UserId);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
layUidata.msg = "数据加载成功";
|
||||||
|
layUidata.code = 0;
|
||||||
|
layUidata.data = data.data;
|
||||||
|
layUidata.count = data.count;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.Error(ex.ToString());
|
||||||
|
layUidata.SetFail(1, "出现错误!" + ex.Message);
|
||||||
|
}
|
||||||
|
return Json(layUidata);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public class WxTranUserQueryDTO
|
||||||
|
{
|
||||||
|
public string action { get; set; }
|
||||||
|
public string umid { get; set; }
|
||||||
|
public DateTime? starttime { get; set; }
|
||||||
|
public DateTime? endtime { get; set; }
|
||||||
|
public string midproductId { get; set; }
|
||||||
|
public string subProductId { get; set; }
|
||||||
|
public string txt_groupIds { get; set; }
|
||||||
|
public string txt_eid { get; set; }
|
||||||
|
public string txt_departmentid { get; set; }
|
||||||
|
public string txt_userId { get; set; }
|
||||||
|
public string txt_deptIds { get; set; }
|
||||||
|
public string txt_deptId { get; set; }
|
||||||
|
public int page { get; set; } = 1;
|
||||||
|
public int limit { get; set; } = 10;
|
||||||
|
}
|
||||||
|
|
||||||
|
public class WxTranUserResultDTO
|
||||||
|
{
|
||||||
|
public string SoftUserName { get; set; }
|
||||||
|
public string Umid { get; set; }
|
||||||
|
public string ResId { get; set; }
|
||||||
|
public string CName { get; set; }
|
||||||
|
public string MidProductId { get; set; }
|
||||||
|
public string SubProductId { get; set; }
|
||||||
|
public string SubProductName { get; set; }
|
||||||
|
public DateTime? EndTime { get; set; }
|
||||||
|
public string Eids { get; set; }
|
||||||
|
public string Gids { get; set; }
|
||||||
|
public string Deptids { get; set; }
|
||||||
|
public bool HasInComplaint { get; set; }
|
||||||
|
public bool HasOutComplaint { get; set; }
|
||||||
|
public string LastServiceTime { get; set; }
|
||||||
|
public string LastServiceEid { get; set;}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -5144,7 +5144,7 @@ namespace WX.CRM.WEB.Controllers.WeiXin
|
||||||
//产品或服务不适当警示确认书
|
//产品或服务不适当警示确认书
|
||||||
content = sHelper.encyptData(clientid, "I_DN" + order.SZZYORDERID.ToString());
|
content = sHelper.encyptData(clientid, "I_DN" + order.SZZYORDERID.ToString());
|
||||||
sign = sHelper.signData(clientid, content);
|
sign = sHelper.signData(clientid, content);
|
||||||
string cphfwUrl = string.Format("{0}/{4}-产品或服务不适当警示及投资者确认书.pdf ?content={1}&sign={2}&clientId={3}&employeeId={5}&employeeName={6}&viewSource={7}&pageSource={8}",
|
string cphfwUrl = string.Format("{0}/{4}-产品或服务风险警示及投资者确认书.pdf ?content={1}&sign={2}&clientId={3}&employeeId={5}&employeeName={6}&viewSource={7}&pageSource={8}",
|
||||||
url, HttpUtility.UrlEncode(content), HttpUtility.UrlEncode(sign), clientid, order.SUBPRODUCTNAME,
|
url, HttpUtility.UrlEncode(content), HttpUtility.UrlEncode(sign), clientid, order.SUBPRODUCTNAME,
|
||||||
Eid,
|
Eid,
|
||||||
UserName,
|
UserName,
|
||||||
|
|
@ -5157,7 +5157,7 @@ namespace WX.CRM.WEB.Controllers.WeiXin
|
||||||
//适当性评估结果确认书
|
//适当性评估结果确认书
|
||||||
content = sHelper.encyptData(clientid, "S_DN" + order.SZZYORDERID.ToString());
|
content = sHelper.encyptData(clientid, "S_DN" + order.SZZYORDERID.ToString());
|
||||||
sign = sHelper.signData(clientid, content);
|
sign = sHelper.signData(clientid, content);
|
||||||
string sdxpgUrl = string.Format("{0}/{4}-适当性评估结果确认书.pdf ?content={1}&sign={2}&clientId={3}&employeeId={5}&employeeName={6}&viewSource={7}&pageSource={8}",
|
string sdxpgUrl = string.Format("{0}/{4}-适当性匹配意见及投资者确认书.pdf ?content={1}&sign={2}&clientId={3}&employeeId={5}&employeeName={6}&viewSource={7}&pageSource={8}",
|
||||||
url, HttpUtility.UrlEncode(content), HttpUtility.UrlEncode(sign), clientid, order.SUBPRODUCTNAME,
|
url, HttpUtility.UrlEncode(content), HttpUtility.UrlEncode(sign), clientid, order.SUBPRODUCTNAME,
|
||||||
Eid,
|
Eid,
|
||||||
UserName,
|
UserName,
|
||||||
|
|
@ -5167,6 +5167,10 @@ namespace WX.CRM.WEB.Controllers.WeiXin
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ViewBag.RiskLevel = ret1.riskType.level;
|
||||||
|
ViewBag.IsC0User = ret1.isC0User;
|
||||||
|
ViewBag.IsC1_0User = ret1.isC1_0User;
|
||||||
}
|
}
|
||||||
|
|
||||||
////适当性评估结果确认书
|
////适当性评估结果确认书
|
||||||
|
|
@ -6612,16 +6616,32 @@ namespace WX.CRM.WEB.Controllers.WeiXin
|
||||||
public class RiskInfoDto
|
public class RiskInfoDto
|
||||||
{
|
{
|
||||||
public int ret { get; set; }
|
public int ret { get; set; }
|
||||||
|
public string name { get; set; }
|
||||||
|
public string idCard { get; set; }
|
||||||
public string answer { get; set; }
|
public string answer { get; set; }
|
||||||
public Int64 createTime { get; set; }
|
public Int64 createTime { get; set; }
|
||||||
public string idCard { get; set; }
|
|
||||||
public string name { get; set; }
|
|
||||||
public string key { get; set; }
|
public string key { get; set; }
|
||||||
public string style { get; set; }
|
public string style { get; set; }
|
||||||
public int index { get; set; }
|
public int index { get; set; }
|
||||||
|
public string version { get; set; }
|
||||||
|
public string expTime { get; set; }
|
||||||
|
public RiskType riskType { get; set; }
|
||||||
|
public int verifyType { get; set; }
|
||||||
|
public int auditStatus { get; set; }
|
||||||
|
public string auditRemark { get; set; }
|
||||||
|
public bool isC0User { get; set; } = false;
|
||||||
|
public bool isC1_0User { get; set; } = false;
|
||||||
public string businesstype { get; set; }
|
public string businesstype { get; set; }
|
||||||
public int paperId { get; set; }
|
public int paperId { get; set; }
|
||||||
}
|
}
|
||||||
|
public class RiskType
|
||||||
|
{
|
||||||
|
public int min { get; set; }
|
||||||
|
public int max { get; set; }
|
||||||
|
public string des { get; set; }
|
||||||
|
public string name { get; set; }
|
||||||
|
public string level { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
public class WX_MYSZZYORDER_EXPORT
|
public class WX_MYSZZYORDER_EXPORT
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,270 @@
|
||||||
|
@using WX.CRM.WebHelper
|
||||||
|
@{
|
||||||
|
ViewBag.Title = "bas_salesDepartment";
|
||||||
|
Layout = "~/Views/Shared/_content.cshtml";
|
||||||
|
}
|
||||||
|
<script src="/Scripts/jquery.easyui.min.js" type="text/javascript"></script>
|
||||||
|
<link href="/Content/themes/blue/easyui.css" rel="stylesheet" />
|
||||||
|
<link href="/Content/Site.css" rel="stylesheet" />
|
||||||
|
<script src="/Scripts/common.js"></script>
|
||||||
|
<link href="/Content/data_grid_list.css" rel="stylesheet" />
|
||||||
|
<script src="/Scripts/op/jquery.rewrite.js"></script>
|
||||||
|
<div class="layui-fluid" style="padding-left:0px;padding-top:10px;">
|
||||||
|
|
||||||
|
|
||||||
|
<style>
|
||||||
|
.self-table-click td {
|
||||||
|
background-color: #f3ebbc;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<div class="layui-card" id="topcard" style="width:100%;padding-top:10px;">
|
||||||
|
<div class="layui-card-body " id="contentBody">
|
||||||
|
<form class="layui-form selftopwhere" id="myform">
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<div class="layui-form-item">
|
||||||
|
@Html.Action("UserSSOComBox", "Control", new
|
||||||
|
{
|
||||||
|
currentRight = WX.CRM.WebHelper.InitRights.CONST_我的订单,
|
||||||
|
@class = "layui-input", // 添加Layui输入框样式
|
||||||
|
style = "width:150px;" // 保持与相邻select一致的宽度
|
||||||
|
})
|
||||||
|
</div>
|
||||||
|
客户id:
|
||||||
|
<div class="layui-inline">
|
||||||
|
<input type="text" name="umid" placeholder="请输入" autocomplete="off" class="layui-input">
|
||||||
|
</div>
|
||||||
|
到期时间:
|
||||||
|
<div class="layui-inline">
|
||||||
|
<input class="layui-input" placeholder="开始日" name="starttime" id="starttime" style="width:120px;">
|
||||||
|
</div>
|
||||||
|
<div class="layui-inline">
|
||||||
|
<input class="layui-input" placeholder="截止日" name="endtime" id="endtime" style="width:120px;">
|
||||||
|
</div>
|
||||||
|
产品大类:
|
||||||
|
<div class="layui-inline">
|
||||||
|
<select id="slt_midproductId" name="midproductId"
|
||||||
|
style="width:150px;height:22px"
|
||||||
|
lay-filter="midproduct"
|
||||||
|
onChange="changeMidProduct(this.value)">
|
||||||
|
<option value="">--请选中产品大类--</option>
|
||||||
|
@foreach (var item in ViewBag.midproductList as List<SelectListItem>)
|
||||||
|
{
|
||||||
|
<option value="@item.Value">@item.Text</option>
|
||||||
|
}
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
产品小类:
|
||||||
|
<div class="layui-inline">
|
||||||
|
<select id="slt_subProductId" name="subProductId" style="width:220px;height:22px">
|
||||||
|
<option value="">--请选中产品小类--</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
<input class="layui-btn layui-btn-sm layui-btn-ok" data-method="search" type="button" value="查询" />
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
<table class="layui-hide" id="tabl1" lay-filter="tabl1"></table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
var selectRow = {};
|
||||||
|
var winindex;
|
||||||
|
var layer;
|
||||||
|
var rowid;
|
||||||
|
//注意:选项卡 依赖 element 模块,否则无法进行功能性操作
|
||||||
|
layui.use(['laypage', 'layer', 'table', 'laydate', 'form'], function () {
|
||||||
|
var form = layui.form;
|
||||||
|
var laydate = layui.laydate;
|
||||||
|
layer = layui.layer;
|
||||||
|
table = layui.table;
|
||||||
|
|
||||||
|
// 添加表单组件初始化
|
||||||
|
form.render('select'); // 初始化所有select元素
|
||||||
|
|
||||||
|
laydate.render({ elem: '#starttime' });
|
||||||
|
laydate.render({ elem: '#endtime' });
|
||||||
|
|
||||||
|
var token = $.cookie("AuthToken");
|
||||||
|
|
||||||
|
var param = $("#myform").serializeFormJSON();
|
||||||
|
for (let k in param) {
|
||||||
|
if (param[k] == "") {
|
||||||
|
delete param[k];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
param.action = "list";
|
||||||
|
|
||||||
|
var tableIns = table.render({
|
||||||
|
id: 'listReload'
|
||||||
|
, elem: '#tabl1'
|
||||||
|
, url: '/Res/TranUser'
|
||||||
|
, method: 'post'
|
||||||
|
, headers: {
|
||||||
|
auth: token
|
||||||
|
}
|
||||||
|
, cellMinWidth: 80
|
||||||
|
, page: true
|
||||||
|
, limit: 20
|
||||||
|
, limits: [10, 20, 30] // 添加可选分页大小
|
||||||
|
, height: "full-160"
|
||||||
|
, size: "sm"
|
||||||
|
, cols: [[
|
||||||
|
{ field: 'Umid', title: '客户ID' }
|
||||||
|
, { field: 'SoftUserName', title: '用户名' }
|
||||||
|
, { field: 'CName', title: '客户名称' }
|
||||||
|
, { field: 'SubProductName', title: '产品名称' }
|
||||||
|
, {
|
||||||
|
field: 'EndTime',
|
||||||
|
title: '到期时间',
|
||||||
|
templet: function(d) {
|
||||||
|
return formatDate(d.EndTime);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
, {
|
||||||
|
field: 'RemainDays',
|
||||||
|
title: '剩余天数',
|
||||||
|
templet: function(d) {
|
||||||
|
if (!d.EndTime) return '';
|
||||||
|
|
||||||
|
var endDate = new Date(parseInt(d.EndTime.match(/\d+/)[0]));
|
||||||
|
var today = new Date();
|
||||||
|
// 设置时间为同一天的0点,避免时间差影响天数计算
|
||||||
|
today.setHours(0, 0, 0, 0);
|
||||||
|
endDate.setHours(0, 0, 0, 0);
|
||||||
|
|
||||||
|
var timeDiff = endDate - today;
|
||||||
|
var daysDiff = Math.ceil(timeDiff / (1000 * 60 * 60 * 24));
|
||||||
|
|
||||||
|
// 已过期显示0,当天显示1
|
||||||
|
return daysDiff < 0 ? 0 : (daysDiff === 0 ? 1 : daysDiff);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
, {
|
||||||
|
field: 'RiskLevel',
|
||||||
|
title: '风险标签',
|
||||||
|
templet: function(d) {
|
||||||
|
var tags = [];
|
||||||
|
if (d.HasInComplaint) {
|
||||||
|
tags.push('<span class="layui-badge layui-bg-orange" style="margin-right:5px;">内诉</span>');
|
||||||
|
}
|
||||||
|
if (d.HasOutComplaint) {
|
||||||
|
tags.push('<span class="layui-badge layui-bg-yellow">外诉</span>');
|
||||||
|
}
|
||||||
|
return tags.length ? tags.join('') : '';
|
||||||
|
},
|
||||||
|
width: 120 // 设置固定宽度
|
||||||
|
}
|
||||||
|
, { field: 'Eids', title: '添加员工' }
|
||||||
|
, { field: 'LastServiceTime', title: '最新跟进时间' }
|
||||||
|
, { field: 'LastServiceEid', title: '最新跟进人员' }
|
||||||
|
//, { field: 'Eids', title: '添加员工' }
|
||||||
|
]]
|
||||||
|
, where: param
|
||||||
|
, parseData: function(res){ // 新增数据解析调试
|
||||||
|
console.log('响应数据:', res);
|
||||||
|
return {
|
||||||
|
"code": res.code,
|
||||||
|
"msg": res.msg,
|
||||||
|
"count": res.count,
|
||||||
|
"data": res.data
|
||||||
|
};
|
||||||
|
}
|
||||||
|
, error: function(res, msg){
|
||||||
|
console.error('表格加载错误:', res, msg);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
//触发单元格工具事件
|
||||||
|
table.on('tool(tabl1)', function (obj) {
|
||||||
|
var data = obj.data;
|
||||||
|
//console.log(data)
|
||||||
|
if (obj.event === 'edit') {
|
||||||
|
layer.open({
|
||||||
|
title: '明细',
|
||||||
|
type: 2,
|
||||||
|
area: ['60%', '80%'],
|
||||||
|
content: '/WeiXin/Invoice/Detail?id=' + data.Id
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
//监听行单击事件
|
||||||
|
table.on('row(tabl1)', function (obj) {
|
||||||
|
var data = obj.data;
|
||||||
|
//标注选中样式
|
||||||
|
console.log(data);
|
||||||
|
obj.tr.addClass('self-table-click').siblings().removeClass('self-table-click');
|
||||||
|
selectRow = data;
|
||||||
|
});
|
||||||
|
|
||||||
|
// 在layui.use回调中添加
|
||||||
|
form.on('select(midproduct)', function (data) {
|
||||||
|
changeMidProduct(data.value);
|
||||||
|
});
|
||||||
|
|
||||||
|
var active = {
|
||||||
|
add: function () {
|
||||||
|
var url = "/WeiXin/Invoice/Add";
|
||||||
|
|
||||||
|
layer.open({
|
||||||
|
title: '发票申请',
|
||||||
|
type: 2,
|
||||||
|
maxmin: true,
|
||||||
|
content: url,
|
||||||
|
area: ['80%', '70%']
|
||||||
|
});
|
||||||
|
},
|
||||||
|
search: function () {
|
||||||
|
tableIns.config.where = {};
|
||||||
|
var param = $("#myform").serializeFormJSON();
|
||||||
|
for (let k in param) {
|
||||||
|
if (param[k] == "") {
|
||||||
|
delete param[k];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
param.action = "list";
|
||||||
|
tableIns.reload({
|
||||||
|
where: param,
|
||||||
|
headers: { auth: token },
|
||||||
|
page: {
|
||||||
|
curr: 1 // 重置到第一页但保留分页大小
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
$('.layui-btn').on('click', function () {
|
||||||
|
var othis = $(this), method = othis.data('method');
|
||||||
|
console.log(method);
|
||||||
|
active[method] ? active[method].call(this, othis) : '';
|
||||||
|
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
function changeMidProduct(productId) {
|
||||||
|
if (productId == 0) {
|
||||||
|
$("#slt_subProductId").html("<option value='0'>--请选中产品小类--</option>");
|
||||||
|
layui.form.render('select'); // 修复作用域问题
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
$.r_post("/JzOrder/GetAllSubProductList?productId=0&midproductId=" + productId, function (data) {
|
||||||
|
$("#slt_subProductId").html("<option value=''>--请选中产品小类--</option>");
|
||||||
|
$(data).each(function (n, m) {
|
||||||
|
$("#slt_subProductId").append("<option value='" + m.Value + "'>" + m.Text + "</option>");
|
||||||
|
});
|
||||||
|
layui.form.render('select'); // 直接调用layui的form模块
|
||||||
|
}, "json");
|
||||||
|
}
|
||||||
|
function onLoadSucced() {
|
||||||
|
console.log(1);
|
||||||
|
//$('#tablist').tablegrid("Search");
|
||||||
|
}// 在表格初始化前添加日期格式化函数
|
||||||
|
function formatDate(timestamp) {
|
||||||
|
if(!timestamp) return '';
|
||||||
|
// 处理ASP.NET的日期格式 /Date(1574063481000)/
|
||||||
|
var date = new Date(parseInt(timestamp.match(/\d+/)[0]));
|
||||||
|
return date.toLocaleDateString();
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
@ -16,7 +16,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
#threeBtn {
|
#threeBtn {
|
||||||
display:none;
|
display: none;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
color: white;
|
color: white;
|
||||||
}
|
}
|
||||||
|
|
@ -68,107 +68,84 @@
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>客户等级:</td>
|
||||||
合同号:
|
<td style="color:red">
|
||||||
</td>
|
@if (ViewBag.IsC0User)
|
||||||
<td class="contract">
|
|
||||||
@Html.Raw(ViewBag.CONTRACTCODE)
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr class="contract">
|
|
||||||
<td>合同:</td>
|
|
||||||
<td>
|
|
||||||
<ul class="mnas">
|
|
||||||
<li><a href="@ViewBag.fxjssUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">风险揭示书.pdf</a></li>
|
|
||||||
@if (ViewBag.businesstype == "smallAmount")
|
|
||||||
{
|
|
||||||
<li><a href="@ViewBag.tgfwxyUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">投教服务协议.pdf</a></li>
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
<li><a href="@ViewBag.tgfwxyUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">投顾服务协议.pdf</a></li>
|
|
||||||
}
|
|
||||||
@if (ViewBag.cphfwUrl != null)
|
|
||||||
{
|
|
||||||
<li><a href="@ViewBag.cphfwUrl" target="_blank" class="layui-btn layui-btn-warm" layui-btn-sm">产品或服务不适当警示及投资者确认书.pdf</a></li>
|
|
||||||
}
|
|
||||||
@if (ViewBag.sdxpgUrl != null)
|
|
||||||
{
|
|
||||||
<li><a href="@ViewBag.sdxpgUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">适当性评估结果确认书.pdf</a></li>
|
|
||||||
}
|
|
||||||
@if (ViewBag.fxpcUrl != null)
|
|
||||||
{
|
|
||||||
<li><a href="@ViewBag.fxpcUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">风险测评</a></li>
|
|
||||||
}
|
|
||||||
</ul>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr class="contract">
|
|
||||||
<td>
|
|
||||||
<p>合同状态:</p>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<p id="showContractStatus"></p>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr id="ContractRemark">
|
|
||||||
<td>
|
|
||||||
<p>合同驳回备注:</p>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<p id="showContractRemark"></p>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<p>合规状态:</p>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
@if (ViewBag.RiskCtrlStatus == -1)
|
|
||||||
{
|
{
|
||||||
<span style="color:orange; font-weight:bold;padding-right:20px;">驳回</span>
|
@Html.Raw("不符合准入条件")
|
||||||
}
|
}
|
||||||
else if (ViewBag.RiskCtrlStatus == 0)
|
else if (ViewBag.IsC1_0User)
|
||||||
{
|
{
|
||||||
<span style="font-weight:bold;">未审核</span>
|
@Html.Raw("C1_0(最低风险承受类别)")
|
||||||
}
|
|
||||||
else if (ViewBag.RiskCtrlStatus == 1)
|
|
||||||
{
|
|
||||||
<span style="font-weight:bold;">分部已审核</span>
|
|
||||||
}
|
|
||||||
else if (ViewBag.RiskCtrlStatus == 2)
|
|
||||||
{
|
|
||||||
<span style="color: green; font-weight:bold;">已通过</span>
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<span>未知</span>
|
@Html.Raw("C" + ViewBag.RiskLevel)
|
||||||
}
|
}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr id="ContractRemark">
|
@if (!string.IsNullOrEmpty(ViewBag.CONTRACTCODE))
|
||||||
<td>
|
{
|
||||||
<p>合规驳回备注:</p>
|
<tr>
|
||||||
</td>
|
<td>
|
||||||
<td>
|
合同号:
|
||||||
@if (ViewBag.RiskCtrlStatus == -1)
|
</td>
|
||||||
{
|
<td class="contract">
|
||||||
<p id="RejectRemark"></p>
|
@Html.Raw(ViewBag.CONTRACTCODE)
|
||||||
}
|
</td>
|
||||||
</td>
|
</tr>
|
||||||
</tr>
|
<tr class="contract">
|
||||||
@*<tr>
|
<td>合同:</td>
|
||||||
|
<td>
|
||||||
|
<ul class="mnas">
|
||||||
|
<li><a href="@ViewBag.fxjssUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">风险揭示书.pdf</a></li>
|
||||||
|
@if (ViewBag.businesstype == "smallAmount")
|
||||||
|
{
|
||||||
|
<li><a href="@ViewBag.tgfwxyUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">投教服务协议.pdf</a></li>
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
<li><a href="@ViewBag.tgfwxyUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">投顾服务协议.pdf</a></li>
|
||||||
|
}
|
||||||
|
@if (ViewBag.cphfwUrl != null)
|
||||||
|
{
|
||||||
|
<li><a href="@ViewBag.cphfwUrl" target="_blank" class="layui-btn layui-btn-warm" layui-btn-sm">产品或服务不适当警示及投资者确认书.pdf</a></li>
|
||||||
|
}
|
||||||
|
@if (ViewBag.sdxpgUrl != null)
|
||||||
|
{
|
||||||
|
<li><a href="@ViewBag.sdxpgUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">适当性评估结果确认书.pdf</a></li>
|
||||||
|
}
|
||||||
|
@if (ViewBag.fxpcUrl != null)
|
||||||
|
{
|
||||||
|
<li><a href="@ViewBag.fxpcUrl" target="_blank" class="layui-btn layui-btn-normal layui-btn-sm">风险测评</a></li>
|
||||||
|
}
|
||||||
|
</ul>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr class="contract">
|
||||||
|
<td>
|
||||||
|
<p>合同状态:</p>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<p id="showContractStatus"></p>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr id="ContractRemark">
|
||||||
|
<td>
|
||||||
|
<p>合同驳回备注:</p>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<p id="showContractRemark"></p>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<p>合规状态:</p>
|
<p>合规状态:</p>
|
||||||
@if (ViewBag.RiskCtrlStatus == -1)
|
|
||||||
{
|
|
||||||
<p>合规驳回备注:</p>
|
|
||||||
}
|
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
@if (ViewBag.RiskCtrlStatus == -1)
|
@if (ViewBag.RiskCtrlStatus == -1)
|
||||||
{
|
{
|
||||||
<span style="color:orange; font-weight:bold;padding-right:20px;">未通过,已驳回</span>
|
<span style="color:orange; font-weight:bold;padding-right:20px;">驳回</span>
|
||||||
}
|
}
|
||||||
else if (ViewBag.RiskCtrlStatus == 0)
|
else if (ViewBag.RiskCtrlStatus == 0)
|
||||||
{
|
{
|
||||||
|
|
@ -186,16 +163,27 @@
|
||||||
{
|
{
|
||||||
<span>未知</span>
|
<span>未知</span>
|
||||||
}
|
}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr id="ContractRemark">
|
||||||
|
<td>
|
||||||
|
<p>合规驳回备注:</p>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
@if (ViewBag.RiskCtrlStatus == -1)
|
@if (ViewBag.RiskCtrlStatus == -1)
|
||||||
{
|
{
|
||||||
<p>@ViewBag.RejectRemark</p>
|
<p id="RejectRemark"></p>
|
||||||
}
|
}
|
||||||
</td>
|
</td>
|
||||||
</tr>*@
|
</tr>
|
||||||
@*<tr>
|
}
|
||||||
<td><input type="button" value="确认" id="btnSave" /></td>
|
else
|
||||||
<td>(备注:风控完成,点击确认按钮提交到总部)</td>
|
{
|
||||||
</tr>*@
|
<tr>
|
||||||
|
<td></td>
|
||||||
|
<td>未签订合同</td>
|
||||||
|
</tr>
|
||||||
|
}
|
||||||
</table>
|
</table>
|
||||||
@*<a id="threeBtn">切回二要素</a>*@
|
@*<a id="threeBtn">切回二要素</a>*@
|
||||||
@*<div id="rejectRemarkDiv">
|
@*<div id="rejectRemarkDiv">
|
||||||
|
|
|
||||||
|
|
@ -271,6 +271,7 @@
|
||||||
<Compile Include="Controllers\Res\SeniorSharedPoolController.cs" />
|
<Compile Include="Controllers\Res\SeniorSharedPoolController.cs" />
|
||||||
<Compile Include="Controllers\Res\SharedCustomerController.cs" />
|
<Compile Include="Controllers\Res\SharedCustomerController.cs" />
|
||||||
<Compile Include="Controllers\Res\SharedPoolController.cs" />
|
<Compile Include="Controllers\Res\SharedPoolController.cs" />
|
||||||
|
<Compile Include="Controllers\Res\TranUserController.cs" />
|
||||||
<Compile Include="Controllers\Res\VIPCustomerController.cs" />
|
<Compile Include="Controllers\Res\VIPCustomerController.cs" />
|
||||||
<Compile Include="Controllers\Res\WXController.cs" />
|
<Compile Include="Controllers\Res\WXController.cs" />
|
||||||
<Compile Include="Controllers\Sms\BatchModelMsgController.cs" />
|
<Compile Include="Controllers\Sms\BatchModelMsgController.cs" />
|
||||||
|
|
@ -2104,6 +2105,7 @@
|
||||||
<Content Include="Views\Hg\ShowTZD.cshtml" />
|
<Content Include="Views\Hg\ShowTZD.cshtml" />
|
||||||
<Content Include="Views\Hg\ShowCFD.cshtml" />
|
<Content Include="Views\Hg\ShowCFD.cshtml" />
|
||||||
<Content Include="Views\Hg\LookNoticeShow.cshtml" />
|
<Content Include="Views\Hg\LookNoticeShow.cshtml" />
|
||||||
|
<Content Include="Views\Res\TranUser\Index.cshtml" />
|
||||||
<None Include="Views\StockPools\GetArticle.cshtml" />
|
<None Include="Views\StockPools\GetArticle.cshtml" />
|
||||||
<Content Include="Views\WeWork\WxResource\WxResourceTab.cshtml" />
|
<Content Include="Views\WeWork\WxResource\WxResourceTab.cshtml" />
|
||||||
<Content Include="Xml\CacheConfig.xml">
|
<Content Include="Xml\CacheConfig.xml">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue