ZZDianXin_UI - 郑州电信 演示

MyTaskResult.html 11KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>我的任务结果</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <script src="../Script/Common/huayi.load.js"></script>
  8. <script src="../Script/Common/huayi.config.js"></script>
  9. <link href="../css/Table/table1.css" rel="stylesheet" />
  10. <link href="../css/init.css" rel="stylesheet" />
  11. <!-- 录屏 -->
  12. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/rrweb@latest/dist/rrweb.min.css"/>
  13. <!-- 回放播放器 -->
  14. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/rrweb-player@latest/dist/style.css"/>
  15. <!-- 录屏-->
  16. <script src="https://cdn.jsdelivr.net/npm/rrweb@latest/dist/record/rrweb-record.min.js"></script>
  17. <script src="https://cdn.jsdelivr.net/npm/rrweb@latest/dist/rrweb.min.js"></script>
  18. <!-- 回放播放器 -->
  19. <script src="https://cdn.jsdelivr.net/npm/rrweb-player@latest/dist/index.js"></script>
  20. <!--<script src="../callScreen/cutVideo.js" type="text/javascript"></script>-->
  21. <style type="text/css">
  22. #replayers{
  23. text-align: center;
  24. /* color: #EEEEEE; */
  25. }
  26. .rr-player.svelte-1wetjm2{
  27. margin: 0px auto;
  28. float: none;
  29. /* box-shadow: 0 24px 48px #000000; */
  30. }
  31. .shade_k{
  32. margin: 2% auto;
  33. overflow-y: scroll;
  34. width: 65%;
  35. min-width: 1040px;
  36. height: 750px;
  37. }
  38. </style>
  39. </head>
  40. <body class="gray-bg">
  41. <div class="wrapper wrapper-content animated fadeInRight">
  42. <div class="daoHang clearfix">
  43. <div class="dhLeft">
  44. <sapn><i class="syIcon"></i>位置:
  45. <a id="ReIndex">首页</a>&gt;
  46. <a href="javaScript:;">外呼管理</a>&gt;
  47. <a href="" style="color: #000;">我的任务结果</a>
  48. </sapn>
  49. </div>
  50. </div>
  51. <div class="th-box">
  52. <div class="th-bar">
  53. <div class="seach-box ">
  54. <ul>
  55. <li style="position: relative;">
  56. 调查时间:
  57. <i class="tub fa fa-calendar"></i>
  58. <input type="text" id="s_time" class="photo laydate-icon" placeholder="请选择调查时间" />
  59. </li>
  60. <li>呼叫结果:
  61. <select name="" class="photo" id="hjjgid"></select>
  62. </li>
  63. <li>电话号码:<input class="photo x-color" type="text" id="key" placeholder="请输入电话号码" /></li>
  64. <!--<li>用户反馈:
  65. <select name="" class="photo" id="yhfkid"></select>
  66. </li>-->
  67. <li>
  68. <a class="sc_btn Block" id="sc_btns">搜索</a>
  69. </li>
  70. </ul>
  71. </div>
  72. </div>
  73. </div>
  74. <div style="width: 100%;padding: 10px;">
  75. <table id="list" data-click-to-select="true" data-row-style="rowStyle" data-query-params="queryParams" data-pagination="true">
  76. <thead>
  77. <tr>
  78. <th data-formatter="formatterOperation" data-align="center">操作</th>
  79. <!--<th data-field="state" data-checkbox="true"></th>-->
  80. <th data-field="F_Phone" data-align="center" data-formatter="Code">电话号码</th>
  81. <!--<th data-field="nid" data-formatter="setCode">录音</th>-->
  82. <th data-field="F_CusName" data-align="center">姓名</th>
  83. <!--<th data-field="ExpandVchField4" data-align="center">乡镇或单位</th>-->
  84. <th data-field="ExpandVchField3" data-align="center">地址</th>
  85. <th data-field="F_UserName" data-align="center">分配坐席</th>
  86. <th data-field="F_HJJGName" data-align="center">呼叫结果</th>
  87. <th data-field="ExpandDatField1" data-align="center">调查时间</th>
  88. <!--<th data-field="F_YHFKName" data-align="center">用户反馈</th>-->
  89. </tr>
  90. </thead>
  91. <tbody id="tbody"></tbody>
  92. </table>
  93. </div>
  94. <!--下载框-->
  95. <div class="t-shade">
  96. <div class="shade_k">
  97. <div class="shade_title">
  98. <span>录屏播放<srong class="cknum"></srong></span>
  99. <span class="setwin"><a>x</a></span>
  100. </div>
  101. <div class="shade_content">
  102. <div class="Ly_box audiojs">
  103. </div>
  104. <div class="boxCon LY_box">
  105. </div>
  106. <div id="replayers"></div>
  107. </div>
  108. </div>
  109. </div>
  110. <!--//下载框结束-->
  111. </div>
  112. <script src="../js/laydate/laydate.js"></script>
  113. <script>
  114. $(document).ready(function() {
  115. laydate.render({
  116. elem: '#s_time',
  117. range: '~',
  118. theme: '#1ab394',
  119. calendar: true,
  120. });
  121. initTable();
  122. GetHJJG(); //呼叫结果下拉
  123. //GetYHFK();//用户反馈
  124. $("#sc_btns").click(function() {
  125. initTable();
  126. });
  127. //回车搜索
  128. // $('#sc_btns').on('keypress',function(e){
  129. // if(e.keyCode==13){
  130. // initTable();
  131. // }
  132. // })
  133. })
  134. function initTable() {
  135. //先销毁表格
  136. $('#list').bootstrapTable('destroy');
  137. //初始化表格,动态从服务器加载数据
  138. $("#list").bootstrapTable({
  139. method: "get", //使用get请求到服务器获取数据
  140. url: huayi.config.callcenter_url + "CallOutPlan/GetMyResultList", //获取数据的Servlet地址
  141. contentType: 'application/x-www-form-urlencoded',
  142. striped: true, //表格显示条纹
  143. pagination: true, //启动分页
  144. pageSize: 10, //每页显示的记录数
  145. pageNumber: 1, //当前第几页
  146. pageList: [10, 20, 50, 100], //记录数可选列表
  147. search: false, //是否启用查询
  148. showColumns: false, //显示下拉框勾选要显示的列
  149. showRefresh: false, //显示刷新按钮
  150. sidePagination: "server", //表示服务端请求
  151. //设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
  152. //设置为limit可以获取limit, offset, search, sort, order
  153. queryParamsType: "undefined",
  154. queryParams: function queryParams(params) { //设置查询参数
  155. var param = {
  156. pageindex: params.pageNumber,
  157. pagesize: params.pageSize,
  158. sdate: $('#s_time').val() && $('#s_time').val().split(' ~ ')[0],
  159. edate: $('#s_time').val() && $('#s_time').val().split(' ~ ')[1],
  160. key: $("#key").val(),
  161. hjjgid: $("#hjjgid").val(), //呼叫结果ID
  162. //yhfkid:$("#yhfkid").val(), //用户反馈ID
  163. token: $.cookie("token")
  164. };
  165. return param;
  166. },
  167. onLoadSuccess: function() { //加载成功时执行
  168. //layer.msg("加载成功");
  169. },
  170. onLoadError: function() { //加载失败时执行
  171. //layer.msg("加载数据失败", { time: 1500, icon: 2 });
  172. }
  173. });
  174. }
  175. //录音
  176. function ck(callId) {
  177. // var path = $(val).attr("item");
  178. $(".t-shade").addClass("cx");
  179. $(".Ly_box").empty();
  180. $(".LY_box").empty();
  181. // $('<audio style="width:100%;"class=" " src="' + path + '" loop="loop" controls="controls"></audio>').appendTo(".Ly_box");
  182. // $('<a href="' + path + '" class="sc_btn LY "download="' + path + '">下载录音</a>').appendTo(".LY_box");
  183. rePlayers(callId);
  184. }
  185. //音频
  186. function setCode(val,row) {
  187. if (val) {
  188. return '<div class="imgs" style="cursor: pointer;">' +
  189. '<img src="../img/vice.png" alt="" onclick= ck("' + row.nid + '") />' +
  190. '</div>';
  191. } else {
  192. return '';
  193. }
  194. }
  195. //关闭录音弹出
  196. $(".setwin").click(function() {
  197. $(".t-shade").removeClass("cx");
  198. // $('audio')[0].pause();
  199. });
  200. // 回放录屏 - 播放器
  201. function rePlayers(callId) {
  202. document.getElementById('replayers').innerHTML = ""; // 清空
  203. //$("#replayers").text("");
  204. $.ajax({
  205. url: huayi.config.callcenter_url + 'CutScreen/GetCutScreenByCallId',
  206. type: 'get',
  207. data: {
  208. callid: callId,
  209. token: $.cookie("token")
  210. },
  211. dataType: "json",
  212. async: true,
  213. success: function(res) {
  214. if (res.state.toLowerCase() === "success") {
  215. var data = res.data;
  216. if (data != null) {
  217. result = data.VideoHtml;
  218. rePlayers2(result);
  219. } else {
  220. $("#replayers").text("暂无录屏信息");
  221. }
  222. }
  223. },
  224. });
  225. }
  226. // 回放录屏 - 播放器
  227. function rePlayers2(res) {
  228. const events = JSON.parse(unescape(res));
  229. //const events = body_result;
  230. if (events != null) {
  231. $("#replayers").text("");
  232. new rrwebPlayer({
  233. target: document.getElementById('replayers'), // document.getElementById('replayers')可以自定义 DOM 元素 document.body
  234. data: {
  235. events,
  236. },
  237. });
  238. // const replayer = new rrweb.Replayer(events);
  239. // replayer.play();
  240. // var heigth = $(".rr-player").outerHeight();
  241. // var heigth2 = $(".rr-player__frame").outerHeight();
  242. // $(".rr-player").css("height",heigth - 100);
  243. // $(".rr-player__frame").css("height",heigth2 - 100);
  244. } else {
  245. $("#replayers").text("暂无录屏信息");
  246. }
  247. }
  248. //获取呼叫结果
  249. function GetHJJG() {
  250. $.ajax({
  251. type: "get",
  252. url: huayi.config.callcenter_url + "Dictionary/GetDicValueListByFlag",
  253. dataType: 'json',
  254. data: {
  255. flag: 'HJJG',
  256. token: $.cookie("token")
  257. },
  258. async: true,
  259. success: function(data) {
  260. var Count = data.data;
  261. $("<option value=''>--全部--</option>").appendTo($("#hjjgid"));
  262. for(var i = 0; i < Count.length; i++) {
  263. $("<option value='" + Count[i].F_DictionaryValueId + "'>" + Count[i].F_Name + "</option>").appendTo($("#hjjgid"));
  264. }
  265. }
  266. });
  267. }
  268. //用户反馈
  269. function GetYHFK() {
  270. $.ajax({
  271. type: "get",
  272. url: huayi.config.callcenter_url + "Dictionary/GetDicValueListByFlag",
  273. dataType: 'json',
  274. data: {
  275. flag: 'YHFK',
  276. token: $.cookie("token")
  277. },
  278. async: true,
  279. success: function(data) {
  280. var Count = data.data;
  281. $("<option value=''>--全部--</option>").appendTo($("#yhfkid"));
  282. for(var i = 0; i < Count.length; i++) {
  283. console.log(Count[i].F_UserName);
  284. $("<option value='" + Count[i].F_DictionaryValueId + "'>" + Count[i].F_Name + "</option>").appendTo($("#yhfkid"));
  285. }
  286. }
  287. });
  288. }
  289. function Code(val, row) {
  290. return '<div><a onclick="XX(' + row.F_Id + ')">' + row.F_Phone + '</a></div>'
  291. }
  292. //格式化操作
  293. function formatterOperation(val, row) {
  294. //ExpandSintField1 1为已存在工单,0为不存在工单
  295. if(row.ExpandSintField1 == '1'){
  296. return '-';
  297. }else if(row.ExpandSintField1 == '0'||row.ExpandSintField1==null){
  298. return '<div class="imgs" ><a class="xg" href="javascript:;" onclick= createOrder("' + row.F_Id + '")>新建工单</a></div>';
  299. }else{
  300. return '-';
  301. }
  302. }
  303. //新建工单
  304. function createOrder(tid) {
  305. layer.open({
  306. type: 2,
  307. content: "../WorkOrder/addwork.html?tid=" + tid, //iframe的url,no代表不显示滚动条
  308. title: '新建工单',
  309. maxmin: true,
  310. area: ['86%', '88%'], //宽高
  311. });
  312. }
  313. //详情
  314. function XX(str) {
  315. console.log(str);
  316. layer.open({
  317. type: 2,
  318. content: "../OutboundMessage/LookMessages.html?Str=" + str, //iframe的url,no代表不显示滚动条
  319. title: '任务信息',
  320. maxmin: true, //开启最大化最小化按钮
  321. id: 'LAY_layuipro1', //防止重复弹出
  322. area: ['86%', '88%'], //宽高
  323. });
  324. }
  325. </script>
  326. </body>
  327. </html>