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
b4fdadcc
Commit
b4fdadcc
authored
Jul 19, 2019
by
agping
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
费用报销
parent
90089687
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
350 additions
and
200 deletions
+350
-200
costCheck.html
application/index/view/cost/costCheck.html
+52
-20
costCheck.js
public/resource/js/costCheck.js
+193
-153
public.js
public/resource/js/public.js
+62
-0
cost_check_template_tpl.html
public/resource/template/cost_check_template_tpl.html
+43
-27
No files found.
application/index/view/cost/costCheck.html
View file @
b4fdadcc
{layout name="global/frame_two_tpl" /}
<input
type=
"hidden"
class=
"page-load"
id=
"costCheck"
/>
<style>
.user-ul2
{
width
:
100%
;
height
:
auto
;
padding-bottom
:
15px
;
float
:
left
;
}
.user-ul2
li
{
list-style
:
none
;
line-height
:
30px
;
}
.user-ul
{
float
:
right
;
text-align
:
center
;
position
:
relative
;
overflow-y
:
scroll
;
height
:
100px
;
left
:
0px
;
width
:
100%
;
line-height
:
30px
;
}
.user-ul
li
{
list-style
:
none
;
line-height
:
20px
;
}
ul
{
-webkit-padding-start
:
0px
!important
;
}
.margain-10
{
margin-bottom
:
10px
;
}
...
...
@@ -76,12 +108,12 @@
<a
href=
"javascript:;"
>
费用报销审核
</a>
</li>
<div
class=
"btn-group"
>
<button
type=
"button"
class=
"choose_btn btn btn-info
"
data-value=
"
1"
style=
"margin-left: 20px;"
>
总监通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
"
data-value=
"3
"
>
财务一审通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
"
data-value=
"2
"
>
财务二审通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
"
data-value=
"
4"
>
财务三审通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
"
data-value=
"5
"
>
未审核
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
"
data-value=
"-1
"
>
全部
</button>
<button
type=
"button"
class=
"choose_btn btn btn-info
choose_btn1"
data-value=
"/index/getCostListTwo/
1"
style=
"margin-left: 20px;"
>
总监通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
choose_btn2"
data-value=
"/index/getCostListThree/2
"
>
财务一审通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
choose_btn3"
data-value=
"/index/getCostListFour/3
"
>
财务二审通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
choose_btn4"
data-value=
"/index/getCostListFive/
4"
>
财务三审通过
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
choose_btn5"
data-value=
"/index/getCostListOne/0
"
>
未审核
</button>
<button
type=
"button"
class=
"choose_btn btn btn-default
choose_btn6"
data-value=
"/index/getCostList
"
>
全部
</button>
</div>
<div
class=
"pull-right"
>
<ul
class=
"bread_btn"
>
...
...
@@ -100,21 +132,21 @@
<td
colspan=
"15"
>
<form
id=
"form_search"
>
<span
class=
"fore-span ld-Marheight"
>
计入月份:
</span>
<input
id=
"co
mit_time_start
"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"请选择"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM',
maxDate:'#F{ $dp.$D(\'comit_time_end\')||\'%y-%M-%d\'}',
readOnly:'readonly' })"
>
<input
id=
"co
unt_time
"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"请选择"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM',readOnly:'readonly' })"
>
<span
class=
"fore-span ld-Marheight"
>
申请提交时间:
</span>
<input
id=
"c
omit
_time_start"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"开始时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',maxDate:'#F{ $dp.$D(\'c
omit
_time_end\')||\'%y-%M-%d\'}',readOnly:'readonly' })"
>
<input
id=
"c
reate
_time_start"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"开始时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',maxDate:'#F{ $dp.$D(\'c
reate
_time_end\')||\'%y-%M-%d\'}',readOnly:'readonly' })"
>
<span
class=
"fore-span ld-Marheight"
>
-
</span>
<input
id=
"c
omit
_time_end"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"结束时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',minDate:'#F{ $dp.$D(\'c
omit
_time_start\' )}',maxDate:'%y-%M-%d',readOnly:'readOnly'})"
>
<input
id=
"c
reate
_time_end"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"结束时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',minDate:'#F{ $dp.$D(\'c
reate
_time_start\' )}',maxDate:'%y-%M-%d',readOnly:'readOnly'})"
>
<span
class=
"fore-span ld-Marheight"
>
财务三审通过时间:
</span>
<input
id=
"
into
_time_start"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"开始时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',maxDate:'#F{ $dp.$D(\'
into
_time_end\')||\'%y-%M-%d\'}',readOnly:'readonly'})"
>
<input
id=
"
pass
_time_start"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"开始时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',maxDate:'#F{ $dp.$D(\'
pass
_time_end\')||\'%y-%M-%d\'}',readOnly:'readonly'})"
>
<span
class=
"fore-span ld-Marheight"
>
-
</span>
<input
id=
"
into
_time_end"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"结束时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',minDate:'#F{ $dp.$D(\'
into
_time_start\')}',maxDate:'%y-%M-%d',readOnly:'readonly'})"
>
<select
class=
"form-control btn2 ld-Marheight"
id=
"c
hanged
_type"
>
<input
id=
"
pass
_time_end"
class=
"form-control btn4 ld-Marheight"
type=
"text"
placeholder=
"结束时间"
onClick=
"WdatePicker({el:this,dateFmt:'yyyy-MM-dd',minDate:'#F{ $dp.$D(\'
pass
_time_start\')}',maxDate:'%y-%M-%d',readOnly:'readonly'})"
>
<select
class=
"form-control btn2 ld-Marheight"
id=
"c
ost
_type"
>
<option
value=
""
>
费用类型
</option>
<option
value=
"0"
>
退意向金
</option>
<option
value=
"1"
>
意向金转定
</option>
...
...
@@ -123,7 +155,7 @@
<option
value=
"4"
>
退中介费
</option>
<option
value=
"5"
>
退案场费
</option>
</select>
<select
class=
"form-control btn2 ld-Marheight"
id=
"
changed_type
"
>
<select
class=
"form-control btn2 ld-Marheight"
id=
"
fee_item
"
>
<option
value=
""
>
费用项目
</option>
<option
value=
"0"
>
退意向金
</option>
<option
value=
"1"
>
意向金转定
</option>
...
...
@@ -132,8 +164,8 @@
<option
value=
"4"
>
退中介费
</option>
<option
value=
"5"
>
退案场费
</option>
</select>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"
changed_id
"
placeholder=
"费用用途"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"
back_id_money
"
placeholder=
"费用报销ID"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"
purpose
"
placeholder=
"费用用途"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"
cost_id
"
placeholder=
"费用报销ID"
type=
"text"
value=
""
>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"comit_name"
placeholder=
"提交人姓名"
type=
"text"
value=
""
>
<ul
class=
"user-ul"
style=
"display:none"
></ul>
<select
class=
"form-control btn2 ld-Marheight"
id=
"commit_home"
>
...
...
public/resource/js/costCheck.js
View file @
b4fdadcc
...
...
@@ -5,26 +5,60 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
pageSize
:
10
,
/*每页显示多少条*/
id
:
''
,
house_id
:
''
,
house_fatherid
:
''
,
collection_del_id
:
''
,
listData
:
""
,
moneyTotal
:
""
,
agent_id_phone
:
''
,
check_status
:
1
,
deleteRefundId
:
''
,
url
:
''
,
agent_id_phone
:
''
,
init
:
function
()
{
//初始化dot
$
(
document
.
body
).
append
(
template
);
//判断权限 总监
if
(
check_auth
(
'index/getCostListTwo/1'
)){
$
(
'.choose_btn1'
).
show
();
}
else
{
$
(
'.choose_btn1'
).
hide
();
};
//判断权限 财务一级
if
(
check_auth
(
'index/getCostListThree/2'
)){
$
(
'.choose_btn2'
).
show
();
}
else
{
$
(
'.choose_btn2'
).
hide
();
};
//判断权限 财务二级
if
(
check_auth
(
'index/getCostListFour/3'
)){
$
(
'.choose_btn3'
).
show
();
}
else
{
$
(
'.choose_btn3'
).
hide
();
};
//判断权限 财务三级
if
(
check_auth
(
'index/getCostListFive/4'
)){
$
(
'.choose_btn4'
).
show
();
}
else
{
$
(
'.choose_btn4'
).
hide
();
};
//判断权限 未审核
if
(
check_auth
(
'index/getCostListOne/0'
)){
$
(
'.choose_btn5'
).
show
();
}
else
{
$
(
'.choose_btn5'
).
hide
();
};
//判断权限 全部
if
(
check_auth
(
'index/getCostList'
)){
$
(
'.choose_btn6'
).
show
();
}
else
{
$
(
'.choose_btn6'
).
hide
();
};
cost
.
url
=
$
(
'.btn-group .choose_btn:nth-of-type(1)'
).
attr
(
'data-value'
);
cost
.
getList
(
1
);
cost
.
event
();
},
event
:
function
()
{
var
that
=
cost
;
var
_doc
=
$
(
document
);
//初始化
$
(
'.pic-con2'
).
show
();
$
(
'.pic-con1'
).
hide
();
//点击不同审核按钮
_doc
.
on
(
'click'
,
'.choose_btn'
,
function
(
e
){
$
(
this
).
removeClass
(
'btn-default'
).
addClass
(
'btn-info'
).
siblings
().
removeClass
(
'btn-info'
).
addClass
(
'btn-default'
);
refund
.
url
=
e
.
target
.
dataset
.
value
;
refund
.
getList
(
1
);
});
//搜索
$
(
document
).
on
(
'click'
,
'#search'
,
function
(
e
){
that
.
getList
(
1
);
...
...
@@ -38,41 +72,37 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
$
(
document
).
on
(
'click'
,
'#export'
,
function
(
e
){
that
.
exportExcel
();
});
//新增报销 上传图片
$
(
'#file_input_pic'
).
on
(
'change'
,
function
(){
//二级联动
that
.
getDistrict
(
function
()
{
_doc
.
on
(
'input'
,
'#commit_home'
,
function
()
{
var
_this
=
$
(
this
);
var
formData
=
new
FormData
();
formData
.
append
(
'type'
,
'chat'
);
formData
.
append
(
'image'
,
_this
[
0
].
files
[
0
]);
$
.
ajax
({
type
:
'post'
,
url
:
ServerHostImageLiu
+
'/index/uploadImg'
,
data
:
formData
,
dataType
:
'json'
,
contentType
:
false
,
cache
:
false
,
processData
:
false
,
beforeSend
:
function
()
{},
success
:
function
(
_data
)
{
if
(
_data
.
code
==
200
)
{
$
(
'#container_body_img_area'
).
append
(
'<div class="result"><img data-imgname="{0}" src="{1}" alt=""/> <span class="span-del">删除</span></div>'
.
stringFormatObj
({
'0'
:
_data
.
data
.
img_path
,
'1'
:
_data
.
data
.
internet_img_name
?
urlDeal
(
_data
.
data
.
internet_img_name
):
_data
.
data
.
internet_img_name
}));
var
_id
=
$
(
'#commit_home'
).
val
();
$
(
'#commit_shop'
).
html
(
''
);
//先清空
if
(
_id
&&
_id
!=
'0'
)
{
that
.
getDistrictStoreList
(
_id
,
function
(
_data
)
{
var
_str
=
'<option value="0">全部</option>'
;
$
.
each
(
_data
,
function
(
i
,
item
)
{
_str
+=
'<option value="'
+
item
.
id
+
'">'
+
item
.
store_name
+
'</option>'
;
});
$
(
'#commit_shop'
).
append
(
_str
)
});
}
else
{};
});
});
//点击li 列表消失
$
(
document
).
delegate
(
".addphone"
,
"click"
,
function
()
{
//list消失新增客户 点击li事件 获取id ul消失
that
.
addphone
(
this
);
});
//分佣方 姓名下拉式
$
(
document
).
on
(
"input"
,
"#comit_name"
,
function
()
{
//手机号新增搜索客方
if
(
$
(
"#comit_name"
).
val
()
==
''
)
{
that
.
agent_id_phone
=
''
;
$
(
".user-ul"
).
html
(
''
);
}
else
{
alert
(
_data
.
msg
);
};
},
error
:
function
()
{
alert
(
'enter error'
);
},
complete
:
function
(
xhr
,
textStatus
)
{
if
(
textStatus
===
'timeout'
)
{
//处理超时的逻辑
alert
(
'请求超时,请重试'
);
};
that
.
search_person
();
}
});
});
//新增报销 上传图片
$
(
'#file_input_pic2'
).
on
(
'change'
,
function
(){
...
...
@@ -110,46 +140,42 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
}
});
});
$
(
'.tit_con'
).
unbind
(
'click'
).
bind
(
'click'
,
function
(
e
){
$
(
this
).
parent
(
'div'
).
find
(
'h4.active'
).
removeClass
(
"active"
);
$
(
this
).
addClass
(
"active"
);
if
(
e
.
currentTarget
.
innerHTML
==
"费用图片"
){
$
(
'.pic-con1'
).
show
();
$
(
'.pic-con2'
).
hide
();
}
else
{
$
(
'.pic-con2'
).
show
();
$
(
'.pic-con1'
).
hide
();
}
});
$
(
document
).
on
(
'click'
,
'.add-pic'
,
function
(
e
){
var
id
=
e
.
target
.
dataset
.
id
;
$
(
".publicCostDetails"
).
attr
(
'src'
,
'/index/publicCostDetails'
)
});
_doc
.
on
(
'click'
,
'.choose_btn'
,
function
(
e
){
var
befor
=
that
.
check_status
$
(
this
).
removeClass
(
'btn-default'
).
addClass
(
'btn-info'
).
siblings
().
removeClass
(
'btn-info'
).
addClass
(
'btn-default'
);
if
(
befor
!=
e
.
target
.
dataset
.
value
)
{
that
.
check_status
=
e
.
target
.
dataset
.
value
;
cost
.
getList
(
1
);
}
})
},
//删除退款
deleteRefund
:
function
(
id
)
{
search_person
:
function
()
{
//手机号新增客户
$
.
ajax
({
url
:
'/index/
delRefund
'
,
type
:
'
POS
T'
,
url
:
'/index/
getBroker_new
'
,
type
:
'
GE
T'
,
async
:
true
,
data
:
{
"refund_id"
:
id
"phone"
:
$
(
"#comit_name"
).
val
(),
'all'
:
1
},
dataType
:
'json'
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
cost
.
getList
(
cost
.
pageNo
);
alert
(
data
.
msg
);
var
user_ul
=
""
;
$
.
each
(
data
.
data
,
function
(
i
,
item
)
{
if
(
item
.
status
==
0
||
item
.
status
==
4
){
var
status
=
' '
;
};
if
(
item
.
status
==
1
){
var
status
=
'-长假'
;
};
if
(
item
.
status
==
2
){
var
status
=
'-离职'
;
};
if
(
item
.
status
==
3
){
var
status
=
'-转勤'
;
}
user_ul
+=
'<li class="addphone" data-id="'
+
item
.
id
+
'">'
+
item
.
id
+
'-'
+
item
.
name
+
'-'
+
item
.
phone
+
status
+
'</li>'
;
});
$
(
".user-ul"
).
html
(
user_ul
);
$
(
".user-ul"
).
show
();
}
else
{
alert
(
data
.
msg
);
}
...
...
@@ -157,6 +183,58 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
}
});
},
//将li里的值 赋给input(分佣方姓名)
addphone
:
function
(
obj
)
{
//新增客户 input赋值
var
that
=
cost
;
var
user_ht
=
$
(
obj
).
html
()
+
''
;
var
user_ht_str
=
user_ht
.
substring
(
0
,
user_ht
.
length
-
3
);
$
(
"#comit_name"
).
val
(
user_ht_str
);
$
(
".user-ul"
).
html
(
''
);
$
(
".user-ul"
).
hide
();
that
.
agent_id_phone
=
$
(
obj
).
attr
(
"data-id"
);
},
getDistrict
:
function
(
fn
)
{
$
.
ajax
({
url
:
'/index/getDistrict'
,
type
:
'GET'
,
async
:
true
,
data
:
{
"pageSize"
:
1000
},
dataType
:
'json'
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
&&
data
.
data
!=
null
)
{
var
str
=
''
;
$
.
each
(
data
.
data
,
function
(
i
,
item
)
{
str
+=
'<option value="'
+
item
.
id
+
'">'
+
item
.
district_name
+
'</option>'
;
});
$
(
'#commit_home'
).
append
(
str
);
fn
&&
fn
();
}
else
{
alert
(
data
.
msg
)
}
}
});
},
getDistrictStoreList
:
function
(
id
,
fn
)
{
$
.
ajax
({
url
:
'/index/getDistrictStoreList'
,
type
:
'GET'
,
async
:
true
,
data
:
{
'id'
:
id
,
"pageSize"
:
1000
},
dataType
:
'json'
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
&&
data
.
data
!=
null
)
{
fn
&&
fn
(
data
.
data
);
}
else
{
alert
(
data
.
msg
)
}
}
});
},
//获取列表
getList
:
function
(
no
){
var
that
=
cost
;
...
...
@@ -164,14 +242,13 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
var
params
=
that
.
buildSearchParams
(
0
);
params
.
pageNo
=
that
.
pageNo
;
params
.
pageSize
=
that
.
pageSize
;
$
.
get
(
'/index/refundList'
,
params
,
function
(
data
){
$
.
get
(
cost
.
url
,
params
,
function
(
data
){
if
(
typeof
data
===
'object'
)
{
if
(
data
.
code
==
200
)
{
that
.
listData
=
data
.
data
.
list
;
var
temp
=
document
.
getElementById
(
'cost_check_template_tpl'
).
innerHTML
;
var
doTtmpl
=
doT
.
template
(
temp
);
$
(
"#order_list"
).
html
(
doTtmpl
(
data
.
data
.
list
));
$
(
'#money_total'
).
text
((
data
.
data
.
total_money
-
0
>
0
)
?
(
data
.
data
.
total_money
+
"元"
):
"0元"
)
/*分页代码*/
add_page
(
data
.
data
.
total
,
no
,
that
.
pageSize
,
that
.
getList
);
...
...
@@ -189,28 +266,24 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
*/
resetAll
:
function
(){
var
that
=
cost
;
$
(
'#comit_time_start'
).
val
(
""
);
$
(
'#comit_time_end'
).
val
(
""
);
$
(
'#into_time_start'
).
val
(
""
);
$
(
'#into_time_end'
).
val
(
""
);
$
(
'#changed_type'
).
val
(
""
);
$
(
'#changed_id'
).
val
(
""
);
$
(
'#back_id'
).
val
(
""
);
$
(
'#get_id'
).
val
(
""
);
$
(
'#shoped_id'
).
val
(
""
);
$
(
'#shoped_addr'
).
val
(
""
);
$
(
'#count_time'
).
val
(
""
);
$
(
'#create_time_start'
).
val
(
""
);
$
(
'#create_time_end'
).
val
(
""
);
$
(
'#pass_time_start'
).
val
(
""
);
$
(
'#pass_time_end'
).
val
(
""
);
$
(
'#cost_type'
).
val
(
""
);
$
(
'#fee_item'
).
val
(
""
);
$
(
'#purpose'
).
val
(
""
);
$
(
'#cost_id'
).
val
(
""
);
$
(
'#commit_home'
).
val
(
""
);
$
(
'#commit_shop'
).
val
(
""
);
$
(
'#comit_name'
).
val
(
""
);
$
(
'#comit_phone'
).
val
(
""
);
$
(
'#is_type'
).
val
(
""
);
$
(
'#is_open'
).
val
(
"-1"
);
$
(
'#back_id_money'
).
val
(
""
);
that
.
agent_id_phone
=
""
;
},
//
退款 审核
//
费用报销 导出
exportExcel
:
function
()
{
var
_url
=
'/index/costListExcel?'
;
window
.
open
(
_url
+
cost
.
buildSearchParams
(
1
));
...
...
@@ -220,64 +293,51 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
*/
buildSearchParams
:
function
(
is_excel
){
var
that
=
cost
;
var
co
mmite_time_start
=
$
(
'#comit_time_start
'
).
val
();
var
c
ommite_time_end
=
$
(
'#comit_time_end
'
).
val
();
var
into_time_start
=
$
(
'#into_time_start
'
).
val
();
var
into_time_end
=
$
(
'#into_time_end
'
).
val
();
var
changed_type
=
$
(
'#changed_type
'
).
val
();
var
c
hanged_id
=
$
(
'#changed_id
'
).
val
();
var
back_id_money
=
$
(
'#back_id_money
'
).
val
();
var
shoped_id
=
$
(
'#shoped_id
'
).
val
();
var
shoped_addr
=
$
(
'#shoped_addr
'
).
val
();
var
co
unt_time
=
$
(
'#count_time
'
).
val
();
var
c
reate_time_start
=
$
(
'#create_time_start
'
).
val
();
var
create_time_end
=
$
(
'#create_time_end
'
).
val
();
var
pass_time_start
=
$
(
'#pass_time_start
'
).
val
();
var
pass_time_end
=
$
(
'#pass_time_end
'
).
val
();
var
c
ost_type
=
$
(
'#cost_type
'
).
val
();
var
fee_item
=
$
(
'#fee_item
'
).
val
();
var
purpose
=
$
(
'#purpose
'
).
val
();
var
cost_id
=
$
(
'#cost_id
'
).
val
();
var
commit_home
=
$
(
'#commit_home'
).
val
();
var
commit_shop
=
$
(
'#commit_shop'
).
val
();
var
comit_name
=
that
.
agent_id_phone
;
//$('#comit_name').val();
var
comit_phone
=
$
(
'#comit_phone'
).
val
();
// var choose_type = $('.btn-group').find('.btn-info').html();
var
is_selt
=
$
(
'#is_type'
).
val
();
var
get_id
=
$
(
'#get_id'
).
val
();
var
is_open
=
$
(
'#is_open'
).
val
();
var
params
=
{};
var
paramsStr
=
""
;
if
(
get_id
)
{
params
.
pay_log_id
=
get_id
;
paramsStr
+=
"
pay_log_id="
+
get_id
+
'&'
;
if
(
create_time_start
)
{
params
.
create_time_start
=
create_time_start
;
paramsStr
+=
"
create_time_start="
+
create_time_start
+
'&'
;
}
if
(
c
ommite_time_start
)
{
params
.
start_time
=
commite_time_start
;
paramsStr
+=
"
start_time="
+
commite_time_start
+
'&'
;
if
(
c
reate_time_end
)
{
params
.
create_time_end
=
create_time_end
;
paramsStr
+=
"
create_time_end="
+
create_time_end
+
'&'
;
}
if
(
commite_time_end
)
{
params
.
end_time
=
commite_time_end
;
paramsStr
+=
"
end_time="
+
commite_time_end
+
'&'
;
if
(
pass_time_start
)
{
params
.
pass_time_start
=
pass_time_start
;
paramsStr
+=
"
pass_time_start="
+
pass_time_start
+
'&'
;
}
if
(
into_time_start
)
{
params
.
income_start_time
=
into_time_start
;
paramsStr
+=
"
income_start_time="
+
into_time_start
+
'&'
;
if
(
pass_time_end
)
{
params
.
pass_time_end
=
pass_time_end
;
paramsStr
+=
"
pass_time_end="
+
pass_time_end
+
'&'
;
}
if
(
into_time_end
)
{
params
.
income_end_time
=
into_time_end
;
paramsStr
+=
"
income_end_time="
+
into_time_end
+
'&'
;
if
(
cost_type
)
{
params
.
type
=
cost_type
;
paramsStr
+=
"
type="
+
cost_type
+
'&'
;
}
if
(
c
hanged_type
)
{
params
.
type
=
changed_type
;
paramsStr
+=
"
type="
+
changed_type
+
'&'
;
if
(
c
ost_id
)
{
params
.
id
=
cost_id
;
paramsStr
+=
"
id="
+
cost_id
+
'&'
;
}
if
(
changed_id
)
{
params
.
order_id
=
changed_id
;
paramsStr
+=
"
order_id="
+
changed_id
+
'&'
;
if
(
purpose
)
{
params
.
purpose
=
purpose
;
paramsStr
+=
"
purpose="
+
purpose
+
'&'
;
}
if
(
back_id_money
)
{
params
.
id
=
back_id_money
;
paramsStr
+=
"id="
+
back_id_money
+
'&'
;
}
if
(
shoped_id
)
{
params
.
house_id
=
shoped_id
;
paramsStr
+=
"house_id="
+
shoped_id
+
'&'
;
}
if
(
shoped_addr
)
{
params
.
address
=
shoped_addr
;
paramsStr
+=
"address="
+
shoped_addr
+
'&'
;
if
(
fee_item
)
{
params
.
fee_item
=
fee_item
;
paramsStr
+=
"fee_item="
+
fee_item
+
'&'
;
}
if
(
commit_home
)
{
params
.
district_id
=
commit_home
;
...
...
@@ -291,26 +351,6 @@ define(['doT', 'text!temp/cost_check_template_tpl.html', 'css!style/home.css', '
params
.
agent_id
=
comit_name
;
paramsStr
+=
"agent_id="
+
comit_name
+
'&'
;
}
if
(
comit_phone
)
{
if
(
comit_phone
[
0
]
==
"1"
&&
comit_phone
.
length
==
11
)
{
params
.
phone
=
comit_phone
;
paramsStr
+=
"phone="
+
comit_phone
+
'&'
;
}
else
{
alert
(
"请输入正确的手机号码"
)
}
}
if
(
is_selt
){
params
.
is_self
=
is_selt
;
paramsStr
+=
"is_self="
+
is_selt
+
'&'
;
}
if
(
is_open
>
-
1
)
{
params
.
is_open
=
is_open
;
paramsStr
+=
"is_open="
+
is_open
+
'&'
;
}
params
.
status
=
that
.
check_status
;
paramsStr
+=
"status="
+
that
.
check_status
;
if
(
is_excel
)
{
return
paramsStr
;
}
else
{
...
...
public/resource/js/public.js
View file @
b4fdadcc
...
...
@@ -332,6 +332,68 @@ function switchRzType(str){
return
'暂无数据'
;
}
};
function
switchFeeItem
(
str
){
//费用项目 100房租租金 101水电费 102其他费用 201总部固定成本 301分部固定成本 401同联发展基金 501家庭基金报销 502社保报销 503总经理基薪 504区域秘书基薪 505招聘成本 506区域经理基本工资平摊 507宿舍成本 508宿舍亏损 509手续费 510员工工资成本 511网络报销 512离职员工网络 513门店独有成本其他费用
switch
(
String
(
str
)){
case
'100'
:
return
'房租租金'
;
case
'101'
:
return
'水电费'
;
case
'102'
:
return
'其他费用'
;
case
'201'
:
return
'总部固定成本'
;
case
'301'
:
return
'分部固定成本'
;
case
'401'
:
return
'同联发展基金'
;
case
'501'
:
return
'家庭基金报销'
;
case
'80'
:
return
'502社保报销'
;
case
'503'
:
return
'总经理基薪'
;
case
'504'
:
return
'区域秘书基薪'
;
case
'505'
:
return
'招聘成本'
;
case
'506'
:
return
'区域经理基本工资平摊'
;
case
'507'
:
return
'宿舍成本'
;
case
'508'
:
return
'宿舍亏损'
;
case
'509'
:
return
'手续费'
;
case
'510'
:
return
'员工工资成本'
;
case
'511'
:
return
'网络报销'
;
case
'512'
:
return
'512离职员工网络'
;
case
'513'
:
return
'513门店独有成本其他费用'
;
default
:
return
'暂无数据'
;
}
};
function
switchFeeSiteId
(
str
){
//费用项目 100房租租金 101水电费 102其他费用 201总部固定成本 301分部固定成本 401同联发展基金 501家庭基金报销 502社保报销 503总经理基薪 504区域秘书基薪 505招聘成本 506区域经理基本工资平摊 507宿舍成本 508宿舍亏损 509手续费 510员工工资成本 511网络报销 512离职员工网络 513门店独有成本其他费用
switch
(
String
(
str
)){
case
'10001'
:
return
'上海市'
;
case
'10002'
:
return
'杭州市'
;
case
'10003'
:
return
'深圳市'
;
case
'10004'
:
return
'广州市'
;
case
'10005'
:
return
'北京市'
;
default
:
return
'暂无数据'
;
}
};
/**
* 如果提示框存在任何问题,可以通过注释alert这个方法,使提示框恢复到之前的默认效果
* 自定义提示框修改
...
...
public/resource/template/cost_check_template_tpl.html
View file @
b4fdadcc
<script
id=
"cost_check_template_tpl"
type=
"text/template"
>
[
%
if
(
it
)
{
%
]
[
%
for
(
var
item
in
it
){
%
]
<
tr
class
=
"text-center"
>
<
td
>
[
%=
it
[
item
][
'create_time'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'id'
]
%
]
<
/td
>
[
%
if
(
it
[
item
][
'status'
]
==
0
)
{
%
]
<
td
>
审核中
<
/td
>
[
%
}
else
if
(
it
[
item
][
'status'
]
==
1
)
{
%
]
<
td
>
审核中
<
/td
>
<
td
>
[
%=
it
[
item
][
'count_time'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'create_time'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'agent_name'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'total_fee'
]
%
]
<
/td
>
[
%
if
(
it
[
item
][
'type'
]
==
1
)
{
%
]
<
td
>
总部成本
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
2
)
{
%
]
<
td
>
分部成本
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
3
)
{
%
]
<
td
>
门店独有成本
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
0
)
{
%
]
<
td
>
办公室成本
<
/td
>
[
%
}
else
{
%
]
<
td
>--<
/td
>
[
%
}
%
]
[
%
if
(
it
[
item
][
'type'
]
==
2
)
{
%
]
<
td
>
[
%=
switchFeeSiteId
(
it
[
item
][
'site_id'
])
%
]
<
/td
>
[
%
}
else
{
%
]
<
td
>
[
%=
switchFeeItem
(
it
[
item
][
'fee_item'
])
%
]
<
/td
>
[
%
}
%
]
<
td
>
[
%=
it
[
item
][
'purpose'
]
%
]
<
/td
>
[
%
if
(
it
[
item
][
'status'
]
==
1
)
{
%
]
<
td
>
总监通过
<
/td
>
[
%
}
else
if
(
it
[
item
][
'status'
]
==
2
)
{
%
]
<
td
>
退款成功
<
/td
>
<
td
>
一审通过
<
/td
>
[
%
}
else
if
(
it
[
item
][
'status'
]
==
3
)
{
%
]
<
td
>
已审核
<
/td
>
<
td
>
二审通过
<
/td
>
[
%
}
else
if
(
it
[
item
][
'status'
]
==
4
)
{
%
]
<
td
>
驳回
<
/td
>
<
td
>
三审通过
<
/td
>
[
%
}
else
if
(
it
[
item
][
'status'
]
==
0
)
{
%
]
<
td
>
申请中
<
/td
>
[
%
}
else
{
%
]
<
td
>--<
/td
>
[
%
}
%
]
<
td
>
[
%=
it
[
item
][
'order_id'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'pay_log_id'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'refund_money'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'income_time'
]
%
]
<
/td
>
<!--<
td
>
[
%=
it
[
item
][
'type'
]
%
]
<
/td>--
>
[
%
if
(
it
[
item
][
'type'
]
==
1
)
{
%
]
<
td
>
意向金转定
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
2
)
{
%
]
<
td
>
退保管金
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
3
)
{
%
]
<
td
>
保管金转定
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
4
)
{
%
]
<
td
>
退中介费
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
5
)
{
%
]
<
td
>
退案场费
<
/td
>
[
%
}
else
if
(
it
[
item
][
'type'
]
==
0
)
{
%
]
<
td
>
退意向金
<
/td
>
[
%
if
(
it
[
item
][
'source'
]
==
1
)
{
%
]
<
td
>
excel
导入
<
/td
>
[
%
}
else
if
(
it
[
item
][
'source'
]
==
2
)
{
%
]
<
td
><
/td
>
[
%
}
else
if
(
it
[
item
][
'source'
]
==
3
)
{
%
]
<
td
><
/td
>
[
%
}
else
if
(
it
[
item
][
'source'
]
==
0
)
{
%
]
<
td
>
app
申请
<
/td
>
[
%
}
else
{
%
]
<
td
>--<
/td
>
[
%
}
%
]
<
td
>
[
%=
it
[
item
][
'agent_name'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'store_name'
]
%
]
<
/td
>
<
td
>
<
a
class
=
"btn1 btn-success add-pic"
href
=
"#modal-addPic"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
审核
<
/a
>
<
a
class
=
"btn1 btn-success is_del"
href
=
"#modal-del"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
删除
<
/a
>
...
...
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