Commit 4723a8c3 by 肖康

阿斯达

parent 47b46898
......@@ -91,7 +91,10 @@ const actions = {
});
},
wxShare({commit}, payload) {
var params = Util.getParams();
let Params_={
current_url:payload.current_url
}
var params = Util.getParams(Params_);
Services.wxShare(params).then((res) => {
let data = res.data;
state.wxShareInfo=data.data;
......
......@@ -47,7 +47,8 @@
created() {
if(util.getCookie("Yo4teW_uid")){
this.$store.dispatch({
type: "wxShare"
type: "wxShare",
current_url:window.location.href
});
}
},
......
......@@ -4098,7 +4098,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vue_
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.10@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var _api_index__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../api/index */ \"./src/api/index.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@2.2.3@vant/es/index.js\");\n/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../util */ \"./src/util/index.js\");\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_2__[\"Toast\"]);\nvar state = {\n cartCount: 0,\n loginCheck: false,\n phpParams: {},\n wxShareInfo: \"\",\n wxShareState: false\n};\nvar mutations = {\n cartCount: function cartCount(state, payload) {\n state.cartCount = payload.data ? payload.data : 0;\n },\n loginCheck: function loginCheck(state, payload) {\n if (payload.data.err_code == 0) {\n //强登录态\n state.loginCheck = true;\n } else if (payload.data.err_code == 11030) {\n //弱登录态\n state.loginCheck = true;\n } else {\n state.loginCheck = false;\n }\n },\n phpParams: function phpParams(state, payload) {\n state.phpParams = payload.data.data;\n }\n};\nvar actions = {\n cartCount: function cartCount(_ref, payload) {\n var commit = _ref.commit;\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].cartCount().then(function (res) {\n var data = res.data;\n console.log(data);\n\n if (data.err_code == 0) {\n commit({\n type: 'cartCount',\n data: data.data\n });\n }\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n loginCheck: function loginCheck(_ref2, payload) {\n var commit = _ref2.commit;\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].loginCheck().then(function (res) {\n var data = res.data;\n\n if (payload.is_jump) {\n if (data.err_code == 11010) {\n window.location.href = '/h5/view/';\n } else if (data.err_code == 11030) {\n window.location.href = '/v3/login';\n }\n } else {\n commit({\n type: 'loginCheck',\n data: data\n });\n }\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n customsrService: function customsrService(_ref3, payload) {\n var commit = _ref3.commit;\n var params = {\n pf: window.lxpf,\n searchModel: ''\n };\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].customsrService(params).then(function (res) {}).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n getCommonParams: function getCommonParams(_ref4, payload) {\n var commit = _ref4.commit;\n var params = _util__WEBPACK_IMPORTED_MODULE_3__[\"default\"].getParams();\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].getCommonParams(params).then(function (res) {\n var data = res.data;\n commit({\n type: 'phpParams',\n data: data\n });\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n wxShare: function wxShare(_ref5, payload) {\n var commit = _ref5.commit;\n var params = _util__WEBPACK_IMPORTED_MODULE_3__[\"default\"].getParams();\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].wxShare(params).then(function (res) {\n var data = res.data;\n state.wxShareInfo = data.data;\n state.wxShareState = true;\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n }\n};\nvar getters = {};\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n state: state,\n mutations: mutations,\n actions: actions,\n getters: getters\n});\n\n//# sourceURL=webpack:///./src/store/modules/common.js?");
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.10@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var _api_index__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../api/index */ \"./src/api/index.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@2.2.3@vant/es/index.js\");\n/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../util */ \"./src/util/index.js\");\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_2__[\"Toast\"]);\nvar state = {\n cartCount: 0,\n loginCheck: false,\n phpParams: {},\n wxShareInfo: \"\",\n wxShareState: false\n};\nvar mutations = {\n cartCount: function cartCount(state, payload) {\n state.cartCount = payload.data ? payload.data : 0;\n },\n loginCheck: function loginCheck(state, payload) {\n if (payload.data.err_code == 0) {\n //强登录态\n state.loginCheck = true;\n } else if (payload.data.err_code == 11030) {\n //弱登录态\n state.loginCheck = true;\n } else {\n state.loginCheck = false;\n }\n },\n phpParams: function phpParams(state, payload) {\n state.phpParams = payload.data.data;\n }\n};\nvar actions = {\n cartCount: function cartCount(_ref, payload) {\n var commit = _ref.commit;\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].cartCount().then(function (res) {\n var data = res.data;\n console.log(data);\n\n if (data.err_code == 0) {\n commit({\n type: 'cartCount',\n data: data.data\n });\n }\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n loginCheck: function loginCheck(_ref2, payload) {\n var commit = _ref2.commit;\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].loginCheck().then(function (res) {\n var data = res.data;\n\n if (payload.is_jump) {\n if (data.err_code == 11010) {\n window.location.href = '/h5/view/';\n } else if (data.err_code == 11030) {\n window.location.href = '/v3/login';\n }\n } else {\n commit({\n type: 'loginCheck',\n data: data\n });\n }\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n customsrService: function customsrService(_ref3, payload) {\n var commit = _ref3.commit;\n var params = {\n pf: window.lxpf,\n searchModel: ''\n };\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].customsrService(params).then(function (res) {}).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n getCommonParams: function getCommonParams(_ref4, payload) {\n var commit = _ref4.commit;\n var params = _util__WEBPACK_IMPORTED_MODULE_3__[\"default\"].getParams();\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].getCommonParams(params).then(function (res) {\n var data = res.data;\n commit({\n type: 'phpParams',\n data: data\n });\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n },\n wxShare: function wxShare(_ref5, payload) {\n var commit = _ref5.commit;\n var Params_ = {\n current_url: payload.current_url\n };\n var params = _util__WEBPACK_IMPORTED_MODULE_3__[\"default\"].getParams(Params_);\n _api_index__WEBPACK_IMPORTED_MODULE_1__[\"services\"].wxShare(params).then(function (res) {\n var data = res.data;\n state.wxShareInfo = data.data;\n state.wxShareState = true;\n }).catch(function (err) {\n console.log('网络出现问题,请重试');\n });\n }\n};\nvar getters = {};\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n state: state,\n mutations: mutations,\n actions: actions,\n getters: getters\n});\n\n//# sourceURL=webpack:///./src/store/modules/common.js?");
/***/ }),
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