123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671 |
- {extend name="public/layout"}
- {block name="body"}
- <link rel="stylesheet" href="__LAYUI__/layui/css/layui.css" media="all">
- <link rel="stylesheet" " href=" /static/css/common.css">
- <script src="/static/js/jquery.min.js"></script>
- <style>
- body {
- padding-bottom: 40px;
- }
- .searchtitlebox {
- display: block;
- padding: 15px 10px;
- border: 1px solid #F0F0F0;
- background: #FCFCFC;
- margin-top: 5px;
- margin-bottom: 10px;
- position: relative;
- min-width: 800px;
- }
- .searchbox {
- display: block;
- margin-top: 8px;
- text-align: center;
- }
- .searchbox input {
- display: inline-block;
- height: 26px;
- line-height: 26px;
- padding-left: 3px;
- vertical-align: middle;
- }
- body {
- font-size: 12px;
- font-family: "宋体";
- }
- .selectbox {
- float: left;
- }
- .leftselect {
- float: left;
- height: 26px;
- line-height: 26px;
- }
- .selectbox select {
- float: left;
- height: 26px;
- }
- .searchtext {
- border: 1px solid #ccc;
- background: #fff url(__STATIC__/img/icon071402.png) no-repeat;
- padding: 1px 2px;
- height: 24px;
- line-height: 24px;
- vertical-align: middle;
- text-indent: 3px;
- margin-left: 4px;
- }
- .searchbtn1 {
- margin-left: 4px;
- cursor: pointer;
- color: #000;
- background: url(__STATIC__/img/btn_bg.gif) repeat-x;
- border: 1px solid #C0C0C0;
- padding: 0 12px;
- *padding: 0 6px;
- height: 26px;
- }
- .layui-table td,
- .layui-table th {
- font-size: 12px;
- }
- .layui-table th {
- font-weight: bold;
- }
- .dingjingorder {
- height: 25px;
- width: 40px;
- background-color: #65c001;
- color: #FFF;
- text-align: center;
- line-height: 25px;
- z-index: 100;
- display: block;
- position: absolute;
- top: 1px;
- right: 3px;
- border-radius: 11px;
- font-size: 12px;
- }
- .addvx {
- position: absolute;
- top: -5px;
- right: 1px;
- height: 14px;
- line-height: 14px;
- font-size: 16px;
- color: #666;
- font-family: "宋体";
- }
- .statebox {
- width: 40px;
- text-align: center;
- z-index: 100;
- display: block;
- position: absolute;
- font-size: 12px;
- top: -5px;
- right: 0px;
- border-radius: 0px;
- background: #4285f4;
- color: #efefef;
- height: 20px;
- line-height: 20px;
- }
- .layui-table-cell {
- overflow: initial;
- padding: 0;
- height: 36px;
- }
- #customer_detail {
- display: block;
- width: 435px;
- height: 100%;
- position: absolute;
- top: 0;
- left: 0;
- }
- .rightbox {
- display: block;
- width: calc(100% - 435px);
- margin-left: 435px;
- }
- .unstatusbox {
- display: block;
- position: absolute;
- top: -5px;
- left: 0;
- width: 100%;
- height: 37px;
- background-color: #FF6600;
- text-align: center;
- color: #FFF;
- }
- .statusbox {
- position: absolute;
- top: 0px;
- right: 0px;
- color: #666;
- text-align: right;
- z-index: 100;
- display: block;
- font-size: 12px;
- }
- .layui-table-view .layui-form-checkbox {
- width: 16px;
- height: 16px;
- line-height: 16px;
- padding-right: 0;
- }
- .layui-table-view .layui-form-checkbox i {
- height: 16px;
- width: 16px;
- font-size: 14px;
- }
- .novisitlog {
- background-color: #9139db !important;
- color: #FFF;
- }
- .novisitlog a {
- color: #FFF;
- }
- .crmsearchlist {
- cursor: pointer;
- }
- .tablebox .layui-form.layui-border-box.layui-table-view {
- max-height: 400px !important;
- height: auto !important;
- }
- .searchbox .layui-form-select {
- float: left;
- width: 130px;
- }
- .searchbox input {
- border: 1px solid #e6e6e6 !important;
- }
- .layui-table-body {
- /* max-height: 400px !important; */
- height: auto !important;
- }
- .layui-table-view .layui-table td {
- cursor: pointer;
- overflow: hidden;
- padding: 0;
- }
- .layui-form-checked {
- background-color: #37AF6E;
- }
- .layui-table-view .layui-form-checked i {
- color: #fff;
- }
- .summary_report h1 {
- text-align: center;
- margin-bottom: 20px;
- margin-top: 20px;
- letter-spacing: 2px;
- font-family: Arial, Helvetica, sans-serif;
- }
- .employee_reportbox,
- .searchbox1 {
- visibility: hidden;
- }
- .selectbox2 {
- width: 610px;
- margin: 100px auto 0;
- float: none !important;
- }
- .divhover:hover {
- background-color: #d0af4c;
- font-weight: bold;
- }
- .clickElement {
- display: inline-block;
- width: 100%;
- height: 100%;
- color: #249DFA;
- }
- .clickElement:hover {
- background-color: #d0af4c;
- }
- </style>
- <body class="clearfix">
- <iframe id="customer_detail" style="display: none;" src=""></iframe>
- <div class="crmbox summary_report">
- <div class="searchtitlebox">
- <form class="layui-form" lay-filter="val-filter1">
- <div style="margin-bottom:8px;">您当前的操作 · <b class="toptitle">各客服报表</b>
- <div class="searchbox clearfix searchbox1" style="float: right;margin-top: 0;">
- <div class="selectbox" style="float: right;">
- <select name="org_id" lay-search>
- <option value="">==所有部门==</option>
- {volist name="org" id="vo"}
- <option value="{$vo.id}">{$vo.name}</option>
- {/volist}
- </select>
- <select name="community_id" id="communityElement" lay-search>
- <option value="">==小区名称==</option>
- {volist name="community" id="vo"}
- <option value="{$vo.id}">{$vo.name}</option>
- {/volist}
- </select>
- <select name="invalid" lay-search>
- <option value="">==包含==</option>
- <option value="1">统计无效</option>
- </select>
- <input style="width:160px" type="text" lay-verify="required" class="left searchtext"
- autocomplete="off" style="border-color: #ccc;" name="date" id="visitime"
- placeholder="选择时间" readonly />
- <button class="left searchbtn1" type="button" lay-submit lay-filter="search">查看</button>
- </div>
- </div>
- </div>
- </form>
- </div>
- <form class="layui-form selectboxout2">
- <div class="searchbox clearfix" style="margin-top: 0 auto;">
- <div class="selectbox selectbox2" style="float: right;">
- <select name="org_id" lay-search>
- <option value="">==所有部门==</option>
- {volist name="org" id="vo"}
- <option value="{$vo.id}">{$vo.name}</option>
- {/volist}
- </select>
- <select name="community_id" lay-search>
- <option value="">==小区名称==</option>
- {volist name="community" id="vo"}
- <option value="{$vo.id}">{$vo.name}</option>
- {/volist}
- </select>
- <select name="invalid" lay-search>
- <option value="">==包含==</option>
- <option value="1">统计无效</option>
- </select>
- <input style="width:160px" type="text" lay-verify="required" class="left searchtext"
- autocomplete="off" style="border-color: #ccc;" name="date" id="visitime1" placeholder="选择时间"
- readonly />
- <button class="left searchbtn1" type="button" lay-submit lay-filter="search2">查看</button>
- </div>
- </div>
- </form>
- <div class="employee_reportbox">
- <h1>各销售客服报表</h1>
- <div class="crmsearchlist">
- <table lay-filter="crmsearchlist" id="crmsearchlist"></table>
- </div>
- </div>
- <div style="margin: 0 auto;">
- <div style="color: #999;text-align: right;">
- <p>注:</p>
- <p>1、基本数据:线索是根据信息录入的报名认时间统计。</p>
- <p>2、基本数据:加微是根据信息录入的时报名时间统计。</p>
- <p>3、基本数据:见面到访是根据首次洽谈的时间统计。</p>
- <p>4、基本数据:预定合同是根据定金时间统计,和报名、见面到访时间无关。</p>
- <p>5、基本数据:施工合同是根据合同时间统计,和报名、见面到访时间无关。</p>
- <p>6、注销:线索是根据变更线索无效的默认时间统计,和线索报名无关。</p>
- <p>7、注销:见面到访是根据首次洽谈时间统计,和线索报名时间无关。</p>
- </div>
- </div>
- </div>
- </body>
- <script src="__LAYUI__/layui/layui.js"></script>
- {/block}{block name="js"}
- <script type="text/html" id="count">
- {{# if(d.name=='求和'){ }}
- <span>{{d.count}}</span>
- {{# }else{ }}
- <span class="clickElement" lay-event="countAlink">{{d.count}}</span>
- {{# } }}
- </script>
- <script type="text/html" id="visitElement">
- {{# if(d.name=='求和'){ }}
- <span>{{d.visit}}</span>
- {{# }else{ }}
- <span class="clickElement" lay-event="visitAlink">{{d.visit}}</span>
- {{# } }}
- </script>
- <script type="text/html" id="depositElement">
- {{# if(d.name=='求和'){ }}
- <span>{{d.deposit}}</span>
- {{# }else{ }}
- <span class="clickElement" lay-event="depositAlink">{{d.deposit}}</span>
- {{# } }}
- </script>
- <script type="text/html" id="signedElement">
- {{# if(d.name=='求和'){ }}
- <span>{{d.signed}}</span>
- {{# }else{ }}
- <span class="clickElement" lay-event="signedAlink">{{d.signed}}</span>
- {{# } }}
- </script>
- <script type="text/javascript">
- var reload = null,
- resizefun = null;
- layui.config({
- base: '__LAYUI__/',
- urlbase: '/sys'
- }).extend({
- index: 'lib/index' //主入口模块
- }).use(['table', 'laydate'], function() {
- var table = layui.table,
- laydate = layui.laydate,
- $ = layui.$;
- form = layui.form;
- var field = {};
- laydate.render({
- elem: '#visitime',
- max: 0,
- trigger: 'click',
- range: true
- });
- laydate.render({
- elem: '#visitime1',
- max: 0,
- trigger: 'click',
- range: true
- });
- form.on('submit(search)', function(data) {
- Object.assign(field, data.field);
- $('.crmsearchlist').empty();
- $('.crmsearchlist').append('<table lay-filter="crmsearchlist" id="crmsearchlist"></table>');
- table.render({
- elem: '#crmsearchlist',
- url: '{:url("community/employee_report")}',
- data: [],
- where: field,
- page: false,
- limit: Number.MAX_VALUE,
- //even: true,
- cols: getCol(data.field.invalid),
- // page: true,
- // limits: [10],
- // limit: 10, //每页默认显示的数量,
- // height: 'full-120',
- text: '对不起,加载出现异常!'
- });
- });
- form.on('submit(search2)', function(data) {
- Object.assign(field, data.field);
- //执行重载
- form.val('val-filter1', data.field);
- $('.employee_reportbox').css('visibility', 'unset')
- $('.searchbox1').css('visibility', 'unset')
- $('.selectboxout2').css('display', 'none');
- form.render();
- $('.crmsearchlist').empty();
- $('.crmsearchlist').append('<table lay-filter="crmsearchlist" id="crmsearchlist"></table>');
- table.render({
- elem: '#crmsearchlist',
- url: '{:url("community/employee_report")}',
- data: [],
- where: field,
- page: false,
- limit: Number.MAX_VALUE,
- //even: true,
- cols: getCol(data.field.invalid),
- // page: true,
- // limits: [10],
- // limit: 10, //每页默认显示的数量,
- // height: 'full-120',
- text: '对不起,加载出现异常!'
- });
- // table.reload('crmsearchlist', {
- // url: '{:url("community/employee_report")}',
- // where: field,
- // });
- });
- table.render({
- elem: '#crmsearchlist',
- url: '',
- data: [],
- page: false,
- limit: Number.MAX_VALUE,
- //even: true,
- cols: getCol(),
- // page: true,
- // limits: [10],
- // limit: 10, //每页默认显示的数量,
- // height: 'full-120',
- text: '对不起,加载出现异常!'
- });
- table.on('tool(crmsearchlist)', function (result) {
- let event = result.event;
- let row = result.data;
- flag = true;
- if (event === "countAlink") {
- let date = $("#visitime").val();
- let communityId = $("#communityElement").val();
- layer.open({
- type: 2,
- title: $(this).attr('title'),
- shadeClose: true,
- scrollbar: false,
- shade: 0.8,
- area: ['99%', '96%'],
- content: "{:url('community/open')}?date="+ date +'&employee_id='+ row.id +'&module=employee&type=customer&community_id='+communityId,
- });
- } else if (event === "visitAlink") {
- let date = $("#visitime").val();
- let communityId = $("#communityElement").val();
- layer.open({
- type: 2,
- title: $(this).attr('title'),
- shadeClose: true,
- scrollbar: false,
- shade: 0.8,
- area: ['99%', '96%'],
- content: "{:url('community/open')}?date="+ date +'&employee_id='+ row.id +'&module=employee&type=visit&community_id='+communityId,
- });
- } else if (event === "depositAlink") {
- let date = $("#visitime").val();
- let communityId = $("#communityElement").val();
- layer.open({
- type: 2,
- title: $(this).attr('title'),
- shadeClose: true,
- scrollbar: false,
- shade: 0.8,
- area: ['99%', '96%'],
- content: "{:url('community/open')}?date="+ date +'&employee_id='+ row.id +'&module=employee&type=deposit&community_id='+communityId,
- });
- } else if (event === "signedAlink") {
- let date = $("#visitime").val();
- let communityId = $("#communityElement").val();
- layer.open({
- type: 2,
- title: $(this).attr('title'),
- shadeClose: true,
- scrollbar: false,
- shade: 0.8,
- area: ['99%', '96%'],
- content: "{:url('community/open')}?date="+ date +'&employee_id='+ row.id +'&module=employee&type=signed&community_id='+communityId,
- });
- }
- })
- resizefun = function() {
- table.resize('crmsearchlist');
- };
- window.resizefun2 = function() {
- table.resize('crmsearchlist');
- };
- reload = function() {
- table.reload('crmsearchlist', {
- url: '{:url("community/employee_report")}',
- where: field
- }, true);
- };
- })
- function getCol(invalid) {
- var xinjushang = "{$xinjushang}";
- var arr = [
- [{
- title: '客服',
- field: 'name',
- align: 'center',
- rowspan: 2,
- },
- {
- title: '基本数据',
- field: 'community_name',
- align: 'center',
- colspan: 11,
- }
- ],
- [{
- title: '信息量',
- field: 'count',
- align: 'center',
- templet: '#count',
- },
- {
- title: '加微量',
- field: 'wechat',
- align: 'center',
- },
- {
- title: '加微率',
- field: 'wechat_lv',
- align: 'center',
- },
- {
- title: '进群量',
- field: 'into_group',
- align: 'center',
- },
- {
- title: '进群率',
- field: 'into_group_lv',
- align: 'center',
- },
- {
- title: '见面量',
- field: 'visit',
- align: 'center',
- templet: "#visitElement"
- },
- {
- title: '见面率',
- field: 'visit_lv',
- align: 'center',
- },
- {
- title: `定金量`,
- field: 'deposit',
- align: 'center',
- templet: "#depositElement"
- },
- {
- title: '成单率',
- field: 'deposit_lv',
- align: 'center',
- },
- {
- title: `合同量`,
- field: 'signed',
- align: 'center',
- templet: "#signedElement"
- },
- {
- title: '业绩总额',
- field: 'signed_money',
- align: 'center',
- }
- ]
- ];
- if (invalid == 1) {
- arr[0].push({
- title: '注销',
- field: 'square',
- align: 'center',
- colspan: 3,
- });
- arr[1].push({
- title: '有效线索',
- field: 'invalid_valid',
- align: 'center',
- })
- arr[1].push({
- title: '见面',
- field: 'invalid_visit',
- align: 'center',
- })
- arr[1].push({
- title: `定金`,
- field: 'invalid_deposit',
- align: 'center',
- })
- }
- return arr;
- }
- function removealog(params) {
- $('#customer_detail').hide();
- $('.crmbox').removeClass('rightbox');
- }
- </script>
- {/block}
|