\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n\r\n\r\n\r\n","import mod from \"-!../node_modules/cache-loader/dist/cjs.js??ref--13-0!../node_modules/babel-loader/lib/index.js!../node_modules/cache-loader/dist/cjs.js??ref--1-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../node_modules/cache-loader/dist/cjs.js??ref--13-0!../node_modules/babel-loader/lib/index.js!../node_modules/cache-loader/dist/cjs.js??ref--1-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=537174c2&\"\nimport script from \"./App.vue?vue&type=script&lang=js&\"\nexport * from \"./App.vue?vue&type=script&lang=js&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=537174c2&prod&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","/* eslint-disable no-console */\r\n\r\nimport { register } from \"register-service-worker\";\r\n\r\nif (process.env.NODE_ENV === \"production\") {\r\n register(`${process.env.BASE_URL}service-worker.js`, {\r\n ready() {\r\n console.log(\r\n \"App is being served from cache by a service worker.\\n\" +\r\n \"For more details, visit https://goo.gl/AFskqB\"\r\n );\r\n },\r\n registered() {\r\n console.log(\"Service worker has been registered.\");\r\n },\r\n cached() {\r\n console.log(\"Content has been cached for offline use.\");\r\n },\r\n updatefound() {\r\n console.log(\"New content is downloading.\");\r\n },\r\n updated() {\r\n console.log(\"New content is available; please refresh.\");\r\n },\r\n offline() {\r\n console.log(\r\n \"No internet connection found. App is running in offline mode.\"\r\n );\r\n },\r\n error(error) {\r\n console.error(\"Error during service worker registration:\", error);\r\n },\r\n });\r\n}\r\n","import Vue from \"vue\";\r\nimport VueRouter from \"vue-router\";\r\nVue.use(VueRouter);\r\nconst originalPush = VueRouter.prototype.push\r\n// 修改 原型对象中的push方法\r\nVueRouter.prototype.push = function push(location) {\r\n return originalPush.call(this, location).catch(err => err)\r\n}\r\nconst routes = [\r\n {\r\n path: \"/\",\r\n name: \"Father\",\r\n component: () => import(\"../views/Father.vue\"),\r\n redirect: '/Introduction/', //默认显示简介\r\n children: [{\r\n path: 'Introduction/',\r\n name: 'Introduction',\r\n component: () => import(\"../components/Introduction.vue\"), //简介\r\n\r\n }, {\r\n path: 'Vote',\r\n name: 'Vote',\r\n meta: {\r\n keepAlive: true\r\n },\r\n component: () => import(\"../components/Vote.vue\"), //投票\r\n }, {\r\n path: 'Ranking',\r\n name: 'Ranking',\r\n meta: {\r\n keepAlive: true\r\n },\r\n // meta: { keepAlive: true},\r\n component: () => import(\"../components/Ranking.vue\"), //排行\r\n },]\r\n },\r\n {\r\n path: \"/UserDetails\",\r\n name: \"UserDetails\",\r\n component: () => import(\"../views/UserDetails.vue\"), //用户详情\r\n },\r\n {\r\n path: \"/SignUp\",\r\n name: \"SignUp\",\r\n meta: {\r\n keepAlive: true\r\n },\r\n component: () => import(\"../views/SignUp.vue\"), //我要报名\r\n },\r\n {\r\n path: \"/BigUserDetails\",\r\n name: \"BigUserDetails\",\r\n component: () => import(\"../views/BigUserDetails.vue\"),\r\n },\r\n {\r\n path: \"/Done\",\r\n name: \"Done\",\r\n component: () => import(\"../views/Done.vue\"), //报名成功\r\n },\r\n {\r\n path: '/reportCard',\r\n name: \"ReportCard\",\r\n component: () => import( /* webpackChunkName: \"ReportCard\" */ '../views/reportCard'),\r\n },\r\n {\r\n path: \"/erry\",\r\n name: \"Erry\",\r\n component: () => import(\"../components/erry.vue\"),\r\n },\r\n {\r\n path: \"/erry2\",\r\n name: \"Erry2\",\r\n component: () => import(\"../components/erry2.vue\"),\r\n }\r\n];\r\n\r\nconst router = new VueRouter({\r\n mode: \"hash\",\r\n base: \"/batrix-h5/h5/vote\",\r\n routes\r\n});\r\nrouter.beforeEach((to, from, next) => {\r\n if (to.path === \"/SignUp\" && from.path === \"/\") {\r\n history.pushState(null, null, location.href);\r\n return\r\n }\r\n next()\r\n // if (to.path === \"/UserDetails\" && from.path === \"/\") {\r\n // window.location.href = window.location.href.split(\"batrix-h5/vote\")[0] + \"batrix-h5/vote?id=\" + to.query.id;\r\n // }\r\n // next()\r\n // if (to.path === \"/BigUserDetails\" && from.path === \"/\") {\r\n // window.location.href = window.location.href.split(\"batrix-h5/vote\")[0] + \"batrix-h5/vote?id=\" + to.query.id;\r\n // }\r\n // next()\r\n\r\n})\r\n\r\n\r\nexport default router;","import Vue from \"vue\";\r\nimport Vuex from \"vuex\";\r\n\r\n// import createPersistedState from 'vuex-persistedstate'\r\nVue.use(Vuex);\r\n\r\n\r\nexport default new Vuex.Store({\r\n state: {\r\n lazyImg: \"https://o.cztvcloud.com/batrix/cms_1670315179_9iwodTUB9V.png\"\r\n },\r\n mutations: {\r\n add (state, url) {\r\n state.lazyImg = url\r\n }\r\n },\r\n actions: {},\r\n modules: {},\r\n});\r\n","import ElementUi from 'element-ui';\r\n\r\n// Fixes an issue with filters not working on mobile\r\nElementUi.Select.computed.readonly = function () {\r\n // trade-off for IE input readonly problem: https://github.com/ElemeFE/element/issues/10403\r\n const isIE = !this.$isServer && !Number.isNaN(Number(document.documentMode));\r\n\r\n return !(this.filterable || this.multiple || !isIE) && !this.visible;\r\n};\r\n\r\nexport default ElementUi;\r\n","import {\r\n GetQueryString\r\n} from \"../msg/guidePages\";\r\nvar vote = GetQueryString('id')\r\nconsole.log(vote);\r\n\r\nexport default {\r\n // detailUrl:'http://zinteract.test.cztv.com/api/votes/104/getItems?item_id=530',投票详情页接口\r\n // 测试\r\n oneUrl: `https://zcatapi.cztv.com/api/votes/${vote}`,\r\n sendVoteList: `https://zcatapi.cztv.com/api/votes/${vote}/getItems`, //获取投票列表\r\n vote: `https://zcatapi.cztv.com/vote/upwork`, //投票\r\n singUp: `https://zcatapi.cztv.com/api/votes/${vote}/selfEnroll`, //报名接口\r\n code:`https://zcatapi.cztv.com`,\r\n BigUserDetailsCode:`https://zinteract.cztv.com/batrix-h5/vote/BigUserDetails/`,\r\n UserDetailsCode:`https://zinteract.cztv.com/batrix-h5/vote/UserDetails`,\r\n reportCard: 'https://zcatapi.cztv.com/api/votes' ,//获取记录\r\n //正式\r\n // oneUrl: `https://interact.cztv.com/api/votes/${vote}`,\r\n // sendVoteList: `https://interact.cztv.com/api/votes/${vote}/getItems`, //获取投票列表\r\n // vote: `https://interact.cztv.com/api/votes/${vote}/finishVote`, //投票\r\n // singUp: `https://interact.cztv.com/api/votes/${vote}/selfEnroll`, //报名接口\r\n // code: `https://interact.cztv.com`,\r\n // BigUserDetailsCode: `https://h5.cztv.com/batrix-h5/h5/vote/BigUserDetails/`,\r\n // UserDetailsCode: `https://h5.cztv.com/batrix-h5/h5/vote/UserDetails`,\r\n // reportCard: 'https://interact.cztv.com/api/votes',//获取记录\r\n\r\n //跳转抽奖链接\r\n // jumpLottery:`http://h5-local.cztv.com/batrix-h5/h5/luckydraw/?id=`, //测试\r\n jumpLottery: `https://zinteract.cztv.com/batrix-h5/luckydraw/?id=`, //正式\r\n}","import Vue from \"vue\";\r\nimport App from \"./App.vue\";\r\nimport \"./registerServiceWorker\";\r\nimport router from \"./router\";\r\nimport store from \"./store\";\r\nimport VueLazyload from 'vue-lazyload'\r\nimport './utils/adaptation'\r\n//vant\r\nimport Vant from 'vant';\r\nimport 'vant/lib/index.css';\r\n\r\n\r\nVue.use(Vant);\r\n\r\n//element\r\n// import ElementUI from 'element-ui';\r\nimport ElementUI from './utils/elui'\r\nimport 'element-ui/lib/theme-chalk/index.css';\r\nVue.use(ElementUI);\r\n\r\n// Vue.http.options.credentials = true\r\n\r\n\r\nimport urls from './utils/urls/url'\r\nVue.prototype.$urls = urls\r\n\r\n\r\n//axios\r\nimport axios from 'axios'\r\nimport VueAxios from 'vue-axios'\r\n// import { cosh } from \"core-js/core/number\";\r\nVue.use(VueAxios, axios)\r\nVue.directive('centerImg', (el, binding) => {\r\n el.addEventListener('load', () => {\r\n el.style.left = \"0\"\r\n el.style.top = \"0\"\r\n if (el.src !== \"https://o.cztvcloud.com/batrix/cms_1670315216_wb1VeGTfGr.png\" && el.src.indexOf(\"video/snapshot\") !== -1 && el.src !== \"https://o.cztvcloud.com/batrix/cms_1670315179_9iwodTUB9V.png\") {\r\n var w = Number(window.getComputedStyle(el.parentNode).width.replace('px', ''));\r\n var h = Number(window.getComputedStyle(el.parentNode).height.replace('px', ''));\r\n // var w2 = el.naturalWidth;\r\n // var h2 = el.naturalHeight;\r\n //图片目前\r\n var w2 = el.width;\r\n var h2 = el.height;\r\n // 盒子宽高比\r\n var boxAspectRatio = w / h\r\n // 图片宽高比\r\n var imgAspectRatio = w2 / h2\r\n var tum = 0;\r\n if (boxAspectRatio > imgAspectRatio) {\r\n el.style.width = w + \"px\"\r\n tum = (el.height * 1 - h) / 2;\r\n el.style.top = \"-\" + tum + \"px\";\r\n el.style.left = \"0\";\r\n console.log('盒子宽高比大于图片宽高比', boxAspectRatio, imgAspectRatio)\r\n } else if (boxAspectRatio < imgAspectRatio) {\r\n el.style.height = h + \"px\"\r\n tum = (el.width * 1 - w) / 2;\r\n el.style.left = \"-\" + tum + \"px\";\r\n el.style.top = \"0\"\r\n console.log('盒子宽高比小于图片宽高比', boxAspectRatio, imgAspectRatio)\r\n } else {\r\n el.style.height = h + \"px\"\r\n el.style.width = w + \"px\"\r\n console.log('盒子宽高比等于图片宽高比', boxAspectRatio, imgAspectRatio)\r\n }\r\n }\r\n\r\n });\r\n})\r\nVue.directive('centerImg2', (el, binding) => {\r\n el.addEventListener('load', () => {\r\n el.style.left = \"0\"\r\n el.style.top = \"0\"\r\n var w = Number(window.getComputedStyle(el.parentNode).width.replace('px', ''));\r\n var h = Number(window.getComputedStyle(el.parentNode).height.replace('px', ''));\r\n // var w2 = el.naturalWidth;\r\n // var h2 = el.naturalHeight;\r\n //图片目前\r\n var w2 = el.width;\r\n var h2 = el.height;\r\n console.log('图片本身高度', el.width, el.height)\r\n // 盒子宽高比\r\n var boxAspectRatio = w / h\r\n\r\n // 图片宽高比\r\n var imgAspectRatio = w2 / h2\r\n var tum = 0;\r\n if (boxAspectRatio > imgAspectRatio) {\r\n el.style.width = w + \"px\"\r\n tum = (el.height * 1 - h) / 2;\r\n el.style.top = \"-\" + tum + \"px\";\r\n el.style.left = \"0\";\r\n console.log('盒子宽高比大于图片宽高比', boxAspectRatio, imgAspectRatio)\r\n } else if (boxAspectRatio < imgAspectRatio) {\r\n el.style.height = h + \"px\"\r\n tum = (el.width * 1 - w) / 2;\r\n el.style.left = \"-\" + tum + \"px\";\r\n el.style.top = \"0\"\r\n console.log('盒子宽高比小于图片宽高比', boxAspectRatio, imgAspectRatio)\r\n } else {\r\n el.style.height = h + \"px\"\r\n el.style.width = w + \"px\"\r\n console.log('盒子宽高比等于图片宽高比', boxAspectRatio, imgAspectRatio)\r\n }\r\n\r\n\r\n });\r\n})\r\nVue.directive('preventReClick', {\r\n\tinserted(el, binding) {\r\n \t el.addEventListener('click', () => {\r\n \tif (!el.disabled) {\r\n \t el.disabled = true\r\n \t setTimeout(() => {\r\n \t el.disabled = false\r\n \t}, binding.value || 2000)\r\n \t}\r\n \t})\r\n\t }\r\n});\r\nVue.directive('throttle-disabled', {\r\n\t// 当被绑定的元素插入到 DOM 中时……\r\n\tinserted(el, binding) {\r\n\t\tlet [event = \"click\", time = 2 * 1000] = binding.value\r\n\t\tel.addEventListener(event, () => {\r\n\t\t\t//默认监听click事件\r\n\t\t\t//当 dom元素el 非禁用状态时 将其设置为禁用状态,同时设置计时器,规定时间后(默认2秒)启用。\r\n\t\t\tif (!el.disabled) {\r\n\t\t\t\tel.disabled = true\r\n\t\t\t\tsetTimeout(() => {\r\n\t\t\t\t\tel.disabled = false\r\n\t\t\t\t}, time)\r\n\t\t\t}\r\n\t\t})\r\n\t}\r\n});\r\nVue.directive('debounce', {\r\n inserted(el, binding) {\r\n el.addEventListener('click', () => {\r\n if (!el.disabled) {\r\n el.disabled = true\r\n setTimeout(() => {\r\n el.disabled = false\r\n }, binding.value || 3 * 1000)\r\n }\r\n })\r\n }\r\n});\r\nVue.config.productionTip = false;\r\nVue.use(VueLazyload, {\r\n loading: store.state.lazyImg// 懒加载默认图片\r\n})\r\nnew Vue({\r\n router,\r\n store,\r\n render: (h) => h(App),\r\n}).$mount(\"#app\");\r\n","//屏幕适配\r\n(function() {\r\n\tvar scWid = document.documentElement.offsetWidth || document.body.offsetWidth;\r\n\tscWid = scWid>750?750:scWid;\r\n\tvar initWid = 750;\r\n\tvar oHtml = document.getElementsByTagName(\"html\")[0];\r\n\toHtml.style.fontSize = (100 * scWid / initWid) + \"px\";\r\n\twindow.onresize = function(){\r\n\t\tvar scWid = document.documentElement.offsetWidth || document.body.offsetWidth;\r\n\t\tscWid = scWid>750?750:scWid;\r\n\t\tvar initWid = 750;\r\n\t\tvar oHtml = document.getElementsByTagName(\"html\")[0];\r\n\t\toHtml.style.fontSize = (100 * scWid / initWid) + \"px\";\r\n\t\tconsole.log(document.documentElement.offsetWidth,2);\r\n\t\tconsole.log(document.body.offsetWidth,2);\r\n\t}\r\n\tconsole.log(document.documentElement.offsetWidth,1);\r\n\t// console.log(document.body.offsetWidth,1);\r\n})();\r\n"],"sourceRoot":""}