custome_detail.ftl 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384
  1. <!DOCTYPE HTML>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="renderer" content="webkit|ie-comp|ie-stand">
  6. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  7. <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
  8. <meta http-equiv="Cache-Control" content="no-siteapp" />
  9. <#include "/base/add_base.ftl">
  10. <link href="${path}/common/lib/jquery.ui/jquery-ui.css" rel="stylesheet" type="text/css"/>
  11. <link href="${path}/common/lib/webuploader/0.1.5/webuploader.css" rel="stylesheet" type="text/css"/>
  12. <link href="${path}/common/lib/icheck/icheck.css" rel="stylesheet" type="text/css"/>
  13. <style>
  14. .tit{position: relative;text-align: left;font-size: 16px;padding-left: 10px;}
  15. .tit:after{content: '';position: absolute;left: 0;top: 20%;height: 60%;width: 3px;background-color: #32a3d8;}
  16. .tit-2{position: relative;text-align: left;font-size: 16px;padding-left: 10px;}
  17. .tit-2:after{content: '';position: absolute;left: 0;top: 20%;height: 60%;width: 3px;background-color: #32a3d8;}
  18. #province select{margin-right:10px; width:100px;height: 31px;-webkit-appearance:none !important;appearance:none;background: url(${path}/common/images/cm/select-1.png) right center no-repeat;background-size: auto 100%;padding-left:3px;padding-right: 25px;}
  19. #suggest, #suggest2 {width:200px}
  20. .gray {color:gray}
  21. .ac_results {background:#fff;border:1px solid #7f9db9;position: absolute;z-index: 10000;display: none}
  22. .ac_results li a {white-space: nowrap;text-decoration:none;display:block;color:#05a;padding:1px 3px}
  23. .ac_results li {border:1px solid #fff}
  24. .ac_over, .ac_results li a:hover {background:#c8e3fc}
  25. .ac_results li a span {float:right}
  26. .ac_result_tip {border-bottom:1px dashed #666;padding:3px}
  27. .select-box{background: url(${path}/common/images/cm/select-1.png) right center no-repeat;background-size: auto 100%;}
  28. .select-box select{-webkit-appearance:none !important;background-color: transparent; appearance:none;padding-right: 25px;}
  29. .dalog-ask{position: absolute;left:60%;top:0;-webkit-transform: translateY(-30%);transform: translateY(-30%);display: none;background-color: #fff;z-index: 10;}
  30. .tag{ width:300px; min-height:300px; border:1px solid #32a3d8; position:relative;background-color: #fff;line-height: 1.5;padding: 10px 12px;}
  31. .tag em{display:block; border-width:15px; position:absolute; top:30%; left:-30px;border-style:solid dashed dashed; border-color:transparent #32a3d8 transparent transparent;font-size:0; line-height:0;}
  32. .dalog-ask .ask{color: #000;margin: 10px 0 5px 0;}
  33. .dalog-ask .answer{color: #666;margin-bottom: 10px;}
  34. .dalog-ask .answer:hover{color: #32a3d8;cursor: pointer;}
  35. .time-line-list{list-style: none;width: 100%;margin-left: -20px;}
  36. .time-line-list>li{position: relative;float: left; text-align: center;width: 100px;overflow: hidden;white-space: nowrap;word-break: break-all;padding: 2px 0;}
  37. .time-line-list .number{display: inline-block; padding: 2px; background: #32a3d8;border: 2px solid #fff;box-shadow:0 0 0 1px #32a3d8;width: 20px;height: 20px;color: #fff;line-height: 20px;border-radius: 50%;}
  38. .time-line-list .red{display: inline-block; padding: 2px; background: red;border: 2px solid #fff;box-shadow:0 0 0 1px #32a3d8;width: 20px;height: 20px;color: #fff;line-height: 20px;border-radius: 50%;}
  39. .time-line-list>li:before{content:'';position: absolute;height: 1px;width: 30%;right:0;top: 15px; background-color: #32a3d8;}
  40. .time-line-list>li:after{content: '';position: absolute;height: 1px;width: 30%;left: 0;top: 15px;background:#32a3d8;}
  41. .time-line-list>li:first-child:after,.time-line-list>li:last-child:before{display: none;}
  42. .time-line-list .arrow{border-width:7px; position:absolute; left:25%; top:9px;border-style:solid dashed dashed; border-color:transparent transparent transparent #32a3d8;font-size:0; line-height:0;}
  43. .time-line-list>li:first-child .arrow{display: none;}
  44. .table-bg th{background-color: #e2f6ff;}
  45. .update-parts>span{margin-right: 10px;padding: 3px 4px;background-color: #effaff;border: 1px solid #32a3d8;}
  46. .my-search-input{padding-left: 30px;background: url(${path}/common/images/cm/search.png) 6px center no-repeat;background-size: auto 60%; }
  47. .txt-red{color:red}
  48. </style>
  49. <title>客诉基本信息</title>
  50. </head>
  51. <body>
  52. <article class="cl pd-20">
  53. <form action="" method="post" class="form form-horizontal" id="form-article-add">
  54. <div class="row cl">
  55. <label class="form-label col-3">
  56. <div class="tit-2">客诉基本信息</div>
  57. </label>
  58. <div class="formControls col-9">
  59. </div>
  60. </div>
  61. <div class="row cl">
  62. <label class="form-label col-1 col-sm-1">跟进客服:</label>
  63. <div class="formControls col-4 col-sm-4">
  64. <label id="adminName"></label>
  65. </div>
  66. <label class="form-label col-1 col-sm-1">来源入口:</label>
  67. <div class="formControls col-4 col-sm-4">
  68. <label id="customerSourceType"></label>
  69. </div>
  70. </div>
  71. <div class="row cl">
  72. <label class="form-label col-1 col-sm-1">咨询类型:</label>
  73. <div class="formControls col-4 col-sm-4">
  74. <label id="customerCounselType"></label>
  75. </div>
  76. <label class="form-label col-1 col-sm-1">产品类别:</label>
  77. <div class="formControls col-4 col-sm-4">
  78. <label id="typeName"></label>
  79. </div>
  80. </div>
  81. <div class="row cl" style="position: relative;">
  82. <label class="form-label col-1 col-sm-1">客诉问题:</label>
  83. <label id="describeTitle"></label>
  84. </div>
  85. <div class="row cl">
  86. <label class="form-label col-1 col-sm-1">回复内容:</label>
  87. <div class="formControls col-5 col-sm-5">
  88. <label id="questionProfile"></label>
  89. </div>
  90. </div>
  91. <div class="row cl">
  92. <label class="form-label col-1 col-sm-1">用户信息:</label>
  93. <div class="formControls col-5 col-sm-5">
  94. <label id="customerName"></label>
  95. <label id="customerTel"></label>
  96. </div>
  97. </div>
  98. <div class="row cl">
  99. <label class="form-label col-3">
  100. <div class="tit-2">处理结果(<label id="customerIsSolve" style="color: red"></label>)</div>
  101. </label>
  102. <div class="formControls col-10 col-sm-10">
  103. </div>
  104. </div>
  105. <div class="row cl">
  106. <label class="form-label col-1 col-sm-1"></label>
  107. <div class="formControls col-10 col-sm-10">
  108. <ul class="time-line-list">
  109. <!--<li id="li-1"><span class="arrow"></span><div id="number-1" class="number">1</div><div id="txt-1">录入客诉</div></li>
  110. <li id="li-2"><span class="arrow"></span><div id="number-2" class="number">2</div><div id="txt-2">督促用户寄回</div></li>
  111. <li id="li-3"><span class="arrow"></span><div id="number-3" class="number">3</div><div id="txt-3">录入快递单号</div></li>
  112. <li id="li-4"><span class="arrow"></span><div id="number-4" class="number">4</div><div id="txt-4">仓库收货</div></li>
  113. <li id="li-5"><span class="arrow"></span><div id="number-5" class="number">5</div><div id="txt-5">换新发货</div></li>
  114. <li id="li-6"><span class="arrow"></span><div id="number-6" class="number">6</div><div id="txt-6">发货通知用户</div></li>
  115. <li id="li-7"><span class="arrow"></span><div id="number-7" class="number">7</div><div id="txt-7">收货后回访</div></li>-->
  116. </ul>
  117. </div>
  118. </div>
  119. <div class="row cl">
  120. <label class="form-label col-1 col-sm-1">订单信息</label>
  121. <div class="formControls col-7 col-sm-7 text-c">
  122. <table class="table table-border table-bg table-bordered">
  123. <tr>
  124. <th>销售</th>
  125. <th>订单号</th>
  126. <th>姓名</th>
  127. <th>电话</th>
  128. <th>订单金额</th>
  129. <th>购买产品</th>
  130. <th>购买日期</th>
  131. </tr>
  132. <tr>
  133. <td id="companyName"></td>
  134. <td id="salesOrderId"></td>
  135. <td id="salesAddressName"></td>
  136. <td id="salesAddressTel"></td>
  137. <td id="salesPayMoney"></td>
  138. <td id="salesItem"></td>
  139. <td id="salesPayTime"></td>
  140. </tr>
  141. </table>
  142. </div>
  143. </div>
  144. <div class="row cl" id="divCloseProdcue">
  145. <label class="form-label col-1 col-sm-1">寄回产品:</label>
  146. <div class="formControls col-5 col-sm-5">
  147. <label id="closeprodcue"></label>
  148. <!--TDS收集-->
  149. <label id="customerTDS"></label>
  150. </div>
  151. </div>
  152. <div class="row cl">
  153. <label class="form-label col-1 col-sm-1">收货地址:</label>
  154. <div class="formControls col-5 col-sm-5">
  155. <label id="relationSendMergeAddress"></label>
  156. </div>
  157. </div>
  158. <div class="row cl" id="divSendProdcue">
  159. <label class="form-label col-1 col-sm-1">寄送产品:</label>
  160. <div class="formControls col-10 col-sm-10">
  161. <label id="sendprodcue"></label>
  162. </div>
  163. </div>
  164. <div class="row cl">
  165. <label class="form-label col-1 col-sm-1">处理描述:</label>
  166. <div class="formControls col-5 col-sm-5">
  167. <textarea id="describeHandleDesc" cols="" rows="2" class="textarea" placeholder="说点什么..."></textarea>
  168. </div>
  169. </div>
  170. <div class="row cl">
  171. <label class="form-label col-1 col-sm-1">回访信息:</label>
  172. <div class="formControls col-5 col-sm-5">
  173. <label id="txtVisit"></label>
  174. </div>
  175. </div>
  176. </form>
  177. </div>
  178. </article>
  179. <script type="text/javascript" src="${path}/common/lib/My97DatePicker/4.8/WdatePicker.js"></script>
  180. <script type="text/javascript" src="${path}/common/lib/webuploader/0.1.5/webuploader.min.js"></script>
  181. <script type="text/javascript" src="${path}/common/lib/icheck/jquery.icheck.min.js"></script>
  182. <script type="text/javascript" src="${path}/common/lib/cm.lib/jquery.provincesCity.js"></script>
  183. <script type="text/javascript" src="${path}/common/lib/cm.lib/provincesData.js"></script>
  184. <script type="text/javascript" src="${path}/common/lib/cm.lib/airCity.js"></script>
  185. <script type="text/javascript" src="${path}/common/lib/cm.lib/suggest.js"></script>
  186. <script type="text/javascript" charset="utf-8" src="${path}/common/lib/ueditor/1.4.3/ueditor.config.js"></script>
  187. <script type="text/javascript" charset="utf-8" src="${path}/common/lib/ueditor/1.4.3/ueditor.all.js"></script>
  188. <script type="text/javascript" charset="utf-8" src="${path}/common/lib/ueditor/1.4.3/ueditor.parse.js"></script>
  189. <script type="text/javascript" charset="utf-8" src="${path}/common/lib/ueditor/1.4.3/lang/zh-cn/zh-cn.js"></script>
  190. <script type="text/javascript">
  191. $(function(){
  192. $('.skin-minimal input').iCheck({
  193. checkboxClass: 'icheckbox-blue',
  194. radioClass: 'iradio-blue',
  195. increaseArea: '20%'
  196. });
  197. $("#province").ProvinceCity();
  198. $('.skin-minimal input').iCheck({
  199. checkboxClass: 'icheckbox-blue',
  200. radioClass: 'iradio-blue',
  201. increaseArea: '20%'
  202. });
  203. $("#arrcity").suggest(citys,{hot_list:commoncitys,dataContainer:'#arrcity_3word',onSelect:function(result){
  204. console.log($(this)[0].value);
  205. // $("#city2").click()
  206. },
  207. attachObject:'#suggest'
  208. });
  209. //$("#city2").suggest(citys,{hot_list:commoncitys,attachObject:"#suggest2"})
  210. getCustomerInfo();
  211. });
  212. /**
  213. * 查询客诉基本信息
  214. */
  215. function getCustomerInfo() {
  216. $.ajax({
  217. cache: true,
  218. type: "POST",
  219. data: {"customerId":${customerId!''}},
  220. url: "${path}/admin/customer/get_customer_info",
  221. async: false,
  222. success: function(data){
  223. if (data.returnCode == 200) {
  224. console.log(data.returnMsg);
  225. var customer = data.returnMsg.customer;
  226. var customerCommon = data.returnMsg.customerCommon;
  227. var salesOrder = data.returnMsg.salesOrder;
  228. if (customer.customerIsSolve != 1 && customer.customerIsSolve != 2) {
  229. resultshow(customer.customerIsSolve, customerCommon.relationBackStatus,customerCommon.relationSendStatus);
  230. }
  231. $('#adminName').html(customer.adminName);
  232. var customerSource = '';
  233. switch (customer.customerSourceType) {
  234. case 1:customerSource = '400电话';break;
  235. case 2:customerSource = '微信公众号';break;
  236. case 3:customerSource = customer.customerSource;break;
  237. }
  238. $('#customerSourceType').html(customerSource);
  239. var customerCounsel = '';
  240. switch (customer.customerCounselType) {
  241. case 1:customerCounsel = '售前咨询';break;
  242. case 2:customerCounsel = '售后咨询';break;
  243. case 3:customerCounsel = '其他';break;
  244. }
  245. $('#customerCounselType').html(customerCounsel);
  246. $('#typeName').html(customer.typeName);
  247. $('#describeTitle').html(customer.describeTitle);
  248. $('#questionProfile').html(customer.questionProfile);
  249. $('#customerName').html(customer.customerName);
  250. $('#customerTel').html(customer.customerTel);
  251. var txtcustomerIsSolve = '';
  252. switch (customer.customerIsSolve) {
  253. case 1:txtcustomerIsSolve = '已解决';break;
  254. case 2:txtcustomerIsSolve = '未解决';break;
  255. case 3:txtcustomerIsSolve = '换新';break;
  256. case 4:txtcustomerIsSolve = '维修';break;
  257. case 5:txtcustomerIsSolve = '补发';break;
  258. case 6:txtcustomerIsSolve = '退货';break;
  259. case 7:txtcustomerIsSolve = '无理由退货';break;
  260. }
  261. $('#customerIsSolve').html(txtcustomerIsSolve);
  262. $('#companyName').html(customer.companyName+"-"+customer.storeName);
  263. $('#salesOrderId').html(salesOrder.salesOrderId);
  264. $('#salesAddressName').html(salesOrder.salesAddressName);
  265. $('#salesAddressTel').html(salesOrder.salesAddressTel);
  266. $('#salesPayMoney').html('¥'+salesOrder.salesPayMoney/100);
  267. var salesItem = '';
  268. $.each(salesOrder.salesOrderItemList,function(index,item){
  269. salesItem = this.itemProductName + '*' + this.itemNum
  270. })
  271. $('#salesItem').html(salesItem);
  272. $('#salesPayTime').html(salesOrder.salesPayTime);
  273. $('#relationSendMergeAddress').html(customerCommon.relationSendMergeAddress+"-"+customerCommon.relationSendAddress);
  274. $('#describeHandleDesc').val(customer.describeHandleDesc);
  275. var sendprodcue = '';
  276. var sendprodcueshow = false;
  277. var closeprodcue = '';
  278. var closeprodcueshow = false;
  279. if (customerCommon.sendProdcues != null && customerCommon.sendProdcues.length > 0) {
  280. sendprodcueshow = true;
  281. $.each(customerCommon.sendProdcues,function(index,item){
  282. sendprodcue += this.sendProduceName + '*' + this.sendProdcueNumber
  283. })
  284. }
  285. if (customerCommon.sendFittings != null && customerCommon.sendFittings.length > 0) {
  286. sendprodcueshow = true;
  287. $.each(customerCommon.sendFittings,function(index,item){
  288. sendprodcue += this.sendProductName + '*' + this.sendFittingNumber
  289. })
  290. }
  291. if (customerCommon.closedProdcues != null && customerCommon.closedProdcues.length > 0) {
  292. closeprodcueshow = true;
  293. $.each(customerCommon.closedProdcues,function(index,item){
  294. closeprodcue += this.closedProductName + '*' + this.closedProdcueNumber
  295. })
  296. }
  297. if (customerCommon.closedFittings != null && customerCommon.closedFittings.length > 0) {
  298. closeprodcueshow = true;
  299. $.each(customerCommon.closedFittings,function(index,item){
  300. closeprodcue += this.fittingName + '*' + this.closedFittingNumber
  301. })
  302. }
  303. $('#sendprodcue').html(sendprodcue+"<br/>");
  304. $('#closeprodcue').html(closeprodcue+"<br/>");
  305. if (sendprodcueshow) {
  306. $('#divSendProdcue').show();
  307. } else {
  308. $('#divSendProdcue').hide();
  309. }
  310. if (closeprodcueshow) {
  311. $('#divCloseProdcue').show();
  312. } else {
  313. $('#divCloseProdcue').hide();
  314. }
  315. $('#customerTDS').html("TDS收集:"+customerCommon.relationSendMergeAddress+",进水"+
  316. customer.customerInTDS+"ppm"+",出水"+customer.customerOutTDS+"ppm");
  317. if (customer.customerIsVisit == '2') {
  318. var visitTime = '';
  319. switch (customer.visitTimeSelect) {
  320. case 1:visitTime = '9:00-12:00';break;
  321. case 2:visitTime = '12:00-14:00';break;
  322. case 3:visitTime = '14:00-18:00';break;
  323. }
  324. $('#txtVisit').html("("+customer.visitName+")&nbsp;&nbsp;"+"在&nbsp;&nbsp;"+customer.visitDate+
  325. "&nbsp;&nbsp;"+visitTime+"对&nbsp;&nbsp;"+customer.visitCompleteName+"&nbsp;&nbsp;"+
  326. customer.visitCompleteTel+"&nbsp;&nbsp;完成回访");
  327. }
  328. }
  329. },
  330. error: function(XmlHttpRequest, textStatus, errorThrown){
  331. }
  332. });
  333. }
  334. /*处理结果的执行状态*/
  335. var isSolve = {
  336. solved : [],
  337. noSolved : [],
  338. renewed : ["录入客诉","督促用户寄回","录入快递单号","仓库收货","换新发货","发货通知用户","收货后回访"],
  339. maintain : ["录入客诉","督促用户寄回","录入快递单号","仓库收货","品质检测","产线维修","换新发货","发货通知用户","收货后回访"],
  340. reissue : ["录入客诉","生成E订单","督促仓库发货","仓库发货","发货通知用户","收货后回访"],
  341. backGoods : ["录入客诉","督促用户寄回","录入快递单号","仓库收货","品质检测","退款","退货完成"],
  342. noReasonBack : ["录入客诉","督促用户寄回","录入快递单号","仓库收货","品质检测","退款","退货完成"]
  343. }
  344. /*
  345. * 按条件展示步骤的对应颜色
  346. * backStatus:寄回状态
  347. * sendStatus:寄送状态
  348. */
  349. function resultshow(customerIsSolve, backStatus, sendStatus) {
  350. var statusHtml = '<li id="div_li"><span class="arrow"></span><div id="div_number" class="number">status_index</div><div id="div_txt">status_html</div></li>';
  351. var result = [];
  352. var resultHtml = '';
  353. switch (customerIsSolve) {
  354. case 1:result = isSolve.solved;break;
  355. case 2:result = isSolve.noSolved;break;
  356. case 3:result = isSolve.renewed;break;
  357. case 4:result = isSolve.maintain;break;
  358. case 5:result = isSolve.reissue;break;
  359. case 6:result = isSolve.backGoods;break;
  360. case 7:result = isSolve.noReasonBack;break;
  361. }
  362. for(var i=0;i< result.length;i++){
  363. var html = statusHtml.replace("status_index",i+1);
  364. html = html.replace("div_li","li-"+(i+1));
  365. html = html.replace("div_number","number-"+(i+1));
  366. html = html.replace("div_txt","txt-"+(i+1));
  367. html = html.replace("status_html",result[i]);
  368. resultHtml += html;
  369. }
  370. $(".time-line-list").html(resultHtml);
  371. }
  372. </script>
  373. </body>
  374. </html>