Commit b741da2a authored by clone's avatar clone

Merge branch 'test'

parents 26a7f3fb ea714aa3
...@@ -51,5 +51,14 @@ ...@@ -51,5 +51,14 @@
<arguments>1.0-name-matches-false-false-node_modules</arguments> <arguments>1.0-name-matches-false-false-node_modules</arguments>
</matcher> </matcher>
</filter> </filter>
<filter>
<id>1530191912321</id>
<name></name>
<type>26</type>
<matcher>
<id>org.eclipse.ui.ide.multiFilter</id>
<arguments>1.0-name-matches-false-false-node_modules</arguments>
</matcher>
</filter>
</filteredResources> </filteredResources>
</projectDescription> </projectDescription>
...@@ -24,6 +24,25 @@ class UploadFileService ...@@ -24,6 +24,25 @@ class UploadFileService
*/ */
public function upload($_upload_file, $type, $size = 1000000, $ext = [ 'jpg' ]) public function upload($_upload_file, $type, $size = 1000000, $ext = [ 'jpg' ])
{ {
/**
*
upload($_FILE['file'])
array(2) {
[0] => array(3) {
["code"] => int(200)
["img_path"] => string(19) "201807021804140.jpg"
["img_ext"] => string(3) "jpg"
}
[1] => array(3) {
["code"] => int(200)
["img_path"] => string(20) "2018070218041401.jpg"
["img_ext"] => string(3) "jpg"
}
}
*/
$check = $this->checkUploadFile($_upload_file, $size, $ext); $check = $this->checkUploadFile($_upload_file, $size, $ext);
if ($check['code'] == 101) { if ($check['code'] == 101) {
...@@ -45,6 +64,7 @@ class UploadFileService ...@@ -45,6 +64,7 @@ class UploadFileService
break; break;
case 'house_img': case 'house_img':
$path .= 'resource/lib/Attachments/images/'; $path .= 'resource/lib/Attachments/images/';
break;
default : default :
$path .= 'static/'; $path .= 'static/';
} }
......
...@@ -77,22 +77,25 @@ class Agent extends Basic ...@@ -77,22 +77,25 @@ class Agent extends Basic
$pageNo = empty($params['pageNo']) ? 1 : $params['pageNo']; $pageNo = empty($params['pageNo']) ? 1 : $params['pageNo'];
$pageSize = empty($params['pageSize']) ? 15 : $params['pageSize']; $pageSize = empty($params['pageSize']) ? 15 : $params['pageSize'];
//条件 //条件
$where = 'a.status in(0,1)'; $where['a.status'] = ['IN',['0,1']];
$where = 'a.id != 1'; $where['a.id'] = ['<>', 1];
$search = $params['search'];
if (!empty($search)) { if (!empty($params['search'])) {
$where .= " and a.id='$search' or a.name like '%$search%' or a.phone like '%$search%' "; $where[] = ['EXP', "a.name like '%{$params['search']}%' OR a.phone like '%{$params['search']}%'"];
$data['search'] = $search;
} }
if (!empty($params['groupname'])) {
$where .= " and g.title like '%{$params['groupname']}%' "; if (!empty($params['group_name'])) {
$data['groupname'] = $params['groupname']; $where['g.title'] = ['LIKE', "%{$params['group_name']}%"];
} }
if (!empty($params['store_name'])) {
$where .= " and s.store_name like '%{$params['store_name']}%' "; if (!empty($params['store_id'])) {
$data['store_name'] = $params['store_name']; $where['a.store_id'] = $params['store_id'];
} }
if (!empty($params['district_id'])) {
$where['a.district_id'] = $params['district_id'];
}
$field = "a.id,a.store_id,a.img,a.district_id,a.`level`,a.`name`,a.phone,a.`status`,a.inviter_id,a.create_time, $field = "a.id,a.store_id,a.img,a.district_id,a.`level`,a.`name`,a.phone,a.`status`,a.inviter_id,a.create_time,
ifnull(s.store_name,'')store_name,ifnull(d.district_name,'')district_name,ifnull(g.title,'无')groupname"; ifnull(s.store_name,'')store_name,ifnull(d.district_name,'')district_name,ifnull(g.title,'无')groupname";
$order = 'a.id DESC'; $order = 'a.id DESC';
......
...@@ -47,7 +47,7 @@ class Collection extends Basic ...@@ -47,7 +47,7 @@ class Collection extends Basic
} }
if (!empty($this->params['internal_title'])) { if (!empty($this->params['internal_title'])) {
$where['d.internal_title'] = ['like', '%'.$where['internal_title'].'%']; $where['d.internal_title'] = ['like', '%'.$this->params['internal_title'].'%'];
} }
if (!empty($this->params['user_name'])) { if (!empty($this->params['user_name'])) {
......
...@@ -1016,47 +1016,57 @@ class Finance extends Basic ...@@ -1016,47 +1016,57 @@ class Finance extends Basic
$pageNo = empty($this->params['pageNo']) ? 1 : $this->params['pageNo']; $pageNo = empty($this->params['pageNo']) ? 1 : $this->params['pageNo'];
$pageSize = empty($this->params['pageSize']) ? 15 : $this->params['pageSize']; $pageSize = empty($this->params['pageSize']) ? 15 : $this->params['pageSize'];
$where['c.is_del'] = 0; //订单状态 $where['b.status'] = ['in', '10,11,13']; //10已提交 11审核成功
$where['a.status'] = ['in', '10,11,13']; //10已提交 11审核成功 $where['a.confirm_status'] = 1; //确认分佣
$where['b.father_id'] = ['<>', 0]; //去除税费总佣金
$where['c.confirm_status'] = 1; //确认分佣
$income_date = $operation_date = ''; $operation_start_data = $operation_end_data = $income_date = $operation_date = '';
/**收佣日期 start**/ /**收佣日期 start**/
if (!empty($this->params['income_start_date']) && empty($this->params['income_end_date'])) { if (!empty($this->params['income_start_date']) && empty($this->params['income_end_date'])) {
$where[] = [ 'EXP', " f.income_time > {$this->params['income_start_date']} or b.operation_date > {$this->params['income_start_date']}"]; $where[] = [ 'EXP', " f.income_time > {$this->params['income_start_date']} or c.operation_date > {$this->params['income_start_date']}"];
$income_date = date('Y.m.d', strtotime($this->params['income_start_date'])); $income_date = date('Y.m.d', strtotime($this->params['income_start_date']));
$operation_start_data = $this->params['income_start_date'];
} }
if (!empty($this->params['income_end_date']) && empty($this->params['income_start_date'])) { if (!empty($this->params['income_end_date']) && empty($this->params['income_start_date'])) {
$where[] = [ 'EXP', " f.income_time < {$this->params['income_end_date']} or b.operation_date < {$this->params['income_start_date']}"]; $where[] = [ 'EXP', " f.income_time < {$this->params['income_end_date']} or c.operation_date < {$this->params['income_start_date']}"];
$income_date = '-'. date('Y.m.d', strtotime($this->params['income_end_date'])); $income_date = '-'. date('Y.m.d', strtotime($this->params['income_end_date']));
$operation_end_data = $this->params['income_end_date'];
} }
if (!empty($this->params['income_start_date']) && !empty($this->params['income_end_date'])){ if (!empty($this->params['income_start_date']) && !empty($this->params['income_end_date'])){
$where[] = [ 'EXP', "(f.income_time > {$this->params['income_start_date']} and f.income_time < {$this->params['income_end_date']}) or $where[] = ['EXP', "(f.income_time BETWEEN '{$this->params['income_start_date']}' and '{$this->params['income_end_date']}')"];
(b.operation_date > {$this->params['income_start_date']} or b.operation_date < {$this->params['income_end_date']})"];
$income_date = date('Y.m.d', strtotime($this->params['income_start_date'])) .'-'. date('Y.m.d', strtotime($this->params['income_end_date'])); $income_date = date('Y.m.d', strtotime($this->params['income_start_date'])) .'-'. date('Y.m.d', strtotime($this->params['income_end_date']));
$operation_start_data = $this->params['income_start_date'];
$operation_end_data = $this->params['income_end_date'];
} }
/**收佣日期 end**/ /**收佣日期 end**/
/**提交成交报告日期 start**/ /**提交成交报告日期 start**/
if (!empty($this->params['bargain_start_date']) && empty($this->params['bargain_end_date'])) { if (!empty($this->params['bargain_start_date']) && empty($this->params['bargain_end_date'])) {
$where[] = [ 'EXP', "a.create_time > {$this->params['bargain_start_date']} . ' 00:00:00' or b.operation_date > {$this->params['bargain_start_date']}"]; $where[] = [ 'EXP', "a.create_time > {$this->params['bargain_start_date']} . ' 00:00:00' OR c.operation_date > {$this->params['bargain_start_date']}"];
$operation_date = date('Y.m.d', strtotime($this->params['bargain_start_date'])); $operation_date = date('Y.m.d', strtotime($this->params['bargain_start_date']));
$operation_start_data = $this->params['bargain_start_date'];
} }
if (!empty($this->params['bargain_end_date']) && empty($this->params['bargain_start_date'])) { if (!empty($this->params['bargain_end_date']) && empty($this->params['bargain_start_date'])) {
$where[] = [ 'EXP', "a.create_time < {$this->params['bargain_end_date']} . ' 23:59:59' or b.operation_date < {$this->params['bargain_end_date']}"]; $where[] = [ 'EXP', "a.create_time < {$this->params['bargain_end_date']} . ' 23:59:59' OR c.operation_date < {$this->params['bargain_end_date']}"];
$operation_date = date('Y.m.d', strtotime($this->params['bargain_end_date'])); $operation_date = date('Y.m.d', strtotime($this->params['bargain_end_date']));
$operation_end_data = $this->params['bargain_end_date'];
} }
if (!empty($this->params['bargain_start_date']) && !empty($this->params['bargain_end_date'])) { if (!empty($this->params['bargain_start_date']) && !empty($this->params['bargain_end_date'])) {
$where[] = [ 'EXP', "(a.create_time > '{$this->params['bargain_start_date']} 00:00:00' and a.create_time < '{$this->params['bargain_end_date']} 23:59:59') or $where[] = ['EXP', "(a.create_time BETWEEN '{$this->params['bargain_start_date']} 00:00:00' and '{$this->params['bargain_end_date']} 23:59:59')"];
(b.operation_date > {$this->params['bargain_start_date']} and b.operation_date < {$this->params['bargain_end_date']})"];
$operation_date = date('Y.m.d', strtotime($this->params['bargain_start_date'])) .'-'. date('Y.m.d', strtotime($this->params['bargain_end_date'])); $operation_date = date('Y.m.d', strtotime($this->params['bargain_start_date'])) .'-'. date('Y.m.d', strtotime($this->params['bargain_end_date']));
$operation_start_data = $this->params['bargain_start_date'];
$operation_end_data = $this->params['bargain_end_date'];
} }
/**部门id**/ /**部门id**/
...@@ -1071,7 +1081,7 @@ class Finance extends Basic ...@@ -1071,7 +1081,7 @@ class Finance extends Basic
/**经纪人手机号**/ /**经纪人手机号**/
if (!empty($this->params['phone'])) { if (!empty($this->params['phone'])) {
$where['b.phone'] = [ 'like', '%' . $this->params['phone'] . '%' ]; $where['d.phone'] = [ 'like', '%' . $this->params['phone'] . '%' ];
} }
/**经纪人姓名**/ /**经纪人姓名**/
...@@ -1079,14 +1089,12 @@ class Finance extends Basic ...@@ -1079,14 +1089,12 @@ class Finance extends Basic
$where['d.name'] = [ 'like', '%' . $this->params['name'] . '%' ]; $where['d.name'] = [ 'like', '%' . $this->params['name'] . '%' ];
} }
$m_bargain = new OBargainModel(); $m_bargain = new OPartialCommission();
if (empty($this->params['excel']) && $this->params['excel'] != 1) { if (empty($this->params['excel']) && $this->params['excel'] != 1) {
$fields = 'f.income_time,a.create_time,a.id,a.agent_id,sum(b.fee) as fee,sum(c.practical_fee) as practical_fee,sum(c.cash) as cash,'; $fields = 'f.income_time,b.create_time,b.id,b.agent_id,sum(a.practical_fee) as practical_fee,sum(a.cash) as cash,';
$fields .= 'sum(b.fee) as fee,sum(c.real_fee) as real_fee,'; $fields .= 'sum(a.real_fee) as real_fee,d.name,d.phone';
$fields .= 'd.name,d.phone'; $data['data']['list'] = $m_bargain->getCommissionTotalList($pageNo, $pageSize, 'a.id desc', $fields, $where, $operation_start_data, $operation_end_data);
$data['data']['list'] = $m_bargain->getCommissionTotalList($pageNo, $pageSize, 'a.id desc', $fields, $where, $whereOr);
foreach ($data['data']['list'] as $k=>$v) { foreach ($data['data']['list'] as $k=>$v) {
$data['data']['list'][$k]['income_date'] = $income_date; $data['data']['list'][$k]['income_date'] = $income_date;
...@@ -1094,17 +1102,17 @@ class Finance extends Basic ...@@ -1094,17 +1102,17 @@ class Finance extends Basic
$data['data']['list'][$k]['over_fee'] = $v['practical_fee'] - $v['fee']; $data['data']['list'][$k]['over_fee'] = $v['practical_fee'] - $v['fee'];
} }
$data['data']['total'] = $m_bargain->getCommissionTotalListTotal($where, $whereOr); $data['data']['total'] = $m_bargain->getCommissionTotalListTotal($where);
} else { } else {
//导出Excel //导出Excel
$fields = 'f.income_time,a.create_time,sum(b.fee) as fee,sum(f.money) as money,sum(c.cash) as cash,'; $fields = 'f.income_time,b.create_time,sum(f.money) as money,sum(a.cash) as cash,';
$fields .= 'sum(c.service_charge) as service_charge,a.agent_id,sum(c.practical_fee) as practical_fee,'; $fields .= 'sum(a.service_charge) as service_charge,a.agent_id,sum(a.practical_fee) as practical_fee,';
$fields .= 'd.name,d.phone,sum(c.charity_fund) as charity_fund, sum(should_commission) as should_commission'; $fields .= 'd.name,d.phone,sum(a.charity_fund) as charity_fund, sum(a.should_commission) as should_commission';
$pageSize = 25000; $pageSize = 25000;
$data = $m_bargain->getCommissionTotalList($pageNo, $pageSize, 'a.id desc', $fields, $where, $whereOr); $data = $m_bargain->getCommissionTotalList($pageNo, $pageSize, 'a.id desc', $fields, $where, $operation_start_data, $operation_end_data);
foreach ($data as $k => $v) { foreach ($data as $k => $v) {
$excel_data[$k]['income_date'] = $income_date; //收佣日期 $excel_data[$k]['income_date'] = $income_date; //收佣日期
......
...@@ -2,240 +2,240 @@ ...@@ -2,240 +2,240 @@
<input type="hidden" class="page-load" id="agent" /> <input type="hidden" class="page-load" id="agent" />
<!--关联经纪人列表liudanjs文件--> <!--关联经纪人列表liudanjs文件-->
<style> <style>
.J_preview{ .J_preview {
width: 30px; width: 30px;
height: 30px; height: 30px;
border-radius: 15px; border-radius: 15px;
} }
</style> </style>
<div id="page-content-wrapper"> <div id="page-content-wrapper">
<div class="container"> <div class="container">
<div class="row"> <div class="row">
<div class="col-lg-10 col-lg-offset-0"> <div class="col-lg-10 col-lg-offset-0">
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading breadcrumb"> <div class="panel-heading breadcrumb">
<li> <li>
<a href="#">经纪人管理</a> <a href="#">经纪人管理</a>
</li> </li>
<li class="active">经纪人列表</li> <li class="active">经纪人列表</li>
<div class="pull-right"> <div class="pull-right">
<ul class="bread_btn"> <ul class="bread_btn">
<li> <li>
<a href="#modal-edit" data-toggle="modal" class="btn btn-default agent_add"> <a href="#modal-edit" data-toggle="modal" class="btn btn-default agent_add">
<i class="icon-plus"></i> <i class="icon-plus"></i> 新增
新增</a> </a>
</li> </li>
</ul> </ul>
</div> </div>
</div> </div>
<div class="panel-body"> <div class="panel-body">
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-striped table-bordered table-hover table-condensed"> <table class="table table-striped table-bordered table-hover table-condensed">
<thead> <thead>
<tr> <tr>
<td colspan="11"> <td colspan="11">
<form id="form_search"> <form id="form_search">
<input class="form-control btn2 ld-Marheight" data-rule-phoneus="false" data-rule-required="false" id="industry_type" placeholder="角色" <input class="form-control btn2 ld-Marheight" data-rule-phoneus="false" data-rule-required="false" id="industry_type" placeholder="角色" type="text" value="" name="groupname">
type="text" value="" name="groupname"> <!--<input class="form-control btn2 ld-Marheight" data-rule-phoneus="false" data-rule-required="false" id="dish" placeholder="门店"
<input class="form-control btn2 ld-Marheight" data-rule-phoneus="false" data-rule-required="false" id="dish" placeholder="门店" type="text" value="" name="store_name">-->
type="text" value="" name="store_name"> <select class="form-control btn2 input ld-Marheight" name="" id="district_id">
<input class="form-control btn2 ld-Marheight" data-rule-phoneus="false" data-rule-required="false" id="id" placeholder="姓名/手机号" <option value="">部门</option>
name="search" type="text" value=""> </select>
<span class="btn btn-default btn3 ld-Marheight" id="search">搜索</span> <select class="form-control btn2 input ld-Marheight" name="" id="guest_stores">
<span class="btn btn-default btn3 ld-Marheight" id="reset">重置</span> </select>
<!--变更角色--> <input class="form-control btn2 ld-Marheight" data-rule-phoneus="false" data-rule-required="false" id="id" placeholder="姓名/手机号" name="search" type="text" value="">
</form> <span class="btn btn-default btn3 ld-Marheight" id="search">搜索</span>
</td> <span class="btn btn-default btn3 ld-Marheight" id="reset">重置</span>
</tr> <!--变更角色-->
<tr>
<th>注册时间</th>
<th>用户ID</th>
<th>用户头像</th>
<th>姓名</th>
<th>手机号</th>
<th>角色</th>
<!--2.2版本 -->
<!--<th>评价次数</th>
<th>分数</th>-->
<th>操作</th>
</tr>
</thead>
<tbody id="agentlist">
</tbody> </form>
</table> </td>
<!-- 列表底部按钮 --> </tr>
<div class="paginations text-right" id="pagediv"> <tr>
</div> <th>注册时间</th>
</div> <th>用户ID</th>
</div> <th>用户头像</th>
</div> <th>姓名</th>
</div> <th>手机号</th>
</div> <th>角色</th>
</div> <!--2.2版本 -->
<!--<th>评价次数</th>-->
<!--<th>分数</th>-->
<th>操作</th>
</tr>
</thead>
<tbody id="agentlist">
</tbody>
</table>
<!-- 列表底部按钮 -->
<div class="paginations text-right" id="pagediv">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div> </div>
<!--编辑--> <!--编辑-->
<div class="modal fade" id="modal-edit" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> <div class="modal fade" id="modal-edit" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">
× ×
</button> </button>
<h4 class="modal-title" id="title"> <h4 class="modal-title" id="title">
经纪人编辑 经纪人编辑
</h4> </h4>
</div> </div>
<div class="modal-body"> <div class="modal-body">
<form class="form-horizontal"> <form class="form-horizontal">
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">用户名:</label> <label class="col-sm-3 control-label">用户名:</label>
<input class="form-control btn6" data-rule-buga="false" data-rule-required="true" name="name" placeholder="登录账户所用名称" type="text" <input class="form-control btn6" data-rule-buga="false" data-rule-required="true" name="name" placeholder="登录账户所用名称" type="text" value="" id="title">
value="" id="title"> </div>
</div> <div class="form-group">
<div class="form-group"> <label class="col-sm-3 control-label">电话(登录账号):</label>
<label class="col-sm-3 control-label">电话(登录账号):</label> <input type="number" class="form-control btn6" name="phone" value="" placeholder="填写手机号">
<input type="number" class="form-control btn6" name="phone" value="" placeholder="填写手机号"> </div>
</div> <div class="form-group hide">
<div class="form-group hide"> <label class="col-sm-3 control-label">密码:</label>
<label class="col-sm-3 control-label">密码:</label> <input type="text" class="form-control btn6" name="password" id="password" value="44444" placeholder="填写密码">
<input type="text" class="form-control btn6" name="password" id="password" value="44444" placeholder="填写密码"> </div>
</div> <div class="form-group">
<div class="form-group"> <label class="col-sm-3 control-label">所属部门:</label>
<label class="col-sm-3 control-label">所属部门:</label> <select name="district_id" class="form-control btn6">
<select name="district_id" class="form-control btn6"> <option value="">选择所属部门</option>
<option value="">选择所属部门</option> </select>
</select> </div>
</div> <div class="form-group">
<div class="form-group"> <label class="col-sm-3 control-label">所属门店:</label>
<label class="col-sm-3 control-label">所属门店:</label> <select name="store_id" class="form-control btn6">
<select name="store_id" class="form-control btn6">
</select>
</select> </div>
</div> <div class="form-group">
<div class="form-group"> <label class="col-sm-3 control-label">性别:</label>
<label class="col-sm-3 control-label">性别:</label> <div class="radio radio-primary btn4 mr-10">
<div class="radio radio-primary btn4 mr-10"> <label for="sex0" class="radio-label1">
<label for="sex0" class="radio-label1">
<div class="iradio_minimal-blue" aria-checked="false" aria-disabled="false" style=""> <div class="iradio_minimal-blue" aria-checked="false" aria-disabled="false" style="">
<input type="radio" name="sex" id="sex0" value="0" checked=""> <input type="radio" name="sex" id="sex0" value="0" checked="">
</div>保密 </div>保密
</label> </label>
</div> </div>
<div class="radio radio-primary btn4 mr-10"> <div class="radio radio-primary btn4 mr-10">
<label for="sex0" class="radio-label1"> <label for="sex0" class="radio-label1">
<div class="iradio_minimal-blue" aria-checked="false" aria-disabled="false" style=""> <div class="iradio_minimal-blue" aria-checked="false" aria-disabled="false" style="">
<input type="radio" name="sex" id="sex1" value="1"> <input type="radio" name="sex" id="sex1" value="1">
</div> </div>
</label> </label>
</div> </div>
<div class="radio radio-primary btn4 mr-10"> <div class="radio radio-primary btn4 mr-10">
<label for="sex0" class="radio-label1"> <label for="sex0" class="radio-label1">
<div class="iradio_minimal-blue" aria-checked="false" aria-disabled="false" style=""> <div class="iradio_minimal-blue" aria-checked="false" aria-disabled="false" style="">
<input type="radio" name="sex" id="sex2" value="2"> <input type="radio" name="sex" id="sex2" value="2">
</div> </div>
</label> </label>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">是否允许访问后台:</label> <label class="col-sm-3 control-label">是否允许访问后台:</label>
<select name="admin_off" id="admin_off" class="form-control btn6"> <select name="admin_off" id="admin_off" class="form-control btn6">
<option value="0">允许</option> <option value="0">允许</option>
<option value="1">不允许</option> <option value="1">不允许</option>
</select> </select>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">个人说明:</label> <label class="col-sm-3 control-label">个人说明:</label>
<textarea name="remarks" id="remarks" class="form-control btn6" length="120" rows="5" placeholder="请填写个人说明"></textarea> <textarea name="remarks" id="remarks" class="form-control btn6" length="120" rows="5" placeholder="请填写个人说明"></textarea>
</div> </div>
</form> </form>
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">关闭 <button type="button" class="btn btn-default" data-dismiss="modal">关闭
</button> </button>
<button type="button" class="btn btn-primary submit_edit"> <button type="button" class="btn btn-primary submit_edit">
提交 提交
</button> </button>
</div> </div>
</div> </div>
<!-- /.modal-content --> <!-- /.modal-content -->
</div> </div>
<!-- /.modal --> <!-- /.modal -->
</div> </div>
<!--变更角色--> <!--变更角色-->
<div class="modal fade" id="modal-user" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> <div class="modal fade" id="modal-user" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">
× ×
</button> </button>
<h4 class="modal-title"> <h4 class="modal-title">
角色设置 角色设置
</h4> </h4>
</div> </div>
<div class="modal-body"> <div class="modal-body">
<form class="form-horizontal"> <form class="form-horizontal">
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">权限角色:</label> <label class="col-sm-3 control-label">权限角色:</label>
<select name="status" class="form-control btn6" id="edit_role"> <select name="status" class="form-control btn6" id="edit_role">
</select> </select>
</div> </div>
</form> </form>
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">关闭 <button type="button" class="btn btn-default" data-dismiss="modal">关闭
</button> </button>
<button type="button" class="btn btn-primary submit_user" data-dismiss="modal"> <button type="button" class="btn btn-primary submit_user" data-dismiss="modal">
提交 提交
</button> </button>
</div> </div>
</div> </div>
<!-- /.modal-content --> <!-- /.modal-content -->
</div> </div>
<!-- /.modal --> <!-- /.modal -->
</div> </div>
<!--绑定手机 2.2版本--> <!--绑定手机 2.2版本-->
<div class="modal fade" id="modal-unbundling" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> <div class="modal fade" id="modal-unbundling" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">
× ×
</button> </button>
<h4 class="modal-title"> <h4 class="modal-title">
角色设置 角色设置
</h4> </h4>
</div> </div>
<div class="modal-body"> <div class="modal-body">
<form class="form-horizontal"> <form class="form-horizontal">
<div class="form-group"> <div class="form-group">
绑定手机 绑定手机
<!--<label class="col-sm-3 control-label">权限角色:</label> <!--<label class="col-sm-3 control-label">权限角色:</label>
<select name="status" class="form-control btn6" id="edit_role"> <select name="status" class="form-control btn6" id="edit_role">
</select>--> </select>-->
</div> </div>
</form> </form>
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<!--<button type="button" class="btn btn-default" data-dismiss="modal">关闭 <!--<button type="button" class="btn btn-default" data-dismiss="modal">关闭
</button> </button>
<button type="button" class="btn btn-primary submit_user" data-dismiss="modal"> <button type="button" class="btn btn-primary submit_user" data-dismiss="modal">
提交 提交
</button>--> </button>-->
</div> </div>
</div> </div>
<!-- /.modal-content --> <!-- /.modal-content -->
</div> </div>
<!-- /.modal --> <!-- /.modal -->
</div> </div>
\ No newline at end of file
...@@ -272,7 +272,7 @@ ...@@ -272,7 +272,7 @@
<div class="modal-footer"> <div class="modal-footer">
<!--<button type="button" class="btn btn-default" data-dismiss="modal">关闭 <!--<button type="button" class="btn btn-default" data-dismiss="modal">关闭
</button>--> </button>-->
<button type="button" class="btn btn-primary submit_edit" id=" " data-dismiss="modal"> <button type="button" class="btn btn-primary" id="saveBtn" data-dismiss="modal">
保存 保存
</button> </button>
</div> </div>
......
...@@ -312,7 +312,7 @@ ...@@ -312,7 +312,7 @@
&times; &times;
</button> </button>
<h4 class="modal-title" > <h4 class="modal-title" >
批量修改 批量修改
</h4> </h4>
</div> </div>
<div class="modal-body modal-body-one"> <div class="modal-body modal-body-one">
......
...@@ -207,7 +207,7 @@ ...@@ -207,7 +207,7 @@
</select> </select>
<select class="form-control btn2 margin-top-ld input" name="" id="district_id" title=" <select class="form-control btn2 margin-top-ld input" name="" id="district_id" title="
客方所属部门、客方所属门店 与邀请人所属部门、邀请人所属门店 不作为并列筛选项"> 客方所属部门、客方所属门店 与邀请人所属部门、邀请人所属门店 不作为并列筛选项">
<option value="">客方所属部门</option> <option value="0">客方所属部门</option>
</select> </select>
...@@ -219,7 +219,7 @@ ...@@ -219,7 +219,7 @@
<!--邀请人--> <!--邀请人-->
<select class="form-control btn2 margin-top-ld input" name="" id="district_id2" title=" <select class="form-control btn2 margin-top-ld input" name="" id="district_id2" title="
客方所属部门、客方所属门店 与邀请人所属部门、邀请人所属门店 不作为并列筛选项"> 客方所属部门、客方所属门店 与邀请人所属部门、邀请人所属门店 不作为并列筛选项">
<option value="">邀请人所属部门</option> <option value="0">邀请人所属部门</option>
</select> </select>
...@@ -242,7 +242,7 @@ ...@@ -242,7 +242,7 @@
<span class="btn btn-info btn3 margin-top-ld" class="reset_1">重置</span> --> <span class="btn btn-info btn3 margin-top-ld" class="reset_1">重置</span> -->
<span class="btn btn-info btn3 margin-top-ld" id="search">搜索</span> <span class="btn btn-info btn3 margin-top-ld" id="search">搜索</span>
<span class="btn btn-info btn3 margin-top-ld" id="reset">重置</span> <span class="btn btn-info btn3 margin-top-ld" id="reset">重置</span>
<a href="#modal_modify_user" data-toggle="modal" class="btn btn-info btn3 margin-top-ld"><i class="icon-plus"></i> 批量修改 <a href="#modal_modify_user" data-toggle="modal" class="btn btn-info btn3 margin-top-ld"><i class="icon-plus"></i> 批量修改
</a> </a>
<!-- <span class="btn btn-info btn3 margin-top-ld" id="modify">批量修改客方</span> --> <!-- <span class="btn btn-info btn3 margin-top-ld" id="modify">批量修改客方</span> -->
...@@ -565,7 +565,7 @@ ...@@ -565,7 +565,7 @@
&times; &times;
</button> </button>
<h4 class="modal-title"> <h4 class="modal-title">
批量修改 批量修改
</h4> </h4>
</div> </div>
<div class="modal-body modal-body-one"> <div class="modal-body modal-body-one">
......
...@@ -12,6 +12,7 @@ namespace app\model; ...@@ -12,6 +12,7 @@ namespace app\model;
class OPartialCommission extends BaseModel class OPartialCommission extends BaseModel
{ {
protected $table = "o_partial_commission"; protected $table = "o_partial_commission";
/** /**
* 成交报告分佣表 * 成交报告分佣表
* *
...@@ -25,13 +26,14 @@ class OPartialCommission extends BaseModel ...@@ -25,13 +26,14 @@ class OPartialCommission extends BaseModel
* @throws \think\db\exception\ModelNotFoundException * @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException * @throws \think\exception\DbException
*/ */
public function getCommissionBargainList($pageNo, $pageSize, $order_ = 'id desc', $fields, $where) { public function getCommissionBargainList($pageNo, $pageSize, $order_ = 'id desc', $fields, $where)
$data = $this->field($fields) {
$data = $this->field($fields)
->alias('a') ->alias('a')
->join('o_bargain b', 'a.bargain_id = b.id', 'left') ->join('o_bargain b', 'a.bargain_id = b.id', 'left')
->join('o_order c', 'b.order_id = c.id', 'left') ->join('o_order c', 'b.order_id = c.id', 'left')
->join('g_houses d', 'c.house_id = d.id', 'left') ->join('g_houses d', 'c.house_id = d.id', 'left')
->join('a_agents e', 'b.agent_id = e.id','left') ->join('a_agents e', 'b.agent_id = e.id', 'left')
->where($where) ->where($where)
->order($order_) ->order($order_)
->limit($pageSize) ->limit($pageSize)
...@@ -39,30 +41,35 @@ class OPartialCommission extends BaseModel ...@@ -39,30 +41,35 @@ class OPartialCommission extends BaseModel
->select(); ->select();
$result = []; $result = [];
$m_agent = new AAgents(); $m_agent = new AAgents();
$m_bargain = new OBargainModel(); $m_bargain = new OBargainModel();
$fields_str = 'a.id,a.name,a.phone,b.store_name,c.district_name'; $fields_str = 'a.id,a.name,a.phone,b.store_name,c.district_name';
foreach ($data as $k => $v) { foreach ($data as $k => $v) {
$result[$k] = $v; $result[$k] = $v;
if (isset($v['agent_id'])) { if (isset($v['agent_id'])) {
$agent_data = $m_agent->getStoreDistrict($fields_str, ['a.id'=>$v['agent_id']]); $agent_data = $m_agent->getStoreDistrict($fields_str, [ 'a.id' => $v['agent_id'] ]);
$result[$k]['agent'] = $agent_data['name'].'-'.$agent_data['phone']; $result[$k]['agent'] = $agent_data['name'] . '-' . $agent_data['phone'];
$result[$k]['district_store'] = $agent_data['district_name'] .'-'.$agent_data['store_name']; $result[$k]['district_store'] = $agent_data['district_name'] . '-' . $agent_data['store_name'];
} }
if (isset($v['role'])) { if (isset($v['role'])) {
switch ($v['role']) { switch ($v['role']) {
case 1 : case 1 :
$data[$k]['role_name'] = '盘方';break; $data[$k]['role_name'] = '盘方';
break;
case 2 : case 2 :
$data[$k]['role_name'] = '客方';break; $data[$k]['role_name'] = '客方';
break;
case 3 : case 3 :
$data[$k]['role_name'] = '反签';break; $data[$k]['role_name'] = '反签';
break;
case 4 : case 4 :
$data[$k]['role_name'] = '独家';break; $data[$k]['role_name'] = '独家';
break;
case 5 : case 5 :
$data[$k]['role_name'] = '合作方';break; $data[$k]['role_name'] = '合作方';
break;
default : default :
$data[$k]['role_name'] = '无'; $data[$k]['role_name'] = '无';
} }
...@@ -84,12 +91,13 @@ class OPartialCommission extends BaseModel ...@@ -84,12 +91,13 @@ class OPartialCommission extends BaseModel
* @throws \think\db\exception\ModelNotFoundException * @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException * @throws \think\exception\DbException
*/ */
public function getCommissionBargainColumn($pageNo, $pageSize, $order_ = 'id desc', $fields, $where) { public function getCommissionBargainColumn($pageNo, $pageSize, $order_ = 'id desc', $fields, $where)
{
$data = $this->alias('a') $data = $this->alias('a')
->join('o_bargain b', 'a.bargain_id = b.id', 'left') ->join('o_bargain b', 'a.bargain_id = b.id', 'left')
->join('o_order c', 'b.order_id = c.id', 'left') ->join('o_order c', 'b.order_id = c.id', 'left')
->join('g_houses d', 'c.house_id = d.id', 'left') ->join('g_houses d', 'c.house_id = d.id', 'left')
->join('a_agents e', 'b.agent_id = e.id','left') ->join('a_agents e', 'b.agent_id = e.id', 'left')
->where($where) ->where($where)
->order($order_) ->order($order_)
->limit($pageSize) ->limit($pageSize)
...@@ -98,22 +106,22 @@ class OPartialCommission extends BaseModel ...@@ -98,22 +106,22 @@ class OPartialCommission extends BaseModel
$result = []; $result = [];
$m_agent = new AAgents(); $m_agent = new AAgents();
$fields_str = 'a.id,a.name,a.phone,b.store_name,c.district_name'; $fields_str = 'a.id,a.name,a.phone,b.store_name,c.district_name';
foreach ($data as $k => $v) { foreach ($data as $k => $v) {
$result[$k]['confirm_date'] = $v['confirm_date']; $result[$k]['confirm_date'] = $v['confirm_date'];
if ($v['agent_id']) { if ($v['agent_id']) {
$agent_data = $m_agent->getStoreDistrict($fields_str, ['a.id'=>$v['agent_id']]); $agent_data = $m_agent->getStoreDistrict($fields_str, [ 'a.id' => $v['agent_id'] ]);
$result[$k]['district_store'] = $agent_data['store_name'] .'-'.$agent_data['store_name']; $result[$k]['district_store'] = $agent_data['store_name'] . '-' . $agent_data['store_name'];
$result[$k]['agent'] = $agent_data['name'].'-'.$agent_data['phone']; $result[$k]['agent'] = $agent_data['name'] . '-' . $agent_data['phone'];
} }
$result[$k]['practical_fee'] = $v['practical_fee']; $result[$k]['practical_fee'] = $v['practical_fee'];
$result[$k]['scale_fee'] = $v['scale_fee']; $result[$k]['scale_fee'] = $v['scale_fee'];
$result[$k]['service_charge'] = $v['service_charge']; $result[$k]['service_charge'] = $v['service_charge'];
$result[$k]['charity_fund'] = $v['charity_fund']; $result[$k]['charity_fund'] = $v['charity_fund'];
$result[$k]['practical_fee'] = $v['practical_fee']; $result[$k]['practical_fee'] = $v['practical_fee'];
$result[$k]['cash'] = $v['cash']; $result[$k]['cash'] = $v['cash'];
$result[$k]['real_fee'] = $v['real_fee']; $result[$k]['real_fee'] = $v['real_fee'];
} }
return $result; return $result;
} }
...@@ -122,12 +130,13 @@ class OPartialCommission extends BaseModel ...@@ -122,12 +130,13 @@ class OPartialCommission extends BaseModel
* @param $where * @param $where
* @return int|string * @return int|string
*/ */
public function getCommissionBargainListTotal($where) { public function getCommissionBargainListTotal($where)
{
return $this->alias('a') return $this->alias('a')
->join('o_bargain b', 'a.bargain_id = b.id', 'left') ->join('o_bargain b', 'a.bargain_id = b.id', 'left')
->join('o_order c', 'b.order_id = c.id', 'left') ->join('o_order c', 'b.order_id = c.id', 'left')
->join('g_houses d', 'c.house_id = d.id', 'left') ->join('g_houses d', 'c.house_id = d.id', 'left')
->join('a_agents e', 'b.agent_id = e.id','left') ->join('a_agents e', 'b.agent_id = e.id', 'left')
->where($where) ->where($where)
->count(); ->count();
} }
...@@ -138,30 +147,31 @@ class OPartialCommission extends BaseModel ...@@ -138,30 +147,31 @@ class OPartialCommission extends BaseModel
* @param $data * @param $data
* @return int|string * @return int|string
*/ */
public function addCommission($data) { public function addCommission($data)
/* $insert_data['id'] = $data['id']; {
$insert_data['bargain_id'] = $data['bargain_id']; //成交报告id /* $insert_data['id'] = $data['id'];
$insert_data['practical_fee'] = $data['practical_fee']; //实收佣金 $insert_data['bargain_id'] = $data['bargain_id']; //成交报告id
$insert_data['cash'] = $data['cash']; //现金奖 $insert_data['practical_fee'] = $data['practical_fee']; //实收佣金
$insert_data['service_charge'] = $data['service_charge']; //手续费 $insert_data['cash'] = $data['cash']; //现金奖
$insert_data['charity_fund'] = $data['charity_fund']; //慈善基金 $insert_data['service_charge'] = $data['service_charge']; //手续费
$insert_data['real_fee'] = $data['real_fee']; //实分佣金 $insert_data['charity_fund'] = $data['charity_fund']; //慈善基金
$insert_data['operation_id'] = $agent_id; //操作人id $insert_data['real_fee'] = $data['real_fee']; //实分佣金
$insert_data['should_commission'] = $data['should_commission']; //应分佣金 $insert_data['operation_id'] = $agent_id; //操作人id
$insert_data['scale'] = $data['scale']; //分佣比例 $insert_data['should_commission'] = $data['should_commission']; //应分佣金
$insert_data['role'] = $data['role']; //分佣方 1盘方 2客方 3 反签 4独家 5合作方 $insert_data['scale'] = $data['scale']; //分佣比例
$insert_data['agent_id'] = $data['agent_id']; //分佣方经纪人 $insert_data['role'] = $data['role']; //分佣方 1盘方 2客方 3 反签 4独家 5合作方
//确认分佣加时间 否则 只是保存分佣数据 $insert_data['agent_id'] = $data['agent_id']; //分佣方经纪人
if ($data['confirm_date']) { //确认分佣加时间 否则 只是保存分佣数据
$insert_data['confirm_date'] = $data['confirm_date']; if ($data['confirm_date']) {
$insert_data['confirm_status'] = 1; $insert_data['confirm_date'] = $data['confirm_date'];
} $insert_data['confirm_status'] = 1;
}
if (empty($insert_data['id'])) { if (empty($insert_data['id'])) {
return $this->insert($insert_data); return $this->insert($insert_data);
} else { } else {
return $this->update($insert_data); return $this->update($insert_data);
}*/ }*/
return $this->saveAll($data); return $this->saveAll($data);
} }
...@@ -175,17 +185,18 @@ class OPartialCommission extends BaseModel ...@@ -175,17 +185,18 @@ class OPartialCommission extends BaseModel
* @throws \think\db\exception\ModelNotFoundException * @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException * @throws \think\exception\DbException
*/ */
public function getCommissionListByBargainId($field,$params){ public function getCommissionListByBargainId($field, $params)
{
$params["a.is_del"] = 0; $params["a.is_del"] = 0;
$result = $this->field($field) $result = $this->field($field)
->alias("a") ->alias("a")
->join("a_agents b","a.agent_id=b.id","left") ->join("a_agents b", "a.agent_id=b.id", "left")
->join("o_bargain c","a.bargain_id=c.id or a.bargain_id = c.father_id","left") ->join("o_bargain c", "a.bargain_id=c.id or a.bargain_id = c.father_id", "left")
->where($params) ->where($params)
->order("a.create_time desc") ->order("a.create_time desc")
->select(); ->select();
echo $this->getLastSql(); echo $this->getLastSql();
return $result ; return $result;
} }
...@@ -197,10 +208,72 @@ class OPartialCommission extends BaseModel ...@@ -197,10 +208,72 @@ class OPartialCommission extends BaseModel
* @throws \think\db\exception\BindParamException * @throws \think\db\exception\BindParamException
* @throws \think\exception\PDOException * @throws \think\exception\PDOException
*/ */
public function getBragainScale(int $bargain_id) { public function getBragainScale(int $bargain_id)
{
$sql = 'SELECT a.bargain_id,a.scale,b.scale_fee,a.agent_id,a.role,substring_index(group_concat(a.id ORDER BY a.id DESC),",",1) AS id $sql = 'SELECT a.bargain_id,a.scale,b.scale_fee,a.agent_id,a.role,substring_index(group_concat(a.id ORDER BY a.id DESC),",",1) AS id
FROM o_partial_commission a LEFT JOIN o_bargain b on a.bargain_id=b.id WHERE a.bargain_id = '.$bargain_id.' FROM o_partial_commission a LEFT JOIN o_bargain b on a.bargain_id=b.id WHERE a.bargain_id = ' . $bargain_id . '
and b.id= '.$bargain_id.' OR b.father_id='.$bargain_id.' GROUP BY role'; and b.id= ' . $bargain_id . ' OR b.father_id=' . $bargain_id . ' GROUP BY role';
return $this->query($sql); return $this->query($sql);
} }
/**
* 分佣提成汇总表
*
* @param int $pageNo
* @param int $pageSize
* @param string $order_
* @param string $field
* @param string $params
* @param $operation_start_data
* @param $operation_end_data
* @return false|\PDOStatement|string|\think\Collection
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException
*/
public function getCommissionTotalList($pageNo = 1, $pageSize = 15, $order_ = 'a.id desc', $field = '', $params = '', $operation_start_data, $operation_end_data)
{
$data = $this->alias('a')
->field($field)
->join('o_bargain b', 'a.bargain_id = b.id', 'left')
->join('o_real_income f', 'b.id = f.bargain_id', 'left')
->join('a_agents d', 'a.agent_id = d.id', 'left')
->where($params)
->order($order_)
->limit($pageSize)
->page($pageNo)
->group('a.agent_id')
->select();
$m_agent = new AAgents();
$m_tax = new OTaxes();
foreach ($data as $k => $v) {
if (isset($v['agent_id'])) {
$district_store = $m_agent->getStoreDistrict('store_name,district_name', [ 'a.id' => $v['agent_id'] ]);
$data[$k]['district_store'] = $district_store['district_name'] . '-' . $district_store['store_name'];
//税费
$data[$k]['fee'] = $m_tax->where('operation_date', 'between time', [$operation_start_data, $operation_end_data])
->where('agent_id', $v['agent_id'])->sum('fee');
}
}
return $data;
}
/**
* @param $params
* @return int|string
*/
public function getCommissionTotalListTotal($params)
{
return $this->alias('a')
->join('o_bargain b', 'a.bargain_id = b.id', 'left')
->join('o_real_income f', 'b.id = f.bargain_id', 'left')
->join('a_agents d', 'a.agent_id = d.id', 'left')
->where($params)
->group('a.agent_id')
->count();
}
} }
\ No newline at end of file
...@@ -23,4 +23,4 @@ ...@@ -23,4 +23,4 @@
if(!doc.addEventListener) return; if(!doc.addEventListener) return;
win.addEventListener(resizeEvt, recalc, false); win.addEventListener(resizeEvt, recalc, false);
doc.addEventListener('DOMContentLoaded', recalc, false); doc.addEventListener('DOMContentLoaded', recalc, false);
})(document, window);</script><script type=text/javascript src=./vconsole.min.js></script><script type=text/javascript>if(~location.origin.indexOf('api.tonglianjituan.com')){console.log('正式服')}else{var vConsole=new VConsole()};</script><link href=./static/css/app.65a7482b65465b468cd50d083c6b13f2.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.94d51f6620cb57f6116c.js></script><script type=text/javascript src=./static/js/app.ae212a464103491b75e1.js></script></body></html> })(document, window);</script><script type=text/javascript src=./vconsole.min.js></script><script type=text/javascript>if(~location.origin.indexOf('api.tonglianjituan.com')){console.log('正式服')}else{var vConsole=new VConsole()};</script><link href=./static/css/app.2c71066ef70dbce04427e0ec71aee085.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.94d51f6620cb57f6116c.js></script><script type=text/javascript src=./static/js/app.db402c74b35141cf046c.js></script></body></html>
\ No newline at end of file \ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
{"version":3,"sources":["webpack:///webpack/bootstrap c055640458e0b8ef7c39"],"names":["parentJsonpFunction","window","chunkIds","moreModules","executeModules","moduleId","chunkId","result","i","resolves","length","installedChunks","push","Object","prototype","hasOwnProperty","call","modules","shift","__webpack_require__","s","installedModules","2","exports","module","l","m","c","d","name","getter","o","defineProperty","configurable","enumerable","get","n","__esModule","object","property","p","oe","err","console","error"],"mappings":"aACA,IAAAA,EAAAC,OAAA,aACAA,OAAA,sBAAAC,EAAAC,EAAAC,GAIA,IADA,IAAAC,EAAAC,EAAAC,EAAAC,EAAA,EAAAC,KACQD,EAAAN,EAAAQ,OAAoBF,IAC5BF,EAAAJ,EAAAM,GACAG,EAAAL,IACAG,EAAAG,KAAAD,EAAAL,GAAA,IAEAK,EAAAL,GAAA,EAEA,IAAAD,KAAAF,EACAU,OAAAC,UAAAC,eAAAC,KAAAb,EAAAE,KACAY,EAAAZ,GAAAF,EAAAE,IAIA,IADAL,KAAAE,EAAAC,EAAAC,GACAK,EAAAC,QACAD,EAAAS,OAAAT,GAEA,GAAAL,EACA,IAAAI,EAAA,EAAYA,EAAAJ,EAAAM,OAA2BF,IACvCD,EAAAY,IAAAC,EAAAhB,EAAAI,IAGA,OAAAD,GAIA,IAAAc,KAGAV,GACAW,EAAA,GAIA,SAAAH,EAAAd,GAGA,GAAAgB,EAAAhB,GACA,OAAAgB,EAAAhB,GAAAkB,QAGA,IAAAC,EAAAH,EAAAhB,IACAG,EAAAH,EACAoB,GAAA,EACAF,YAUA,OANAN,EAAAZ,GAAAW,KAAAQ,EAAAD,QAAAC,IAAAD,QAAAJ,GAGAK,EAAAC,GAAA,EAGAD,EAAAD,QAKAJ,EAAAO,EAAAT,EAGAE,EAAAQ,EAAAN,EAGAF,EAAAS,EAAA,SAAAL,EAAAM,EAAAC,GACAX,EAAAY,EAAAR,EAAAM,IACAhB,OAAAmB,eAAAT,EAAAM,GACAI,cAAA,EACAC,YAAA,EACAC,IAAAL,KAMAX,EAAAiB,EAAA,SAAAZ,GACA,IAAAM,EAAAN,KAAAa,WACA,WAA2B,OAAAb,EAAA,SAC3B,WAAiC,OAAAA,GAEjC,OADAL,EAAAS,EAAAE,EAAA,IAAAA,GACAA,GAIAX,EAAAY,EAAA,SAAAO,EAAAC,GAAsD,OAAA1B,OAAAC,UAAAC,eAAAC,KAAAsB,EAAAC,IAGtDpB,EAAAqB,EAAA,KAGArB,EAAAsB,GAAA,SAAAC,GAA8D,MAApBC,QAAAC,MAAAF,GAAoBA","file":"static/js/manifest.3ad1d5771e9b13dbdad2.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tvar parentJsonpFunction = window[\"webpackJsonp\"];\n \twindow[\"webpackJsonp\"] = function webpackJsonpCallback(chunkIds, moreModules, executeModules) {\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [], result;\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(chunkIds, moreModules, executeModules);\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n \t\tif(executeModules) {\n \t\t\tfor(i=0; i < executeModules.length; i++) {\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = executeModules[i]);\n \t\t\t}\n \t\t}\n \t\treturn result;\n \t};\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// objects to store loaded and loading chunks\n \tvar installedChunks = {\n \t\t2: 0\n \t};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"./\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap c055640458e0b8ef7c39"],"sourceRoot":""} {"version":3,"sources":["webpack:///webpack/bootstrap 7befbe63d01516c8269f"],"names":["parentJsonpFunction","window","chunkIds","moreModules","executeModules","moduleId","chunkId","result","i","resolves","length","installedChunks","push","Object","prototype","hasOwnProperty","call","modules","shift","__webpack_require__","s","installedModules","2","exports","module","l","m","c","d","name","getter","o","defineProperty","configurable","enumerable","get","n","__esModule","object","property","p","oe","err","console","error"],"mappings":"aACA,IAAAA,EAAAC,OAAA,aACAA,OAAA,sBAAAC,EAAAC,EAAAC,GAIA,IADA,IAAAC,EAAAC,EAAAC,EAAAC,EAAA,EAAAC,KACQD,EAAAN,EAAAQ,OAAoBF,IAC5BF,EAAAJ,EAAAM,GACAG,EAAAL,IACAG,EAAAG,KAAAD,EAAAL,GAAA,IAEAK,EAAAL,GAAA,EAEA,IAAAD,KAAAF,EACAU,OAAAC,UAAAC,eAAAC,KAAAb,EAAAE,KACAY,EAAAZ,GAAAF,EAAAE,IAIA,IADAL,KAAAE,EAAAC,EAAAC,GACAK,EAAAC,QACAD,EAAAS,OAAAT,GAEA,GAAAL,EACA,IAAAI,EAAA,EAAYA,EAAAJ,EAAAM,OAA2BF,IACvCD,EAAAY,IAAAC,EAAAhB,EAAAI,IAGA,OAAAD,GAIA,IAAAc,KAGAV,GACAW,EAAA,GAIA,SAAAH,EAAAd,GAGA,GAAAgB,EAAAhB,GACA,OAAAgB,EAAAhB,GAAAkB,QAGA,IAAAC,EAAAH,EAAAhB,IACAG,EAAAH,EACAoB,GAAA,EACAF,YAUA,OANAN,EAAAZ,GAAAW,KAAAQ,EAAAD,QAAAC,IAAAD,QAAAJ,GAGAK,EAAAC,GAAA,EAGAD,EAAAD,QAKAJ,EAAAO,EAAAT,EAGAE,EAAAQ,EAAAN,EAGAF,EAAAS,EAAA,SAAAL,EAAAM,EAAAC,GACAX,EAAAY,EAAAR,EAAAM,IACAhB,OAAAmB,eAAAT,EAAAM,GACAI,cAAA,EACAC,YAAA,EACAC,IAAAL,KAMAX,EAAAiB,EAAA,SAAAZ,GACA,IAAAM,EAAAN,KAAAa,WACA,WAA2B,OAAAb,EAAA,SAC3B,WAAiC,OAAAA,GAEjC,OADAL,EAAAS,EAAAE,EAAA,IAAAA,GACAA,GAIAX,EAAAY,EAAA,SAAAO,EAAAC,GAAsD,OAAA1B,OAAAC,UAAAC,eAAAC,KAAAsB,EAAAC,IAGtDpB,EAAAqB,EAAA,KAGArB,EAAAsB,GAAA,SAAAC,GAA8D,MAApBC,QAAAC,MAAAF,GAAoBA","file":"static/js/manifest.3ad1d5771e9b13dbdad2.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tvar parentJsonpFunction = window[\"webpackJsonp\"];\n \twindow[\"webpackJsonp\"] = function webpackJsonpCallback(chunkIds, moreModules, executeModules) {\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [], result;\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(chunkIds, moreModules, executeModules);\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n \t\tif(executeModules) {\n \t\t\tfor(i=0; i < executeModules.length; i++) {\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = executeModules[i]);\n \t\t\t}\n \t\t}\n \t\treturn result;\n \t};\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// objects to store loaded and loading chunks\n \tvar installedChunks = {\n \t\t2: 0\n \t};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"./\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 7befbe63d01516c8269f"],"sourceRoot":""}
\ No newline at end of file \ No newline at end of file
...@@ -181,11 +181,12 @@ function loadMain(){ ...@@ -181,11 +181,12 @@ function loadMain(){
}); });
}); });
if(data['data']['user_info']['user_status'] == 0 || data['data']['user_info']['user_status'] == 1 || data['data']['user_info']['user_status'] == -1 ){ //标签没有默认状态了
_markAreaObj.find('a[data-markid="'+data['data']['user_info']['user_status']+'"]').addClass('genjin-mark-active').siblings().removeClass('genjin-mark-active'); // if(data['data']['user_info']['user_status'] == 0 || data['data']['user_info']['user_status'] == 1 || data['data']['user_info']['user_status'] == -1 ){
}else{ // _markAreaObj.find('a[data-markid="'+data['data']['user_info']['user_status']+'"]').addClass('genjin-mark-active').siblings().removeClass('genjin-mark-active');
layerTipsX('状态标签返回有误'); // }else{
} // layerTipsX('状态标签返回有误');
// }
}else { }else {
layerTipsX(data['msg']); layerTipsX(data['msg']);
...@@ -324,51 +325,61 @@ function loadMain(){ ...@@ -324,51 +325,61 @@ function loadMain(){
} }
}; };
$.ajax({ if(isCallFlag && ((_genjinMarkOBj2.attr('data-markid') == '1') || (_genjinMarkOBj2.attr('data-markid') == '4'))){
type: 'POST', if(_isFreeFlag) {
url: ServerHostTempC + '/broker/add_phone_follow_up', freePhone();
data: _data, };
timeout: 30000, layer.close(_index);
dataType: 'json', return false;
beforeSend: function() { //如果是电话跟进,选择了没打通或者取消拨打,则关掉不进行提交
_btnSave.hide(); }else{
_btnSaveTemp.css('display','block'); $.ajax({
}, type: 'POST',
success: function(data) { url: ServerHostTempC + '/broker/add_phone_follow_up',
if(typeof data === 'object') { data: _data,
if (data.code == 200) { timeout: 30000,
if(isCallFlag&&_isFreeFlag){ dataType: 'json',
//释放 beforeSend: function() {
freePhone(); _btnSave.hide();
}else{ _btnSaveTemp.css('display','block');
layer.open({ },
content: '提交成功', success: function(data) {
btn: ['确定'], if(typeof data === 'object') {
yes: function(_index){ if (data.code == 200) {
if(isCallFlag&&_isFreeFlag){
location.reload(); //释放
layer.close(_index); freePhone();
} }else{
}); layer.open({
}; content: '提交成功',
}else { btn: ['确定'],
layerTipsX(data['msg']); yes: function(_index){
};
}else{ location.reload();
layerTipsX('数据错误'); layer.close(_index);
}; }
}, });
error: function() { };
layerTipsX('error'); }else {
}, layerTipsX(data['msg']);
complete: function(xhr, textStatus){ };
_btnSaveTemp.hide(); }else{
_btnSave.css('display','block'); layerTipsX('数据错误');
if(textStatus === 'timeout'){ };
layerTipsX('请求超时'); },
}; error: function() {
} layerTipsX('error');
}); },
complete: function(xhr, textStatus){
_btnSaveTemp.hide();
_btnSave.css('display','block');
if(textStatus === 'timeout'){
layerTipsX('请求超时');
};
}
});
}
}); });
function freePhone(obj){ function freePhone(obj){
......
...@@ -187,6 +187,7 @@ ...@@ -187,6 +187,7 @@
</script> </script>
<style scoped> <style scoped>
/*注释部分*/
nav>.nav-main { nav>.nav-main {
display: flex; display: flex;
box-sizing: border-box; box-sizing: border-box;
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<span>{{data.name}}</span> <span>{{data.name}}</span>
<span>{{data.district_name+data.store_name}}</span> <span>{{data.district_name+data.store_name}}</span>
</p> </p>
<p>ID:{{data.create_time}}</p> <p>{{data.create_time}}</p>
</div> </div>
<div class="flex-center">{{isreceipt?data.practical_fee:data.scale_fee}}</div> <div class="flex-center">{{isreceipt?data.practical_fee:data.scale_fee}}</div>
</div> </div>
......
...@@ -12,11 +12,10 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin ...@@ -12,11 +12,10 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin
event: function () { event: function () {
var _doc = $(document); var _doc = $(document);
agent.getDistrict(function(){ agent.getDistrict(function(){
_doc.on('input', '[name=district_id]', function(){ _doc.on('input', '#district_id', function(){
var _this = $(this); var _this = $(this);
var _id = _this.val(); var _id = _this.val();
var _objTemp = _this.parent().next().find('select'); _this.next().html('');//先清空
_objTemp.html('');//先清空
if(_id && _id != '0'){ if(_id && _id != '0'){
agent.getDistrictStoreList(_id, function(_data){ agent.getDistrictStoreList(_id, function(_data){
// var _str = ''; // var _str = '';
...@@ -24,12 +23,12 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin ...@@ -24,12 +23,12 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin
$.each(_data, function(i,item) { $.each(_data, function(i,item) {
_str += '<option value="'+item.id+'">'+item.store_name+'</option>'; _str += '<option value="'+item.id+'">'+item.store_name+'</option>';
}); });
_objTemp.html(_str); _this.next().html(_str);//先清空
}); });
}else{ }else{
}; };
}); });
}) });
$('#search').click(function (pageNo) { $('#search').click(function (pageNo) {
agent.getList(1); agent.getList(1);
}); });
...@@ -243,8 +242,11 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin ...@@ -243,8 +242,11 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin
params.pageNo = agent.pageNo; params.pageNo = agent.pageNo;
params.pageSize = agent.pageSize; params.pageSize = agent.pageSize;
params.search = $("input[name='search']").val(); params.search = $("input[name='search']").val();
params.groupname = $("input[name='groupname']").val(); params.group_name = $("input[name='groupname']").val();
params.store_name = $("input[name='store_name']").val(); params.store_name = $("input[name='store_name']").val();
//后端加入两个字段搜索
params.district_id=$("#district_id").val();
params.store_id=$("#guest_stores").val();
$.ajax({ $.ajax({
url: '/index/AgentList', url: '/index/AgentList',
type: 'GET', type: 'GET',
...@@ -298,7 +300,7 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin ...@@ -298,7 +300,7 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'css!style/home.css', 'pagin
$.each(data.data, function(i,item) { $.each(data.data, function(i,item) {
str += '<option value="'+item.id+'">'+item.district_name+'</option>'; str += '<option value="'+item.id+'">'+item.district_name+'</option>';
}); });
$('[name=district_id]').append(str); $('#district_id').append(str);
fn && fn(); fn && fn();
} }
} }
......
...@@ -21,7 +21,7 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -21,7 +21,7 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
event: function() { event: function() {
var _doc = $(document); var _doc = $(document);
var _imgMaskObj = $('#img_mask_area'); //预览大图的mask var _imgMaskObj = $('#img_mask_area'); //预览大图的mask
var _imgUploadLunbo = $('#xiangqing_pic_ul'); //详情页轮播图ul
_doc.on('click', 'a[href="#modal-time"]', function(e){ _doc.on('click', 'a[href="#modal-time"]', function(e){
follow.house_id = $ (this).attr ("data-id"); follow.house_id = $ (this).attr ("data-id");
e.preventDefault(); e.preventDefault();
...@@ -32,6 +32,20 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -32,6 +32,20 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
$("#search").click(function() { $("#search").click(function() {
follow.getList(1); follow.getList(1);
}); });
//点击收款图片 2.2版本
// $(".add-pic").click(function() {
// follow.getaddPicList();
// });
_doc.on('click', '.add-pic', function(){
follow.getaddPicList();
});
$("#reset").click(function() { //重置 $("#reset").click(function() { //重置
document.getElementById("form_search").reset(); document.getElementById("form_search").reset();
}); });
...@@ -109,7 +123,7 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -109,7 +123,7 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
url: '/index/delHouseFile', url: '/index/delHouseFile',
data: { data: {
'id': _imgId, 'id': _imgId,
'house_id': _id 'house_id': 3104,
}, },
timeout: 30000, timeout: 30000,
dataType: 'json', dataType: 'json',
...@@ -140,17 +154,55 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -140,17 +154,55 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
} }
}; };
}); });
//图片预览点击放大事件 //图片预览点击放大事件
_doc.on('click', '.img-pre-ul>li>img', function(e) { _doc.on('click', '.img-pre-ul>li>img', function(e) {
_imgMaskObj.show().find('img').attr('src', this.src); _imgMaskObj.show().find('img').attr('src', this.src);
}); });
_imgMaskObj.click(function(e) { _imgMaskObj.click(function(e) {
this.style.display = 'none'; this.style.display = 'none';
}); });
//图片上传 2.2版本 //保存上传的图片
_doc.on('click', '#saveBtn', function(e) {
var _this = $(this);
var _data={
id:3104,
};
e.preventDefault();
e.stopPropagation();
var _imgUploadLunbo = $('#xiangqing_pic_ul'); //详情页轮播图ul
var _xiangqingPicObj = _imgUploadLunbo.find('li>img');
var _urlCut = location.origin + '/resource/lib/Attachments/images/';//要截取的部分url
$.each(_xiangqingPicObj, function(i, item) {
_data['slide_show[' + i + ']'] = item.src.replace(_urlCut, '');
});
var _imgId = _this.parent().attr('data-imgid');
$.ajax({
type: 'POST',
url: '/index/houseEdit',
data: _data,
// timeout: 30000,
dataType: 'json',
beforeSend: function() {},
success: function(_data) {
if(typeof _data === 'object') {
} else {
alert('数据错误');
};
},
error: function() {
alert('enter error');
},
complete: function(xhr, textStatus){
if(textStatus === 'timeout') {
//处理超时的逻辑
alert('请求超时,请重试');
};
}
});
});
//图片上传 2.2版本
}, },
addphone2:function(obj){ addphone2:function(obj){
...@@ -202,6 +254,34 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -202,6 +254,34 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
} }
}); });
}, },
//点击收款图片 调用的接口
getaddPicList: function() { //提交
var _imgUploadLunbo = $('#xiangqing_pic_ul'); //详情页轮播图ul
var _urlCut = location.origin + '/resource/lib/Attachments/images/';//要截取的部分url
_imgUploadLunbo.empty();
$.ajax({
'type': 'GET',
'url': '/index/houseEdit',
data: {
"id": 3104,
},
dataType: "json",
success: function(data) {
if(data.code == 200) {
var _data = data['data'];
for(var i in _data['slide_show']) {
_imgUploadLunbo.append('<li data-imgid="{id}"><img title="点击查看大图" src="{0}" /><a href="javascript:;" class="delet-pic-btn">删除</a></li>'.stringFormatObj({
'0': _urlCut + _data['slide_show'][i]['img_name'],
'id': _data['slide_show'][i]['id']
}));
};
// follow.getList(0);
} else {
}
}
});
},
// 导出列表 // 导出列表
exportList: function(pageNo) { exportList: function(pageNo) {
console.log(2); console.log(2);
......
...@@ -592,6 +592,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin ...@@ -592,6 +592,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
dataType: 'json', dataType: 'json',
success: function(data) { success: function(data) {
if(data.code == 200) { if(data.code == 200) {
business.getList(1);
console.log(666); console.log(666);
} }
} }
......
...@@ -397,6 +397,21 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', ' ...@@ -397,6 +397,21 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', '
getList: function (pageNo) { getList: function (pageNo) {
user.pageNo = pageNo; user.pageNo = pageNo;
var params = {}; var params = {};
// 并列搜索
// if($("#district_id").val()!=0){
// $("#district_id2").val('0');
// $("#guest_stores2").val('');
// console.log($("#district_id2").val());
// console.log($("#guest_stores2").val());
// };
// if($("#district_id2").val()!=0){
// $("#district_id1").val('0');
// $("#guest_stores1").val('');
// console.log($("#district_id").val());
// console.log($("#guest_stores").val());
// };
// 输入 name // 输入 name
// params.name = $("input[name='user']").val(); // params.name = $("input[name='user']").val();
......
...@@ -9,7 +9,11 @@ ...@@ -9,7 +9,11 @@
<td>[%= it[item]['practical_fee'] %]</td> <td>[%= it[item]['practical_fee'] %]</td>
<td>[%= it[item]['cash'] %]</td> <td>[%= it[item]['cash'] %]</td>
<td>[%= it[item]['practical_fee'] %]</td> <td>[%= it[item]['practical_fee'] %]</td>
<td>[%= it[item]['fee'] %]</td> <td>
[% if (it[item]['fee']){ %]
[%= it[item]['fee'] %]
[% } %]
</td>
<td>[%= it[item]['over_fee'] %]</td> <td>[%= it[item]['over_fee'] %]</td>
</tr> </tr>
[% } %] [% } %]
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
<td>[%= it[item]['house_number'] %]</td> <td>[%= it[item]['house_number'] %]</td>
<td> <td>
<!--增加收款图片 2.2版本--> <!--增加收款图片 2.2版本-->
<!--<a class="btn1 btn-info add-pic" href="#modal-addPic" data-toggle="modal" data-id='[%= it[item]["order_id"] %]'>收款图片</a>--> <a class="btn1 btn-info add-pic" href="#modal-addPic" data-toggle="modal" data-id='[%= it[item]["order_id"] %]'>收款图片</a>
<a class="btn1 btn-info timeline" href="#modal-time" data-toggle="modal" data-id='[%= it[item]["order_id"] %]'>时间轴</a> <a class="btn1 btn-info timeline" href="#modal-time" data-toggle="modal" data-id='[%= it[item]["order_id"] %]'>时间轴</a>
<a class="btn1 btn-info submit_edit2" href="#modal-linetime" data-toggle="modal" data-id='[%= it[item]["id"]%]' data-money='[%= it[item]["real_money"] %]'>编辑</a> <a class="btn1 btn-info submit_edit2" href="#modal-linetime" data-toggle="modal" data-id='[%= it[item]["id"]%]' data-money='[%= it[item]["real_money"] %]'>编辑</a>
</td> </td>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment