Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tl_estate
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hujun
tl_estate
Commits
236d1c0b
Commit
236d1c0b
authored
May 23, 2018
by
hujun
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'test-v1.9' of
https://gitee.com/zwyjjc/tl_estate
into test-v1.9
parents
30bb9869
a5e12d33
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
1642 additions
and
364 deletions
+1642
-364
commission.html
application/index/view/finance/commission.html
+3
-3
commission_total.html
application/index/view/finance/commission_total.html
+253
-2
tax.html
application/index/view/finance/tax.html
+253
-2
commission.js
public/resource/js/commission.js
+356
-0
commissionTotal.js
public/resource/js/commissionTotal.js
+356
-0
stateMent.js
public/resource/js/stateMent.js
+0
-356
tax.js
public/resource/js/tax.js
+362
-0
commissionTotal_template_tpl.html
public/resource/template/commissionTotal_template_tpl.html
+25
-0
commission_template_tpl.html
public/resource/template/commission_template_tpl.html
+1
-1
tax_template_tpl.html
public/resource/template/tax_template_tpl.html
+33
-0
No files found.
application/index/view/finance/commission.html
View file @
236d1c0b
{layout name="global/frame_tpl" /}
<input
type=
"hidden"
class=
"page-load"
id=
"
stateMent
"
/>
<input
type=
"hidden"
class=
"page-load"
id=
"
commission
"
/>
<style>
#note_text
{
width
:
80%
;
...
...
@@ -67,8 +67,8 @@
<form
id=
"form_search"
>
<span
class=
"fore-span ld-Marheight"
>
收佣日期:
</span>
<input
class=
"form-control btn4 ld-Marheight"
value=
""
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"create_time"
name=
"start_date"
type=
"date"
>
<
!--<span class="fore-span ld-Marheight">-</span>--
>
<
!--<input class="form-control btn4 ld-Marheight" value="" data-rule-phoneus="false" data-rule-required="false" id="end_time" name="end_date" type="date">--
>
<
span
class=
"fore-span ld-Marheight"
>
-
</span
>
<
input
class=
"form-control btn4 ld-Marheight"
value=
""
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"end_time"
name=
"end_date"
type=
"date"
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"internal_address"
placeholder=
"商铺地址"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"internal_num"
placeholder=
"商铺号"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"user_name"
placeholder=
"业务员姓名"
type=
"text"
value=
""
>
...
...
application/index/view/finance/commission_total.html
View file @
236d1c0b
{layout name="global/frame_tpl" /}
分佣提成汇总表
\ No newline at end of file
<input
type=
"hidden"
class=
"page-load"
id=
"commissionTotal"
/>
<style>
#note_text
{
width
:
80%
;
margin-left
:
48px
;
margin-top
:
-20px
;
}
#note_text_re
{
width
:
80%
;
margin-left
:
48px
;
margin-top
:
-20px
;
}
.Tswitch_one
{
display
:
none
;
}
.Tswitch_two
{
display
:
none
;
}
.left
{
float
:
left
;
width
:
340px
;
line-height
:
36px
;
}
.right
{
line-height
:
36px
;
}
.btn_2
{
width
:
60px
;
display
:
inline-block
;
height
:
26px
;
padding
:
3px
6px
}
.edit_new
{
float
:
right
;
margin-bottom
:
5px
;
margin-top
:
-10px
;
}
.form-control-one
{
display
:
inline-block
;
width
:
40%
;
}
#form_search
{
line-height
:
48px
;
}
.modal-body-two
{
height
:
500px
;
overflow-y
:
scroll
;
}
</style>
<div
id=
"page-content-wrapper"
>
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
"col-lg-10 col-lg-offset-0"
>
<div
class=
"panel panel-default"
>
<div
class=
"panel-heading breadcrumb"
>
<li><a
href=
"#"
>
分佣提成汇总表
</a></li>
</div>
<div
class=
"panel-body"
>
<div
class=
"table-responsive"
>
<table
class=
"table table-striped table-bordered table-hover table-condensed"
>
<thead>
<tr>
<td
colspan=
"9"
>
<form
id=
"form_search"
>
<span
class=
"fore-span ld-Marheight"
>
收佣日期:
</span>
<input
class=
"form-control btn4 ld-Marheight"
value=
""
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"create_time"
name=
"start_date"
type=
"date"
>
<!--<span class="fore-span ld-Marheight">-</span>-->
<!--<input class="form-control btn4 ld-Marheight" value="" data-rule-phoneus="false" data-rule-required="false" id="end_time" name="end_date" type="date">-->
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"internal_address"
placeholder=
"商铺地址"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"internal_num"
placeholder=
"商铺号"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"user_name"
placeholder=
"业务员姓名"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"user_phone"
placeholder=
"业务员手机号"
type=
"text"
value=
""
>
<span
class=
"btn btn-info btn3"
id=
"search"
>
搜索
</span>
<span
class=
"btn btn-info btn3"
id=
"reset"
>
重置
</span>
<span
class=
"btn btn-info btn3"
id=
"export"
>
导出excel
</span>
</form>
</td>
</tr>
<tr>
<th
class=
"text-center"
>
收佣日期
</th>
<th
class=
"text-center"
>
所属部门/门店
</th>
<th
class=
"text-center"
>
业务员
</th>
<th
class=
"text-center"
>
商铺地址
</th>
<th
class=
"text-center"
>
商铺号
</th>
<th
class=
"text-center"
>
应收佣金(元)
</th>
<th
class=
"text-center"
>
实收佣金(元)
</th>
<th
class=
"text-center"
>
操作
</th>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"business_list"
>
</table>
</div>
<!-- /#page-content-wrapper -->
<div
class=
"text-right"
id=
"pagediv"
>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- 弹出框 编辑 -->
<div
class=
"modal fade"
id=
"modal-details"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"myModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
<span
class=
"btn btn-info"
id=
"information"
>
成交信息
</span>
<span
class=
"btn btn-default caozuo"
id=
"fees"
>
分佣提成
</span>
<span
class=
"btn btn-default"
id=
"records"
>
收款记录
</span>
</h4>
</div>
<div
class=
"modal-body modal-body-two"
>
<div
class=
"Tswitch"
>
<div
class=
"left"
>
<span>
商铺地址:
</span><span
class=
"internal_address"
></span><br>
<span>
客户姓名:
</span><span
class=
"user_name"
></span><br>
<span>
应收总佣金:
</span>
<input
class=
"form-control btn_2 commission"
type=
"text"
>
元
<br>
<span>
实收佣金:
</span>
<input
class=
"form-control btn_2 practical_fee"
type=
"text"
>
元
<br>
</div>
<div
class=
"right"
>
<span>
商铺名称:
</span><span
class=
"internal_title"
></span><br>
<span>
客户电话:
</span><span
class=
"user_phone"
></span><br>
<span>
提交日期:
</span><span
class=
"create_time"
></span><br>
</div>
<input
type=
"hidden"
class=
"page-pass"
/>
</div>
<div
class=
"Tswitch Tswitch_one"
>
<!--分佣提成-->
<a
class=
"btn btn-success edit_new"
href=
"#modal-new"
data-toggle=
"modal"
>
新增
</a>
<table
class=
"table table-striped table-bordered table-hover table-condensed"
id=
"caozuo_hide"
>
<thead>
<tr>
<th
class=
"text-center"
>
分佣方
</th>
<th
class=
"text-center"
>
业务员
</th>
<th
class=
"text-center"
>
所属门店
</th>
<th
class=
"text-center"
>
分佣比例
</th>
<th
class=
"text-center"
>
应分佣金(元)
</th>
<th
class=
"text-center"
>
实分佣金
</th>
<th
class=
"text-center"
>
备注
</th>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"caozuo_table"
>
</table>
<!--分佣提成-->
</div>
<div
class=
"Tswitch Tswitch_two"
>
<table
class=
"table table-striped table-bordered table-hover table-condensed"
id=
"tcaozuo_hide"
>
<thead>
<tr>
<th
class=
"text-center"
>
入账时间
</th>
<th
class=
"text-center"
>
入账金额(元)
</th>
<th
class=
"text-center"
>
入账类型
</th>
<th
class=
"text-center"
>
入账方式
</th>
<th
class=
"text-center"
>
操作人
</th>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"tcaozuo_table"
>
</table>
</div>
<br><br><br><br>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
取消
</button>
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
id=
"confirm_edit"
>
确定
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
<!-- 弹出框 时间 -->
<div
class=
"modal fade"
id=
"modal-linetime"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"myModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
时间轴
</h4>
</div>
<div
class=
"modal-body"
>
<div
class=
"modal-body"
id=
"del_msg"
>
时间轴
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"button"
class=
"btn btn-primary"
id=
" "
>
删除
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
<!-- 分佣提成新增 -->
<div
class=
"modal fade"
id=
"modal-new"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"myModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
新增分佣提成
</h4>
</div>
<div
class=
"modal-body"
>
<div
class=
"modal-body"
id=
""
>
<!-- 新增分佣提成 -->
<form
id=
"form_search"
>
分佣方:
<select
class=
"form-control form-control-one"
id=
"is_carefully_chosen"
>
<option
value=
"0"
>
请选择
</option>
<option
value=
"1"
>
盘方
</option>
<option
value=
"2"
>
客方
</option>
<option
value=
"3"
>
反签
</option>
<option
value=
"4"
>
独家
</option>
<option
value=
"5"
>
合作方
</option>
</select><br>
<span>
业务员:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
" "
placeholder=
""
type=
"text"
value=
""
><br>
<span>
所属门店:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
" "
placeholder=
""
type=
"text"
value=
""
><br>
<span>
分佣比例:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"commission-rate"
placeholder=
""
type=
"text"
value=
""
><br>
<span>
应分佣金:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"should-commission"
placeholder=
""
type=
"text"
value=
""
><br>
</form>
<!-- 新增分佣提成 -->
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
取消
</button>
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
id=
"new-commission"
>
确定
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
application/index/view/finance/tax.html
View file @
236d1c0b
{layout name="global/frame_tpl" /}
税费承担明细表
\ No newline at end of file
<input
type=
"hidden"
class=
"page-load"
id=
"tax"
/>
<style>
#note_text
{
width
:
80%
;
margin-left
:
48px
;
margin-top
:
-20px
;
}
#note_text_re
{
width
:
80%
;
margin-left
:
48px
;
margin-top
:
-20px
;
}
.Tswitch_one
{
display
:
none
;
}
.Tswitch_two
{
display
:
none
;
}
.left
{
float
:
left
;
width
:
340px
;
line-height
:
36px
;
}
.right
{
line-height
:
36px
;
}
.btn_2
{
width
:
60px
;
display
:
inline-block
;
height
:
26px
;
padding
:
3px
6px
}
.edit_new
{
float
:
right
;
margin-bottom
:
5px
;
margin-top
:
-10px
;
}
.form-control-one
{
display
:
inline-block
;
width
:
40%
;
}
#form_search
{
line-height
:
48px
;
}
.modal-body-two
{
height
:
500px
;
overflow-y
:
scroll
;
}
</style>
<div
id=
"page-content-wrapper"
>
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
"col-lg-10 col-lg-offset-0"
>
<div
class=
"panel panel-default"
>
<div
class=
"panel-heading breadcrumb"
>
<li><a
href=
"#"
>
税费承担明细表
</a></li>
</div>
<div
class=
"panel-body"
>
<div
class=
"table-responsive"
>
<table
class=
"table table-striped table-bordered table-hover table-condensed"
>
<thead>
<tr>
<td
colspan=
"9"
>
<form
id=
"form_search"
>
<span
class=
"fore-span ld-Marheight"
>
开票日期:
</span>
<input
class=
"form-control btn4 ld-Marheight"
value=
""
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"create_time"
name=
"start_date"
type=
"date"
>
<span
class=
"fore-span ld-Marheight"
>
-
</span>
<input
class=
"form-control btn4 ld-Marheight"
value=
""
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"end_time"
name=
"end_date"
type=
"date"
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"internal_address"
placeholder=
"商铺地址"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"internal_num"
placeholder=
"商铺号"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"user_name"
placeholder=
"业务员姓名"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"user_phone"
placeholder=
"业务员手机号"
type=
"text"
value=
""
>
<span
class=
"btn btn-info btn3"
id=
"search"
>
搜索
</span>
<span
class=
"btn btn-info btn3"
id=
"reset"
>
重置
</span>
<!--<span class="btn btn-info btn3" id="export">导出excel</span>-->
<span>
税费合计:
</span><span
id=
"taxTotal"
>
15000元
</span>
</form>
</td>
</tr>
<tr>
<th
class=
"text-center"
>
开票日期
</th>
<th
class=
"text-center"
>
所属部门/门店
</th>
<th
class=
"text-center"
>
业务员
</th>
<th
class=
"text-center"
>
商铺地址
</th>
<th
class=
"text-center"
>
商铺号
</th>
<th
class=
"text-center"
>
税费(元)
</th>
<th
class=
"text-center"
>
操作
</th>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"business_list"
>
</table>
</div>
<!-- /#page-content-wrapper -->
<div
class=
"text-right"
id=
"pagediv"
>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- 弹出框 编辑 -->
<div
class=
"modal fade"
id=
"modal-details"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"myModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
<span
class=
"btn btn-info"
id=
"information"
>
成交信息
</span>
<span
class=
"btn btn-default caozuo"
id=
"fees"
>
分佣提成
</span>
<span
class=
"btn btn-default"
id=
"records"
>
收款记录
</span>
</h4>
</div>
<div
class=
"modal-body modal-body-two"
>
<div
class=
"Tswitch"
>
<div
class=
"left"
>
<span>
商铺地址:
</span><span
class=
"internal_address"
></span><br>
<span>
客户姓名:
</span><span
class=
"user_name"
></span><br>
<span>
应收总佣金:
</span>
<input
class=
"form-control btn_2 commission"
type=
"text"
>
元
<br>
<span>
实收佣金:
</span>
<input
class=
"form-control btn_2 practical_fee"
type=
"text"
>
元
<br>
</div>
<div
class=
"right"
>
<span>
商铺名称:
</span><span
class=
"internal_title"
></span><br>
<span>
客户电话:
</span><span
class=
"user_phone"
></span><br>
<span>
提交日期:
</span><span
class=
"create_time"
></span><br>
</div>
<input
type=
"hidden"
class=
"page-pass"
/>
</div>
<div
class=
"Tswitch Tswitch_one"
>
<!--分佣提成-->
<a
class=
"btn btn-success edit_new"
href=
"#modal-new"
data-toggle=
"modal"
>
新增
</a>
<table
class=
"table table-striped table-bordered table-hover table-condensed"
id=
"caozuo_hide"
>
<thead>
<tr>
<th
class=
"text-center"
>
分佣方
</th>
<th
class=
"text-center"
>
业务员
</th>
<th
class=
"text-center"
>
所属门店
</th>
<th
class=
"text-center"
>
分佣比例
</th>
<th
class=
"text-center"
>
应分佣金(元)
</th>
<th
class=
"text-center"
>
实分佣金
</th>
<th
class=
"text-center"
>
备注
</th>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"caozuo_table"
>
</table>
<!--分佣提成-->
</div>
<div
class=
"Tswitch Tswitch_two"
>
<table
class=
"table table-striped table-bordered table-hover table-condensed"
id=
"tcaozuo_hide"
>
<thead>
<tr>
<th
class=
"text-center"
>
入账时间
</th>
<th
class=
"text-center"
>
入账金额(元)
</th>
<th
class=
"text-center"
>
入账类型
</th>
<th
class=
"text-center"
>
入账方式
</th>
<th
class=
"text-center"
>
操作人
</th>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"tcaozuo_table"
>
</table>
</div>
<br><br><br><br>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
取消
</button>
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
id=
"confirm_edit"
>
确定
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
<!-- 弹出框 时间 -->
<div
class=
"modal fade"
id=
"modal-linetime"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"myModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
时间轴
</h4>
</div>
<div
class=
"modal-body"
>
<div
class=
"modal-body"
id=
"del_msg"
>
时间轴
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"button"
class=
"btn btn-primary"
id=
" "
>
删除
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
<!-- 分佣提成新增 -->
<div
class=
"modal fade"
id=
"modal-new"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"myModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
新增分佣提成
</h4>
</div>
<div
class=
"modal-body"
>
<div
class=
"modal-body"
id=
""
>
<!-- 新增分佣提成 -->
<form
id=
"form_search"
>
分佣方:
<select
class=
"form-control form-control-one"
id=
"is_carefully_chosen"
>
<option
value=
"0"
>
请选择
</option>
<option
value=
"1"
>
盘方
</option>
<option
value=
"2"
>
客方
</option>
<option
value=
"3"
>
反签
</option>
<option
value=
"4"
>
独家
</option>
<option
value=
"5"
>
合作方
</option>
</select><br>
<span>
业务员:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
" "
placeholder=
""
type=
"text"
value=
""
><br>
<span>
所属门店:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
" "
placeholder=
""
type=
"text"
value=
""
><br>
<span>
分佣比例:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"commission-rate"
placeholder=
""
type=
"text"
value=
""
><br>
<span>
应分佣金:
</span><input
class=
"form-control form-control-one"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"should-commission"
placeholder=
""
type=
"text"
value=
""
><br>
</form>
<!-- 新增分佣提成 -->
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
取消
</button>
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
id=
"new-commission"
>
确定
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
public/resource/js/commission.js
0 → 100644
View file @
236d1c0b
define
([
'doT'
,
'text!temp/commission_template_tpl.html'
,
'css!style/home.css'
,
'ckfinder'
,
'ckfinderStart'
,
'pagination'
,
'bootstrapJs'
],
function
(
doT
,
template
)
{
business
=
{
pageNo
:
1
,
/*第几页*/
pageSize
:
10
,
/*每页显示多少条*/
id
:
''
,
house_id
:
''
,
type
:
''
,
valueCurrent
:
''
,
ajaxObj
:
''
,
stopstatus
:
true
,
ldHtml
:
$
(
'.phone_list'
),
boxphoto
:
''
,
exclusive_id
:
0
,
init
:
function
()
{
//初始化dot
$
(
"body"
).
append
(
template
);
business
.
getList
();
business
.
event
();
},
event
:
function
()
{
var
_doc
=
$
(
document
);
$
(
"#search"
).
click
(
function
()
{
business
.
getList
(
1
);
});
$
(
"#export"
).
click
(
function
()
{
//导出列表
business
.
exportList
();
});
$
(
"#reset"
).
click
(
function
()
{
//重置
document
.
getElementById
(
"form_search"
).
reset
();
});
$
(
document
).
delegate
(
".del_modal"
,
"click"
,
function
()
{
business
.
id
=
$
(
this
).
attr
(
"data-id"
);
});
$
(
document
).
delegate
(
".caozuo"
,
"click"
,
function
()
{
//点击操作记录
business
.
Caozuo
();
});
// 时间轴
$
(
document
).
delegate
(
".timeline"
,
"click"
,
function
()
{
//时间轴
// business.house_id = $ (this).attr ("data-id");
business
.
Timeline
();
});
// 编辑
$
(
document
).
delegate
(
".edit"
,
"click"
,
function
()
{
//点击编辑
business
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
business
.
Edit
();
});
$
(
document
).
delegate
(
".is_pass"
,
"click"
,
function
()
{
//点击编辑
follow
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
console
.
log
(
follow
.
house_id
);
});
$
(
document
).
delegate
(
"#confirm_edit"
,
"click"
,
function
()
{
//点击编辑确定
business
.
confirmEdit
();
});
$
(
document
).
delegate
(
"#new-commission"
,
"click"
,
function
()
{
//点击分佣提成
business
.
newCommission
();
business
.
Caozuo
();
});
//table切换
$
(
document
).
delegate
(
"#information"
,
"click"
,
function
()
{
business
.
Information
();
});
$
(
document
).
delegate
(
"#fees"
,
"click"
,
function
()
{
console
.
log
(
business
.
house_id
);
business
.
Fees
();
});
$
(
document
).
delegate
(
"#records"
,
"click"
,
function
()
{
business
.
Records
();
});
},
Timeline
:
function
()
{
//获取时间轴
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/selectReportAll'
,
data
:
{
"order_id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
console
.
log
(
data
.
data
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Edit
:
function
()
{
//报告详情
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/bargainInfo'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
$
(
".create_time"
).
html
(
data
.
data
.
create_time
);
$
(
".user_phone"
).
html
(
data
.
data
.
user_phone
);
$
(
".user_name"
).
html
(
data
.
data
.
user_name
);
$
(
".internal_address"
).
html
(
data
.
data
.
internal_address
);
$
(
".internal_title"
).
html
(
data
.
data
.
internal_title
);
$
(
".commission"
).
val
(
data
.
data
.
commission
);
$
(
".practical_fee"
).
val
(
data
.
data
.
practical_fee
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
confirmEdit
:
function
()
{
//修改报告详情
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/editBargainInfo'
,
data
:
{
"id"
:
business
.
house_id
,
"scale_fee"
:
$
(
".commission"
).
val
(),
"practical_fee"
:
$
(
".practical_fee"
).
val
()
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Caozuo
:
function
()
{
//分佣提成获取跟进详情的数据
console
.
log
(
business
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/commissionList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
role
+
'</td><td>'
+
item
.
agent_name
+
'</td><td>'
+
item
.
store_name
+
'</td><td>'
+
item
.
scale
+
'</td><td>'
+
item
.
scale_fee
+
'</td><td>'
+
item
.
practical_fee
+
'</td><td>'
+
item
.
content
+
'</td></tr>'
;
});
$
(
"#caozuo_table"
).
html
(
caozuo_table
);
$
(
"#caozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp
=
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
();
//获取一列的值
if
(
temp
==
'null'
)
{
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Records
:
function
()
{
//分佣提成数据
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
show
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-default"
);
$
(
"#records"
).
addClass
(
"btn-info"
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/payLogList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
create_time
+
'</td><td>'
+
item
.
money
+
'</td><td>'
+
item
.
type
+
'</td><td>'
+
item
.
pay_type
+
'</td><td>'
+
item
.
agent_name
+
'</td></tr>'
;
});
$
(
"#tcaozuo_table"
).
html
(
caozuo_table
);
$
(
"#tcaozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp_one
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
();
var
temp
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
();
//获取一列的值
var
temp_two
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
();
// 支付方式 10支付宝 20 微信 30pos机器 40转账 50现金 60其他
if
(
temp
*
1
==
10
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"支付宝"
)
}
if
(
temp
*
1
==
20
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"微信"
)
}
if
(
temp
*
1
==
30
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"pos机器"
)
}
if
(
temp
*
1
==
40
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"转账"
)
}
if
(
temp
*
1
==
50
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"现金"
)
}
if
(
temp
*
1
==
60
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"其他"
)
}
// 付款类型 10意向金 20定金 30保管金 40押金 50 租金 60 进场费 70转让费 80其他
if
(
temp_two
*
1
==
10
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"意向金"
)
}
if
(
temp_two
*
1
==
20
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"定金"
)
}
if
(
temp_two
*
1
==
30
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"保管金"
)
}
if
(
temp_two
*
1
==
40
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"押金"
)
}
if
(
temp_two
*
1
==
50
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"租金"
)
}
if
(
temp_two
*
1
==
60
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"进场费"
)
}
if
(
temp_two
*
1
==
70
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"转让费"
)
}
if
(
temp_two
*
1
==
80
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"其他"
)
};
if
(
temp_one
==
'null'
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
newCommission
:
function
()
{
//新增分佣提成
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/addBargain'
,
data
:
{
"id"
:
business
.
house_id
,
"role"
:
$
(
"#is_carefully_chosen"
).
val
(),
"scale"
:
$
(
"#commission-rate"
).
val
(),
"scale_fee"
:
$
(
"#should-commission"
).
val
(),
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
console
.
log
(
666
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
// table切换
Information
:
function
()
{
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
Fees
:
function
()
{
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
show
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-default"
);
$
(
"#fees"
).
addClass
(
"btn-info"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
getList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
params
=
{};
params
.
pageNo
=
business
.
pageNo
;
params
.
pageSize
=
business
.
pageSize
;
// params.create_time = $('#create_time') .val();
params
.
internal_address
=
$
(
'#internal_address'
).
val
();
params
.
name
=
$
(
'#user_name'
).
val
();
params
.
phone
=
$
(
'#user_phone'
).
val
();
params
.
house_number
=
$
(
'#internal_num'
).
val
();
$
.
ajax
({
url
:
'/index/partialCommissionList'
,
//获取列表
type
:
'GET'
,
async
:
true
,
data
:
params
,
dataType
:
'json'
,
success
:
function
(
data
)
{
console
.
log
(
data
);
var
temp
=
document
.
getElementById
(
'commission_list_tpl'
).
innerHTML
;
var
doTtmpl
=
doT
.
template
(
temp
);
$
(
"#business_list"
).
html
(
doTtmpl
(
data
.
data
.
data
.
list
));
/*分页代码*/
add_page
(
data
.
data
.
data
.
total
,
pageNo
,
business
.
pageSize
,
business
.
getList
);
}
});
},
exportList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
create_time
=
$
(
'#create_time'
).
val
();
var
end_time
=
$
(
'#end_time'
).
val
();
var
internal_address
=
$
(
'#internal_address'
).
val
();
var
agent
=
$
(
'#user_name'
).
val
();
var
user_phone
=
$
(
'#user_phone'
).
val
();
var
house_number
=
$
(
'#internal_num'
).
val
();
window
.
open
(
'/index/exportExcel?create_time='
+
create_time
+
'&end_time='
+
end_time
+
'&internal_address='
+
internal_address
+
'&name='
+
agent
+
'&phone='
+
user_phone
+
'&house_number='
+
house_number
);
},
};
return
business
;
});
\ No newline at end of file
public/resource/js/commissionTotal.js
0 → 100644
View file @
236d1c0b
define
([
'doT'
,
'text!temp/commissionTotal_template_tpl.html'
,
'css!style/home.css'
,
'ckfinder'
,
'ckfinderStart'
,
'pagination'
,
'bootstrapJs'
],
function
(
doT
,
template
)
{
business
=
{
pageNo
:
1
,
/*第几页*/
pageSize
:
10
,
/*每页显示多少条*/
id
:
''
,
house_id
:
''
,
type
:
''
,
valueCurrent
:
''
,
ajaxObj
:
''
,
stopstatus
:
true
,
ldHtml
:
$
(
'.phone_list'
),
boxphoto
:
''
,
exclusive_id
:
0
,
init
:
function
()
{
//初始化dot
$
(
"body"
).
append
(
template
);
business
.
getList
();
business
.
event
();
},
event
:
function
()
{
var
_doc
=
$
(
document
);
$
(
"#search"
).
click
(
function
()
{
business
.
getList
(
1
);
});
$
(
"#export"
).
click
(
function
()
{
//导出列表
business
.
exportList
();
});
$
(
"#reset"
).
click
(
function
()
{
//重置
document
.
getElementById
(
"form_search"
).
reset
();
});
$
(
document
).
delegate
(
".del_modal"
,
"click"
,
function
()
{
business
.
id
=
$
(
this
).
attr
(
"data-id"
);
});
$
(
document
).
delegate
(
".caozuo"
,
"click"
,
function
()
{
//点击操作记录
business
.
Caozuo
();
});
// 时间轴
$
(
document
).
delegate
(
".timeline"
,
"click"
,
function
()
{
//时间轴
// business.house_id = $ (this).attr ("data-id");
business
.
Timeline
();
});
// 编辑
$
(
document
).
delegate
(
".edit"
,
"click"
,
function
()
{
//点击编辑
business
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
business
.
Edit
();
});
$
(
document
).
delegate
(
".is_pass"
,
"click"
,
function
()
{
//点击编辑
follow
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
console
.
log
(
follow
.
house_id
);
});
$
(
document
).
delegate
(
"#confirm_edit"
,
"click"
,
function
()
{
//点击编辑确定
business
.
confirmEdit
();
});
$
(
document
).
delegate
(
"#new-commission"
,
"click"
,
function
()
{
//点击分佣提成
business
.
newCommission
();
business
.
Caozuo
();
});
//table切换
$
(
document
).
delegate
(
"#information"
,
"click"
,
function
()
{
business
.
Information
();
});
$
(
document
).
delegate
(
"#fees"
,
"click"
,
function
()
{
console
.
log
(
business
.
house_id
);
business
.
Fees
();
});
$
(
document
).
delegate
(
"#records"
,
"click"
,
function
()
{
business
.
Records
();
});
},
Timeline
:
function
()
{
//获取时间轴
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/selectReportAll'
,
data
:
{
"order_id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
console
.
log
(
data
.
data
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Edit
:
function
()
{
//报告详情
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/bargainInfo'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
$
(
".create_time"
).
html
(
data
.
data
.
create_time
);
$
(
".user_phone"
).
html
(
data
.
data
.
user_phone
);
$
(
".user_name"
).
html
(
data
.
data
.
user_name
);
$
(
".internal_address"
).
html
(
data
.
data
.
internal_address
);
$
(
".internal_title"
).
html
(
data
.
data
.
internal_title
);
$
(
".commission"
).
val
(
data
.
data
.
commission
);
$
(
".practical_fee"
).
val
(
data
.
data
.
practical_fee
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
confirmEdit
:
function
()
{
//修改报告详情
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/editBargainInfo'
,
data
:
{
"id"
:
business
.
house_id
,
"scale_fee"
:
$
(
".commission"
).
val
(),
"practical_fee"
:
$
(
".practical_fee"
).
val
()
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Caozuo
:
function
()
{
//分佣提成获取跟进详情的数据
console
.
log
(
business
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/commissionList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
role
+
'</td><td>'
+
item
.
agent_name
+
'</td><td>'
+
item
.
store_name
+
'</td><td>'
+
item
.
scale
+
'</td><td>'
+
item
.
scale_fee
+
'</td><td>'
+
item
.
practical_fee
+
'</td><td>'
+
item
.
content
+
'</td></tr>'
;
});
$
(
"#caozuo_table"
).
html
(
caozuo_table
);
$
(
"#caozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp
=
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
();
//获取一列的值
if
(
temp
==
'null'
)
{
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Records
:
function
()
{
//分佣提成数据
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
show
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-default"
);
$
(
"#records"
).
addClass
(
"btn-info"
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/payLogList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
create_time
+
'</td><td>'
+
item
.
money
+
'</td><td>'
+
item
.
type
+
'</td><td>'
+
item
.
pay_type
+
'</td><td>'
+
item
.
agent_name
+
'</td></tr>'
;
});
$
(
"#tcaozuo_table"
).
html
(
caozuo_table
);
$
(
"#tcaozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp_one
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
();
var
temp
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
();
//获取一列的值
var
temp_two
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
();
// 支付方式 10支付宝 20 微信 30pos机器 40转账 50现金 60其他
if
(
temp
*
1
==
10
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"支付宝"
)
}
if
(
temp
*
1
==
20
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"微信"
)
}
if
(
temp
*
1
==
30
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"pos机器"
)
}
if
(
temp
*
1
==
40
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"转账"
)
}
if
(
temp
*
1
==
50
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"现金"
)
}
if
(
temp
*
1
==
60
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"其他"
)
}
// 付款类型 10意向金 20定金 30保管金 40押金 50 租金 60 进场费 70转让费 80其他
if
(
temp_two
*
1
==
10
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"意向金"
)
}
if
(
temp_two
*
1
==
20
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"定金"
)
}
if
(
temp_two
*
1
==
30
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"保管金"
)
}
if
(
temp_two
*
1
==
40
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"押金"
)
}
if
(
temp_two
*
1
==
50
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"租金"
)
}
if
(
temp_two
*
1
==
60
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"进场费"
)
}
if
(
temp_two
*
1
==
70
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"转让费"
)
}
if
(
temp_two
*
1
==
80
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"其他"
)
};
if
(
temp_one
==
'null'
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
newCommission
:
function
()
{
//新增分佣提成
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/addBargain'
,
data
:
{
"id"
:
business
.
house_id
,
"role"
:
$
(
"#is_carefully_chosen"
).
val
(),
"scale"
:
$
(
"#commission-rate"
).
val
(),
"scale_fee"
:
$
(
"#should-commission"
).
val
(),
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
console
.
log
(
666
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
// table切换
Information
:
function
()
{
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
Fees
:
function
()
{
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
show
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-default"
);
$
(
"#fees"
).
addClass
(
"btn-info"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
getList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
params
=
{};
params
.
pageNo
=
business
.
pageNo
;
params
.
pageSize
=
business
.
pageSize
;
// params.create_time = $('#create_time') .val();
params
.
internal_address
=
$
(
'#internal_address'
).
val
();
params
.
name
=
$
(
'#user_name'
).
val
();
params
.
phone
=
$
(
'#user_phone'
).
val
();
params
.
house_number
=
$
(
'#internal_num'
).
val
();
$
.
ajax
({
url
:
'/index/getTallAgeList'
,
//获取列表
type
:
'GET'
,
async
:
true
,
data
:
params
,
dataType
:
'json'
,
success
:
function
(
data
)
{
console
.
log
(
data
);
var
temp
=
document
.
getElementById
(
'commissionTotal_list_tpl'
).
innerHTML
;
var
doTtmpl
=
doT
.
template
(
temp
);
$
(
"#business_list"
).
html
(
doTtmpl
(
data
.
data
.
data
.
list
));
/*分页代码*/
add_page
(
data
.
data
.
data
.
total
,
pageNo
,
business
.
pageSize
,
business
.
getList
);
}
});
},
exportList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
create_time
=
$
(
'#create_time'
).
val
();
var
end_time
=
$
(
'#end_time'
).
val
();
var
internal_address
=
$
(
'#internal_address'
).
val
();
var
agent
=
$
(
'#user_name'
).
val
();
var
user_phone
=
$
(
'#user_phone'
).
val
();
var
house_number
=
$
(
'#internal_num'
).
val
();
window
.
open
(
'/index/exportExcel?create_time='
+
create_time
+
'&end_time='
+
end_time
+
'&internal_address='
+
internal_address
+
'&name='
+
agent
+
'&phone='
+
user_phone
+
'&house_number='
+
house_number
);
},
};
return
business
;
});
\ No newline at end of file
public/resource/js/stateMent.js
deleted
100644 → 0
View file @
30bb9869
/**
* Created by 刘丹 on 2017/12/11.
*/
define
([
'doT'
,
'text!temp/statement_template_tpl.html'
,
'css!style/home.css'
,
'ckfinder'
,
'ckfinderStart'
,
'pagination'
,
'bootstrapJs'
],
function
(
doT
,
template
)
{
business
=
{
pageNo
:
1
,
/*第几页*/
pageSize
:
10
,
/*每页显示多少条*/
id
:
''
,
house_id
:
''
,
type
:
''
,
valueCurrent
:
''
,
ajaxObj
:
''
,
stopstatus
:
true
,
ldHtml
:
$
(
'.phone_list'
),
boxphoto
:
''
,
exclusive_id
:
0
,
init
:
function
()
{
//初始化dot
$
(
"body"
).
append
(
template
);
business
.
getList
();
business
.
event
();
},
event
:
function
()
{
var
_doc
=
$
(
document
);
$
(
"#search"
).
click
(
function
()
{
business
.
getList
(
1
);
});
$
(
"#export"
).
click
(
function
()
{
//导出列表
business
.
exportList
();
});
$
(
"#reset"
).
click
(
function
()
{
//重置
document
.
getElementById
(
"form_search"
).
reset
();
});
$
(
document
).
delegate
(
".del_modal"
,
"click"
,
function
()
{
business
.
id
=
$
(
this
).
attr
(
"data-id"
);
});
$
(
document
).
delegate
(
".caozuo"
,
"click"
,
function
()
{
//点击操作记录
business
.
Caozuo
();
});
// 时间轴
$
(
document
).
delegate
(
".timeline"
,
"click"
,
function
()
{
//时间轴
// business.house_id = $ (this).attr ("data-id");
business
.
Timeline
();
});
// 编辑
$
(
document
).
delegate
(
".edit"
,
"click"
,
function
()
{
//点击编辑
business
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
business
.
Edit
();
});
$
(
document
).
delegate
(
".is_pass"
,
"click"
,
function
()
{
//点击编辑
follow
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
console
.
log
(
follow
.
house_id
);
});
$
(
document
).
delegate
(
"#confirm_edit"
,
"click"
,
function
()
{
//点击编辑确定
business
.
confirmEdit
();
});
$
(
document
).
delegate
(
"#new-commission"
,
"click"
,
function
()
{
//点击分佣提成
business
.
newCommission
();
business
.
Caozuo
();
});
//table切换
$
(
document
).
delegate
(
"#information"
,
"click"
,
function
()
{
business
.
Information
();
});
$
(
document
).
delegate
(
"#fees"
,
"click"
,
function
()
{
console
.
log
(
business
.
house_id
);
business
.
Fees
();
});
$
(
document
).
delegate
(
"#records"
,
"click"
,
function
()
{
business
.
Records
();
});
},
Timeline
:
function
(){
//获取时间轴
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/selectReportAll'
,
data
:
{
"order_id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
){
if
(
data
.
code
==
200
){
if
(
data
.
data
)
{
console
.
log
(
data
.
data
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Edit
:
function
(){
//报告详情
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/bargainInfo'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
){
if
(
data
.
code
==
200
){
if
(
data
.
data
)
{
$
(
".create_time"
).
html
(
data
.
data
.
create_time
);
$
(
".user_phone"
).
html
(
data
.
data
.
user_phone
);
$
(
".user_name"
).
html
(
data
.
data
.
user_name
);
$
(
".internal_address"
).
html
(
data
.
data
.
internal_address
);
$
(
".internal_title"
).
html
(
data
.
data
.
internal_title
);
$
(
".commission"
).
val
(
data
.
data
.
commission
);
$
(
".practical_fee"
).
val
(
data
.
data
.
practical_fee
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
confirmEdit
:
function
(){
//修改报告详情
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/editBargainInfo'
,
data
:
{
"id"
:
business
.
house_id
,
"scale_fee"
:
$
(
".commission"
).
val
(),
"practical_fee"
:
$
(
".practical_fee"
).
val
()
},
dataType
:
"json"
,
success
:
function
(
data
){
if
(
data
.
code
==
200
){
if
(
data
.
data
)
{
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Caozuo
:
function
(){
//分佣提成获取跟进详情的数据
console
.
log
(
business
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/commissionList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
){
if
(
data
.
code
==
200
){
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
role
+
'</td><td>'
+
item
.
agent_name
+
'</td><td>'
+
item
.
store_name
+
'</td><td>'
+
item
.
scale
+
'</td><td>'
+
item
.
scale_fee
+
'</td><td>'
+
item
.
practical_fee
+
'</td><td>'
+
item
.
content
+
'</td></tr>'
;
});
$
(
"#caozuo_table"
).
html
(
caozuo_table
);
$
(
"#caozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp
=
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
();
//获取一列的值
if
(
temp
==
'null'
){
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Records
:
function
(){
//分佣提成数据
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
show
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-default"
);
$
(
"#records"
).
addClass
(
"btn-info"
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/payLogList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
){
if
(
data
.
code
==
200
){
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
create_time
+
'</td><td>'
+
item
.
money
+
'</td><td>'
+
item
.
type
+
'</td><td>'
+
item
.
pay_type
+
'</td><td>'
+
item
.
agent_name
+
'</td></tr>'
;
});
$
(
"#tcaozuo_table"
).
html
(
caozuo_table
);
$
(
"#tcaozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp_one
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
();
var
temp
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
();
//获取一列的值
var
temp_two
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
();
// 支付方式 10支付宝 20 微信 30pos机器 40转账 50现金 60其他
if
(
temp
*
1
==
10
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"支付宝"
)
}
if
(
temp
*
1
==
20
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"微信"
)
}
if
(
temp
*
1
==
30
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"pos机器"
)
}
if
(
temp
*
1
==
40
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"转账"
)
}
if
(
temp
*
1
==
50
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"现金"
)
}
if
(
temp
*
1
==
60
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"其他"
)
}
// 付款类型 10意向金 20定金 30保管金 40押金 50 租金 60 进场费 70转让费 80其他
if
(
temp_two
*
1
==
10
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"意向金"
)
}
if
(
temp_two
*
1
==
20
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"定金"
)
}
if
(
temp_two
*
1
==
30
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"保管金"
)
}
if
(
temp_two
*
1
==
40
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"押金"
)
}
if
(
temp_two
*
1
==
50
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"租金"
)
}
if
(
temp_two
*
1
==
60
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"进场费"
)
}
if
(
temp_two
*
1
==
70
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"转让费"
)
}
if
(
temp_two
*
1
==
80
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"其他"
)
};
if
(
temp_one
==
'null'
){
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
newCommission
:
function
(){
//新增分佣提成
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/addBargain'
,
data
:
{
"id"
:
business
.
house_id
,
"role"
:
$
(
"#is_carefully_chosen"
).
val
(),
"scale"
:
$
(
"#commission-rate"
).
val
(),
"scale_fee"
:
$
(
"#should-commission"
).
val
(),
},
dataType
:
"json"
,
success
:
function
(
data
){
if
(
data
.
code
==
200
){
if
(
data
.
data
)
{
console
.
log
(
666
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
// table切换
Information
:
function
(){
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
Fees
:
function
(){
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
show
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-default"
);
$
(
"#fees"
).
addClass
(
"btn-info"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
getList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
params
=
{};
params
.
pageNo
=
business
.
pageNo
;
params
.
pageSize
=
business
.
pageSize
;
params
.
create_time
=
$
(
'#create_time'
)
.
val
();
params
.
internal_address
=
$
(
'#internal_address'
)
.
val
();
params
.
agent
=
$
(
'#user_name'
)
.
val
();
// params.user_phone = $('#user_phone') .val();
params
.
house_number
=
$
(
'#internal_num'
)
.
val
();
$
.
ajax
({
url
:
'/index/partialCommissionList'
,
//获取列表
type
:
'GET'
,
async
:
true
,
data
:
params
,
dataType
:
'json'
,
success
:
function
(
data
)
{
console
.
log
(
data
);
var
temp
=
document
.
getElementById
(
'statement_list_tpl'
).
innerHTML
;
var
doTtmpl
=
doT
.
template
(
temp
);
$
(
"#business_list"
).
html
(
doTtmpl
(
data
.
data
.
data
.
list
));
/*分页代码*/
add_page
(
data
.
data
.
data
.
total
,
pageNo
,
business
.
pageSize
,
business
.
getList
);
}
});
},
exportList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
create_time
=
$
(
'#create_time'
)
.
val
();
var
end_time
=
$
(
'#end_time'
)
.
val
();
var
internal_address
=
$
(
'#internal_address'
)
.
val
();
var
agent
=
$
(
'#user_name'
)
.
val
();
var
user_phone
=
$
(
'#user_phone'
)
.
val
();
var
house_number
=
$
(
'#internal_num'
)
.
val
();
window
.
open
(
'/index/exportExcel?create_time='
+
create_time
+
'&end_time='
+
end_time
+
'&internal_address='
+
internal_address
+
'&name='
+
agent
+
'&phone='
+
user_phone
+
'&house_number='
+
house_number
);
},
};
return
business
;
});
\ No newline at end of file
public/resource/js/tax.js
0 → 100644
View file @
236d1c0b
define
([
'doT'
,
'text!temp/tax_template_tpl.html'
,
'css!style/home.css'
,
'ckfinder'
,
'ckfinderStart'
,
'pagination'
,
'bootstrapJs'
],
function
(
doT
,
template
)
{
business
=
{
pageNo
:
1
,
/*第几页*/
pageSize
:
10
,
/*每页显示多少条*/
id
:
''
,
house_id
:
''
,
type
:
''
,
valueCurrent
:
''
,
ajaxObj
:
''
,
stopstatus
:
true
,
ldHtml
:
$
(
'.phone_list'
),
boxphoto
:
''
,
exclusive_id
:
0
,
init
:
function
()
{
//初始化dot
$
(
"body"
).
append
(
template
);
business
.
getList
();
business
.
event
();
},
event
:
function
()
{
var
_doc
=
$
(
document
);
$
(
"#search"
).
click
(
function
()
{
business
.
getList
(
1
);
});
$
(
"#export"
).
click
(
function
()
{
//导出列表
business
.
exportList
();
});
$
(
"#reset"
).
click
(
function
()
{
//重置
document
.
getElementById
(
"form_search"
).
reset
();
});
$
(
document
).
delegate
(
".del_modal"
,
"click"
,
function
()
{
business
.
id
=
$
(
this
).
attr
(
"data-id"
);
});
$
(
document
).
delegate
(
".caozuo"
,
"click"
,
function
()
{
//点击操作记录
business
.
Caozuo
();
});
// 时间轴
$
(
document
).
delegate
(
".timeline"
,
"click"
,
function
()
{
//时间轴
// business.house_id = $ (this).attr ("data-id");
business
.
Timeline
();
});
// 编辑
$
(
document
).
delegate
(
".edit"
,
"click"
,
function
()
{
//点击编辑
business
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
business
.
Edit
();
});
$
(
document
).
delegate
(
".is_pass"
,
"click"
,
function
()
{
//点击编辑
follow
.
house_id
=
$
(
this
).
attr
(
"data-id"
);
console
.
log
(
follow
.
house_id
);
});
$
(
document
).
delegate
(
"#confirm_edit"
,
"click"
,
function
()
{
//点击编辑确定
business
.
confirmEdit
();
});
$
(
document
).
delegate
(
"#new-commission"
,
"click"
,
function
()
{
//点击分佣提成
business
.
newCommission
();
business
.
Caozuo
();
});
//table切换
$
(
document
).
delegate
(
"#information"
,
"click"
,
function
()
{
business
.
Information
();
});
$
(
document
).
delegate
(
"#fees"
,
"click"
,
function
()
{
console
.
log
(
business
.
house_id
);
business
.
Fees
();
});
$
(
document
).
delegate
(
"#records"
,
"click"
,
function
()
{
business
.
Records
();
});
},
Timeline
:
function
()
{
//获取时间轴
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/selectReportAll'
,
data
:
{
"order_id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
console
.
log
(
data
.
data
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Edit
:
function
()
{
//报告详情
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/bargainInfo'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
$
(
".create_time"
).
html
(
data
.
data
.
create_time
);
$
(
".user_phone"
).
html
(
data
.
data
.
user_phone
);
$
(
".user_name"
).
html
(
data
.
data
.
user_name
);
$
(
".internal_address"
).
html
(
data
.
data
.
internal_address
);
$
(
".internal_title"
).
html
(
data
.
data
.
internal_title
);
$
(
".commission"
).
val
(
data
.
data
.
commission
);
$
(
".practical_fee"
).
val
(
data
.
data
.
practical_fee
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
confirmEdit
:
function
()
{
//修改报告详情
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/editBargainInfo'
,
data
:
{
"id"
:
business
.
house_id
,
"scale_fee"
:
$
(
".commission"
).
val
(),
"practical_fee"
:
$
(
".practical_fee"
).
val
()
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Caozuo
:
function
()
{
//分佣提成获取跟进详情的数据
console
.
log
(
business
);
console
.
log
(
business
.
house_id
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/commissionList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
role
+
'</td><td>'
+
item
.
agent_name
+
'</td><td>'
+
item
.
store_name
+
'</td><td>'
+
item
.
scale
+
'</td><td>'
+
item
.
scale_fee
+
'</td><td>'
+
item
.
practical_fee
+
'</td><td>'
+
item
.
content
+
'</td></tr>'
;
});
$
(
"#caozuo_table"
).
html
(
caozuo_table
);
$
(
"#caozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp
=
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
();
//获取一列的值
if
(
temp
==
'null'
)
{
$
(
"#caozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
6
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
Records
:
function
()
{
//分佣提成数据
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
show
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-default"
);
$
(
"#records"
).
addClass
(
"btn-info"
);
$
.
ajax
({
'type'
:
'GET'
,
'url'
:
'/index/payLogList'
,
data
:
{
"id"
:
business
.
house_id
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
var
caozuo_table
=
""
;
$
.
each
(
data
[
'data'
],
function
(
i
,
item
)
{
caozuo_table
+=
'<tr><td>'
+
item
.
create_time
+
'</td><td>'
+
item
.
money
+
'</td><td>'
+
item
.
type
+
'</td><td>'
+
item
.
pay_type
+
'</td><td>'
+
item
.
agent_name
+
'</td></tr>'
;
});
$
(
"#tcaozuo_table"
).
html
(
caozuo_table
);
$
(
"#tcaozuo_table tr"
).
each
(
function
(
e
)
{
//不能为空
var
temp_one
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
();
var
temp
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
();
//获取一列的值
var
temp_two
=
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
();
// 支付方式 10支付宝 20 微信 30pos机器 40转账 50现金 60其他
if
(
temp
*
1
==
10
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"支付宝"
)
}
if
(
temp
*
1
==
20
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"微信"
)
}
if
(
temp
*
1
==
30
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"pos机器"
)
}
if
(
temp
*
1
==
40
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"转账"
)
}
if
(
temp
*
1
==
50
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"现金"
)
}
if
(
temp
*
1
==
60
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
3
).
html
(
"其他"
)
}
// 付款类型 10意向金 20定金 30保管金 40押金 50 租金 60 进场费 70转让费 80其他
if
(
temp_two
*
1
==
10
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"意向金"
)
}
if
(
temp_two
*
1
==
20
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"定金"
)
}
if
(
temp_two
*
1
==
30
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"保管金"
)
}
if
(
temp_two
*
1
==
40
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"押金"
)
}
if
(
temp_two
*
1
==
50
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"租金"
)
}
if
(
temp_two
*
1
==
60
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"进场费"
)
}
if
(
temp_two
*
1
==
70
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"转让费"
)
}
if
(
temp_two
*
1
==
80
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
2
).
html
(
"其他"
)
};
if
(
temp_one
==
'null'
)
{
$
(
"#tcaozuo_table"
).
find
(
"tr"
).
eq
(
e
).
find
(
"td"
).
eq
(
4
).
html
(
" "
)
}
});
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
newCommission
:
function
()
{
//新增分佣提成
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/addBargain'
,
data
:
{
"id"
:
business
.
house_id
,
"role"
:
$
(
"#is_carefully_chosen"
).
val
(),
"scale"
:
$
(
"#commission-rate"
).
val
(),
"scale_fee"
:
$
(
"#should-commission"
).
val
(),
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
if
(
data
.
data
)
{
console
.
log
(
666
);
}
}
else
{
alert
(
'获取失败!'
);
}
}
});
},
// table切换
Information
:
function
()
{
$
(
".Tswitch"
).
eq
(
0
).
show
();
$
(
".Tswitch"
).
eq
(
1
).
hide
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-default"
);
$
(
"#information"
).
addClass
(
"btn-info"
);
$
(
"#fees"
).
removeClass
(
"btn-info"
);
$
(
"#fees"
).
addClass
(
"btn-default"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
Fees
:
function
()
{
$
(
".Tswitch"
).
eq
(
0
).
hide
();
$
(
".Tswitch"
).
eq
(
1
).
show
();
$
(
".Tswitch"
).
eq
(
2
).
hide
();
$
(
"#information"
).
removeClass
(
"btn-info"
);
$
(
"#information"
).
addClass
(
"btn-default"
);
$
(
"#fees"
).
removeClass
(
"btn-default"
);
$
(
"#fees"
).
addClass
(
"btn-info"
);
$
(
"#records"
).
removeClass
(
"btn-info"
);
$
(
"#records"
).
addClass
(
"btn-default"
);
},
getList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
params
=
{};
params
.
pageNo
=
business
.
pageNo
;
params
.
pageSize
=
business
.
pageSize
;
params
.
create_time
=
$
(
'#create_time'
)
.
val
();
params
.
end_time
=
$
(
'#end_time'
)
.
val
();
params
.
internal_address
=
$
(
'#internal_address'
).
val
();
params
.
name
=
$
(
'#user_name'
).
val
();
params
.
phone
=
$
(
'#user_phone'
).
val
();
params
.
house_number
=
$
(
'#internal_num'
).
val
();
$
.
ajax
({
url
:
'/index/getTallAgeList'
,
//获取列表
type
:
'GET'
,
async
:
true
,
data
:
params
,
dataType
:
'json'
,
success
:
function
(
data
)
{
// console.log(data);
var
temp
=
document
.
getElementById
(
'tax_list_tpl'
).
innerHTML
;
var
doTtmpl
=
doT
.
template
(
temp
);
$
(
"#business_list"
).
html
(
doTtmpl
(
data
.
data
.
list
));
$
(
"taxTotal"
).
html
(
data
.
total_tax
);
/*分页代码*/
add_page
(
data
.
data
.
total
,
pageNo
,
business
.
pageSize
,
business
.
getList
);
//总的税费
}
});
},
exportList
:
function
(
pageNo
)
{
business
.
pageNo
=
pageNo
;
var
create_time
=
$
(
'#create_time'
).
val
();
var
end_time
=
$
(
'#end_time'
).
val
();
var
internal_address
=
$
(
'#internal_address'
).
val
();
var
agent
=
$
(
'#user_name'
).
val
();
var
user_phone
=
$
(
'#user_phone'
).
val
();
var
house_number
=
$
(
'#internal_num'
).
val
();
window
.
open
(
'/index/exportExcel?create_time='
+
create_time
+
'&end_time='
+
end_time
+
'&internal_address='
+
internal_address
+
'&name='
+
agent
+
'&phone='
+
user_phone
+
'&house_number='
+
house_number
);
},
};
return
business
;
});
\ No newline at end of file
public/resource/template/commissionTotal_template_tpl.html
0 → 100644
View file @
236d1c0b
<script
id=
"commissionTotal_list_tpl"
type=
"text/template"
>
[
%
if
(
it
)
{
%
]
[
%
for
(
var
item
in
it
){
%
]
<
tr
class
=
"text-center"
>
<
td
>
[
%=
it
[
item
][
'create_time'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'district_store'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'agent'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'internal_address'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'house_number'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'scale_fee'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'practical_fee'
]
%
]
<
/td
>
<
td
>
<
a
class
=
"btn1 btn-info edit"
href
=
"#modal-details"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
详情
<
/a
>
<
a
class
=
"btn1 btn-info timeline"
href
=
"#modal-linetime"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
时间轴
<
/a
>
<
/td
>
<
/tr
>
[
%
}
%
]
[
%
}
else
{
%
]
<
tr
>
<
td
colspan
=
"8"
style
=
"text-align:center;"
>
暂无数据
<
/td
>
<
/tr
>
[
%
}
%
]
</script>
public/resource/template/
statement
_template_tpl.html
→
public/resource/template/
commission
_template_tpl.html
View file @
236d1c0b
<script
id=
"
statement
_list_tpl"
type=
"text/template"
>
<script
id=
"
commission
_list_tpl"
type=
"text/template"
>
[
%
if
(
it
)
{
%
]
[
%
for
(
var
item
in
it
){
%
]
<
tr
class
=
"text-center"
>
...
...
public/resource/template/tax_template_tpl.html
0 → 100644
View file @
236d1c0b
<script
id=
"tax_list_tpl"
type=
"text/template"
>
[
%
if
(
it
)
{
%
]
[
%
for
(
var
item
in
it
){
%
]
<
tr
class
=
"text-center"
>
<
td
>
[
%=
it
[
item
][
'create_time'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'district_store'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'name'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'internal_address'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'house_number'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'fee'
]
%
]
<
/td
>
<
td
>
<
a
class
=
"btn1 btn-info edit"
href
=
"#modal-details"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
详情
<
/a
>
<
a
class
=
"btn1 btn-info timeline"
href
=
"#modal-linetime"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
时间轴
<
/a
>
<
/td
>
<
/tr
>
[
%
}
%
]
[
%
}
else
{
%
]
<
tr
>
<
td
colspan
=
"8"
style
=
"text-align:center;"
>
暂无数据
<
/td
>
<
/tr
>
[
%
}
%
]
</script>
<!--id int 编号
create_time string 提交时间
name int 姓名
phone string 手机号
house_number string 商铺号
internal_address string 商铺地址
house_number string 商铺号
agent_id int 经纪人id
district_store string 所属部门/门店-->
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment