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
04856007
Commit
04856007
authored
Nov 19, 2018
by
agping
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
h5
parent
3e9a707e
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
176 additions
and
9 deletions
+176
-9
houseList.html
application/index/view/houses/houseList.html
+8
-0
detaila_tl.js
public/app/js/detaila_tl.js
+78
-1
shopList.vue
public/appnew/src/components/shop/shopList.vue
+50
-7
houseList.js
public/resource/js/houseList.js
+40
-1
No files found.
application/index/view/houses/houseList.html
View file @
04856007
...
...
@@ -487,7 +487,15 @@
生成推广链接
</h4>
</div>
<div
class=
"modal-body modal-body-one"
>
<div
class=
"tuiguang-type"
>
<a
href=
"javascript:;"
class=
"btn btn-info"
>
百度推广
</a>
<a
href=
"javascript:;"
class=
"btn btn-default"
>
腾讯推广
</a>
<a
href=
"javascript:;"
class=
"btn btn-default"
>
今日头条推广
</a>
<a
href=
"javascript:;"
class=
"btn btn-default"
>
其他
</a>
</div>
<br>
<br>
<br>
<div>
...
...
public/app/js/detaila_tl.js
View file @
04856007
...
...
@@ -12,6 +12,17 @@
var
_shangpuId
=
jsonObect
.
id
;
//
var
_shangpuName
=
jsonObect
.
housename
;
//从url获取的商铺名
var
_isC
=
jsonObect
.
isC
;
var
_panfang_name
=
''
;
var
_panfang_img
=
''
;
var
_panfang_tel
=
''
;
var
generalize_id
=
jsonObect
.
generalizeId
;
//分享链接的来源
var
p_city
=
jsonObect
.
city
;
var
p_type
=
jsonObect
.
type
;
var
p_district_id
=
jsonObect
.
p_district_id
;
var
p_store_id
=
jsonObect
.
p_store_id
;
var
p_agent_id
=
jsonObect
.
p_agent_id
;
// var _shangpuName = getUrlParam('housename'); //从url获取的商铺名
// var _isC = getUrlParam('isC')
//site_area区分是c端还是b端
...
...
@@ -31,6 +42,9 @@
success
:
function
(
response
)
{
if
(
typeof
response
===
'object'
)
{
if
(
response
[
'code'
]
==
'200'
)
{
_panfang_name
=
response
.
data
.
panParty
[
0
].
name
;
_panfang_img
=
"https://api.tonglianjituan.com/static/user_header/"
+
response
.
data
.
panParty
[
0
].
img
;
_panfang_tel
=
response
.
data
.
panParty
[
0
].
phone
;
var
shang
=
response
.
data
.
shop_type
;
var
shanpu
=
' '
;
if
(
shang
==
"0"
)
{
...
...
@@ -268,9 +282,73 @@
var
_name
=
jsonObect
.
user_name
;
var
_name_img
=
jsonObect
.
user_img
;
var
_tel
=
jsonObect
.
user_tel
;
var
_city
=
jsonObect
.
city
;
// var _name = getUrlParam('user_name');
// var _name_img = getUrlParam('user_img');
// var _tel = getUrlParam('user_tel');
// pc h5推广
if
(
_city
){
var
_fix_bottom
=
$
(
".fix_area_bottom_new"
);
_fix_bottom
.
show
();
$
(
'.shop-list'
).
show
();
$
(
"#fix_name"
).
html
(
_panfang_name
);
// $("#fix_tel").attr("href", "tel:" + _tel).html(_tel);
$
(
"#fix_tel"
).
attr
(
"href"
,
"tel:"
+
_panfang_tel
);
if
(
_panfang_img
){
$
(
".head-img-agent"
).
attr
(
"src"
,
_panfang_img
);
}
else
{
$
(
".head-img-agent"
).
attr
(
"src"
,
"/app/images/ic_default_headpic.png"
);
}
//点击拨打 记录拨打次数 朱威
$
(
"#fix_tel"
).
click
(
function
()
{
var
time
=
localStorage
.
getItem
(
_shangpuId
+
"_"
+
_tel
);
var
nowTime
=
(
new
Date
()).
getTime
();
if
(
!
time
||
nowTime
-
time
>
24
*
3600
*
1000
){
$
.
ajax
({
url
:
'/api/addUserCallAgentV2'
,
type
:
'POST'
,
async
:
true
,
data
:
{
'phone'
:
_tel
,
'source'
:
generalize_id
},
dataType
:
'json'
,
success
:
function
(
data
)
{
localStorage
.
setItem
(
_shangpuId
+
"_"
+
_tel
,(
new
Date
()).
getTime
());
}
});
}
});
$
(
"#fix_tel"
).
click
(
function
()
{
var
_time
=
localStorage
.
getItem
(
_tel
+
"_"
+
_shangpuId
);
var
_nowTime
=
(
new
Date
()).
getTime
();
if
(
!
_time
||
_nowTime
-
_time
>
24
*
3600
*
1000
){
$
.
ajax
({
url
:
'/api/recordCallNumShare'
,
type
:
'POST'
,
async
:
true
,
data
:
{
'phone'
:
_tel
// 'generalize_id':generalize_id
},
dataType
:
'json'
,
success
:
function
(
data
)
{
localStorage
.
setItem
(
_tel
+
"_"
+
_shangpuId
,(
new
Date
()).
getTime
());
}
});
}
});
$
(
"#fix_area_bottom_btn"
).
click
(
function
()
{
_fix_bottom
.
hide
();
});
//点击 商铺详情的 更多商铺
$
(
'.shop-list'
).
click
(
function
()
{
location
.
href
=
ServerHost
+
"/app/dist/#/shopList?city="
+
p_city
+
'&type='
+
p_type
+
'&p_district_id='
+
p_district_id
+
'&p_store_id='
+
p_store_id
+
'&p_agent_id='
+
p_agent_id
;
});
};
//经纪人 商铺列表 微门店
if
(
_name
||
_tel
)
{
var
_fix_bottom
=
$
(
".fix_area_bottom_new"
);
_fix_bottom
.
show
();
...
...
@@ -284,7 +362,6 @@
$
(
".head-img-agent"
).
attr
(
"src"
,
"/app/images/ic_default_headpic.png"
);
}
//点击拨打 记录拨打次数 朱威
$
(
"#fix_tel"
).
click
(
function
()
{
var
time
=
localStorage
.
getItem
(
_shangpuId
+
"_"
+
_tel
);
...
...
public/appnew/src/components/shop/shopList.vue
View file @
04856007
...
...
@@ -2,7 +2,7 @@
<div
class=
"min-height-list"
>
<nav>
<div
class=
"top-city-select-area flex-center"
>
<select
@
change=
"changeCity"
>
<select
@
change=
"changeCity"
v-model=
"initSelectCity"
>
<option
value=
"上海市"
>
上海市
</option>
<option
value=
"杭州市"
>
杭州市
</option>
<option
value=
"深圳市"
>
深圳市
</option>
...
...
@@ -130,6 +130,11 @@
initTabNumArea
:
0
,
initTabNumRent
:
0
,
initSelectCity
:
'上海市'
,
p_district_id
:
''
,
p_store_id
:
''
,
p_agent_id
:
''
,
site_area
:
2
,
generalizeId
:
1
,
initTabNumAreaCity
:
0
,
initTabNumBusiness
:
0
,
initMoreNum
:
0
,
...
...
@@ -164,6 +169,15 @@
}),
created
()
{
let
_this
=
this
;
if
(
_this
.
$route
.
query
.
city
){
_this
.
initSelectCity
=
decodeURIComponent
(
_this
.
$route
.
query
.
city
);
_this
.
initTabNumMain
=
_this
.
$route
.
query
.
type
*
1
==
1
?
0
:
1
;
_this
.
p_district_id
=
_this
.
$route
.
query
.
p_district_id
;
_this
.
p_store_id
=
_this
.
$route
.
query
.
p_store_id
;
_this
.
p_agent_id
=
_this
.
$route
.
query
.
p_agent_id
;
_this
.
generalizeId
=
_this
.
$route
.
query
.
generalizeId
;
_this
.
site_area
=
6
;
}
_this
.
getChooseList
();
_this
.
common
.
duringRequest
({
'urlStr'
:
'/api/getShopList'
,
...
...
@@ -188,10 +202,23 @@
var
_data
=
{};
_data
.
pageSize
=
_this
.
pageSize
;
_data
.
pageNo
=
_this
.
mainData
[
_index
].
page
;
_data
.
site_area
=
2
;
// _data.site_area = 2;
_data
.
site_area
=
_this
.
site_area
;
_data
.
is_carefully_chosen
=
0
;
_data
.
shop_type
=
_this
.
initTabNumMain
?
0
:
1
;
_data
.
city
=
_this
.
initSelectCity
;
//pc h5推广 部门id 门店id 经纪人id
if
(
_this
.
p_district_id
){
_data
.
p_district_id
=
_this
.
p_district_id
;
};
if
(
_this
.
p_store_id
){
_data
.
p_store_id
=
_this
.
p_store_id
;
};
if
(
_this
.
p_agent_id
){
_data
.
p_agent_id
=
_this
.
p_agent_id
;
};
if
(
_this
.
ajax_shop_area_start
){
_data
.
shop_area_start
=
_this
.
ajax_shop_area_start
;
};
...
...
@@ -226,7 +253,17 @@
.
then
(
function
(
response
)
{
_this
.
mainData
[
_index
].
isLoadOnce
=
true
;
if
(
response
.
data
.
code
==
200
)
{
let
_list
=
response
.
data
.
data
;
if
(
_this
.
$route
.
query
.
city
){
if
(
response
.
data
.
data
.
list
){
var
_list
=
response
.
data
.
data
.
list
;
}
else
{
var
_list
=
response
.
data
.
data
;
}
}
else
{
var
_list
=
response
.
data
.
data
;
}
if
(
Array
.
isArray
(
_list
)){
if
(
_list
.
length
===
0
)
{
_this
.
mainData
[
_index
].
page
===
1
&&
(
_this
.
mainData
[
_index
].
noDataFlag
=
true
);
...
...
@@ -424,10 +461,16 @@
_this
.
ajaxShopSign
=
_this
.
arrShop
.
join
(
','
);
},
toShopDetail
(
id
){
var
user_img
=
localStorage
.
getItem
(
'shop_list_b_user_img'
);
var
user_name
=
localStorage
.
getItem
(
'shop_list_b_user'
);
var
user_tel
=
localStorage
.
getItem
(
'shop_list_b_user_tel'
);
var
str
=
this
.
common
.
ServerHost
+
"/index/shareShop?id="
+
id
+
'&share=1&isC=0&client=b&user_name='
+
user_name
+
'&user_img='
+
user_img
+
'&user_tel='
+
user_tel
;
let
_this
=
this
;
//从推广链接 跳转
if
(
_this
.
$route
.
query
.
city
){
var
str
=
this
.
common
.
ServerHost
+
"/index/shareShop?id="
+
id
+
'&share=1&isC=0&client=b&city='
+
_this
.
$route
.
query
.
city
+
'&type='
+
_this
.
$route
.
query
.
type
+
'&p_district_id='
+
_this
.
$route
.
query
.
p_district_id
+
'&p_store_id='
+
_this
.
$route
.
query
.
p_store_id
+
'&p_agent_id='
+
_this
.
$route
.
query
.
p_agent_id
+
'&generalizeId='
+
_this
.
$route
.
query
.
generalizeId
;
}
else
{
var
user_img
=
localStorage
.
getItem
(
'shop_list_b_user_img'
);
var
user_name
=
localStorage
.
getItem
(
'shop_list_b_user'
);
var
user_tel
=
localStorage
.
getItem
(
'shop_list_b_user_tel'
);
var
str
=
this
.
common
.
ServerHost
+
"/index/shareShop?id="
+
id
+
'&share=1&isC=0&client=b&user_name='
+
user_name
+
'&user_img='
+
user_img
+
'&user_tel='
+
user_tel
;
}
// var str = this.common.ServerHost + "/app.php/app/share_detail?id=" + id +'&share=1&isC=0&client=b&user_name=' + user_name +'&user_img=' + user_img +'&user_tel=' + user_tel;
location
.
href
=
str
;
...
...
public/resource/js/houseList.js
View file @
04856007
...
...
@@ -42,6 +42,8 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
file_id_arr
:[],
agent_id_choose
:
''
,
agent_id_choose_p
:
''
,
generalize_id
:
1
,
detailTabIndexTuiGuang
:
0
,
init
:
function
()
{
//初始化dot
...
...
@@ -144,6 +146,42 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
_doc
.
delegate
(
".addphone-agent"
,
"click"
,
function
()
{
//客户列表 客户员工 下拉式 搜索 点击li事件 获取id ul消失
business
.
addphoneAgent
(
this
);
});
//切换 不同的推广 类型
_doc
.
on
(
'click'
,
'.tuiguang-type>a'
,
function
(
e
){
e
.
preventDefault
();
e
.
stopPropagation
();
var
_this
=
$
(
this
);
_this
.
removeClass
(
'btn-default'
).
addClass
(
'btn-info'
).
siblings
().
removeClass
(
'btn-info'
).
addClass
(
'btn-default'
);
business
.
detailTabIndexTuiGuang
=
_this
.
index
();
if
(
business
.
detailTabIndexTuiGuang
==
0
){
business
.
generalize_id
=
1
;
};
if
(
business
.
detailTabIndexTuiGuang
==
1
){
business
.
generalize_id
=
3
;
};
if
(
business
.
detailTabIndexTuiGuang
==
2
){
business
.
generalize_id
=
2
;
};
if
(
business
.
detailTabIndexTuiGuang
==
3
){
business
.
generalize_id
=
4
;
};
var
p_district_id
=
$
(
'#district_id_panfang'
).
val
();
var
p_store_id
=
$
(
'#guest_stores_panfang'
).
val
();
var
p_agent_id
=
business
.
agent_id_choose_p
;
var
type
=
$
(
'#shop_type'
).
val
();
var
city
=
$
(
'.shop_city_choose_site_list'
).
val
();
if
(
p_store_id
==
null
){
p_store_id
=
''
;
}
var
_shopLink
=
'https://www.tonglianjituan.com/shop_link.html?'
+
'p_district_id'
+
'='
+
p_district_id
+
'&'
+
'p_store_id'
+
'='
+
p_store_id
+
'&'
+
'p_agent_id'
+
'='
+
p_agent_id
+
'&'
+
'type'
+
'='
+
(
type
==
-
1
?
1
:
type
)
+
'&'
+
'city'
+
'='
+
encodeURIComponent
(
city
==
""
?
'上海市'
:
city
)
+
'&'
+
'generalizeId'
+
'='
+
business
.
generalize_id
;
if
(
p_district_id
||
p_store_id
||
p_agent_id
){
$
(
'#link_content'
).
html
(
_shopLink
);
}
else
{
$
(
'#link_content'
).
html
(
'进行部门 门店 个人筛选 才会有 推广链接产生'
);
}
});
_doc
.
on
(
'click'
,
'.link_shop_c'
,
function
(
e
)
{
e
.
preventDefault
();
e
.
stopPropagation
();
...
...
@@ -155,7 +193,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
if
(
p_store_id
==
null
){
p_store_id
=
''
;
}
var
_shopLink
=
'https://www.tonglianjituan.com/shop_link.html?'
+
'p_district_id'
+
'='
+
p_district_id
+
'&'
+
'p_store_id'
+
'='
+
p_store_id
+
'&'
+
'p_agent_id'
+
'='
+
p_agent_id
+
'&'
+
'type'
+
'='
+
(
type
==
-
1
?
1
:
type
)
+
'&'
+
'city'
+
'='
+
e
scape
(
city
==
""
?
'上海市'
:
city
)
;
var
_shopLink
=
'https://www.tonglianjituan.com/shop_link.html?'
+
'p_district_id'
+
'='
+
p_district_id
+
'&'
+
'p_store_id'
+
'='
+
p_store_id
+
'&'
+
'p_agent_id'
+
'='
+
p_agent_id
+
'&'
+
'type'
+
'='
+
(
type
==
-
1
?
1
:
type
)
+
'&'
+
'city'
+
'='
+
e
ncodeURIComponent
(
city
==
""
?
'上海市'
:
city
)
+
'&'
+
'generalizeId'
+
'='
+
business
.
generalize_id
;
if
(
p_district_id
||
p_store_id
||
p_agent_id
){
$
(
'#link_content'
).
html
(
_shopLink
);
}
else
{
...
...
@@ -173,6 +211,7 @@ define(['doT', 'text!temp/house_template_tpl.html', 'css!style/home.css', 'ckfin
document
.
execCommand
(
"Copy"
);
alert
(
"复制成功!"
);
});
//部门 门店 二级联动
business
.
getDistrictPanFang
(
function
(){
//有了列表 点击 调用门店列表
_doc
.
on
(
'input'
,
'#district_id_panfang'
,
function
(){
...
...
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