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
eb0691b7
Commit
eb0691b7
authored
Sep 04, 2018
by
agping
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
商圈 筛选
parent
7d15a014
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
91 additions
and
4 deletions
+91
-4
houseList.html
application/index/view/houses/houseList.html
+3
-0
houseList.js
public/resource/js/houseList.js
+52
-4
user.js
public/resource/js/user.js
+32
-0
user_template_tpl.html
public/resource/template/user_template_tpl.html
+4
-0
No files found.
application/index/view/houses/houseList.html
View file @
eb0691b7
...
@@ -173,6 +173,9 @@
...
@@ -173,6 +173,9 @@
<select
class=
"form-control btn2"
id=
"shop_area_id"
>
<select
class=
"form-control btn2"
id=
"shop_area_id"
>
<option
value=
""
selected=
"selected"
>
区域
</option>
<option
value=
""
selected=
"selected"
>
区域
</option>
</select>
</select>
<select
class=
"form-control btn2"
id=
"business_circle_id"
>
<option
value=
""
selected=
"selected"
>
商圈
</option>
</select>
<select
class=
"form-control btn2"
id=
"shop_type"
>
<select
class=
"form-control btn2"
id=
"shop_type"
>
<option
value=
"-1"
>
商铺类型
</option>
<option
value=
"-1"
>
商铺类型
</option>
<option
value=
"0"
>
商场
</option>
<option
value=
"0"
>
商场
</option>
...
...
public/resource/js/houseList.js
View file @
eb0691b7
...
@@ -276,13 +276,40 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
...
@@ -276,13 +276,40 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
$
(
'#user_area_choose'
).
html
(
''
);
//先清空
$
(
'#user_area_choose'
).
html
(
''
);
//先清空
if
(
_id
&&
_id
!=
'0'
)
{
if
(
_id
&&
_id
!=
'0'
)
{
business
.
getDistrictStoreList
(
_id
,
function
(
_data
)
{
business
.
getDistrictStoreList
(
_id
,
function
(
_data
)
{
// var _str = '';
var
_str
=
'<option value="">区域</option>'
;
var
_str
=
'<option value="">区域</option>'
;
$
.
each
(
_data
,
function
(
i
,
item
)
{
$
.
each
(
_data
,
function
(
i
,
item
)
{
_str
+=
'<option value="'
+
item
.
fullName
+
'">'
+
item
.
fullName
+
'</option>'
;
_str
+=
'<option value="'
+
item
.
fullName
+
'">'
+
item
.
fullName
+
'</option>'
;
});
});
$
(
'#shop_area_id'
).
html
(
_str
);
$
(
'#shop_area_id'
).
html
(
_str
);
business
.
getList
();
});
}
else
{};
});
//点击 区域 获取 商圈
_doc
.
on
(
'input'
,
'#shop_area_id'
,
function
()
{
var
_this
=
$
(
this
);
var
_id
=
_this
.
val
();
var
_province
=
$
(
'#user_city_choose'
).
val
();
var
_city
=
$
(
'#shop_area_id'
).
val
();
if
(
_province
==
310100
){
_province
=
'上海市'
;
_city
=
'上海市'
;
};
if
(
_province
==
330100
){
_province
=
'浙江省'
;
_city
=
'杭州市'
;
};
$
(
'#user_area_choose'
).
html
(
''
);
//先清空
if
(
_id
&&
_id
!=
'0'
)
{
business
.
getBusinessCircle
(
_id
,
_province
,
_city
,
function
(
_data
)
{
var
_str
=
'<option value="">商圈</option>'
;
$
.
each
(
_data
,
function
(
i
,
item
)
{
_str
+=
'<option value="'
+
item
.
id
+
'">'
+
item
.
name
+
'</option>'
;
});
$
(
'#business_circle_id'
).
html
(
_str
);
business
.
getList
();
});
});
}
else
{};
}
else
{};
});
});
...
@@ -529,7 +556,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
...
@@ -529,7 +556,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
if
(
_limitTop
&&
(
_fileNum
<
_limitTop
))
{
if
(
_limitTop
&&
(
_fileNum
<
_limitTop
))
{
var
formData
=
new
FormData
();
var
formData
=
new
FormData
();
formData
.
append
(
'type'
,
'
business_school
_file'
);
formData
.
append
(
'type'
,
'
exclusive
_file'
);
formData
.
append
(
'image'
,
_this
[
0
].
files
[
0
]);
formData
.
append
(
'image'
,
_this
[
0
].
files
[
0
]);
console
.
log
(
formData
);
console
.
log
(
formData
);
$
.
ajax
({
$
.
ajax
({
...
@@ -650,7 +677,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
...
@@ -650,7 +677,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
console
.
log
(
file_paths
[
i
][
'file_name'
])
console
.
log
(
file_paths
[
i
][
'file_name'
])
var
_tempArr
=
file_paths
[
i
][
'file_name'
].
split
(
'/'
);
var
_tempArr
=
file_paths
[
i
][
'file_name'
].
split
(
'/'
);
file_paths
[
i
][
'file_name'
]
&&
$
(
'#fujian_ul'
).
append
(
'<li class="pdf-pre-li" id='
+
file_paths
[
i
][
'id'
]
+
'><a class="pdf-pre-a" download="{1}" href="{0}" title="点击可下载">{1}</a><a href="javascript:;" class="delet-pic-btn">删除</a></li>'
.
stringFormatObj
({
file_paths
[
i
][
'file_name'
]
&&
$
(
'#fujian_ul'
).
append
(
'<li class="pdf-pre-li" id='
+
file_paths
[
i
][
'id'
]
+
'><a class="pdf-pre-a" download="{1}" href="{0}" title="点击可下载">{1}</a><a href="javascript:;" class="delet-pic-btn">删除</a></li>'
.
stringFormatObj
({
'0'
:
'/'
+
file_paths
[
i
][
'show_fil
e'
],
'0'
:
file_paths
[
i
][
'file_nam
e'
],
'1'
:
dealFileName
(
decodeURI
(
_tempArr
[
_tempArr
.
length
-
1
]))
'1'
:
dealFileName
(
decodeURI
(
_tempArr
[
_tempArr
.
length
-
1
]))
}));
}));
};
};
...
@@ -1047,6 +1074,7 @@ if(data.code == 200) {
...
@@ -1047,6 +1074,7 @@ if(data.code == 200) {
params
.
city
=
'杭州市'
;
params
.
city
=
'杭州市'
;
}
}
params
.
disc
=
$
(
'#shop_area_id'
).
val
();
//区域筛选
params
.
disc
=
$
(
'#shop_area_id'
).
val
();
//区域筛选
params
.
business_id
=
$
(
'#shop_area_id'
).
val
()
//商圈筛选
params
.
industry_type
=
$
(
'#yetai_id'
).
val
();
//业态筛选
params
.
industry_type
=
$
(
'#yetai_id'
).
val
();
//业态筛选
params
.
dish_name
=
$
(
'#dish_name'
).
val
();
//盘方姓名
params
.
dish_name
=
$
(
'#dish_name'
).
val
();
//盘方姓名
params
.
dish_phone
=
$
(
'#dish_phone'
).
val
();
//盘方手机号
params
.
dish_phone
=
$
(
'#dish_phone'
).
val
();
//盘方手机号
...
@@ -1130,6 +1158,26 @@ if(data.code == 200) {
...
@@ -1130,6 +1158,26 @@ if(data.code == 200) {
}
}
}
}
});
});
},
//商圈 筛选
getBusinessCircle
:
function
(
id
,
province
,
city
,
fn
)
{
$
.
ajax
({
url
:
'/index/getBusinessAll'
,
type
:
'GET'
,
async
:
true
,
data
:
{
'province'
:
province
,
'city'
:
city
,
'disc'
:
id
},
dataType
:
'json'
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
&&
data
.
data
!=
null
)
{
fn
&&
fn
(
data
.
data
);
}
}
});
},
},
delBusiness
:
function
()
{
delBusiness
:
function
()
{
$
.
ajax
({
$
.
ajax
({
...
...
public/resource/js/user.js
View file @
eb0691b7
...
@@ -44,6 +44,7 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
...
@@ -44,6 +44,7 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
customerInfo
:
{},
customerInfo
:
{},
all_custom
:
true
,
// true :所有客户 ,false :当前客户
all_custom
:
true
,
// true :所有客户 ,false :当前客户
main_select
:
false
,
// true : 开启高级搜索 ,false :关闭高级搜索
main_select
:
false
,
// true : 开启高级搜索 ,false :关闭高级搜索
user_status
:
''
,
init
:
function
()
{
init
:
function
()
{
//初始化dot
//初始化dot
$
(
"body"
).
append
(
template
);
$
(
"body"
).
append
(
template
);
...
@@ -101,6 +102,8 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
...
@@ -101,6 +102,8 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
var
day_start
=
getPreMonth
(
day_end
);
var
day_start
=
getPreMonth
(
day_end
);
$
(
'#start_date'
).
val
(
day_start
);
$
(
'#start_date'
).
val
(
day_start
);
$
(
'#end_date'
).
val
(
day_end
);
//客户列表 进来 默认时间 一个月
$
(
'#end_date'
).
val
(
day_end
);
//客户列表 进来 默认时间 一个月
//默认 筛选求租客户
$
(
"select[name=public_status]"
).
val
(
'0'
);
user
.
getList
();
user
.
getList
();
user
.
event
();
user
.
event
();
//新增 默认上海
//新增 默认上海
...
@@ -111,6 +114,7 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
...
@@ -111,6 +114,7 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
});
});
$
(
'#user_area_add'
).
html
(
_str
);
$
(
'#user_area_add'
).
html
(
_str
);
});
});
//汉化实现
//汉化实现
;(
function
(
$
){
;(
function
(
$
){
...
@@ -162,6 +166,17 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
...
@@ -162,6 +166,17 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
e
.
stopPropagation
();
e
.
stopPropagation
();
$
(
this
).
parent
().
remove
();
$
(
this
).
parent
().
remove
();
});
});
//点击 无效
_doc
.
on
(
'click'
,
'.is_invalid'
,
function
(
e
)
{
e
.
preventDefault
();
e
.
stopPropagation
();
user
.
user_id
=
$
(
this
).
attr
(
"data-id"
);
user
.
user_status
=
$
(
this
).
attr
(
"data-status"
);
$
(
this
).
attr
(
'class'
,
'btn1 btn-default is_invalid'
);
if
(
user
.
user_status
*
1
!=
-
1
){
user
.
isInvalid
();
}
});
//收藏 取消收藏
//收藏 取消收藏
$
(
document
).
delegate
(
".is_show"
,
"click"
,
function
()
{
//点击收藏 取消收藏
$
(
document
).
delegate
(
".is_show"
,
"click"
,
function
()
{
//点击收藏 取消收藏
var
user_info_obj
=
JSON
.
parse
(
decodeURIComponent
(
localStorage
.
getItem
(
'pcUserInfo'
)));
//读取缓存
var
user_info_obj
=
JSON
.
parse
(
decodeURIComponent
(
localStorage
.
getItem
(
'pcUserInfo'
)));
//读取缓存
...
@@ -1589,7 +1604,24 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
...
@@ -1589,7 +1604,24 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
}
}
});
});
},
},
//客户列表 无效 修改
isInvalid
:
function
()
{
checkLogin
();
$
.
ajax
({
url
:
'/index/updateUserStatus'
,
type
:
'POST'
,
async
:
true
,
data
:
{
"user_id"
:
user
.
user_id
,
},
dataType
:
'json'
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
&&
data
.
data
!=
null
)
{
}
}
});
},
//筛选
//筛选
getList
:
function
(
pageNo
)
{
getList
:
function
(
pageNo
)
{
var
user_info_obj
=
JSON
.
parse
(
decodeURIComponent
(
localStorage
.
getItem
(
'pcUserInfo'
)));
//读取缓存
var
user_info_obj
=
JSON
.
parse
(
decodeURIComponent
(
localStorage
.
getItem
(
'pcUserInfo'
)));
//读取缓存
...
...
public/resource/template/user_template_tpl.html
View file @
eb0691b7
<script
id=
"user_list_tpl"
type=
"text/template"
>
<script
id=
"user_list_tpl"
type=
"text/template"
>
[
%
var
sw
=
function
(
s
){
switch
(
Number
(
s
)){
case
2
:
return
"btn-info"
;
case
1
:
return
"btn-default"
}};
%
]
[
%
var
sw
=
function
(
s
){
switch
(
Number
(
s
)){
case
2
:
return
"btn-info"
;
case
1
:
return
"btn-default"
}};
%
]
[
%
var
sw3
=
function
(
s
){
switch
(
Number
(
s
)){
case
0
:
return
"btn-info"
;
case
1
:
return
"btn-info"
;
case
-
1
:
return
"btn-default"
}};
%
]
[
%
if
(
it
[
0
])
{
%
]
[
%
for
(
var
item
in
it
){
%
]
[
%
if
(
it
[
0
])
{
%
]
[
%
for
(
var
item
in
it
){
%
]
<
tr
class
=
"text-center"
>
<
tr
class
=
"text-center"
>
<
td
>
[
%=
it
[
item
][
'id'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'id'
]
%
]
<
/td
>
...
@@ -59,6 +61,8 @@
...
@@ -59,6 +61,8 @@
<
a
class
=
"btn1 btn-success caozuo cao-zuo-record"
href
=
"#modal-record-edit"
data
-
toggle
=
"modal"
data
-
phone
=
'[%= it[item]["user_phone"] %]'
data
-
id
=
'[%= it[item]["id"] %]'
>
客户编辑
<
/a
>
<
a
class
=
"btn1 btn-success caozuo cao-zuo-record"
href
=
"#modal-record-edit"
data
-
toggle
=
"modal"
data
-
phone
=
'[%= it[item]["user_phone"] %]'
data
-
id
=
'[%= it[item]["id"] %]'
>
客户编辑
<
/a
>
[
%
}
%
]
[
%
}
%
]
<
a
class
=
"btn1 is_invalid [%= sw3(it[item]['user_status']) %]"
href
=
""
data
-
id
=
'[%= it[item]["id"] %]'
data
-
status
=
'[%= it[item]["user_status"] %]'
>
无效
<
/a
>
[
%
}
%
]
[
%
}
%
]
<
/td
>
<
/td
>
<
/tr
>
<
/tr
>
...
...
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