Commit 17da5188 by 梁建民

js

parent 1bbe3caa
Showing with 6 additions and 6 deletions
......@@ -7,7 +7,7 @@
</a>
<span class="t1">猎芯网</span>
</div>
<van-swipe :autoplay="3000" :height="bannerHeight">
<van-swipe :autoplay="3000" :height="bannerHeight" v-if="getfileuploadbanner.data">
<van-swipe-item v-for="(item, index) in getfileuploadbanner.data" :key="index">
<a :href="item.url" :target="item.window_open > 0 ?'_blank':'_self'">
<img :src="item.images" height="100%" width="100%"/>
......@@ -87,13 +87,13 @@
},
toUrl() {
Toast({
message: "请登录后下载,跳转",
message: "请登录后下载",
duration: 2000
});
setTimeout(() => {
window.location.href = '/v3/login'
},2000)
window.location.href = '/v3/login?from=download'
}, 2000)
},
scrollFns() {
......
......@@ -8,7 +8,7 @@
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime@7.4.5@@babel/runtime/helpers/esm/objectSpread.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.10@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.1@vuex/dist/vuex.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@2.0.1@vant/es/index.js\");\n/* harmony import */ var _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/views/common/Header.vue */ \"./src/views/common/Header.vue\");\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_1__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_3__[\"Swipe\"]).use(vant__WEBPACK_IMPORTED_MODULE_3__[\"SwipeItem\"]).use(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"news\",\n data: function data() {\n return {\n title: \"资料下载\",\n p: 1,\n meaushow: true,\n bannerHeight: 200,\n navListfixed: false\n };\n },\n computed: Object(E_h5_node_modules_babel_runtime_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_2__[\"mapState\"])({\n getfileuploadbanner: function getfileuploadbanner(state) {\n return state.download.getfileuploadbanner;\n },\n articleShowData: function articleShowData(state) {\n return state.download.articleShowData;\n }\n })),\n created: function created() {\n this.getData();\n },\n mounted: function mounted() {\n this.scrollFns();\n },\n methods: {\n getData: function getData() {\n this.$store.dispatch({\n type: \"getfileuploadbanner\"\n });\n this.$store.dispatch({\n type: \"articleShowData\"\n });\n },\n download: function download(id) {\n this.$store.dispatch({\n type: \"downloadFile\",\n id: id\n });\n },\n toUrl: function toUrl() {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: \"请登录后下载,跳转\",\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = '/v3/login';\n }, 2000);\n },\n scrollFns: function scrollFns() {\n var self = this;\n\n window.onscroll = function () {\n var t = document.documentElement.scrollTop || document.body.scrollTop;\n\n if (t >= 300) {\n self.navListfixed = true;\n } else {\n self.navListfixed = false;\n }\n };\n }\n },\n components: {\n Header: _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_4__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/download/Index.vue?./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.6@babel-loader/lib!./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.7.0@vue-loader/lib??vue-loader-options");
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime@7.4.5@@babel/runtime/helpers/esm/objectSpread.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.10@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.1@vuex/dist/vuex.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@2.0.1@vant/es/index.js\");\n/* harmony import */ var _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/views/common/Header.vue */ \"./src/views/common/Header.vue\");\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_1__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_3__[\"Swipe\"]).use(vant__WEBPACK_IMPORTED_MODULE_3__[\"SwipeItem\"]).use(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"news\",\n data: function data() {\n return {\n title: \"资料下载\",\n p: 1,\n meaushow: true,\n bannerHeight: 200,\n navListfixed: false\n };\n },\n computed: Object(E_h5_node_modules_babel_runtime_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_2__[\"mapState\"])({\n getfileuploadbanner: function getfileuploadbanner(state) {\n return state.download.getfileuploadbanner;\n },\n articleShowData: function articleShowData(state) {\n return state.download.articleShowData;\n }\n })),\n created: function created() {\n this.getData();\n },\n mounted: function mounted() {\n this.scrollFns();\n },\n methods: {\n getData: function getData() {\n this.$store.dispatch({\n type: \"getfileuploadbanner\"\n });\n this.$store.dispatch({\n type: \"articleShowData\"\n });\n },\n download: function download(id) {\n this.$store.dispatch({\n type: \"downloadFile\",\n id: id\n });\n },\n toUrl: function toUrl() {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: \"请登录后下载\",\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = '/v3/login?from=download';\n }, 2000);\n },\n scrollFns: function scrollFns() {\n var self = this;\n\n window.onscroll = function () {\n var t = document.documentElement.scrollTop || document.body.scrollTop;\n\n if (t >= 300) {\n self.navListfixed = true;\n } else {\n self.navListfixed = false;\n }\n };\n }\n },\n components: {\n Header: _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_4__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/download/Index.vue?./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.6@babel-loader/lib!./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.7.0@vue-loader/lib??vue-loader-options");
/***/ }),
......@@ -20,7 +20,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var E_h5
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"render\", function() { return render; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"staticRenderFns\", function() { return staticRenderFns; });\nvar render = function() {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n return _c(\n \"section\",\n { staticClass: \"news\" },\n [\n _c(\"Header\", {\n attrs: { bgcolor: \"#fff\", title: _vm.title, meaushow: _vm.meaushow }\n }),\n _vm._m(0),\n _c(\n \"van-swipe\",\n { attrs: { autoplay: 3000, height: _vm.bannerHeight } },\n _vm._l(_vm.getfileuploadbanner.data, function(item, index) {\n return _c(\"van-swipe-item\", { key: index }, [\n _c(\n \"a\",\n {\n attrs: {\n href: item.url,\n target: item.window_open > 0 ? \"_blank\" : \"_self\"\n }\n },\n [\n _c(\"img\", {\n attrs: { src: item.images, height: \"100%\", width: \"100%\" }\n })\n ]\n )\n ])\n }),\n 1\n ),\n _c(\"div\", { staticClass: \"down-list\" }, [\n _c(\n \"ul\",\n { staticClass: \"boxsiz\" },\n _vm._l(_vm.articleShowData, function(item, index) {\n return _c(\"li\", { key: index, staticClass: \"boxsiz\" }, [\n _c(\"p\", { staticClass: \"t1\" }, [_vm._v(_vm._s(item.title))]),\n _c(\"div\", { staticClass: \"bar\" }, [\n _c(\"p\", { staticClass: \"t2\" }, [\n _vm._v(\"已下载\" + _vm._s(item.download_num) + \"次\")\n ]),\n _c(\n \"a\",\n {\n staticClass: \"btn\",\n on: {\n click: function($event) {\n return _vm.download(item.data_id)\n }\n }\n },\n [_vm._v(\"下载\")]\n )\n ])\n ])\n }),\n 0\n )\n ]),\n _vm.articleShowData.length <= 3\n ? [\n _c(\"div\", { staticClass: \"islogin\", on: { click: _vm.toUrl } }, [\n _c(\"img\", {\n attrs: {\n src: __webpack_require__(/*! ../../assets/images/download/loading.png */ \"./src/assets/images/download/loading.png\"),\n alt: \"\"\n }\n }),\n _c(\"a\", { attrs: { href: \"javascript:;\" } }, [\n _vm._v(\"点击登录查看更多 >\")\n ])\n ])\n ]\n : _vm._e(),\n _c(\n \"div\",\n {\n directives: [{ name: \"backTopWindow\", rawName: \"v-backTopWindow\" }],\n staticClass: \"slide-bar\",\n staticStyle: { cursor: \"pointer\" }\n },\n [\n _vm.navListfixed\n ? _c(\"div\", { staticClass: \"backtop\" }, [\n _c(\"i\", { staticClass: \"iconfont icon-xiangshang1\" })\n ])\n : _vm._e()\n ]\n )\n ],\n 2\n )\n}\nvar staticRenderFns = [\n function() {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n return _c(\"div\", { staticClass: \"new-head boxsiz\" }, [\n _c(\"a\", { staticClass: \"logo\", attrs: { href: \"/\" } }, [\n _c(\"img\", {\n attrs: {\n src: __webpack_require__(/*! ../../assets/images/download/logo.png */ \"./src/assets/images/download/logo.png\"),\n alt: \"猎芯网\"\n }\n })\n ]),\n _c(\"span\", { staticClass: \"t1\" }, [_vm._v(\"猎芯网\")])\n ])\n }\n]\nrender._withStripped = true\n\n\n\n//# sourceURL=webpack:///./src/views/download/Index.vue?./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js?%7B%22cacheDirectory%22:%22node_modules/.cache/vue-loader%22,%22cacheIdentifier%22:%223fdc9e70-vue-loader-template%22%7D!./node_modules/_vue-loader@15.7.0@vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.7.0@vue-loader/lib??vue-loader-options");
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"render\", function() { return render; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"staticRenderFns\", function() { return staticRenderFns; });\nvar render = function() {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n return _c(\n \"section\",\n { staticClass: \"news\" },\n [\n _c(\"Header\", {\n attrs: { bgcolor: \"#fff\", title: _vm.title, meaushow: _vm.meaushow }\n }),\n _vm._m(0),\n _vm.getfileuploadbanner.data\n ? _c(\n \"van-swipe\",\n { attrs: { autoplay: 3000, height: _vm.bannerHeight } },\n _vm._l(_vm.getfileuploadbanner.data, function(item, index) {\n return _c(\"van-swipe-item\", { key: index }, [\n _c(\n \"a\",\n {\n attrs: {\n href: item.url,\n target: item.window_open > 0 ? \"_blank\" : \"_self\"\n }\n },\n [\n _c(\"img\", {\n attrs: { src: item.images, height: \"100%\", width: \"100%\" }\n })\n ]\n )\n ])\n }),\n 1\n )\n : _vm._e(),\n _c(\"div\", { staticClass: \"down-list\" }, [\n _c(\n \"ul\",\n { staticClass: \"boxsiz\" },\n _vm._l(_vm.articleShowData, function(item, index) {\n return _c(\"li\", { key: index, staticClass: \"boxsiz\" }, [\n _c(\"p\", { staticClass: \"t1\" }, [_vm._v(_vm._s(item.title))]),\n _c(\"div\", { staticClass: \"bar\" }, [\n _c(\"p\", { staticClass: \"t2\" }, [\n _vm._v(\"已下载\" + _vm._s(item.download_num) + \"次\")\n ]),\n _c(\n \"a\",\n {\n staticClass: \"btn\",\n on: {\n click: function($event) {\n return _vm.download(item.data_id)\n }\n }\n },\n [_vm._v(\"下载\")]\n )\n ])\n ])\n }),\n 0\n )\n ]),\n _vm.articleShowData.length <= 3\n ? [\n _c(\"div\", { staticClass: \"islogin\", on: { click: _vm.toUrl } }, [\n _c(\"img\", {\n attrs: {\n src: __webpack_require__(/*! ../../assets/images/download/loading.png */ \"./src/assets/images/download/loading.png\"),\n alt: \"\"\n }\n }),\n _c(\"a\", { attrs: { href: \"javascript:;\" } }, [\n _vm._v(\"点击登录查看更多 >\")\n ])\n ])\n ]\n : _vm._e(),\n _c(\n \"div\",\n {\n directives: [{ name: \"backTopWindow\", rawName: \"v-backTopWindow\" }],\n staticClass: \"slide-bar\",\n staticStyle: { cursor: \"pointer\" }\n },\n [\n _vm.navListfixed\n ? _c(\"div\", { staticClass: \"backtop\" }, [\n _c(\"i\", { staticClass: \"iconfont icon-xiangshang1\" })\n ])\n : _vm._e()\n ]\n )\n ],\n 2\n )\n}\nvar staticRenderFns = [\n function() {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n return _c(\"div\", { staticClass: \"new-head boxsiz\" }, [\n _c(\"a\", { staticClass: \"logo\", attrs: { href: \"/\" } }, [\n _c(\"img\", {\n attrs: {\n src: __webpack_require__(/*! ../../assets/images/download/logo.png */ \"./src/assets/images/download/logo.png\"),\n alt: \"猎芯网\"\n }\n })\n ]),\n _c(\"span\", { staticClass: \"t1\" }, [_vm._v(\"猎芯网\")])\n ])\n }\n]\nrender._withStripped = true\n\n\n\n//# sourceURL=webpack:///./src/views/download/Index.vue?./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js?%7B%22cacheDirectory%22:%22node_modules/.cache/vue-loader%22,%22cacheIdentifier%22:%223fdc9e70-vue-loader-template%22%7D!./node_modules/_vue-loader@15.7.0@vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.7.0@vue-loader/lib??vue-loader-options");
/***/ }),
......
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