Commit 34d365d6 by 梁建民

init

parent bd7897f5
<?php
echo "var time =".time().";";
\ No newline at end of file
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
"@vue/cli-plugin-babel": "^3.3.0", "@vue/cli-plugin-babel": "^3.3.0",
"@vue/cli-service": "^3.3.0", "@vue/cli-service": "^3.3.0",
"node-sass": "^4.9.0", "node-sass": "^4.9.0",
"qs": "^6.6.0",
"sass-loader": "^7.0.1", "sass-loader": "^7.0.1",
"vue-template-compiler": "^2.5.21" "vue-template-compiler": "^2.5.21"
}, },
......
<?php
echo "var fwtime =".time().";";
\ No newline at end of file
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
<meta name="keywords" content="猎芯网,电子元器件采购,电子元器件商城,电子元器件现货,IC采购网,电子元器件寄售,电子元件,元器件商城,元器件采购,电子商城,"> <meta name="keywords" content="猎芯网,电子元器件采购,电子元器件商城,电子元器件现货,IC采购网,电子元器件寄售,电子元件,元器件商城,元器件采购,电子商城,">
<link rel="icon" href="<%= BASE_URL %>favicon.ico"> <link rel="icon" href="<%= BASE_URL %>favicon.ico">
<link rel="stylesheet" href="<%= BASE_URL %>static/iconfont.css"> <link rel="stylesheet" href="<%= BASE_URL %>static/iconfont.css">
<script type="text/javascript" src="get_time.php"></script>
<script src="https://res.wx.qq.com/open/js/jweixin-1.3.2.js" type="text/javascript" charset="utf-8"></script> <script src="https://res.wx.qq.com/open/js/jweixin-1.3.2.js" type="text/javascript" charset="utf-8"></script>
<script src="<%= BASE_URL %>static/flexible.min.js" type="text/javascript" charset="utf-8"></script> <script src="<%= BASE_URL %>static/flexible.min.js" type="text/javascript" charset="utf-8"></script>
</head> </head>
......
...@@ -44,11 +44,7 @@ export const apis = { ...@@ -44,11 +44,7 @@ export const apis = {
export const services = { export const services = {
index(params) { index(params) {
return axios.get(apis.index, { return axios.post(apis.index, params)
params: {
data: params
}
})
}, },
cartCount(params) { cartCount(params) {
return axios.get(apis.cartCount, { return axios.get(apis.cartCount, {
......
import Vue from 'vue' import Vue from 'vue'
import App from './App.vue' import App from './App.vue'
import axios from 'axios'
import {router} from './router'; import {router} from './router';
import store from './store/store' import store from './store/store'
import filters from './filters' import filters from './filters'
...@@ -11,6 +12,11 @@ import '@/assets/css/global.min.css' ...@@ -11,6 +12,11 @@ import '@/assets/css/global.min.css'
//过滤器遍历 //过滤器遍历
Object.keys(filters).forEach(key => Vue.filter(key, filters[key])); Object.keys(filters).forEach(key => Vue.filter(key, filters[key]));
//设置请求头
Vue.prototype.$http = axios;
axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded';
Vue.config.productionTip = true; Vue.config.productionTip = true;
new Vue({ new Vue({
......
...@@ -2,6 +2,7 @@ import Vue from 'vue' ...@@ -2,6 +2,7 @@ import Vue from 'vue'
import axios from 'axios' import axios from 'axios'
import {services as Services} from '../../api/index' import {services as Services} from '../../api/index'
import {Toast} from 'vant'; import {Toast} from 'vant';
import Util from '../../util/index';
Vue.use(Toast); Vue.use(Toast);
...@@ -17,7 +18,9 @@ const mutations = { ...@@ -17,7 +18,9 @@ const mutations = {
const actions = { const actions = {
index({commit}, payload) { index({commit}, payload) {
Services.index().then(function (res) { var params=Util.getParams();
Services.index(params).then(function (res) {
let data = res.data; let data = res.data;
if (data.err_code == 0) { if (data.err_code == 0) {
commit({ commit({
...@@ -42,3 +45,4 @@ export default { ...@@ -42,3 +45,4 @@ export default {
actions, actions,
getters getters
} }
var hexcase = 0;
var b64pad = "";
var chrsz = 8;
export function hex_sha1(s) {
return binb2hex(core_sha1(str2binb(s), s.length * chrsz))
}
export function b64_sha1(s) {
return binb2b64(core_sha1(str2binb(s), s.length * chrsz))
}
export function str_sha1(s) {
return binb2str(core_sha1(str2binb(s), s.length * chrsz))
}
export function hex_hmac_sha1(key, data) {
return binb2hex(core_hmac_sha1(key, data))
}
export function b64_hmac_sha1(key, data) {
return binb2b64(core_hmac_sha1(key, data))
}
export function str_hmac_sha1(key, data) {
return binb2str(core_hmac_sha1(key, data))
}
export function sha1_vm_test() {
return hex_sha1("abc") == "a9993e364706816aba3e25717850c26c9cd0d89d"
}
export function core_sha1(x, len) {
x[len >> 5] |= 0x80 << (24 - len % 32);
x[((len + 64 >> 9) << 4) + 15] = len;
var w = Array(80);
var a = 1732584193;
var b = -271733879;
var c = -1732584194;
var d = 271733878;
var e = -1009589776;
for (var i = 0; i < x.length; i += 16) {
var olda = a;
var oldb = b;
var oldc = c;
var oldd = d;
var olde = e;
for (var j = 0; j < 80; j++) {
if (j < 16) w[j] = x[i + j];
else w[j] = rol(w[j - 3] ^ w[j - 8] ^ w[j - 14] ^ w[j - 16], 1);
var t = safe_add(safe_add(rol(a, 5), sha1_ft(j, b, c, d)), safe_add(safe_add(e, w[j]), sha1_kt(j)));
e = d;
d = c;
c = rol(b, 30);
b = a;
a = t
}
a = safe_add(a, olda);
b = safe_add(b, oldb);
c = safe_add(c, oldc);
d = safe_add(d, oldd);
e = safe_add(e, olde)
}
return Array(a, b, c, d, e)
}
export function sha1_ft(t, b, c, d) {
if (t < 20) return (b & c) | ((~b) & d);
if (t < 40) return b ^ c ^ d;
if (t < 60) return (b & c) | (b & d) | (c & d);
return b ^ c ^ d
}
export function sha1_kt(t) {
return (t < 20) ? 1518500249 : (t < 40) ? 1859775393 : (t < 60) ? -1894007588 : -899497514
}
export function core_hmac_sha1(key, data) {
var bkey = str2binb(key);
if (bkey.length > 16) bkey = core_sha1(bkey, key.length * chrsz);
var ipad = Array(16),
opad = Array(16);
for (var i = 0; i < 16; i++) {
ipad[i] = bkey[i] ^ 0x36363636;
opad[i] = bkey[i] ^ 0x5C5C5C5C
}
var hash = core_sha1(ipad.concat(str2binb(data)), 512 + data.length * chrsz);
return core_sha1(opad.concat(hash), 512 + 160)
}
export function safe_add(x, y) {
var lsw = (x & 0xFFFF) + (y & 0xFFFF);
var msw = (x >> 16) + (y >> 16) + (lsw >> 16);
return (msw << 16) | (lsw & 0xFFFF)
}
export function rol(num, cnt) {
return (num << cnt) | (num >>> (32 - cnt))
}
export function str2binb(str) {
var bin = Array();
var mask = (1 << chrsz) - 1;
for (var i = 0; i < str.length * chrsz; i += chrsz) bin[i >> 5] |= (str.charCodeAt(i / chrsz) & mask) << (24 - i % 32);
return bin
}
export function binb2str(bin) {
var str = "";
var mask = (1 << chrsz) - 1;
for (var i = 0; i < bin.length * 32; i += chrsz) str += String.fromCharCode((bin[i >> 5] >>> (24 - i % 32)) & mask);
return str
}
export function binb2hex(binarray) {
var hex_tab = hexcase ? "0123456789ABCDEF" : "0123456789abcdef";
var str = "";
for (var i = 0; i < binarray.length * 4; i++) {
str += hex_tab.charAt((binarray[i >> 2] >> ((3 - i % 4) * 8 + 4)) & 0xF) + hex_tab.charAt((binarray[i >> 2] >> ((3 - i % 4) * 8)) & 0xF)
}
return str
}
export function binb2b64(binarray) {
var tab = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
var str = "";
for (var i = 0; i < binarray.length * 4; i += 3) {
var triplet = (((binarray[i >> 2] >> 8 * (3 - i % 4)) & 0xFF) << 16) | (((binarray[i + 1 >> 2] >> 8 * (3 - (i + 1) % 4)) & 0xFF) << 8) | ((binarray[i + 2 >> 2] >> 8 * (3 - (i + 2) % 4)) & 0xFF);
for (var j = 0; j < 4; j++) {
if (i * 8 + j * 6 > binarray.length * 32) str += b64pad;
else str += tab.charAt((triplet >> 6 * (3 - j)) & 0x3F)
}
}
return str
}
\ No newline at end of file
import {hex_sha1} from '../util/des';
import filters from "../filters";
var qs = require('qs');
export default { export default {
/** /**
* 设置cookie * 设置cookie
...@@ -5,16 +10,13 @@ export default { ...@@ -5,16 +10,13 @@ export default {
* @param value * @param value
* @param iDay * @param iDay
*/ */
setCookie: function (name, value, iDay, type) { setCookie: function (name, value, time, domain) {
var oDate = new Date(); domain = domain ? ";domain=" + domain : "";
if (type == 1) { var Days = time;
var expires = new Date(); var exp = new Date();
expires.setTime(oDate.getTime() + 1000 * 60 * 60 * 24); exp.setTime(exp.getTime() + Days * 24 * 60 * 60 * 1000);
document.cookie = name + '=' + value + ';expires=' + expires.toGMTString(); document.cookie = name + "=" + encodeURIComponent(value) + ";expires=" + exp.toGMTString() + ";path=/" + domain;
} else { return true;
oDate.setDate(oDate.getDate() + iDay);
document.cookie = name + '=' + value + ';expires=' + oDate;
}
}, },
/** /**
* 获取cookie * 获取cookie
...@@ -42,5 +44,56 @@ export default { ...@@ -42,5 +44,56 @@ export default {
var cval = this.getCookie(name); var cval = this.getCookie(name);
if (cval != null) if (cval != null)
document.cookie = name + "=" + cval + ";expires=" + exp.toGMTString(); document.cookie = name + "=" + cval + ";expires=" + exp.toGMTString();
},
/**
* 加密token
*/
getParams(params) {
var fwtimes = window.fwtime - Math.floor((new Date().getTime()) / 1000);
var qwertyuiop = Math.floor((new Date().getTime()) / 1000) + fwtimes;
var Yo4teW_gid = getCookie('Yo4teW_gid');
var abb = [];
var abbo = {};
var asdfghjkl = '';
var appx = '';
var aggx = '';
var as = {
pf: 2,
qwertyuiop: qwertyuiop,
Yo4teW_gid: Yo4teW_gid
}
var obj = Object.assign({}, as, params);
Object.keys(obj).forEach(function (value, index, array) {
abb.push(value);
});
abb = abb.sort();
abb.forEach(function (value, index, array) {
abbo[abb[index]] = obj[abb[index]]
})
Object.keys(abbo).forEach(function (value, index, array) {
asdfghjkl += value + '=' + abbo[value]
});
appx = asdfghjkl.replace(/[^0-9a-zA-Z]/g, '');
appx = appx.toUpperCase();
for (var i = 0; i < appx.length; i++) {
if (appx[i] != "A" && appx[i] != "B" && appx[i] != "C") {
aggx += appx[i]
}
}
asdfghjkl = hex_sha1(aggx);
var parameter = Object.assign({}, params, {asdfghjkl: asdfghjkl}, {qwertyuiop: qwertyuiop}, {pf: 2});
return qs.stringify(parameter);
} }
} }
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
<div class="tab-content boxsiz"> <div class="tab-content boxsiz">
<ul class="boxsiz"> <ul class="boxsiz">
<li v-for="(item,index) in index.business_entry"> <li v-for="(item,index) in index.business_entry">
<a :href="item.url" :target="item.window_open > 0 ?'_blank':'_self'"> <a :href="item.url+'?ptag='+ptag+'-path'+(index * 1 +1)" :target="item.window_open > 0 ?'_blank':'_self'">
<img :src="item.images" alt=""> <img :src="item.images" alt="">
<p>{{item.title}}</p> <p>{{item.title}}</p>
</a> </a>
...@@ -45,7 +45,7 @@ ...@@ -45,7 +45,7 @@
</ul> </ul>
</div> </div>
<div class="content boxsiz"> <div class="content boxsiz">
<template v-for="(item,index) in index.template"> <template v-for="(item,count) in index.template">
<!--自营现货--> <!--自营现货-->
<template v-if="item.class == 'temp2'"> <template v-if="item.class == 'temp2'">
<div class="selfshop boxsiz"> <div class="selfshop boxsiz">
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
<span class="t2 va-b">{{item.ad_words}}</span> <span class="t2 va-b">{{item.ad_words}}</span>
</div> </div>
<template v-if="item.link_words"> <template v-if="item.link_words">
<a class="r" :href="item.url+'?ptag=index-floor'+index"> <a class="r" :href="item.url+'?ptag='+ptag+'-floor'+(count * 1 +1)">
<span class="va-m">{{item.link_words}}</span> <span class="va-m">{{item.link_words}}</span>
<i class="lineBlock va-m"></i> <i class="lineBlock va-m"></i>
</a> </a>
...@@ -64,7 +64,7 @@ ...@@ -64,7 +64,7 @@
</div> </div>
<ul class="boxsiz list"> <ul class="boxsiz list">
<li class="boxsiz" v-for="(v,index) in item.data.tempGoods" :key="index"> <li class="boxsiz" v-for="(v,index) in item.data.tempGoods" :key="index">
<a :href="'/item/'+v.goods_id+'.html'"> <a :href="'/item/'+v.goods_id+'.html?ptag='+ptag+'-floor'+(count * 1 +1)">
<!--限时限量--> <!--限时限量-->
<template v-if="v.ac_type == 1"> <template v-if="v.ac_type == 1">
<img :src="v.default_img" :alt="v.supplier_name"> <img :src="v.default_img" :alt="v.supplier_name">
...@@ -126,7 +126,7 @@ ...@@ -126,7 +126,7 @@
<span class="t2 va-b">{{item.ad_words}}</span> <span class="t2 va-b">{{item.ad_words}}</span>
</div> </div>
<template v-if="item.link_words"> <template v-if="item.link_words">
<a class="r" :href="item.url"> <a class="r" :href="item.url+'?ptag='+ptag+'-floor'+(count * 1 +1)">
<span class="va-m">{{item.link_words}}</span> <span class="va-m">{{item.link_words}}</span>
<i class="lineBlock va-m"></i> <i class="lineBlock va-m"></i>
</a> </a>
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
</div> </div>
<ul class="boxsiz list"> <ul class="boxsiz list">
<li class="boxsiz" v-for="(v,index) in item.data.brandImages" :key="index"> <li class="boxsiz" v-for="(v,index) in item.data.brandImages" :key="index">
<a :href="v.url" class="boxsiz"> <a :href="v.url+'?ptag='+ptag+'-floor'+(count * 1 +1)">
<div class="pic"> <div class="pic">
<img :src="v.images" :alt="v.title"> <img :src="v.images" :alt="v.title">
</div> </div>
...@@ -153,7 +153,7 @@ ...@@ -153,7 +153,7 @@
<span class="t2 va-b">{{item.ad_words}}</span> <span class="t2 va-b">{{item.ad_words}}</span>
</div> </div>
<template v-if="item.link_words"> <template v-if="item.link_words">
<a class="r" :href="item.url"> <a class="r" :href="item.url+'?ptag='+ptag+'-floor'+(count * 1 +1)">
<span class="va-m">{{item.link_words}}</span> <span class="va-m">{{item.link_words}}</span>
<i class="lineBlock va-m"></i> <i class="lineBlock va-m"></i>
</a> </a>
...@@ -161,7 +161,7 @@ ...@@ -161,7 +161,7 @@
</div> </div>
<ul class="list boxsiz"> <ul class="list boxsiz">
<li class="boxsiz" v-for="(v,index) in item.data.pointGoods" :key="index"> <li class="boxsiz" v-for="(v,index) in item.data.pointGoods" :key="index">
<a class="boxsiz"> <a class="boxsiz" :href="'/v3/pointmall'+'?ptag='+ptag+'-floor'+(count * 1 +1)">
<div class="pic"> <div class="pic">
<img :src="v.prize_img_url" :alt="v.prize_name"> <img :src="v.prize_img_url" :alt="v.prize_name">
</div> </div>
...@@ -185,7 +185,7 @@ ...@@ -185,7 +185,7 @@
<span class="t2 va-b">{{item.ad_words}}</span> <span class="t2 va-b">{{item.ad_words}}</span>
</div> </div>
<template v-if="item.link_words"> <template v-if="item.link_words">
<a class="r" :href="item.url"> <a class="r" :href="item.url+'?ptag='+ptag+'-floor'+(count * 1 +1)">
<span class="va-m">{{item.link_words}}</span> <span class="va-m">{{item.link_words}}</span>
<i class="lineBlock va-m"></i> <i class="lineBlock va-m"></i>
</a> </a>
...@@ -193,7 +193,7 @@ ...@@ -193,7 +193,7 @@
</div> </div>
<ul class="list boxsiz"> <ul class="list boxsiz">
<li class="boxsiz" v-for="(v,index) in item.data.tempImages" :key="index"> <li class="boxsiz" v-for="(v,index) in item.data.tempImages" :key="index">
<a class="boxsiz" href="v.url"> <a class="boxsiz" :href="v.url+'?ptag='+ptag+'-floor'+(count * 1 +1)">
<img :src="v.images" :alt="v.title"> <img :src="v.images" :alt="v.title">
</a> </a>
</li> </li>
...@@ -208,7 +208,7 @@ ...@@ -208,7 +208,7 @@
<i class="lineBlock va-b"></i> <i class="lineBlock va-b"></i>
<span class="t1 va-b">资讯中心</span> <span class="t1 va-b">资讯中心</span>
</div> </div>
<a class="r"> <a class="r" :href="'/news?cat_id=11&ptag='+ptag+'-dynamic'">
<span class="va-m">更多</span> <span class="va-m">更多</span>
<i class="lineBlock va-m"></i> <i class="lineBlock va-m"></i>
</a> </a>
......
No preview for this file type
No preview for this file type
No preview for this file type
This diff could not be displayed because it is too large.
<!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=//static.h5.ichunt.com/favicon.ico><link rel=stylesheet href=//static.h5.ichunt.com/static/iconfont.css><script src=https://res.wx.qq.com/open/js/jweixin-1.3.2.js charset=utf-8></script><script src=//static.h5.ichunt.com/static/flexible.min.js charset=utf-8></script><link href=//static.h5.ichunt.com/css/chunk-b3993bd2.ba391bba.css rel=prefetch><link href=//static.h5.ichunt.com/js/chunk-b3993bd2.0f725a48.js rel=prefetch><link href=//static.h5.ichunt.com/css/app.49eecd25.css rel=preload as=style><link href=//static.h5.ichunt.com/css/chunk-vendors.521d5c8e.css rel=preload as=style><link href=//static.h5.ichunt.com/js/app.dbeb4433.js rel=preload as=script><link href=//static.h5.ichunt.com/js/chunk-vendors.184c91fd.js rel=preload as=script><link href=//static.h5.ichunt.com/css/chunk-vendors.521d5c8e.css rel=stylesheet><link href=//static.h5.ichunt.com/css/app.49eecd25.css rel=stylesheet></head><body><noscript><strong>网站出现了一点小问题,正在修复中.......</strong></noscript><div id=app></div><script>//百度统计
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__ = 'https://static.ichunt.com/dist';
break;
case "www.liexin.com":
__PUBLIC__ = 'http://res.liexin.com/dist';
break;
case "sz.ichunt.com":
__PUBLIC__ = 'https://szm.ichunt.com/v3/dist';
break;
case "t.ichunt.com":
__PUBLIC__ = 'https://t.ichunt.com/v3/dist';
break;
default:
__PUBLIC__ = 'http://res.liexin.com/dist';
}
function getCookie(name) {
var strCookie = document.cookie;
var arrCookie = strCookie.split("; ");
for (var i = 0; i < arrCookie.length; i++) {
var arr = arrCookie[i].split("=");
if (name == arr[0]) {
return arr[1];
}
}
return "";
}
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: 'http://shence.ichunt.com:8106/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: 'http://shence.ichunt.com:8106/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=//static.h5.ichunt.com/js/chunk-vendors.184c91fd.js></script><script src=//static.h5.ichunt.com/js/app.dbeb4433.js></script></body></html>
\ No newline at end of file
(function(e){function t(t){for(var r,a,i=t[0],u=t[1],s=t[2],d=0,l=[];d<i.length;d++)a=i[d],o[a]&&l.push(o[a][0]),o[a]=0;for(r in u)Object.prototype.hasOwnProperty.call(u,r)&&(e[r]=u[r]);f&&f(t);while(l.length)l.shift()();return c.push.apply(c,s||[]),n()}function n(){for(var e,t=0;t<c.length;t++){for(var n=c[t],r=!0,a=1;a<n.length;a++){var i=n[a];0!==o[i]&&(r=!1)}r&&(c.splice(t--,1),e=u(u.s=n[0]))}return e}var r={},a={app:0},o={app:0},c=[];function i(e){return u.p+"js/"+({}[e]||e)+"."+{"chunk-b3993bd2":"0f725a48"}[e]+".js"}function u(t){if(r[t])return r[t].exports;var n=r[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,u),n.l=!0,n.exports}u.e=function(e){var t=[],n={"chunk-b3993bd2":1};a[e]?t.push(a[e]):0!==a[e]&&n[e]&&t.push(a[e]=new Promise(function(t,n){for(var r="css/"+({}[e]||e)+"."+{"chunk-b3993bd2":"ba391bba"}[e]+".css",o=u.p+r,c=document.getElementsByTagName("link"),i=0;i<c.length;i++){var s=c[i],d=s.getAttribute("data-href")||s.getAttribute("href");if("stylesheet"===s.rel&&(d===r||d===o))return t()}var l=document.getElementsByTagName("style");for(i=0;i<l.length;i++){s=l[i],d=s.getAttribute("data-href");if(d===r||d===o)return t()}var f=document.createElement("link");f.rel="stylesheet",f.type="text/css",f.onload=t,f.onerror=function(t){var r=t&&t.target&&t.target.src||o,c=new Error("Loading CSS chunk "+e+" failed.\n("+r+")");c.request=r,delete a[e],f.parentNode.removeChild(f),n(c)},f.href=o;var p=document.getElementsByTagName("head")[0];p.appendChild(f)}).then(function(){a[e]=0}));var r=o[e];if(0!==r)if(r)t.push(r[2]);else{var c=new Promise(function(t,n){r=o[e]=[t,n]});t.push(r[2]=c);var s,d=document.createElement("script");d.charset="utf-8",d.timeout=120,u.nc&&d.setAttribute("nonce",u.nc),d.src=i(e),s=function(t){d.onerror=d.onload=null,clearTimeout(l);var n=o[e];if(0!==n){if(n){var r=t&&("load"===t.type?"missing":t.type),a=t&&t.target&&t.target.src,c=new Error("Loading chunk "+e+" failed.\n("+r+": "+a+")");c.type=r,c.request=a,n[1](c)}o[e]=void 0}};var l=setTimeout(function(){s({type:"timeout",target:d})},12e4);d.onerror=d.onload=s,document.head.appendChild(d)}return Promise.all(t)},u.m=e,u.c=r,u.d=function(e,t,n){u.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},u.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},u.t=function(e,t){if(1&t&&(e=u(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(u.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)u.d(n,r,function(t){return e[t]}.bind(null,r));return n},u.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return u.d(t,"a",t),t},u.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},u.p="//static.h5.ichunt.com/",u.oe=function(e){throw console.error(e),e};var s=window["webpackJsonp"]=window["webpackJsonp"]||[],d=s.push.bind(s);s.push=t,s=s.slice();for(var l=0;l<s.length;l++)t(s[l]);var f=d;c.push([0,"chunk-vendors"]),n()})({0:function(e,t,n){e.exports=n("56d7")},"56d7":function(e,t,n){"use strict";n.r(t);var r=n("0ec6"),a=n.n(r),o=(n("c764"),n("9f07"),n("0964"),n("1cc5")),c=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{attrs:{id:"app"}},[n("keep-alive",{attrs:{exclude:""}},[n("router-view",{staticClass:"router-view"})],1)],1)},i=[],u={name:"app"},s=u,d=n("25c1"),l=Object(d["a"])(s,c,i,!1,null,null,null);l.options.__file="App.vue";var f=l.exports,p=(n("0a16"),n("081a")),h=function(e){return n.e("chunk-b3993bd2").then(function(){var t=[n("9553")];e.apply(null,t)}.bind(this)).catch(n.oe)};o["a"].use(p["a"]);var m=[{path:"/home",component:h,meta:{title:"猎芯网"}},{path:"/",redirect:"/home"},{path:"*",redirect:"/"}];m.forEach(function(e){e.path=e.path||"/"+(e.name||"")});var v=new p["a"]({routes:m});v.beforeEach(function(e,t,n){var r=e.meta&&e.meta.title;r&&(document.title=r),n()});var b,g=n("52c1"),w=n("7f43"),y=n.n(w);switch(window.location.hostname){case"www.ichunt.com":b="https://api.ichunt.com/";break;case"www.liexin.com":b="http://api.liexin.com/";break;case"m.liexin.com":b="http://m.liexin.com/";break;case"sz.ichunt.com":b="https://szapi.ichunt.com/";break;case"t.ichunt.com":b="https://api.ichunt.com/";break;default:b="/api/"}var x=b,k={index:x+"index",cartCount:x+"cart/count"},C={index:function(e){return y.a.get(k.index,{params:{data:e}})},cartCount:function(e){return y.a.get(k.cartCount,{params:{data:e}})}},j=n("6ef6");o["a"].use(j["e"]),o["a"].use(j["a"]);var O={index:{}},_={index:function(e,t){e.index=t.data}},E={index:function(e,t){var n=e.commit;C.index().then(function(e){var t=e.data;0==t.err_code&&n({type:"index",data:t.data})}).catch(function(e){Object(j["e"])({message:"网络出现问题,请重试",duration:1500})})}},T={},P={state:O,mutations:_,actions:E,getters:T};o["a"].use(j["e"]);var S={cartCount:""},M={cartCount:function(e,t){e.cartCount=0==t.data?"":t.data}},A={cartCount:function(e,t){var n=e.commit;C.cartCount().then(function(e){var t=e.data;0==t.err_code&&n({type:"cartCount",data:t.data})}).catch(function(e){Object(j["e"])({message:"网络出现问题,请重试",duration:1500})})}},N={},B={state:S,mutations:M,actions:A,getters:N};o["a"].use(g["a"]);var q=new g["a"].Store({modules:{home:P,common:B}}),z=(n("4ddc"),function(e){var t=new Date;t.setTime(1e3*e);var n=t.getFullYear(),r=t.getMonth()+1;r=r<10?"0"+r:r;var a=t.getDate();a=a<10?"0"+a:a;var o=t.getHours();o=o<10?"0"+o:o;var c=t.getMinutes(),i=t.getSeconds();return c=c<10?"0"+c:c,i=i<10?"0"+i:i,n+"-"+r+"-"+a+" "}),D={dateTimeFormate:z};n("e1a5"),n("bfd9");a()(D).forEach(function(e){return o["a"].filter(e,D[e])}),o["a"].config.productionTip=!0,new o["a"]({router:v,store:q,render:function(e){return e(f)}}).$mount("#app")},bfd9:function(e,t,n){}});
//# sourceMappingURL=app.dbeb4433.js.map
\ No newline at end of file
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-b3993bd2"],{"0218":function(s,t,a){"use strict";var i=a("8b2f"),l=a.n(i);l.a},"266c":function(s,t,a){s.exports=a.p+"img/logo.77238714.png"},"3d12":function(s,t,a){s.exports=a.p+"img/banner.712c55b3.png"},"6cf3":function(s,t,a){},"8a9e":function(s,t,a){"use strict";var i=a("6cf3"),l=a.n(i);l.a},"8b2f":function(s,t,a){},9553:function(s,t,a){"use strict";a.r(t);var i=function(){var s=this,t=s.$createElement,i=s._self._c||t;return i("section",{staticClass:"main-interface boxsiz"},[i("div",{staticClass:"container-wrap boxsiz"},[i("van-pull-refresh",{on:{refresh:s.onRefresh},model:{value:s.isLoading,callback:function(t){s.isLoading=t},expression:"isLoading"}},[i("div",{staticClass:"head boxsiz"},[i("div",{staticClass:"banner boxsiz"},[i("Slide",{attrs:{slidedata:s.index.rollbanner}})],1),i("div",{staticClass:"login-wrap"},[i("a",{staticClass:"btn",staticStyle:{display:"none"},attrs:{href:"/v3/login?ptag=index-topnav"}},[s._v("登录")]),i("a",{staticClass:"person-btn",attrs:{href:"/v3/user?ptag=index-topnav"}},[i("i")])]),i("div",{staticClass:"search boxsiz"},[i("div",{staticClass:"search-wrap boxsiz"},[i("div",{staticClass:"pic"},[i("img",{staticClass:"logo",attrs:{src:a("266c"),alt:""}})]),i("div",{staticClass:"inp boxsiz"},[i("i"),i("input",{staticClass:"boxsiz",attrs:{type:"text",placeholder:"请输入元器件型号、参数"}})])])])]),s.index.lx_activity?i("div",{staticClass:"notice boxsiz"},[i("span",[s._v("猎芯活动")]),i("i",{staticClass:"lineBlock va-m"}),i("div",{staticClass:"notice-contant"},[i("van-swipe",{attrs:{vertical:"","show-indicators":!1,height:s.height,autoplay:3e3}},s._l(s.index.lx_activity,function(t,a){return i("van-swipe-item",{key:a},[i("a",{attrs:{href:t.url}},[s._v(s._s(t.title))])])}),1)],1),i("a",{staticClass:"more"},[s._v("更多")])]):s._e(),i("div",{staticClass:"tab-content boxsiz"},[i("ul",{staticClass:"boxsiz"},s._l(s.index.business_entry,function(t,a){return i("li",[i("a",{attrs:{href:t.url,target:t.window_open>0?"_blank":"_self"}},[i("img",{attrs:{src:t.images,alt:""}}),i("p",[s._v(s._s(t.title))])])])}),0)]),i("div",{staticClass:"content boxsiz"},[s._l(s.index.template,function(t,a){return["temp2"==t.class?[i("div",{staticClass:"selfshop boxsiz"},[i("div",{staticClass:"tit boxsiz"},[i("div",{staticClass:"l"},[i("i",{staticClass:"lineBlock va-b"}),i("span",{staticClass:"t1 va-b"},[s._v(s._s(t.tem_name))]),i("span",{staticClass:"t2 va-b"},[s._v(s._s(t.ad_words))])]),t.link_words?[i("a",{staticClass:"r",attrs:{href:t.url+"?ptag=index-floor"+a}},[i("span",{staticClass:"va-m"},[s._v(s._s(t.link_words))]),i("i",{staticClass:"lineBlock va-m"})])]:s._e()],2),i("ul",{staticClass:"boxsiz list"},s._l(t.data.tempGoods,function(t,a){return i("li",{key:a,staticClass:"boxsiz"},[i("a",{attrs:{href:"/item/"+t.goods_id+".html"}},[1==t.ac_type?[i("img",{attrs:{src:t.default_img,alt:t.supplier_name}}),i("div",{staticClass:"text"},[i("p",{staticClass:"t1"},[s._v(s._s(t.goods_name))]),i("p",{staticClass:"t2"},[i("span",{staticClass:"l"},[s._v(s._s(t.price_ac))]),i("span",{staticClass:"r"},[s._v("抢购")])]),i("p",{staticClass:"t3"},[s._v(s._s(t.price))])])]:2==t.ac_type?[i("img",{attrs:{src:t.default_img,alt:t.supplier_name}}),i("div",{staticClass:"text"},[i("p",{staticClass:"t1"},[s._v(s._s(t.goods_name))]),i("p",{staticClass:"t2"},[i("span",{staticClass:"l"},[s._v(s._s(t.price_ac))]),i("span",{staticClass:"r"},[s._v("抢购")])]),i("p",{staticClass:"t3"},[s._v(s._s(t.price))])])]:3==t.ac_type?[i("img",{attrs:{src:t.default_img,alt:t.supplier_name}}),i("div",{staticClass:"text"},[i("p",{staticClass:"t1"},[s._v(s._s(t.goods_name))]),i("p",{staticClass:"t2"},[i("span",{staticClass:"l"},[s._v(s._s(t.price_ac))]),i("span",{staticClass:"r"},[s._v("优惠")])]),i("p",{staticClass:"t3"},[s._v(s._s(t.price))])])]:[i("img",{attrs:{src:t.default_img,alt:t.supplier_name}}),i("div",{staticClass:"text"},[i("p",{staticClass:"t1"},[s._v(s._s(t.goods_name))]),i("p",{staticClass:"t2"},[i("span",{staticClass:"l"},[s._v(s._s(t.price_ac))])])])]],2)])}),0)])]:"temp1"==t.class?[i("div",{staticClass:"lxshop boxsiz"},[i("div",{staticClass:"tit boxsiz"},[i("div",{staticClass:"l"},[i("i",{staticClass:"lineBlock va-b"}),i("span",{staticClass:"t1 va-b"},[s._v(s._s(t.tem_name))]),i("span",{staticClass:"t2 va-b"},[s._v(s._s(t.ad_words))])]),t.link_words?[i("a",{staticClass:"r",attrs:{href:t.url}},[i("span",{staticClass:"va-m"},[s._v(s._s(t.link_words))]),i("i",{staticClass:"lineBlock va-m"})])]:s._e()],2),i("ul",{staticClass:"boxsiz list"},s._l(t.data.brandImages,function(s,t){return i("li",{key:t,staticClass:"boxsiz"},[i("a",{staticClass:"boxsiz",attrs:{href:s.url}},[i("div",{staticClass:"pic"},[i("img",{attrs:{src:s.images,alt:s.title}})])])])}),0)])]:"temp3"==t.class?[i("div",{staticClass:"jfshop boxsiz"},[i("div",{staticClass:"tit boxsiz"},[i("div",{staticClass:"l"},[i("i",{staticClass:"lineBlock va-b"}),i("span",{staticClass:"t1 va-b"},[s._v(s._s(t.tem_name))]),i("span",{staticClass:"t2 va-b"},[s._v(s._s(t.ad_words))])]),t.link_words?[i("a",{staticClass:"r",attrs:{href:t.url}},[i("span",{staticClass:"va-m"},[s._v(s._s(t.link_words))]),i("i",{staticClass:"lineBlock va-m"})])]:s._e()],2),i("ul",{staticClass:"list boxsiz"},s._l(t.data.pointGoods,function(t,a){return i("li",{key:a,staticClass:"boxsiz"},[i("a",{staticClass:"boxsiz"},[i("div",{staticClass:"pic"},[i("img",{attrs:{src:t.prize_img_url,alt:t.prize_name}})]),i("p",{staticClass:"t1"},[s._v(s._s(t.prize_name))]),i("p",{staticClass:"t2"},[i("i",{staticClass:"va-m lineBlock"}),i("em",[s._v(s._s(t.prize_point))])])])])}),0)])]:"temp4"==t.class?[i("div",{staticClass:"pcb boxsiz"},[i("div",{staticClass:"tit boxsiz"},[i("div",{staticClass:"l"},[i("i",{staticClass:"lineBlock va-b"}),i("span",{staticClass:"t1 va-b"},[s._v(s._s(t.tem_name))]),i("span",{staticClass:"t2 va-b"},[s._v(s._s(t.ad_words))])]),t.link_words?[i("a",{staticClass:"r",attrs:{href:t.url}},[i("span",{staticClass:"va-m"},[s._v(s._s(t.link_words))]),i("i",{staticClass:"lineBlock va-m"})])]:s._e()],2),i("ul",{staticClass:"list boxsiz"},s._l(t.data.tempImages,function(s,t){return i("li",{key:t,staticClass:"boxsiz"},[i("a",{staticClass:"boxsiz",attrs:{href:"v.url"}},[i("img",{attrs:{src:s.images,alt:s.title}})])])}),0)])]:s._e()]}),s.index.footer_new_article?i("div",{staticClass:"news boxsiz"},[i("div",{staticClass:"tit boxsiz"},[i("div",{staticClass:"l"},[i("i",{staticClass:"lineBlock va-b"}),i("span",{staticClass:"t1 va-b"},[s._v("资讯中心")])]),i("a",{staticClass:"r"},[i("span",{staticClass:"va-m"},[s._v("更多")]),i("i",{staticClass:"lineBlock va-m"})])]),i("ul",{staticClass:"list boxsiz"},s._l(s.index.footer_new_article,function(t){return i("li",{key:t.art_id,staticClass:"boxsiz"},[i("a",{staticClass:"boxsiz",attrs:{href:"/article/"+t.art_id+".html?ptag="+s.ptag+"-dynamic"}},[i("div",{staticClass:"pic"},[i("img",{attrs:{src:t.litpic}})]),i("div",{staticClass:"text"},[i("p",{staticClass:"t1"},[s._v(s._s(t.title_seo))]),i("div",{staticClass:"t2"},[i("span",[s._v("来源:"+s._s(t.writer))]),i("div",[i("i",{staticClass:"ico lineBlock va-m"}),i("em",{staticClass:"va-m"},[s._v("\n "+s._s(parseInt(t.click)+parseInt(t.start_review))+"\n ")])])])])])])}),0)]):s._e()],2)])],1),i("Navigator")],1)},l=[],e=(a("9f07"),a("0964"),a("1cc5")),c=a("52c1"),n=a("6ef6"),r=function(){var s=this,t=s.$createElement,a=s._self._c||t;return a("div",{staticClass:"navigator"},[a("ul",{staticClass:"boxsiz"},[s._m(0),s._m(1),s._m(2),a("li",[a("a",{attrs:{href:"/v3/joincart?ptag=index-bottomnav"}},[a("i",{staticClass:"iconfont icon-gouwuche1"}),a("p",[s._v("购物车")]),a("span",{staticClass:"cart boxsiz"},[s._v(s._s(s.cartCount>99?"99+":s.cartCount))])])]),s._m(3)])])},o=[function(){var s=this,t=s.$createElement,a=s._self._c||t;return a("li",{staticClass:"curr"},[a("a",{attrs:{href:"/v3?ptag=index-bottomnav"}},[a("i",{staticClass:"iconfont icon-shouye"}),a("p",[s._v("首页")])])])},function(){var s=this,t=s.$createElement,a=s._self._c||t;return a("li",[a("a",{attrs:{href:"/v3/lxshop?ptag=index-bottomnav"}},[a("i",{staticClass:"iconfont icon-ziying"}),a("p",[s._v("自营商城")])])])},function(){var s=this,t=s.$createElement,a=s._self._c||t;return a("li",[a("a",{attrs:{href:"/v3/xianhuo?ptag=index-bottomnav"}},[a("i",{staticClass:"iconfont icon-lianying"}),a("p",[s._v("联营商城")])])])},function(){var s=this,t=s.$createElement,a=s._self._c||t;return a("li",[a("a",{attrs:{href:"/v3/user?ptag=index-bottomnav"}},[a("i",{staticClass:"iconfont icon-huiyuanzhongxin1"}),a("p",[s._v("会员中心")])])])}],_={name:"navigator",computed:Object(c["b"])({cartCount:function(s){return s.common.cartCount}}),created:function(){}},v=_,p=a("25c1"),d=Object(p["a"])(v,r,o,!1,null,null,null);d.options.__file="Navigator.vue";var C=d.exports,u=function(){var s=this,t=s.$createElement,i=s._self._c||t;return i("van-swipe",{attrs:{autoplay:3e6,"indicator-color":"#ffffff",loop:!1}},[s.slidedata?s._l(s.slidedata,function(s,t){return i("van-swipe-item",{key:t},[i("img",{staticClass:"slide-pic",attrs:{src:s.images}})])}):[i("van-swipe-item",[i("img",{staticClass:"slide-pic",attrs:{src:a("3d12")}})])]],2)},m=[];e["a"].use(n["c"]).use(n["d"]);var f={name:"slide",props:{slidedata:Array}},b=f,x=(a("0218"),Object(p["a"])(b,u,m,!1,null,null,null));x.options.__file="Slide.vue";var g=x.exports;e["a"].use(n["b"]);var h={name:"index",computed:Object(c["b"])({index:function(s){return s.home.index}}),data:function(){return{ptag:"index",isLoading:!1,height:33}},created:function(){this.$store.dispatch({type:"index"})},methods:{onRefresh:function(){var s=this;setTimeout(function(){s.isLoading=!1},500)}},components:{Navigator:C,Slide:g}},z=h,w=(a("8a9e"),Object(p["a"])(z,i,l,!1,null,"2858528a",null));w.options.__file="Index.vue";t["default"]=w.exports}}]);
//# sourceMappingURL=chunk-b3993bd2.0f725a48.js.map
\ No newline at end of file
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
!function(a,b){function c(){var b=f.getBoundingClientRect().width;b/i>540&&(b=540*i);var c=b/10;f.style.fontSize=c+"px",k.rem=a.rem=c}var d,e=a.document,f=e.documentElement,g=e.querySelector('meta[name="viewport"]'),h=e.querySelector('meta[name="flexible"]'),i=0,j=0,k=b.flexible||(b.flexible={});if(g){var l=g.getAttribute("content").match(/initial\-scale=([\d\.]+)/);l&&(j=parseFloat(l[1]),i=parseInt(1/j))}else if(h){var m=h.getAttribute("content");if(m){var n=m.match(/initial\-dpr=([\d\.]+)/),o=m.match(/maximum\-dpr=([\d\.]+)/);n&&(i=parseFloat(n[1]),j=parseFloat((1/i).toFixed(2))),o&&(i=parseFloat(o[1]),j=parseFloat((1/i).toFixed(2)))}}if(!i&&!j){var p=(a.navigator.appVersion.match(/android/gi),a.navigator.appVersion.match(/iphone/gi)),q=a.devicePixelRatio;i=p?q>=3&&(!i||i>=3)?3:q>=2&&(!i||i>=2)?2:1:1,j=1/i}if(f.setAttribute("data-dpr",i),!g){if(g=e.createElement("meta"),g.setAttribute("name","viewport"),g.setAttribute("content","initial-scale="+j+", maximum-scale="+j+", minimum-scale="+j+", user-scalable=no"),f.firstElementChild){f.firstElementChild.appendChild(g)}else{var r=e.createElement("div");r.appendChild(g),e.write(r.innerHTML)}}a.addEventListener("resize",function(){clearTimeout(d),d=setTimeout(c,300)},!1),a.addEventListener("pageshow",function(a){a.persisted&&(clearTimeout(d),d=setTimeout(c,300))},!1),"complete"===e.readyState?e.body.style.fontSize=12*i+"px":e.addEventListener("DOMContentLoaded",function(){e.body.style.fontSize=12*i+"px"},!1),c(),k.dpr=a.dpr=i,k.refreshRem=c,k.rem2px=function(a){var b=parseFloat(a)*this.rem;return "string"==typeof a&&a.match(/rem$/)&&(b+="px"),b},k.px2rem=function(a){var b=parseFloat(a)/this.rem;return "string"==typeof a&&a.match(/px$/)&&(b+="rem"),b}}(window,window.lib||(window.lib={}));
\ No newline at end of file
No preview for this file type
This diff could not be displayed because it is too large.
No preview for this file type
No preview for this file type
module.exports = { module.exports = {
publicPath: process.env.NODE_ENV === 'production' ? '//static.h5.ichunt.com/' : '/', publicPath: process.env.NODE_ENV === 'production' ? '//h5static.ichunt.com/' : '//h5static.ichunt.com/',
outputDir: 'view', outputDir: 'view',
assetsDir: '', assetsDir: '',
devServer: { devServer: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment