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
429044ff
Commit
429044ff
authored
Sep 28, 2018
by
agping
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
后台 日报 周报修改
parent
67a2193a
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
913 additions
and
10 deletions
+913
-10
DayAchievementsReport.php
application/index/controller/DayAchievementsReport.php
+23
-0
WeekAchievementsReport.php
application/index/controller/WeekAchievementsReport.php
+23
-0
day-achievements-report.html
...dex/view/achievements_report/day-achievements-report.html
+151
-0
week-achievements-report.html
...ex/view/achievements_report/week-achievements-report.html
+155
-0
route.php
application/route.php
+3
-10
dayAchievementsReport.js
public/resource/js/dayAchievementsReport.js
+251
-0
weekAchievementsReport.js
public/resource/js/weekAchievementsReport.js
+256
-0
day_achievements_report_template_tpl.html
...source/template/day_achievements_report_template_tpl.html
+25
-0
week_achievements_report_template_tpl.html
...ource/template/week_achievements_report_template_tpl.html
+26
-0
No files found.
application/index/controller/DayAchievementsReport.php
0 → 100644
View file @
429044ff
<?php
namespace
app\index\controller
;
/**
* Created by PhpStorm.
* User: liu yin ping
* Date: 2018/8/7
* Time: 15:48
*/
use
app\index\extend\Basic
;
class
DayAchievementsReport
extends
Basic
{
public
function
dayAchievementsReportList
()
{
if
(
!
$this
->
request
->
isAjax
())
{
return
view
(
'achievements_report/day-achievements-report'
);
//执行view方法 找view文件件夹下 相对应的html文件
}
}
}
\ No newline at end of file
application/index/controller/WeekAchievementsReport.php
0 → 100644
View file @
429044ff
<?php
namespace
app\index\controller
;
/**
* Created by PhpStorm.
* User: liu yin ping
* Date: 2018/8/7
* Time: 15:48
*/
use
app\index\extend\Basic
;
class
WeekAchievementsReport
extends
Basic
{
public
function
weekAchievementsReportList
()
{
if
(
!
$this
->
request
->
isAjax
())
{
return
view
(
'achievements_report/week-achievements-report'
);
}
}
}
\ No newline at end of file
application/index/view/achievements_report/day-achievements-report.html
0 → 100644
View file @
429044ff
{layout name="global/frame_tpl" /}
<input
type=
"hidden"
class=
"page-load"
id=
"dayAchievementsReport"
/>
<style>
.modal-body
{
/*height: 600px;*/
overflow-y
:
auto
;
padding-bottom
:
60px
;
}
.user-ul2
{
width
:
100%
;
height
:
auto
;
padding-bottom
:
15px
;
float
:
left
;
}
.user-ul2
li
{
list-style
:
none
;
line-height
:
30px
;
}
.money_total_two
{
font-weight
:
bold
;
font-size
:
15px
;
}
#search
{
float
:
left
;
}
#reset
{
float
:
left
;
}
.del-font
{
font-size
:
16px
;
font-weight
:
600
;
}
</style>
<div
id=
"page-content-wrapper"
>
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
""
>
<div
class=
"panel panel-default"
>
<div
class=
"panel-heading breadcrumb"
>
<li>
<a
href=
"javascript:;"
>
业绩日报
</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=
"10"
>
<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_start"
name=
"start_date1"
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=
"create_time_end"
name=
"end_date1"
type=
"date"
>
<select
class=
"form-control btn4 ld-Marheight input"
name=
""
id=
"district_id"
>
<option
value=
""
>
选择部门
</option>
</select>
<select
class=
"form-control btn4 ld-Marheight input"
name=
""
id=
"guest_stores"
value=
""
>
</select>
<input
class=
"form-control btn2 ld-Marheight"
data-rule-phoneus=
"false"
data-rule-required=
"false"
id=
"report_agent_name"
placeholder=
"选择经纪人"
type=
"text"
value=
""
>
<select
class=
"form-control btn2 ld-Marheight"
id=
"shop_type"
>
<option
value=
""
>
日报类型
</option>
<option
value=
"0"
>
总监日报
</option>
<option
value=
"1"
>
店长日报
</option>
<option
value=
"2"
>
业务员日报
</option>
</select>
<span
class=
"btn btn-info btn3 ld-Marheight"
id=
"search"
>
搜索
</span>
<span
class=
"btn btn-info btn3 ld-Marheight"
id=
"reset"
>
重置
</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>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"report_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-report-img"
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"
>
<img
src=
""
alt=
""
class=
"review-images2"
/>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
<!-- /#删除模态框 -->
<div
class=
"modal fade"
id=
"modal-delete"
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 del-font"
>
<input
type=
"hidden"
value=
""
id=
"delete_id"
/>
确认删除吗?
</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=
"confirm_delete"
>
删除
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
\ No newline at end of file
application/index/view/achievements_report/week-achievements-report.html
0 → 100644
View file @
429044ff
{layout name="global/frame_tpl" /}
<input
type=
"hidden"
class=
"page-load"
id=
"weekAchievementsReport"
/>
<style>
.modal-body
{
/*height: 600px;*/
overflow-y
:
auto
;
padding-bottom
:
60px
;
}
.user-ul2
{
width
:
100%
;
height
:
auto
;
padding-bottom
:
15px
;
float
:
left
;
}
.user-ul2
li
{
list-style
:
none
;
line-height
:
30px
;
}
.money_total_two
{
font-weight
:
bold
;
font-size
:
15px
;
}
#search
{
float
:
left
;
}
#reset
{
float
:
left
;
}
.del-font
{
font-size
:
16px
;
font-weight
:
600
;
}
</style>
<div
id=
"page-content-wrapper"
>
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
""
>
<div
class=
"panel panel-default"
>
<div
class=
"panel-heading breadcrumb"
>
<li>
<a
href=
"javascript:;"
>
业绩周报
</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=
"10"
>
<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_start"
name=
"start_date1"
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=
"create_time_end"
name=
"end_date1"
type=
"date"
>
<select
class=
"form-control btn4 ld-Marheight input"
name=
""
id=
"district_id"
>
<option
value=
""
>
选择部门
</option>
</select>
<select
class=
"form-control btn4 ld-Marheight input"
name=
""
id=
"guest_stores"
value=
""
>
</select>
<select
class=
"form-control btn2 ld-Marheight"
id=
"shop_type"
>
<option
value=
""
>
周报类型
</option>
<option
value=
"0"
>
总监周报
</option>
<option
value=
"1"
>
店长周报
</option>
</select>
<span
class=
"btn btn-info btn3 ld-Marheight"
id=
"search"
>
搜索
</span>
<span
class=
"btn btn-info btn3 ld-Marheight"
id=
"reset"
>
重置
</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>
</tr>
</thead>
<tbody
class=
"text-center"
id=
"report_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-report-img"
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"
>
<img
src=
""
alt=
""
class=
"review-images2"
/>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
<!-- /#删除模态框 -->
<div
class=
"modal fade"
id=
"modal-delete"
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 del-font"
>
<input
type=
"hidden"
value=
""
id=
"delete_id"
/>
确认删除吗?
</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=
"confirm_delete"
>
删除
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
application/route.php
View file @
429044ff
...
@@ -296,22 +296,19 @@ Route::group('index', [
...
@@ -296,22 +296,19 @@ Route::group('index', [
'performancesubsidiaryList'
=>
[
'index/PerformanceSubsidiary/performancesubsidiaryList'
,
[
'method'
=>
'POST|GET'
]
],
//业绩明细liu
'performancesubsidiaryList'
=>
[
'index/PerformanceSubsidiary/performancesubsidiaryList'
,
[
'method'
=>
'POST|GET'
]
],
//业绩明细liu
'myCollectionUserList'
=>
[
'index/myCollectionUser/myCollectionUserList'
,
[
'method'
=>
'POST|GET'
]
],
//我收藏的客户liu
'myCollectionUserList'
=>
[
'index/myCollectionUser/myCollectionUserList'
,
[
'method'
=>
'POST|GET'
]
],
//我收藏的客户liu
'myCollectionShopList'
=>
[
'index/myCollectionShop/myCollectionShopList'
,
[
'method'
=>
'POST|GET'
]
],
//我收藏的客户liu
'myCollectionShopList'
=>
[
'index/myCollectionShop/myCollectionShopList'
,
[
'method'
=>
'POST|GET'
]
],
//我收藏的客户liu
'dayAchievementsReport'
=>
[
'index/dayAchievementsReport/dayAchievementsReportList'
,
[
'method'
=>
'POST|GET'
]
],
//日报liu
'weekAchievementsReport'
=>
[
'index/weekAchievementsReport/weekAchievementsReportList'
,
[
'method'
=>
'POST|GET'
]
],
//周报liu
//‘页面的地址’ =》 index/控制器名称/使用的方法
'inviteStatistics'
=>
[
'index/InviteStatistics/inviteStatisticsList'
,
[
'method'
=>
'POST|GET'
]
],
//邀请注册liu
'inviteStatistics'
=>
[
'index/InviteStatistics/inviteStatisticsList'
,
[
'method'
=>
'POST|GET'
]
],
//邀请注册liu
'operationalData'
=>
[
'index/OperationalData/operationalDataList'
,
[
'method'
=>
'POST|GET'
]
],
//运营数据统计liu
'operationalData'
=>
[
'index/OperationalData/operationalDataList'
,
[
'method'
=>
'POST|GET'
]
],
//运营数据统计liu
'lookShopIndex'
=>
[
'index/LookShop/lookShopIndex'
,
[
'method'
=>
'GET'
]
],
//商铺查看日志
'lookShopIndex'
=>
[
'index/LookShop/lookShopIndex'
,
[
'method'
=>
'GET'
]
],
//商铺查看日志
'selectDistrictPerformance'
=>
[
'index/Performance/selectDistrictPerformance'
,
[
'method'
=>
'POST|GET'
]
],
//区域业绩排行 朱伟 2018-07-31
'selectDistrictPerformance'
=>
[
'index/Performance/selectDistrictPerformance'
,
[
'method'
=>
'POST|GET'
]
],
//区域业绩排行 朱伟 2018-07-31
'selectStorePerformance'
=>
[
'index/Performance/selectStorePerformance'
,
[
'method'
=>
'POST|GET'
]
],
//门店业绩排行 朱伟 2018-07-31
'selectStorePerformance'
=>
[
'index/Performance/selectStorePerformance'
,
[
'method'
=>
'POST|GET'
]
],
//门店业绩排行 朱伟 2018-07-31
'selectIndividualPerformance'
=>
[
'index/Performance/selectIndividualPerformance'
,
[
'method'
=>
'POST|GET'
]
],
//个人业绩排行 朱伟 2018-07-31
'selectIndividualPerformance'
=>
[
'index/Performance/selectIndividualPerformance'
,
[
'method'
=>
'POST|GET'
]
],
//个人业绩排行 朱伟 2018-07-31
'transformFollowUp'
=>
[
'index/HouseFollowUp/transformFollowUp'
,
[
'method'
=>
'GET'
]
],
//个人业绩排行 朱伟 2018-07-31
'transformFollowUp'
=>
[
'index/HouseFollowUp/transformFollowUp'
,
[
'method'
=>
'GET'
]
],
//个人业绩排行 朱伟 2018-07-31
'getPerformanceExcel'
=>
[
'index/Performance/getPerformanceExcel'
,
[
'method'
=>
'POST|GET'
]
],
'getPerformanceExcel'
=>
[
'index/Performance/getPerformanceExcel'
,
[
'method'
=>
'POST|GET'
]
],
'pictureShow'
=>
[
'index/PictureShow/pictureShow'
,
[
'method'
=>
'POST|GET'
]
],
//商铺图库 杜欣源 2018-08-31
'pictureShow'
=>
[
'index/PictureShow/pictureShow'
,
[
'method'
=>
'POST|GET'
]
],
//商铺图库 杜欣源 2018-08-31
//c端商铺图库相关
//c端商铺图库相关
'addImageDepot'
=>
[
'index/ImageDepot/addImageDepot'
,
[
'method'
=>
'get | post'
]
],
//上传保存图片
'addImageDepot'
=>
[
'index/ImageDepot/addImageDepot'
,
[
'method'
=>
'get | post'
]
],
//上传保存图片
'getImageTypeLabel'
=>
[
'index/ImageDepot/getImageTypeLabel'
,
[
'method'
=>
'get | post'
]
],
//获取图片类型与标签
'getImageTypeLabel'
=>
[
'index/ImageDepot/getImageTypeLabel'
,
[
'method'
=>
'get | post'
]
],
//获取图片类型与标签
...
@@ -326,8 +323,6 @@ Route::group('index', [
...
@@ -326,8 +323,6 @@ Route::group('index', [
'operationLoginNum'
=>
[
'index/OperationData/loginNum'
,
[
'method'
=>
'get | post'
]
],
//
'operationLoginNum'
=>
[
'index/OperationData/loginNum'
,
[
'method'
=>
'get | post'
]
],
//
'operationHouseNum'
=>
[
'index/OperationData/houseNum'
,
[
'method'
=>
'get | post'
]
],
//
'operationHouseNum'
=>
[
'index/OperationData/houseNum'
,
[
'method'
=>
'get | post'
]
],
//
'operationHouseBargainNum'
=>
[
'index/OperationData/houseBargainNum'
,
[
'method'
=>
'get | post'
]
],
//
'operationHouseBargainNum'
=>
[
'index/OperationData/houseBargainNum'
,
[
'method'
=>
'get | post'
]
],
//
'getFirstLoginTotal'
=>
[
'index/InviteTotal/getFirstLoginTotal'
,
[
'method'
=>
'get | post'
]
],
//
'getFirstLoginTotal'
=>
[
'index/InviteTotal/getFirstLoginTotal'
,
[
'method'
=>
'get | post'
]
],
//
...
@@ -429,8 +424,6 @@ Route::group('chat', [
...
@@ -429,8 +424,6 @@ Route::group('chat', [
'pushMsg_gethouseinfo'
=>
[
'chat/AppChat/getHouseInfoByFrom'
,
[
'method'
=>
'post|get'
]
],
'pushMsg_gethouseinfo'
=>
[
'chat/AppChat/getHouseInfoByFrom'
,
[
'method'
=>
'post|get'
]
],
'getUserInfoByFrom'
=>
[
'chat/AppChat/getUserInfoByFrom'
,
[
'method'
=>
'post|get'
]
],
'getUserInfoByFrom'
=>
[
'chat/AppChat/getUserInfoByFrom'
,
[
'method'
=>
'post|get'
]
],
'getChatRelation'
=>
[
'chat/AppChat/getChatRelation'
,
[
'method'
=>
'post|get'
]
],
'getChatRelation'
=>
[
'chat/AppChat/getChatRelation'
,
[
'method'
=>
'post|get'
]
],
'getSystemMessageByShop'
=>
[
'chat/AppChat/getSystemMessageByShop'
,
[
'method'
=>
'post|get'
]
],
'getSystemMessageByShop'
=>
[
'chat/AppChat/getSystemMessageByShop'
,
[
'method'
=>
'post|get'
]
],
'getSystemMessageByUser'
=>
[
'chat/AppChat/getSystemMessageByUser'
,
[
'method'
=>
'post|get'
]
],
'getSystemMessageByUser'
=>
[
'chat/AppChat/getSystemMessageByUser'
,
[
'method'
=>
'post|get'
]
],
...
...
public/resource/js/dayAchievementsReport.js
0 → 100644
View file @
429044ff
define
([
'doT'
,
'text!temp/day_achievements_report_template_tpl.html'
,
'css!style/home.css'
,
'ckfinder'
,
'ckfinderStart'
,
"datetimepicker"
,
'pagination'
,
'bootstrapJs'
,
'blow-up'
],
function
(
doT
,
template
)
{
report
=
{
pageNo
:
1
,
/*第几页*/
pageSize
:
15
,
/*每页显示多少条*/
id
:
''
,
house_id
:
''
,
type
:
''
,
valueCurrent
:
''
,
ajaxObj
:
''
,
stopstatus
:
true
,
boxphoto
:
''
,
report_id
:
''
,
init
:
function
()
{
//初始化dot
$
(
document
.
body
).
append
(
template
);
report
.
getList
(
1
);
report
.
event
();
},
event
:
function
()
{
var
_doc
=
$
(
document
);
//二级联动
report
.
getDistrict
(
function
(){
_doc
.
on
(
'input'
,
'#district_id, #district_id2'
,
function
(){
var
_this
=
$
(
this
);
var
_id
=
_this
.
val
();
_this
.
next
().
html
(
''
);
//先清空
if
(
_id
&&
_id
!=
'0'
){
report
.
getDistrictStoreList
(
_id
,
function
(
_data
){
var
_str
=
'<option value="">选择门店</option>'
;
$
.
each
(
_data
,
function
(
i
,
item
)
{
_str
+=
'<option value="'
+
item
.
id
+
'">'
+
item
.
store_name
+
'</option>'
;
});
_this
.
next
().
html
(
_str
);
});
}
else
{
};
});
});
//业绩图片 显示
$
(
document
).
delegate
(
".review-images"
,
"click"
,
function
()
{
//提交
$
(
'.review-images2'
).
attr
(
'src'
,
$
(
this
).
attr
(
"data-img"
));
});
//删除
$
(
"#confirm_delete"
).
click
(
function
(){
var
params
=
{};
params
.
id
=
report
.
report_id
;
if
(
!
params
.
id
||
params
.
id
==
null
){
alert
(
"要删除的id不能为空"
);
return
false
;
}
report
.
delete_report
(
params
);
});
$
(
document
).
delegate
(
".report-del"
,
"click"
,
function
()
{
report
.
report_id
=
$
(
this
).
attr
(
"data-id"
);
});
$
(
"#search"
).
click
(
function
()
{
report
.
getList
(
1
);
});
$
(
"#reset"
).
click
(
function
()
{
//重置
document
.
getElementById
(
"form_search"
).
reset
();
$
(
'#guest_stores'
).
html
(
''
);
});
$
(
document
).
delegate
(
".review-images"
,
"click"
,
function
()
{
//提交
console
.
log
(
$
(
this
).
attr
(
"data-img"
));
});
$
(
"#export"
).
click
(
function
()
{
//导出列表
report
.
exportList
();
});
$
(
document
).
delegate
(
".submit_edit2"
,
"click"
,
function
()
{
//提交
report
.
house_id2
=
$
(
this
).
attr
(
"data-id"
);
console
.
log
(
report
.
house_id2
);
$
(
"#real_money"
).
val
(
$
(
this
).
attr
(
"data-money"
));
});
$
(
document
).
delegate
(
".submit_edit"
,
"click"
,
function
()
{
//提交
report
.
Submit_follow
();
});
$
(
document
).
on
(
"input"
,
"#cus_fang"
,
function
()
{
//手机号搜索客方2
if
(
$
(
"#cus_fang"
).
val
()
==
''
){
$
(
".user-ul2"
).
html
(
''
);
}
else
{
report
.
search_phone2
();
}
});
$
(
document
).
delegate
(
".addphone2"
,
"click"
,
function
()
{
//list2消失
report
.
addphone2
(
this
);
});
},
addphone2
:
function
(
obj
){
var
user_ht
=
$
(
obj
).
html
();
$
(
"#cus_fang"
).
val
(
user_ht
);
$
(
".user-ul2"
).
html
(
''
);
report
.
agent_id
=
$
(
obj
).
attr
(
"data-id"
);
},
search_phone2
:
function
(){
//手机号
$
.
ajax
({
url
:
'/index/select_by_phone'
,
type
:
'POST'
,
async
:
true
,
data
:
{
"phone"
:
$
(
"#cus_fang"
).
val
()
},
dataType
:
'json'
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
var
user_ul2
=
""
;
$
.
each
(
data
.
data
,
function
(
i
,
item
)
{
user_ul2
+=
'<li class="addphone2" data-id="'
+
item
.
id
+
'">'
+
item
.
id
+
'-'
+
item
.
realname
+
'-'
+
item
.
phone
+
'</li>'
;
});
$
(
".user-ul2"
).
html
(
user_ul2
);
}
else
{
alert
(
data
.
msg
);
}
}
});
},
Submit_follow
:
function
()
{
//提交
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/addRealMoney'
,
data
:
{
"collection_id"
:
report
.
house_id2
,
"real_money"
:
$
(
"#real_money"
).
val
(),
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
report
.
getList
(
0
);
}
else
{
}
}
});
},
getList
:
function
(
pageNo
)
{
console
.
log
(
$
(
'#customer_name'
).
val
());
console
.
log
(
$
(
'#start_date'
).
val
());
console
.
log
(
$
(
'#shop_name'
).
val
());
report
.
pageNo
=
pageNo
;
var
params
=
{};
params
.
create_time_start
=
$
(
'#create_time_start'
).
val
();
params
.
create_time_end
=
$
(
'#create_time_end'
).
val
();
params
.
district_id
=
$
(
'#district_id'
).
val
()
*
1
;
params
.
store_id
=
$
(
'#guest_stores'
).
val
()
*
1
;
params
.
user_name
=
$
(
'#user_name'
).
val
();
params
.
user_phone
=
$
(
'#user_phone'
).
val
();
//跟进搜索
params
.
report_agent_phone
=
$
(
'#report_agent_phone'
).
val
();
params
.
report_agent_name
=
$
(
'#report_agent_name'
).
val
();
params
.
house_title
=
$
(
'#house_title'
).
val
();
params
.
shop_type
=
$
(
'#shop_type'
).
val
()
*
1
;
//跟进搜索
params
.
pageNo
=
report
.
pageNo
;
params
.
pageSize
=
report
.
pageSize
;
$
.
ajax
({
type
:
'GET'
,
url
:
'/index/marchInList'
,
//拜访列表
data
:
params
,
timeout
:
30000
,
dataType
:
'json'
,
beforeSend
:
function
()
{},
success
:
function
(
data
)
{
if
(
typeof
data
===
'object'
)
{
if
(
data
.
code
==
200
)
{
var
doTtmpl
=
doT
.
template
(
document
.
getElementById
(
'day_achievements_report_list_tpl'
).
innerHTML
);
$
(
"#report_list"
).
html
(
doTtmpl
(
data
.
data
.
list
));
/*分页代码*/
add_page
(
data
.
data
.
total
,
pageNo
,
report
.
pageSize
,
report
.
getList
);
}
else
{
alert
(
data
[
'msg'
]);
};
}
else
{
alert
(
'数据错误'
);
};
},
error
:
function
()
{
alert
(
'error'
);
},
complete
:
function
(
xhr
,
textStatus
){
if
(
textStatus
===
'timeout'
){
alert
(
'请求超时'
);
};
}
});
},
//调用部门 和 门店的接口
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>'
;
});
$
(
"#district_id"
).
append
(
str
);
$
(
"#district_id2"
).
append
(
str
);
fn
&&
fn
();
}
}
});
},
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
);
}
}
});
},
delete_report
:
function
(
params
)
{
$
.
ajax
({
url
:
'/index/delNotice'
,
type
:
'POST'
,
async
:
true
,
data
:
params
,
dataType
:
'json'
,
success
:
function
(
data
)
{
$
(
"#modal-delete"
).
modal
(
'hide'
);
if
(
data
.
code
==
"101"
)
{
alert
(
data
.
msg
);
return
false
;
}
report
.
getList
(
report
.
pageNo
);
}
});
},
};
return
report
;
});
\ No newline at end of file
public/resource/js/weekAchievementsReport.js
0 → 100644
View file @
429044ff
define
([
'doT'
,
'text!temp/week_achievements_report_template_tpl.html'
,
'css!style/home.css'
,
'ckfinder'
,
'ckfinderStart'
,
"datetimepicker"
,
'pagination'
,
'bootstrapJs'
,
'blow-up'
],
function
(
doT
,
template
)
{
report
=
{
pageNo
:
1
,
/*第几页*/
pageSize
:
15
,
/*每页显示多少条*/
id
:
''
,
house_id
:
''
,
type
:
''
,
valueCurrent
:
''
,
ajaxObj
:
''
,
stopstatus
:
true
,
boxphoto
:
''
,
report_id
:
''
,
init
:
function
()
{
//初始化dot
$
(
document
.
body
).
append
(
template
);
report
.
getList
(
1
);
report
.
event
();
},
event
:
function
()
{
var
_doc
=
$
(
document
);
//二级联动
report
.
getDistrict
(
function
(){
_doc
.
on
(
'input'
,
'#district_id, #district_id2'
,
function
(){
var
_this
=
$
(
this
);
var
_id
=
_this
.
val
();
_this
.
next
().
html
(
''
);
//先清空
if
(
_id
&&
_id
!=
'0'
){
report
.
getDistrictStoreList
(
_id
,
function
(
_data
){
var
_str
=
'<option value="">选择门店</option>'
;
$
.
each
(
_data
,
function
(
i
,
item
)
{
_str
+=
'<option value="'
+
item
.
id
+
'">'
+
item
.
store_name
+
'</option>'
;
});
_this
.
next
().
html
(
_str
);
});
}
else
{
};
});
});
//业绩图片 显示
$
(
document
).
delegate
(
".review-images"
,
"click"
,
function
()
{
//提交
$
(
'.review-images2'
).
attr
(
'src'
,
$
(
this
).
attr
(
"data-img"
));
});
//删除
$
(
"#confirm_delete"
).
click
(
function
(){
var
params
=
{};
params
.
id
=
report
.
report_id
;
if
(
!
params
.
id
||
params
.
id
==
null
){
alert
(
"要删除的id不能为空"
);
return
false
;
}
report
.
delete_report
(
params
);
});
$
(
document
).
delegate
(
".report-del"
,
"click"
,
function
()
{
report
.
report_id
=
$
(
this
).
attr
(
"data-id"
);
});
$
(
"#search"
).
click
(
function
()
{
report
.
getList
(
1
);
});
$
(
"#reset"
).
click
(
function
()
{
//重置
document
.
getElementById
(
"form_search"
).
reset
();
$
(
'#guest_stores'
).
html
(
''
);
});
$
(
document
).
delegate
(
".review-images"
,
"click"
,
function
()
{
//提交
console
.
log
(
$
(
this
).
attr
(
"data-img"
));
});
$
(
"#export"
).
click
(
function
()
{
//导出列表
report
.
exportList
();
});
$
(
document
).
delegate
(
".submit_edit2"
,
"click"
,
function
()
{
//提交
report
.
house_id2
=
$
(
this
).
attr
(
"data-id"
);
console
.
log
(
report
.
house_id2
);
$
(
"#real_money"
).
val
(
$
(
this
).
attr
(
"data-money"
));
});
$
(
document
).
delegate
(
".submit_edit"
,
"click"
,
function
()
{
//提交
report
.
Submit_follow
();
});
$
(
document
).
on
(
"input"
,
"#cus_fang"
,
function
()
{
//手机号搜索客方2
if
(
$
(
"#cus_fang"
).
val
()
==
''
){
$
(
".user-ul2"
).
html
(
''
);
}
else
{
report
.
search_phone2
();
}
});
$
(
document
).
delegate
(
".addphone2"
,
"click"
,
function
()
{
//list2消失
report
.
addphone2
(
this
);
});
},
addphone2
:
function
(
obj
){
var
user_ht
=
$
(
obj
).
html
();
$
(
"#cus_fang"
).
val
(
user_ht
);
$
(
".user-ul2"
).
html
(
''
);
report
.
agent_id
=
$
(
obj
).
attr
(
"data-id"
);
},
search_phone2
:
function
(){
//手机号
$
.
ajax
({
url
:
'/index/select_by_phone'
,
type
:
'POST'
,
async
:
true
,
data
:
{
"phone"
:
$
(
"#cus_fang"
).
val
()
},
dataType
:
'json'
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
var
user_ul2
=
""
;
$
.
each
(
data
.
data
,
function
(
i
,
item
)
{
user_ul2
+=
'<li class="addphone2" data-id="'
+
item
.
id
+
'">'
+
item
.
id
+
'-'
+
item
.
realname
+
'-'
+
item
.
phone
+
'</li>'
;
});
$
(
".user-ul2"
).
html
(
user_ul2
);
}
else
{
alert
(
data
.
msg
);
}
}
});
},
Submit_follow
:
function
()
{
//提交
$
.
ajax
({
'type'
:
'POST'
,
'url'
:
'/index/addRealMoney'
,
data
:
{
"collection_id"
:
report
.
house_id2
,
"real_money"
:
$
(
"#real_money"
).
val
(),
},
dataType
:
"json"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
)
{
report
.
getList
(
0
);
}
else
{
}
}
});
},
getList
:
function
(
pageNo
)
{
console
.
log
(
$
(
'#customer_name'
).
val
());
console
.
log
(
$
(
'#start_date'
).
val
());
console
.
log
(
$
(
'#shop_name'
).
val
());
report
.
pageNo
=
pageNo
;
var
params
=
{};
params
.
create_time_start
=
$
(
'#create_time_start'
).
val
();
params
.
create_time_end
=
$
(
'#create_time_end'
).
val
();
params
.
district_id
=
$
(
'#district_id'
).
val
()
*
1
;
params
.
store_id
=
$
(
'#guest_stores'
).
val
()
*
1
;
params
.
user_name
=
$
(
'#user_name'
).
val
();
params
.
user_phone
=
$
(
'#user_phone'
).
val
();
//跟进搜索
params
.
report_agent_phone
=
$
(
'#report_agent_phone'
).
val
();
params
.
report_agent_name
=
$
(
'#report_agent_name'
).
val
();
params
.
house_title
=
$
(
'#house_title'
).
val
();
params
.
shop_type
=
$
(
'#shop_type'
).
val
()
*
1
;
//跟进搜索
params
.
pageNo
=
report
.
pageNo
;
params
.
pageSize
=
report
.
pageSize
;
$
.
ajax
({
type
:
'GET'
,
url
:
'/index/marchInList'
,
//拜访列表
data
:
params
,
timeout
:
30000
,
dataType
:
'json'
,
beforeSend
:
function
()
{},
success
:
function
(
data
)
{
if
(
typeof
data
===
'object'
)
{
if
(
data
.
code
==
200
)
{
var
doTtmpl
=
doT
.
template
(
document
.
getElementById
(
'week_achievements_report_list_tpl'
).
innerHTML
);
$
(
"#report_list"
).
html
(
doTtmpl
(
data
.
data
.
list
));
/*分页代码*/
add_page
(
data
.
data
.
total
,
pageNo
,
report
.
pageSize
,
report
.
getList
);
}
else
{
alert
(
data
[
'msg'
]);
};
}
else
{
alert
(
'数据错误'
);
};
},
error
:
function
()
{
alert
(
'error'
);
},
complete
:
function
(
xhr
,
textStatus
){
if
(
textStatus
===
'timeout'
){
alert
(
'请求超时'
);
};
}
});
},
//调用部门 和 门店的接口
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>'
;
});
$
(
"#district_id"
).
append
(
str
);
$
(
"#district_id2"
).
append
(
str
);
fn
&&
fn
();
}
}
});
},
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
);
}
}
});
},
delete_report
:
function
(
params
)
{
$
.
ajax
({
url
:
'/index/delNotice'
,
type
:
'POST'
,
async
:
true
,
data
:
params
,
dataType
:
'json'
,
success
:
function
(
data
)
{
$
(
"#modal-delete"
).
modal
(
'hide'
);
if
(
data
.
code
==
"101"
)
{
alert
(
data
.
msg
);
return
false
;
}
report
.
getList
(
report
.
pageNo
);
}
});
},
};
return
report
;
});
\ No newline at end of file
public/resource/template/day_achievements_report_template_tpl.html
0 → 100644
View file @
429044ff
<script
id=
"day_achievements_report_list_tpl"
type=
"text/template"
>
[
%
if
(
it
)
{
%
]
[
%
for
(
var
item
in
it
){
%
]
<
tr
class
=
"text-center"
>
<
td
>
[
%=
it
[
item
][
'create_time'
]
%
]
<
/td
>
<
td
>
<
a
class
=
"review-images"
href
=
"#modal-report-img"
data
-
toggle
=
"modal"
data
-
img
=
'[%= it[item]["scene_photo"] %]'
>
查看
<
/a
>
<
/td
>
<
td
>
[
%=
it
[
item
][
'house_title'
]
%
]
<
/td
>
<
td
>
<
a
class
=
"btn1 btn-danger report-del"
href
=
"#modal-delete"
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/week_achievements_report_template_tpl.html
0 → 100644
View file @
429044ff
<script
id=
"week_achievements_report_list_tpl"
type=
"text/template"
>
[
%
if
(
it
)
{
%
]
[
%
for
(
var
item
in
it
){
%
]
<
tr
class
=
"text-center"
>
<
td
>
[
%=
it
[
item
][
'user_name'
]
%
]
<
/td
>
<
td
>
<
a
class
=
"review-images"
href
=
"#modal-report-img"
data
-
toggle
=
"modal"
data
-
img
=
'[%= it[item]["scene_photo"] %]'
>
查看
<
/a
>
<
/td
>
<
td
>
[
%=
it
[
item
][
'create_time'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'report_agent_name'
]
%
]
<
/td
>
<
td
>
<
a
class
=
"btn1 btn-danger report-del"
href
=
"#modal-delete"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
删除
<
/a
>
<
/td
>
<
/tr
>
[
%
}
%
]
[
%
}
else
{
%
]
<
tr
>
<
td
colspan
=
"8"
style
=
"text-align:center;"
>
暂无数据
<
/td
>
<
/tr
>
[
%
}
%
]
</script>
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