Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
梁建民
/
h5
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
5e48c457
authored
May 21, 2019
by
施宇
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
h5自营
parent
d3987db0
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
239 deletions
.gitignore
src/store/modules/xianhuo/xianhuo.js
src/views/xianhuo/xianhuo.vue
view/index.html
.gitignore
View file @
5e48c457
...
...
@@ -19,3 +19,4 @@ yarn-error.log*
*.sln
*.sw*
/view
/view
src/store/modules/xianhuo/xianhuo.js
View file @
5e48c457
...
...
@@ -18,7 +18,8 @@ const state = {
classLight
:
{},
zyFilterData
:
{},
//过滤数据
zyData
:
[],
total
:
0
,
loading
:
false
,
finished
:
false
}
const
mutations
=
{
xianhuo
(
state
,
payload
)
{
...
...
@@ -33,7 +34,7 @@ const mutations = {
}
else
if
(
payload
.
type
==
"class_light"
)
{
state
.
classLight
=
payload
.
data
;
}
else
if
(
payload
.
type
==
"zydata"
)
{
state
.
zyData
=
payload
.
data
state
.
zyData
=
state
.
zyData
.
concat
(
payload
.
data
)
}
}
}
...
...
@@ -41,10 +42,14 @@ const actions = {
getZyData
({
commit
},
payload
)
{
state
.
loading
=
true
;
state
.
finished
=
false
;
let
p
=
payload
.
data
.
params
;
console
Services
.
getZyData
(
qs
.
stringify
(
payload
.
data
)).
then
((
res
)
=>
{
state
.
loading
=
false
;
let
data
=
res
.
data
;
if
(
data
.
error_code
==
0
)
{
state
.
total
=
data
.
data
.
total
;
if
(
data
.
data
.
aggs
)
{
commit
(
"xianhuo"
,
{
//过滤数据
type
:
"filter"
,
...
...
@@ -83,6 +88,7 @@ const actions = {
}
}).
catch
(
function
(
err
)
{
state
.
loading
=
false
;
});
}
}
...
...
src/views/xianhuo/xianhuo.vue
View file @
5e48c457
...
...
@@ -143,12 +143,10 @@
</div>
<div
class=
"content_scroll"
>
<van-list
v-model=
"loading"
v-model=
"loading
Xh
"
:finished=
"finished"
finished-text=
"我是有底线的噢"
@
load=
"onLoad"
error-text=
"请求失败,点击重新加载"
:immediate-check=
"true"
>
<GoodsOne
:dataList=
"zyData"
></GoodsOne>
</van-list>
...
...
@@ -203,9 +201,8 @@ export default {
isResetData
:
false
,
//是否重置数据
isShowRight
:
false
,
//是否展示右侧
list
:
[],
loading
:
false
,
finished
:
false
,
p
:
1
loadingXh
:
false
,
p
:
0
};
},
created
()
{},
...
...
@@ -218,10 +215,15 @@ export default {
classLight
:
state
=>
state
.
xianhuo
.
classLight
,
zyFilterData
:
state
=>
state
.
xianhuo
.
zyFilterData
,
zyData
:
state
=>
state
.
xianhuo
.
zyData
,
total
:
state
=>
state
.
xianhuo
.
total
total
:
state
=>
state
.
xianhuo
.
total
,
loading
:
state
=>
state
.
xianhuo
.
loading
,
finished
:
state
=>
state
.
xianhuo
.
finished
})
},
watch
:
{
loading
(
now
)
{
this
.
loadingXh
=
now
;
},
zyRankInit
(
now
)
{
this
.
getZyData
();
},
...
...
@@ -244,6 +246,8 @@ export default {
},
methods
:
{
onLoad
()
{
console
.
log
(
this
.
loadingXh
);
this
.
p
++
;
this
.
getZyData
();
},
toSearch
()
{},
...
...
@@ -298,7 +302,7 @@ export default {
}
},
getZyData
(
rightFilter
=
{})
{
let
params
=
{
p
:
1
,
offset
:
10
};
let
params
=
{
p
:
this
.
p
,
offset
:
10
};
let
rightFilterStr
=
JSON
.
stringify
(
rightFilter
);
if
(
this
.
addClassStr
)
{
params
[
"class_id/condition"
]
=
this
.
addClassStr
;
...
...
view/index.html
deleted
100644 → 0
View file @
d3987db0
<!DOCTYPE HTML>
<html
lang=
zh-CN
><head><title></title><meta
name=
author
content=
www.ichunt.com
><meta
name=
viewport
content=
"width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0,user-scalable=no,minimal-ui"
><meta
http-equiv=
Content-Type
content=
"text/html;charset=utf-8"
><meta
name=
apple-mobile-web-app-capable
content=
yes
><meta
name=
apple-mobile-web-app-status-bar-style
content=
black
><meta
name=
format-detection
content=
"telephone=no"
><meta
http-equiv=
Expires
content=
-1
><meta
http-equiv=
Cache-Control
content=
no-cache
><meta
http-equiv=
Pragma
content=
no-cache
><meta
name=
full-screen
content=
yes
><meta
name=
browsermode
content=
application
><meta
name=
x5-fullscreen
content=
true
><meta
name=
x5-page-mode
content=
app
><meta
name=
description
content=
猎芯网,快速成长的专业电子元器件商城,贸泽(MOUSER)全系产品、e络盟(element14)树莓派系列产品授权经销商,已获得多轮风险投资。为客户提供电子元器件现货,IC采购,进口报关,电子元器件寄售,供应链金融等一站式电子元器件采购服务。
><meta
name=
keywords
content=
猎芯网,电子元器件采购,电子元器件商城,电子元器件现货,IC采购网,电子元器件寄售,电子元件,元器件商城,元器件采购,电子商城,
><link
rel=
icon
href=
//h5static.ichunt.com/favicon.ico
><link
rel=
stylesheet
href=
/v3/dist/res/m/css/font/iconfont.css
><script
src=
/h5/view/get_time.php
></script><script>
var
fwtimes
=
window
.
fwtime
-
(
Math
.
floor
((
new
Date
().
getTime
())
/
1000
));
//获取服务器时间差
</script><script
src=
https://res.wx.qq.com/open/js/jweixin-1.3.2.js
charset=
utf-8
></script><script
src=
//h5static.ichunt.com/static/js/flexible.min.js
charset=
utf-8
></script><script
src=
//h5static.ichunt.com/static/js/shence.min.js
charset=
utf-8
></script><link
href=
//h5static.ichunt.com/css/chunk-0152a94c.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-0528a41a.b6a6f279.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-0ccaff37.9a3ef394.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-0d688f2e.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-111df22d.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-13b2a374.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-15480d0d.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-158c3ed4.fe46872f.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-178fc040.dcbf5852.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-19601764.39b0c29e.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-1c9625fe.746ec6f3.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-22e40ede.f7670042.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-23e7944a.c8649411.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-2d4f397c.2ba08771.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-2f5da85a.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-34076066.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-3479b5a0.80056bad.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-3765c3c6.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-41226dfb.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-4631de92.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-50997173.2a594d86.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-5474cc08.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-5cf16964.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-6be99e9a.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-73b3e1a8.e137fec1.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-7ca9fe78.46303413.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-86ed5d90.384460bb.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-8aab87ce.92647ec0.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-8ce0ddd0.22356d82.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-978da802.b12435d8.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-a99dec30.58a2ea9a.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/chunk-f9d0f84e.5dae5cb6.css
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-0152a94c.424b4dad.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-0528a41a.63b26c50.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-0ccaff37.f1a1243c.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-0d688f2e.2cf30008.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-111df22d.362d0434.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-13b2a374.6bf5cf12.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-15480d0d.663f4dc4.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-158c3ed4.e23f68f8.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-178fc040.31454c37.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-19601764.13723fe7.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-1c9625fe.f62130c0.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-22e40ede.9da1ca2d.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-23e7944a.2d323e2e.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-2d4f397c.c648404a.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-2f5da85a.5966be84.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-34076066.4fdb5495.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-3479b5a0.5876e3a4.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-3765c3c6.af00f17d.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-41226dfb.51dee55e.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-4631de92.a33e31ea.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-50997173.c05debec.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-5474cc08.2b947dd4.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-5cf16964.60a9c936.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-6be99e9a.4f1c9253.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-73b3e1a8.4ebace5c.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-7ca9fe78.491de515.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-86ed5d90.c343029a.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-8aab87ce.48bd60ce.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-8ce0ddd0.6edd0622.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-978da802.42957bde.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-a99dec30.890be1d3.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/js/chunk-f9d0f84e.a9225526.js
rel=
prefetch
><link
href=
//h5static.ichunt.com/css/app.d18d399e.css
rel=
preload
as=
style
><link
href=
//h5static.ichunt.com/css/chunk-vendors.4a9b0375.css
rel=
preload
as=
style
><link
href=
//h5static.ichunt.com/js/app.a6a7fe52.js
rel=
preload
as=
script
><link
href=
//h5static.ichunt.com/js/chunk-vendors.6f48e8b1.js
rel=
preload
as=
script
><link
href=
//h5static.ichunt.com/css/chunk-vendors.4a9b0375.css
rel=
stylesheet
><link
href=
//h5static.ichunt.com/css/app.d18d399e.css
rel=
stylesheet
></head><body
class=
boxsiz
><noscript><strong>
网站出现了一点小问题,正在紧急修复中.......
</strong></noscript><div
id=
app
></div><script>
function
SetCookie
(
name
,
value
,
time
,
domain
)
{
domain
=
domain
?
";domain="
+
domain
:
""
;
var
Days
=
time
;
var
exp
=
new
Date
();
exp
.
setTime
(
exp
.
getTime
()
+
Days
*
24
*
60
*
60
*
1000
);
document
.
cookie
=
name
+
"="
+
encodeURIComponent
(
value
)
+
";expires="
+
exp
.
toGMTString
()
+
";path=/"
+
domain
;
return
true
;
}
function
getCookie
(
name
)
{
var
arr
=
document
.
cookie
.
match
(
new
RegExp
(
"(^| )"
+
name
+
"=([^;]*)(;|$)"
));
if
(
arr
!=
null
)
return
unescape
(
arr
[
2
]);
return
null
;
}
function
delCookie
(
name
)
{
var
exp
=
new
Date
();
exp
.
setTime
(
exp
.
getTime
()
-
1
);
var
cval
=
getCookie
(
name
);
if
(
cval
!=
null
)
document
.
cookie
=
name
+
"="
+
cval
+
";expires="
+
exp
.
toGMTString
();
}
var
cookiex
=
getCookie
(
"Yo4teW_csrf"
)
||
""
,
csrf
=
"csrf"
;
var
cookieHostname
=
window
.
location
.
hostname
.
split
(
"."
)[
1
]
+
"."
+
window
.
location
.
hostname
.
split
(
"."
)[
2
];
var
browser
=
{
versions
:
function
()
{
var
u
=
navigator
.
userAgent
,
app
=
navigator
.
appVersion
;
return
{
//移动终端浏览器版本信息
trident
:
u
.
indexOf
(
'Trident'
)
>
-
1
,
//IE内核
presto
:
u
.
indexOf
(
'Presto'
)
>
-
1
,
//opera内核
webKit
:
u
.
indexOf
(
'AppleWebKit'
)
>
-
1
,
//苹果、谷歌内核
gecko
:
u
.
indexOf
(
'Gecko'
)
>
-
1
&&
u
.
indexOf
(
'KHTML'
)
==
-
1
,
//火狐内核
mobile
:
!!
u
.
match
(
/AppleWebKit.*Mobile.*/
),
//是否为移动终端
ios
:
!!
u
.
match
(
/
\(
i
[^
;
]
+;
(
U;
)?
CPU.+Mac OS X/
),
//ios终端
android
:
u
.
indexOf
(
'Android'
)
>
-
1
||
u
.
indexOf
(
'Linux'
)
>
-
1
,
//android终端或uc浏览器
iPhone
:
u
.
indexOf
(
'iPhone'
)
>
-
1
,
//是否为iPhone或者QQHD浏览器
iPad
:
u
.
indexOf
(
'iPad'
)
>
-
1
,
//是否iPad
webApp
:
u
.
indexOf
(
'Safari'
)
==
-
1
//是否web应该程序,没有头部与底部
};
}(),
language
:
(
navigator
.
browserLanguage
||
navigator
.
language
).
toLowerCase
()
}
//判断是否在微信小程序打开
function
is_miniProgram
()
{
if
(
window
.
__wxjs_environment
===
'miniprogram'
)
{
SetCookie
(
"Yo4teW_miniProgram"
,
true
,
1
,
cookieHostname
);
return
true
;
}
else
{
SetCookie
(
"Yo4teW_miniProgram"
,
false
,
1
,
cookieHostname
);
return
false
;
}
}
if
(
!
window
.
WeixinJSBridge
||
!
WeixinJSBridge
.
invoke
)
{
document
.
addEventListener
(
'WeixinJSBridgeReady'
,
is_miniProgram
,
false
);
}
else
{
is_miniProgram
();
}
if
(
getCookie
(
"Yo4teW_miniProgram"
)
!==
'true'
)
{
var
isMiniProgram
=
is_miniProgram
();
//二次确认
wx
.
miniProgram
.
getEnv
(
function
(
res
)
{
if
(
res
.
miniprogram
==
true
)
{
isMiniProgram
=
res
.
miniprogram
SetCookie
(
"Yo4teW_miniProgram"
,
true
,
1
,
cookieHostname
);
}
else
{
SetCookie
(
"Yo4teW_miniProgram"
,
false
,
1
,
cookieHostname
);
}
if
(
isMiniProgram
)
{
lxpf
=
6
;
}
})
}
else
{
isMiniProgram
=
true
}
var
lxpf
=
2
;
if
(
isMiniProgram
)
{
lxpf
=
6
;
}
//百度统计
var
_hmt
=
_hmt
||
[];
(
function
()
{
var
hm
=
document
.
createElement
(
"script"
);
hm
.
src
=
"https://hm.baidu.com/hm.js?0c48775abb60d7d7aeb4343bca7a239b"
;
document
.
getElementsByTagName
(
'head'
)[
0
].
appendChild
(
hm
);
})();
//腾讯统计
var
host_v
=
window
.
location
.
host
;
if
(
host_v
==
"m.ichunt.com"
)
{
if
(
isMiniProgram
)
{
var
_mtac
=
{};
(
function
()
{
var
mta
=
document
.
createElement
(
"script"
);
mta
.
src
=
"//pingjs.qq.com/h5/stats.js?v2.0.4"
;
mta
.
setAttribute
(
"name"
,
"MTAH5"
);
mta
.
setAttribute
(
"sid"
,
"500626053"
);
var
s
=
document
.
getElementsByTagName
(
"script"
)[
0
];
s
.
parentNode
.
insertBefore
(
mta
,
s
);
})();
}
else
{
var
_mtac
=
{
"performanceMonitor"
:
1
,
"senseQuery"
:
1
};
(
function
()
{
var
mta
=
document
.
createElement
(
"script"
);
mta
.
src
=
"//pingjs.qq.com/h5/stats.js?v2.0.4"
;
mta
.
setAttribute
(
"name"
,
"MTAH5"
);
mta
.
setAttribute
(
"sid"
,
"500482933"
);
mta
.
setAttribute
(
"cid"
,
"500485800"
);
document
.
getElementsByTagName
(
'head'
)[
0
].
appendChild
(
mta
);
})();
}
}
</script><script>
//神策统计
var
host_v
=
window
.
location
.
host
;
var
__PUBLIC__
;
switch
(
window
.
location
.
hostname
)
{
case
"www.ichunt.com"
:
__PUBLIC__
=
'//static.ichunt.com/dist'
;
break
;
case
"m.ichunt.com"
:
__PUBLIC__
=
'//static.ichunt.com/dist'
;
break
;
case
"sz.ichunt.com"
:
__PUBLIC__
=
'/v3/dist'
;
break
;
case
"szm.ichunt.com"
:
__PUBLIC__
=
'/v3/dist'
;
break
;
case
"t.ichunt.com"
:
__PUBLIC__
=
'//t.ichunt.com/v3/dist'
;
break
;
case
"tm.ichunt.com"
:
__PUBLIC__
=
'//t.ichunt.com/v3/dist'
;
break
;
case
"www.liexin.com"
:
__PUBLIC__
=
'/dist'
;
break
;
default
:
__PUBLIC__
=
'//res.liexin.com/dist'
;
}
if
(
host_v
==
"m.ichunt.com"
||
host_v
==
"sc.ichunt.com"
)
{
(
function
(
para
)
{
var
p
=
para
.
sdk_url
,
n
=
para
.
name
,
w
=
window
,
d
=
document
,
s
=
'script'
,
x
=
null
,
y
=
null
;
if
(
typeof
(
w
[
'sensorsDataAnalytic201505'
])
!==
'undefined'
)
{
return
false
;
}
w
[
'sensorsDataAnalytic201505'
]
=
n
;
w
[
n
]
=
w
[
n
]
||
function
(
a
)
{
return
function
()
{
(
w
[
n
].
_q
=
w
[
n
].
_q
||
[]).
push
([
a
,
arguments
]);
}
};
var
ifs
=
[
'track'
,
'quick'
,
'register'
,
'registerPage'
,
'registerOnce'
,
'trackSignup'
,
'trackAbtest'
,
'setProfile'
,
'setOnceProfile'
,
'appendProfile'
,
'incrementProfile'
,
'deleteProfile'
,
'unsetProfile'
,
'identify'
,
'login'
,
'logout'
,
'trackLink'
,
'clearAllRegister'
,
'getAppStatus'
];
for
(
var
i
=
0
;
i
<
ifs
.
length
;
i
++
)
{
w
[
n
][
ifs
[
i
]]
=
w
[
n
].
call
(
null
,
ifs
[
i
]);
}
if
(
!
w
[
n
].
_t
)
{
x
=
d
.
createElement
(
s
),
y
=
d
.
getElementsByTagName
(
s
)[
0
];
x
.
async
=
1
;
x
.
src
=
p
;
x
.
setAttribute
(
'charset'
,
'UTF-8'
);
y
.
parentNode
.
insertBefore
(
x
,
y
);
w
[
n
].
para
=
para
;
}
})({
sdk_url
:
__PUBLIC__
+
'/res/m/js/global/sensorsdata.min.js'
,
heatmap_url
:
__PUBLIC__
+
'/res/m/js/global/heatmap.min.js'
,
name
:
'sensors'
,
server_url
:
'https://shence.ichunt.com:4006/sa?project=production'
,
heatmap
:
{}
});
//以异步加载 SDK 为例,神策 SDK 初始化完成,此时调用设置公共属性的方法,来保证之后的事件都有这两个属性。
sensors
.
registerPage
({
current_url
:
location
.
href
,
referrer
:
document
.
referrer
,
platformType
:
'2'
,
//H5
is_login
:
(
getCookie
(
"Yo4teW_uid"
)
?
true
:
false
),
user_rank
:
'0'
});
sensors
.
quick
(
'autoTrack'
);
}
else
{
(
function
(
para
)
{
var
p
=
para
.
sdk_url
,
n
=
para
.
name
,
w
=
window
,
d
=
document
,
s
=
'script'
,
x
=
null
,
y
=
null
;
if
(
typeof
(
w
[
'sensorsDataAnalytic201505'
])
!==
'undefined'
)
{
return
false
;
}
w
[
'sensorsDataAnalytic201505'
]
=
n
;
w
[
n
]
=
w
[
n
]
||
function
(
a
)
{
return
function
()
{
(
w
[
n
].
_q
=
w
[
n
].
_q
||
[]).
push
([
a
,
arguments
]);
}
};
var
ifs
=
[
'track'
,
'quick'
,
'register'
,
'registerPage'
,
'registerOnce'
,
'trackSignup'
,
'trackAbtest'
,
'setProfile'
,
'setOnceProfile'
,
'appendProfile'
,
'incrementProfile'
,
'deleteProfile'
,
'unsetProfile'
,
'identify'
,
'login'
,
'logout'
,
'trackLink'
,
'clearAllRegister'
,
'getAppStatus'
];
for
(
var
i
=
0
;
i
<
ifs
.
length
;
i
++
)
{
w
[
n
][
ifs
[
i
]]
=
w
[
n
].
call
(
null
,
ifs
[
i
]);
}
if
(
!
w
[
n
].
_t
)
{
x
=
d
.
createElement
(
s
),
y
=
d
.
getElementsByTagName
(
s
)[
0
];
x
.
async
=
1
;
x
.
src
=
p
;
x
.
setAttribute
(
'charset'
,
'UTF-8'
);
y
.
parentNode
.
insertBefore
(
x
,
y
);
w
[
n
].
para
=
para
;
}
})({
sdk_url
:
__PUBLIC__
+
'/res/m/js/global/sensorsdata.min.js'
,
heatmap_url
:
__PUBLIC__
+
'__PUBLIC__/res/m/js/global/heatmap.min.js'
,
name
:
'sensors'
,
server_url
:
'https://shence.ichunt.com:4006/sa'
,
heatmap
:
{}
});
//以异步加载 SDK 为例,神策 SDK 初始化完成,此时调用设置公共属性的方法,来保证之后的事件都有这两个属性。
sensors
.
registerPage
({
current_url
:
location
.
href
,
referrer
:
document
.
referrer
,
platformType
:
'2'
,
//H5
is_login
:
(
getCookie
(
"Yo4teW_uid"
)
?
true
:
false
),
user_rank
:
'0'
});
sensors
.
quick
(
'autoTrack'
);
}
</script><script
src=
//h5static.ichunt.com/js/chunk-vendors.6f48e8b1.js
></script><script
src=
//h5static.ichunt.com/js/app.a6a7fe52.js
></script></body></html>
\ No newline at end of file
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