operate_report.html 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758
  1. {extend name="public/layout"}
  2. {block name="body"}
  3. <link rel="stylesheet" href="__LAYUI__/layui/css/layui.css" media="all">
  4. <link rel="stylesheet" " href=" /static/css/common.css">
  5. <script src="/static/js/jquery.min.js"></script>
  6. <style>
  7. body {
  8. padding-bottom: 40px;
  9. }
  10. .searchtitlebox {
  11. display: block;
  12. padding: 15px 10px;
  13. border: 1px solid #F0F0F0;
  14. background: #FCFCFC;
  15. margin-top: 5px;
  16. margin-bottom: 10px;
  17. position: relative;
  18. min-width: 800px;
  19. }
  20. .searchbox {
  21. display: block;
  22. margin-top: 8px;
  23. text-align: center;
  24. }
  25. .searchbox input {
  26. display: inline-block;
  27. height: 26px;
  28. line-height: 26px;
  29. padding-left: 3px;
  30. vertical-align: middle;
  31. }
  32. body {
  33. font-size: 12px;
  34. font-family: "宋体";
  35. }
  36. .selectbox {
  37. float: left;
  38. }
  39. .leftselect {
  40. float: left;
  41. height: 26px;
  42. line-height: 26px;
  43. }
  44. .selectbox select {
  45. float: left;
  46. height: 26px;
  47. }
  48. .searchtext {
  49. border: 1px solid #ccc;
  50. background: #fff url(__STATIC__/img/icon071402.png) no-repeat;
  51. padding: 1px 2px;
  52. height: 24px;
  53. line-height: 24px;
  54. vertical-align: middle;
  55. text-indent: 3px;
  56. margin-left: 4px;
  57. }
  58. .searchbtn1 {
  59. margin-left: 4px;
  60. cursor: pointer;
  61. color: #000;
  62. background: url(__STATIC__/img/btn_bg.gif) repeat-x;
  63. border: 1px solid #C0C0C0;
  64. padding: 0 12px;
  65. *padding: 0 6px;
  66. height: 26px;
  67. }
  68. .layui-table td,
  69. .layui-table th {
  70. font-size: 12px;
  71. }
  72. .layui-table th {
  73. font-weight: bold;
  74. }
  75. .dingjingorder {
  76. height: 25px;
  77. width: 40px;
  78. background-color: #65c001;
  79. color: #FFF;
  80. text-align: center;
  81. line-height: 25px;
  82. z-index: 100;
  83. display: block;
  84. position: absolute;
  85. top: 1px;
  86. right: 3px;
  87. border-radius: 11px;
  88. font-size: 12px;
  89. }
  90. .addvx {
  91. position: absolute;
  92. top: -5px;
  93. right: 1px;
  94. height: 14px;
  95. line-height: 14px;
  96. font-size: 16px;
  97. color: #666;
  98. font-family: "宋体";
  99. }
  100. .statebox {
  101. width: 40px;
  102. text-align: center;
  103. z-index: 100;
  104. display: block;
  105. position: absolute;
  106. font-size: 12px;
  107. top: -5px;
  108. right: 0px;
  109. border-radius: 0px;
  110. background: #4285f4;
  111. color: #efefef;
  112. height: 20px;
  113. line-height: 20px;
  114. }
  115. .layui-table-cell {
  116. overflow: initial;
  117. }
  118. #customer_detail {
  119. display: block;
  120. width: 435px;
  121. height: 100%;
  122. position: absolute;
  123. top: 0;
  124. left: 0;
  125. }
  126. .rightbox {
  127. display: block;
  128. width: calc(100% - 435px);
  129. margin-left: 435px;
  130. }
  131. .unstatusbox {
  132. display: block;
  133. position: absolute;
  134. top: -5px;
  135. left: 0;
  136. width: 100%;
  137. height: 37px;
  138. background-color: #FF6600;
  139. text-align: center;
  140. color: #FFF;
  141. }
  142. .statusbox {
  143. position: absolute;
  144. top: 0px;
  145. right: 0px;
  146. color: #666;
  147. text-align: right;
  148. z-index: 100;
  149. display: block;
  150. font-size: 12px;
  151. }
  152. .layui-table-view .layui-form-checkbox {
  153. width: 16px;
  154. height: 16px;
  155. line-height: 16px;
  156. padding-right: 0;
  157. }
  158. .layui-table-view .layui-form-checkbox i {
  159. height: 16px;
  160. width: 16px;
  161. font-size: 14px;
  162. }
  163. .novisitlog {
  164. background-color: #9139db !important;
  165. color: #FFF;
  166. }
  167. .novisitlog a {
  168. color: #FFF;
  169. }
  170. .crmsearchlist {
  171. max-height: 760px;
  172. cursor: pointer;
  173. }
  174. .crmsearchlist-box{
  175. visibility: hidden;
  176. }
  177. .tablebox .layui-form.layui-border-box.layui-table-view {
  178. max-height: 400px !important;
  179. height: auto !important;
  180. }
  181. .searchbox .layui-form-select {
  182. float: left;
  183. width: 130px;
  184. }
  185. .searchbox input {
  186. border: 1px solid #e6e6e6 !important;
  187. }
  188. .layui-table-body {
  189. max-height: 400px !important;
  190. height: auto !important;
  191. }
  192. .layui-table-view .layui-table td {
  193. cursor: pointer;
  194. overflow: hidden;
  195. }
  196. .layui-form-checked {
  197. background-color: #37AF6E;
  198. }
  199. .layui-table-view .layui-form-checked i {
  200. color: #fff;
  201. }
  202. .summary_report h1 {
  203. text-align: center;
  204. margin-bottom: 20px;
  205. margin-top: 20px;
  206. letter-spacing: 2px;
  207. font-family: Arial, Helvetica, sans-serif;
  208. }
  209. .operate_report_op2{
  210. display: none;
  211. }
  212. .crmsearchlist-box .layui-table-cell{
  213. white-space: normal;
  214. height: auto;
  215. line-height: 1.2em;
  216. padding: 0;
  217. }
  218. .bgred{
  219. background-color: red;
  220. }
  221. .bgyellow{
  222. background-color: yellow;
  223. }
  224. .bggreen{
  225. background-color: green;
  226. }
  227. </style>
  228. <body class="clearfix">
  229. <iframe id="customer_detail" style="display: none;" src=""></iframe>
  230. <div class="crmbox summary_report">
  231. <form class="layui-form">
  232. <div class="searchtitlebox">
  233. <div style="margin-bottom:8px;">您当前的操作 · <b class="buildering-name">重点楼盘运营管控报表</b>
  234. <div class="searchbox clearfix operate_report_op2" style="width: 400px;float: right;margin-top: 0;">
  235. <div class="selectbox community1box" style="width: 400px;float: right;">
  236. <input style="width:160px" type="text" class="left searchtext" autocomplete="off" style="border-color: #ccc;" name="visitime" id="visitime" placeholder="选择时间"
  237. readonly />
  238. <select name="community1" lay-search>
  239. <option value="">==小区名称==</option>
  240. {volist name="community" id="vo"}
  241. <option value="{$vo.id}">{$vo.name}</option>
  242. {/volist}
  243. </select>
  244. <button class="left searchbtn1" type="button" lay-submit lay-filter="search1">查看</button>
  245. </div>
  246. </div>
  247. </div>
  248. </div>
  249. <div class="searchbox clearfix operate_report_op1">
  250. <div class="selectbox community2box" style="width: 316px;float: none;margin: 40px auto;">
  251. <select name="community2" lay-search>
  252. <option value="">==小区名称==</option>
  253. {volist name="community" id="vo"}
  254. <option value="{$vo.id}">{$vo.name}</option>
  255. {/volist}
  256. </select>
  257. <button class="left searchbtn1" type="button" lay-submit lay-filter="search2">查看</button>
  258. </div>
  259. </div>
  260. <div class="crmsearchlist-box">
  261. <h1></h1>
  262. <div class="crmsearchlist">
  263. <table lay-filter="crmsearchlist" id="crmsearchlist"></table>
  264. </div>
  265. </div>
  266. </form>
  267. </div>
  268. </body>
  269. <script src="__LAYUI__/layui/layui.js"></script>
  270. {/block}{block name="js"}
  271. <script type="text/javascript">
  272. var reload = null,
  273. resizefun = null;
  274. layui.config({
  275. base: '__LAYUI__/',
  276. urlbase: '/sys'
  277. }).extend({
  278. index: 'lib/index' //主入口模块
  279. }).use(['table', 'laydate'], function() {
  280. var table = layui.table,
  281. laydate = layui.laydate,
  282. $ = layui.$;
  283. form = layui.form;
  284. var field = {};
  285. laydate.render({
  286. elem: '#visitime',
  287. max:0
  288. ,trigger:'click',
  289. range: true
  290. });
  291. form.on('submit(search1)', function(data) {
  292. var community_id = $('[name=community1]').val();
  293. $('.buildering-name').html($('.community1box .layui-form-select input').val()+'运营管控报表')
  294. $('.crmsearchlist-box h1').html($('.community1box .layui-form-select input').val()+'小区综合报表')
  295. var date = $('#visitime').val();
  296. field['community_id'] = community_id;
  297. field['date'] = date;
  298. //执行重载
  299. table.reload('crmsearchlist', {
  300. url: '{:url("community/operate_report")}',
  301. where: field,
  302. page: {
  303. curr: 1
  304. }
  305. });
  306. });
  307. form.on('submit(search2)', function(data) {
  308. var community_id = $('[name=community2]').val();
  309. if(!community_id){
  310. return false
  311. }
  312. $('.operate_report_op1').css('display','none');
  313. $('.operate_report_op2').css('display','block');
  314. $('.crmsearchlist-box').css('visibility','unset');
  315. var date = $('#visitime').val();
  316. field['date'] = date;
  317. $('[name=community1]').val(community_id);
  318. $('.buildering-name').html($('.community2box .layui-form-select input').val()+'运营管控报表')
  319. $('.crmsearchlist-box h1').html($('.community2box .layui-form-select input').val()+'小区综合报表')
  320. // $('.community1box input').val(community_id);
  321. field['community_id'] = community_id;
  322. form.render();
  323. //执行重载
  324. table.reload('crmsearchlist', {
  325. url: '{:url("community/operate_report")}',
  326. where: field,
  327. page: {
  328. curr: 1
  329. }
  330. });
  331. });
  332. table.render({
  333. elem: '#crmsearchlist',
  334. url: '',
  335. data: [],
  336. resize: true,
  337. //even: true,
  338. cols: [
  339. [{
  340. title: '日期',
  341. field: 'date',
  342. align: 'center',
  343. rowspan: 2,
  344. },
  345. {
  346. title: '每日必完成项',
  347. field: 'community_name',
  348. align: 'center',
  349. colspan: 6,
  350. },
  351. {
  352. title: '实时安排类',
  353. field: 'square',
  354. align: 'center',
  355. colspan: 6,
  356. },
  357. {
  358. title: '到店引流类',
  359. field: 'square',
  360. align: 'center',
  361. colspan: 6,
  362. },
  363. {
  364. title: '活动类',
  365. field: 'square',
  366. align: 'center',
  367. colspan: 7,
  368. },
  369. {
  370. title: '价值输出类',
  371. field: 'square',
  372. align: 'center',
  373. colspan: 5,
  374. },
  375. {
  376. title: '会议类',
  377. field: 'square',
  378. align: 'center',
  379. colspan: 4,
  380. }
  381. ],
  382. [{
  383. title: '加微',
  384. field: 'jiav',
  385. align: 'center',
  386. minWidth:30,
  387. },
  388. {
  389. title: '进群',
  390. field: 'into_owner_group',
  391. align: 'center',
  392. minWidth:30,
  393. },
  394. {
  395. title: '回访',
  396. field: 'last_contact_date',
  397. align: 'center',
  398. minWidth:30,
  399. },
  400. {
  401. title: '口碑',
  402. field: 'reputation_gather',
  403. align: 'center',
  404. minWidth:30,
  405. },
  406. {
  407. title: '运营',
  408. field: 'chat_group',
  409. align: 'center',
  410. minWidth:30,
  411. },
  412. {
  413. title: '日志',
  414. field: 'work_log',
  415. align: 'center',
  416. minWidth:30,
  417. },
  418. {
  419. title: '社群剧本',
  420. field: 'group_script',
  421. align: 'center',
  422. minWidth:30,
  423. },
  424. {
  425. title: '种子客户',
  426. field: 'customer_worship',
  427. align: 'center',
  428. minWidth:30,
  429. },
  430. {
  431. title: 'VR楼书',
  432. field: 'building_output',
  433. align: 'center',
  434. minWidth:30,
  435. },
  436. {
  437. title: '谈单演练',
  438. field: 'talk_drill',
  439. align: 'center',
  440. minWidth:30,
  441. },
  442. {
  443. title: '素材包',
  444. field: 'material_production',
  445. align: 'center',
  446. minWidth:30,
  447. },
  448. {
  449. title: '威智慧口碑',
  450. field: 'wei_opinions',
  451. align: 'center',
  452. minWidth:30,
  453. },
  454. {
  455. title: '小区直播',
  456. field: 'community_broadcast',
  457. align: 'center',
  458. minWidth:30,
  459. },
  460. {
  461. title: '户型直播',
  462. field: 'housetype_broadcast',
  463. align: 'center',
  464. minWidth:30,
  465. },
  466. {
  467. title: '收房验房',
  468. field: 'house_inspection_broadcast',
  469. align: 'center',
  470. minWidth:30,
  471. },
  472. {
  473. title: '开工直播',
  474. field: 'start_work_broadcast',
  475. align: 'center',
  476. minWidth:30,
  477. },
  478. {
  479. title: '样板直播',
  480. field: 'sample_room_broadcast',
  481. align: 'center',
  482. minWidth:30,
  483. },
  484. {
  485. title: '定锚引流',
  486. field: 'anchoring_traffic',
  487. align: 'center',
  488. minWidth:30,
  489. },
  490. {
  491. title: '样板征集',
  492. field: 'sample_room_collect',
  493. align: 'center',
  494. minWidth:30,
  495. },
  496. {
  497. title: '业主团购',
  498. field: 'owner_buy',
  499. align: 'center',
  500. minWidth:30,
  501. },
  502. {
  503. title: '业主见面',
  504. field: 'owner_meeting',
  505. align: 'center',
  506. minWidth:30,
  507. },
  508. {
  509. title: '工地直通',
  510. field: 'construction_direct',
  511. align: 'center',
  512. minWidth:30,
  513. },
  514. {
  515. title: '验房抢购',
  516. field: 'house_inspection',
  517. align: 'center',
  518. minWidth:30,
  519. },
  520. {
  521. title: '归家晚宴',
  522. field: 'home_dinner',
  523. align: 'center',
  524. minWidth:30,
  525. },
  526. {
  527. title: '客户答谢',
  528. field: 'customer_thanks',
  529. align: 'center',
  530. minWidth:30,
  531. },
  532. {
  533. title: '户型分享',
  534. field: 'housetype_share',
  535. align: 'center',
  536. minWidth:30,
  537. },
  538. {
  539. title: '省钱攻略',
  540. field: 'decoration_saves_money',
  541. align: 'center',
  542. minWidth:30,
  543. },
  544. {
  545. title: '闭坑指南',
  546. field: 'decoration_closed_pit',
  547. align: 'center',
  548. minWidth:30,
  549. },
  550. {
  551. title: '十大空间',
  552. field: 'top_ten_spatial_planning',
  553. align: 'center',
  554. minWidth:30,
  555. },
  556. {
  557. title: '验收标准',
  558. field: 'decoration_acceptance_standards',
  559. align: 'center',
  560. minWidth:30,
  561. },
  562. {
  563. title: '周会',
  564. field: 'weekly_meeting',
  565. align: 'center',
  566. minWidth:30,
  567. },
  568. {
  569. title: '月会',
  570. field: 'month_meeting',
  571. align: 'center',
  572. minWidth:30,
  573. },
  574. {
  575. title: '对单会',
  576. field: 'single_meeting',
  577. align: 'center',
  578. minWidth:30,
  579. },
  580. {
  581. title: '培训会',
  582. field: 'train_meeting',
  583. align: 'center',
  584. minWidth:30,
  585. },
  586. ]
  587. ],
  588. page: true,
  589. limits: [10],
  590. limit: 10, //每页默认显示的数量,
  591. height: 'full-120',
  592. text: '对不起,加载出现异常!',
  593. done:function (res, page, count) {
  594. var that = this.elem.next();
  595. res.data.forEach(function (item,index) {
  596. var tr = that.find("[data-index=" + index + "]").children();
  597. tr.each(function () {
  598. var b = $(this).text();
  599. let arr =['anchoring_traffic',
  600. 'building_output',
  601. 'chat_group',
  602. 'community_broadcast',
  603. 'construction_direct',
  604. 'customer_thanks',
  605. 'customer_worship',
  606. 'decoration_acceptance_standards',
  607. 'decoration_closed_pit',
  608. 'decoration_saves_money',
  609. 'group_script',
  610. 'home_dinner',
  611. 'house_inspection',
  612. 'house_inspection_broadcast',
  613. 'housetype_broadcast',
  614. 'housetype_share',
  615. 'material_production',
  616. 'month_meeting',
  617. 'owner_buy',
  618. 'owner_meeting',
  619. 'sample_room_broadcast',
  620. 'sample_room_collect',
  621. 'single_meeting',
  622. 'start_work_broadcast',
  623. 'talk_drill',
  624. 'top_ten_spatial_planning',
  625. 'train_meeting',
  626. 'weekly_meeting',
  627. 'wei_opinions',
  628. 'work_log',]
  629. var field = $(this).attr('data-field');
  630. if (arr.indexOf(field) != -1) {
  631. if(b=='1'){
  632. $(this).css("background-color", "red");//单元格背景颜色
  633. $(this).css("color", "red");//单元格字体颜色
  634. }else if(b=='2'){
  635. $(this).css("background-color", "yellow");//单元格背景颜色
  636. $(this).css("color", "yellow");//单元格字体颜色
  637. }else if(b=='3'){
  638. $(this).css("background-color", "green");//单元格背景颜色
  639. $(this).css("color", "green");//单元格字体颜色
  640. }else{
  641. // $(this).css("background-color", "#fff");//单元格背景颜色
  642. $(this).css("color", "transparent");//单元格字体颜色
  643. }
  644. }
  645. })
  646. })
  647. },
  648. });
  649. resizefun = function() {
  650. table.resize('crmsearchlist');
  651. };
  652. window.resizefun2 = function() {
  653. table.resize('crmsearchlist');
  654. };
  655. reload = function() {
  656. table.reload('crmsearchlist', {
  657. url: '{:url("community/operate_report")}',
  658. where: field
  659. }, true);
  660. };
  661. })
  662. function removealog(params) {
  663. $('#customer_detail').hide();
  664. $('.crmbox').removeClass('rightbox');
  665. }
  666. </script>
  667. {/block}