Browse Source

去除多余console

master
gaoxs 5 years ago
parent
commit
e08d2a6fa7
  1. 2
      components/CountDown.vue
  2. 1
      components/ProductWindow.vue
  3. 1
      components/PromotionGood.vue
  4. 1
      libs/wechat.js
  5. 3
      main.js
  6. 3
      pages/Loading/index.vue
  7. 1
      pages/activity/GoodsSeckill/index.vue
  8. 1
      pages/activity/GroupDetails/index.vue
  9. 2
      pages/activity/SeckillDetails/index.vue
  10. 2
      pages/home/index.vue
  11. 2
      pages/launch/index.vue
  12. 1
      pages/order/OrderDetails/index.vue
  13. 19
      pages/order/OrderSubmission/index.vue
  14. 4
      pages/shop/GoodsCon/index.vue
  15. 1
      pages/shop/GoodsList/index.vue
  16. 3
      pages/shop/ShoppingCart/index.vue
  17. 1
      pages/user/Login/index.vue
  18. 2
      pages/user/PersonalData/index.vue
  19. 4
      pages/user/User/index.vue
  20. 1
      pages/user/address/AddAddress/index.vue
  21. 1
      pages/user/signIn/Integral/index.vue
  22. 46
      utils/index.js
  23. 2
      utils/request.js

2
components/CountDown.vue

@ -43,7 +43,6 @@ export default {
// this.show_time(); // this.show_time();
}, },
mounted: function() { mounted: function() {
console.log(this)
this.rtipText = this.$props.tipText; this.rtipText = this.$props.tipText;
this.rdayText = this.$props.dayText; this.rdayText = this.$props.dayText;
this.rhourText = this.$props.hourText; this.rhourText = this.$props.hourText;
@ -51,7 +50,6 @@ export default {
this.rsecondText = this.$props.secondText; this.rsecondText = this.$props.secondText;
this.rdatatime = this.$props.datatime; this.rdatatime = this.$props.datatime;
this.risDay = this.$props.isDay; this.risDay = this.$props.isDay;
console.log(this.rdayText)
this.show_time(); this.show_time();
}, },
methods: { methods: {

1
components/ProductWindow.vue

@ -66,7 +66,6 @@ export default {
return {}; return {};
}, },
mounted: function() { mounted: function() {
console.log(this.attr);
}, },
methods: { methods: {
closeAttr: function() { closeAttr: function() {

1
components/PromotionGood.vue

@ -31,7 +31,6 @@ export default {
} }
}, },
mounted() { mounted() {
console.log(this, 999);
} }
}; };
</script> </script>

1
libs/wechat.js

@ -2,7 +2,6 @@
export const weappPay = (option) => { export const weappPay = (option) => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
// 吊起微信支付 // 吊起微信支付
console.log(option,9999)
uni.requestPayment({ uni.requestPayment({
...option, ...option,
timeStamp: option.timeStamp + '', timeStamp: option.timeStamp + '',

3
main.js

@ -50,7 +50,6 @@ Vue.mixin({
const { const {
$mp $mp
} = this.$root } = this.$root
console.log($mp)
this._route = parseRoute($mp) this._route = parseRoute($mp)
// this.$VUE_APP_RESOURCES_URL = VUE_APP_RESOURCES_URL; // this.$VUE_APP_RESOURCES_URL = VUE_APP_RESOURCES_URL;
this._data.$VUE_APP_RESOURCES_URL = VUE_APP_RESOURCES_URL; this._data.$VUE_APP_RESOURCES_URL = VUE_APP_RESOURCES_URL;
@ -84,7 +83,6 @@ store.commit('UPDATE_DEVICETYPE','h5')
// #ifdef APP-PLUS // #ifdef APP-PLUS
// App平台编译的代码 // App平台编译的代码
console.log('App平台编译的代码')
Vue.prototype.$deviceType = 'app' Vue.prototype.$deviceType = 'app'
store.commit('UPDATE_DEVICETYPE','app') store.commit('UPDATE_DEVICETYPE','app')
Vue.prototype.$platform = uni.getSystemInfoSync().platform Vue.prototype.$platform = uni.getSystemInfoSync().platform
@ -92,7 +90,6 @@ Vue.prototype.$platform = uni.getSystemInfoSync().platform
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
// 微信小程序编译的代码 // 微信小程序编译的代码
console.log('微信小程序编译的代码')
Vue.prototype.$deviceType = 'weixin' Vue.prototype.$deviceType = 'weixin'
store.commit('UPDATE_DEVICETYPE','weixin') store.commit('UPDATE_DEVICETYPE','weixin')
// #endif // #endif

3
pages/Loading/index.vue

@ -41,8 +41,6 @@ export default {
this.toLaunch(); this.toLaunch();
return; return;
} }
console.log(this.$store.getters.token, '获取store里面的 token');
console.log(this.$store.getters.userInfo, '获取store里面的 userInfo');
cookie.get("spread"); cookie.get("spread");
// this.toLaunch(); // this.toLaunch();
if (this.$deviceType == 'app') { if (this.$deviceType == 'app') {
@ -61,7 +59,6 @@ export default {
methods: { methods: {
...mapActions(["changeAuthorization", "setUserInfo"]), ...mapActions(["changeAuthorization", "setUserInfo"]),
toLaunch() { toLaunch() {
console.log(this);
this.changeAuthorization(false); this.changeAuthorization(false);
this.$yrouter.switchTab({ this.$yrouter.switchTab({
path: "/pages/home/index" path: "/pages/home/index"

1
pages/activity/GoodsSeckill/index.vue

@ -114,7 +114,6 @@ export default {
}, },
methods: { methods: {
changeTime: function(index) { changeTime: function(index) {
console.log(index);
this.active = index; this.active = index;
this.getSeckillList(); this.getSeckillList();
}, },

1
pages/activity/GroupDetails/index.vue

@ -235,7 +235,6 @@ export default {
}, },
mountedStart: function() { mountedStart: function() {
var that = this; var that = this;
console.log(that);
let id = that.$yroute.query.id; let id = that.$yroute.query.id;
getCombinationDetail(id).then(res => { getCombinationDetail(id).then(res => {
that.userCollect = res.data.userCollect; that.userCollect = res.data.userCollect;

2
pages/activity/SeckillDetails/index.vue

@ -199,7 +199,6 @@ export default {
if (that.attr.cartAttr == false) { if (that.attr.cartAttr == false) {
that.attr.cartAttr = !this.attr.attrcartAttr; that.attr.cartAttr = !this.attr.attrcartAttr;
} else { } else {
console.log(that.storeInfo);
var data = {}; var data = {};
data.productId = that.storeInfo.productId; data.productId = that.storeInfo.productId;
data.cartNum = that.attr.productSelect.cart_num; data.cartNum = that.attr.productSelect.cart_num;
@ -208,7 +207,6 @@ export default {
data.new = 1; data.new = 1;
postCartAdd(data) postCartAdd(data)
.then(res => { .then(res => {
console.log(res);
that.$yrouter.push({ that.$yrouter.push({
path: "/pages/order/OrderSubmission/index", path: "/pages/order/OrderSubmission/index",
query: { id: res.data.cartId } query: { id: res.data.cartId }

2
pages/home/index.vue

@ -213,7 +213,6 @@ export default {
title: '加载中' title: '加载中'
}); });
getHomeData().then(res => { getHomeData().then(res => {
console.log(res);
that.logoUrl = res.data.logoUrl; that.logoUrl = res.data.logoUrl;
that.$set(that, 'banner', res.data.banner); that.$set(that, 'banner', res.data.banner);
that.$set(that, 'menus', res.data.menus); that.$set(that, 'menus', res.data.menus);
@ -246,7 +245,6 @@ export default {
}); });
}, },
goGoodsCon(item) { goGoodsCon(item) {
console.log(item);
this.$yrouter.push({ this.$yrouter.push({
path: '/pages/shop/GoodsCon/index', path: '/pages/shop/GoodsCon/index',
query: { id: item.id } query: { id: item.id }

2
pages/launch/index.vue

@ -46,7 +46,6 @@ export default {
}, },
mounted() { mounted() {
let type = this.$yroute.query.type; let type = this.$yroute.query.type;
console.log(2222)
if (type) { if (type) {
} }
@ -54,7 +53,6 @@ export default {
// } // }
}, },
onHide() { onHide() {
console.log("清除状态");
} }
}; };
</script> </script>

1
pages/order/OrderDetails/index.vue

@ -514,7 +514,6 @@ export default {
}); });
}, },
goGroupRule(orderInfo) { goGroupRule(orderInfo) {
console.log(orderInfo)
this.$yrouter.push({ this.$yrouter.push({
path: "/pages/activity/GroupRule/index", path: "/pages/activity/GroupRule/index",
query: { query: {

19
pages/order/OrderSubmission/index.vue

@ -345,7 +345,6 @@
}, },
changeUseIntegral: function(e) { changeUseIntegral: function(e) {
// this.computedPrice(); // this.computedPrice();
console.log(e)
this.useIntegral = e.mp.detail.value[0]; this.useIntegral = e.mp.detail.value[0];
}, },
computedPrice() { computedPrice() {
@ -486,22 +485,6 @@
if (this.$deviceType == 'app') { if (this.$deviceType == 'app') {
form.form = 'app' form.form = 'app'
} }
console.log(this.orderGroupInfo.orderKey, {
realName: this.contacts,
phone: this.contactsTel,
addressId: this.addressInfo.id,
useIntegral: this.useIntegral ? 1 : 0,
couponId: this.usableCoupon.id || 0,
payType: this.active,
pinkId: this.pinkId,
seckillId: this.orderGroupInfo.seckill_id,
combinationId: this.orderGroupInfo.combination_id,
bargainId: this.orderGroupInfo.bargain_id,
from: this.from,
mark: this.mark || "",
shippingType: parseInt(shipping_type) + 1,
...form
})
createOrder(this.orderGroupInfo.orderKey, { createOrder(this.orderGroupInfo.orderKey, {
realName: this.contacts, realName: this.contacts,
phone: this.contactsTel, phone: this.contactsTel,
@ -519,7 +502,6 @@
...form ...form
}) })
.then(res => { .then(res => {
console.log(res)
uni.hideLoading(); uni.hideLoading();
const data = res.data; const data = res.data;
switch (data.status) { switch (data.status) {
@ -565,7 +547,6 @@
break; break;
case "WECHAT_PAY": case "WECHAT_PAY":
weappPay(data.result.jsConfig).then(res => { weappPay(data.result.jsConfig).then(res => {
console.log(res)
this.$yrouter.replace({ this.$yrouter.replace({
path: "/pages/order/OrderDetails/index", path: "/pages/order/OrderDetails/index",
query: { query: {

4
pages/shop/GoodsCon/index.vue

@ -257,9 +257,7 @@ export default {
}, },
computed: mapGetters(["isLogin"]), computed: mapGetters(["isLogin"]),
mounted: function() { mounted: function() {
console.log(this);
let url = handleQrCode(); let url = handleQrCode();
console.log(url);
if (url && url.productId) { if (url && url.productId) {
this.id = url.productId; this.id = url.productId;
} else { } else {
@ -329,7 +327,6 @@ export default {
if (this.$deviceType == "app") { if (this.$deviceType == "app") {
form.form = "app"; form.form = "app";
} }
console.log(form, 2222);
getProductDetail(that.id, form) getProductDetail(that.id, form)
.then(res => { .then(res => {
that.$set(that, "storeInfo", res.data.storeInfo); that.$set(that, "storeInfo", res.data.storeInfo);
@ -500,7 +497,6 @@ export default {
}, },
changeattr: function(msg) { changeattr: function(msg) {
this.attr.cartAttr = msg; this.attr.cartAttr = msg;
console.log(this.attr, msg);
this.isOpen = false; this.isOpen = false;
}, },
// //

1
pages/shop/GoodsList/index.vue

@ -177,7 +177,6 @@ export default {
// document.title = this.title || this.$yroute.meta.title; // document.title = this.title || this.$yroute.meta.title;
}, },
get_product_list() { get_product_list() {
console.log("请求李贝奥");
var that = this; var that = this;
this.setWhere(); this.setWhere();
// if (to.name !== "GoodsList") return; // if (to.name !== "GoodsList") return;

3
pages/shop/ShoppingCart/index.vue

@ -193,7 +193,6 @@ export default {
// }, // },
watch: { watch: {
userInfo(user) { userInfo(user) {
console.log(user, '用户信息,8585');
if (user.uid) { if (user.uid) {
this.carnum(); this.carnum();
this.countMoney(); this.countMoney();
@ -202,7 +201,6 @@ export default {
} }
}, },
token(token) { token(token) {
console.log(token, '用户token,8585');
if (this.userInfo.uid) { if (this.userInfo.uid) {
this.carnum(); this.carnum();
this.countMoney(); this.countMoney();
@ -348,7 +346,6 @@ export default {
}); });
return; return;
} }
console.log(id);
this.$yrouter.push({ this.$yrouter.push({
path: '/pages/order/OrderSubmission/index', path: '/pages/order/OrderSubmission/index',
query: { query: {

1
pages/user/Login/index.vue

@ -285,7 +285,6 @@
this.current = index; this.current = index;
}, },
async submit() { async submit() {
console.log("spread:" + cookie.get("spread"));
const { const {
account, account,
password password

2
pages/user/PersonalData/index.vue

@ -235,7 +235,7 @@ export default {
}) })
.catch(err => {}); .catch(err => {});
} else if (res.cancel) { } else if (res.cancel) {
console.log("用户点击取消"); // console.log("");
} }
} }
}); });

4
pages/user/User/index.vue

@ -220,7 +220,6 @@ export default {
this.$yrouter.push("/pages/user/PersonalData/index"); this.$yrouter.push("/pages/user/PersonalData/index");
}, },
getPhoneNumber: function(e) { getPhoneNumber: function(e) {
console.log(e.mp.detail);
// //
if (e.mp.detail.errMsg == "getPhoneNumber:ok") { if (e.mp.detail.errMsg == "getPhoneNumber:ok") {
uni.showLoading({ uni.showLoading({
@ -230,7 +229,6 @@ export default {
uni.getProvider({ uni.getProvider({
service: "oauth", service: "oauth",
success: function(res) { success: function(res) {
console.log(res.provider);
// h5 // h5
if (res.provider) { if (res.provider) {
uni.login({ uni.login({
@ -324,8 +322,6 @@ export default {
} }
}, },
onShow() { onShow() {
console.log(this.$store.getters.token);
console.log(this.userInfo);
if (this.$store.getters.token) { if (this.$store.getters.token) {
this.User(); this.User();
this.MenuUser(); this.MenuUser();

1
pages/user/address/AddAddress/index.vue

@ -133,7 +133,6 @@ export default {
this.address.province = e.labelArr[0] || ""; this.address.province = e.labelArr[0] || "";
this.address.city = e.labelArr[1] || ""; this.address.city = e.labelArr[1] || "";
this.address.district = e.labelArr[2] || ""; this.address.district = e.labelArr[2] || "";
console.log(this.pickerText);
}, },
getUserAddress: function() { getUserAddress: function() {
if (!this.id) return false; if (!this.id) return false;

1
pages/user/signIn/Integral/index.vue

@ -132,7 +132,6 @@ export default {
that.loadTitle = that.loaded ? "人家是有底线的" : "上拉加载更多"; that.loadTitle = that.loaded ? "人家是有底线的" : "上拉加载更多";
that.where.page = that.where.page + 1; that.where.page = that.where.page + 1;
that.list.push.apply(that.list, res.data); that.list.push.apply(that.list, res.data);
console.log(that.list)
}, },
err => { err => {
uni.showToast({ uni.showToast({

46
utils/index.js

@ -119,7 +119,6 @@ export const replaceLogin = (msg) => {
}); });
// 这里代表已经失去登录状态以及401强制推出登录了 // 这里代表已经失去登录状态以及401强制推出登录了
store.commit('LOGOUT') store.commit('LOGOUT')
console.log(uni, 989)
if (Vue.prototype.$deviceType == 'weixin') { if (Vue.prototype.$deviceType == 'weixin') {
// 如果是微信小程序,跳转到授权页 // 如果是微信小程序,跳转到授权页
login({ login({
@ -152,7 +151,6 @@ export const getProvider = () => {
uni.getProvider({ uni.getProvider({
service: 'oauth', service: 'oauth',
success: function (res) { success: function (res) {
console.log(`当前环境的服务商为 | ${res.provider}`)
// 此处可以排除h5 // 此处可以排除h5
if (res.provider) { if (res.provider) {
resolve(res.provider[0]) resolve(res.provider[0])
@ -185,7 +183,6 @@ export const authorize = (authorizeStr) => {
} }
export const login = (option) => { export const login = (option) => {
console.log('调用登录')
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getProvider().then(provider => { getProvider().then(provider => {
// 调用登录接口 // 调用登录接口
@ -193,16 +190,12 @@ export const login = (option) => {
provider: provider, provider: provider,
success: function (loginRes) { success: function (loginRes) {
// 微信登录 // 微信登录
console.log(`获取code | ${loginRes.code}`)
let code = loginRes.code; let code = loginRes.code;
// 检查授权, 检查用户信息授权 // 检查授权, 检查用户信息授权
authorize('userInfo').then(() => { authorize('userInfo').then(() => {
uni.getUserInfo({ uni.getUserInfo({
provider: provider, provider: provider,
success: function (user) { success: function (user) {
console.log(user)
console.log(`用户昵称为 | ${user.userInfo.nickName}`);
console.log(`当前的环境 | ${Vue.prototype.$deviceType}`)
if (Vue.prototype.$deviceType == 'weixin') { if (Vue.prototype.$deviceType == 'weixin') {
wxappAuth({ wxappAuth({
encryptedData: user.encryptedData, encryptedData: user.encryptedData,
@ -212,23 +205,14 @@ export const login = (option) => {
}).then(({ }).then(({
data data
}) => { }) => {
console.log('登录成功')
console.log(data)
console.log('登录成功1')
resolve(data) resolve(data)
console.log('登录成功3')
uni.hideLoading(); uni.hideLoading();
console.log('登录成功4')
store.commit("LOGIN", data.token, dayjs(data.expires_time)); store.commit("LOGIN", data.token, dayjs(data.expires_time));
console.log('登录成功5')
console.log(store) console.log(store)
handleGetUserInfo() handleGetUserInfo()
}).catch(error => { }).catch(error => {
reject() reject()
console.log('微信登录失败')
console.log(error) console.log(error)
handleFail(option, '微信登录失败') handleFail(option, '微信登录失败')
}); });
@ -264,19 +248,13 @@ export const login = (option) => {
} }
export const handleGetUserInfo = () => { export const handleGetUserInfo = () => {
console.log('登录后请求用户信息')
getUser().then(res => { getUser().then(res => {
console.log(res.data, '登录后的样式')
store.dispatch('setUserInfo', res.data) store.dispatch('setUserInfo', res.data)
console.log('登录成功6')
var pages = getCurrentPages() //获取加载的页面 var pages = getCurrentPages() //获取加载的页面
console.log('登录成功7')
var currentPage = pages[pages.length - 1] //获取当前页面的对象 var currentPage = pages[pages.length - 1] //获取当前页面的对象
let url = "/pages/home/index" let url = "/pages/home/index"
let query = {} let query = {}
console.log('登录成功8')
console.log(currentPage)
if (currentPage) { if (currentPage) {
// 获取到最后一个页面 // 获取到最后一个页面
@ -297,11 +275,6 @@ export const handleGetUserInfo = () => {
} }
} }
} }
console.log('登录成功9')
console.log({
path: url,
query
})
if (url == '/pages/home/index' || url == '/pages/shop/GoodsClass/index' || url == '/pages/shop/ShoppingCart/index' || url == '/pages/user/User/index') { if (url == '/pages/home/index' || url == '/pages/shop/GoodsClass/index' || url == '/pages/shop/ShoppingCart/index' || url == '/pages/user/User/index') {
switchTab({ switchTab({
path: `${url}`, path: `${url}`,
@ -363,7 +336,6 @@ export function auth() {
* userInfo只是用来限时用户信息作用并不是很大 * userInfo只是用来限时用户信息作用并不是很大
* ps只需要判断 token 是否存在即可 * ps只需要判断 token 是否存在即可
*/ */
console.log(cookie.get('login_status'), 'token')
if (cookie.get('login_status')) { if (cookie.get('login_status')) {
return true return true
} }
@ -372,7 +344,6 @@ export function auth() {
export const handleLoginStatus = (location, complete, fail, success) => { export const handleLoginStatus = (location, complete, fail, success) => {
console.log(location, '开始检验权限')
// 不登录可访问的页面 // 不登录可访问的页面
let page = [{ let page = [{
path: '/pages/Loading/index', path: '/pages/Loading/index',
@ -405,7 +376,6 @@ export const handleLoginStatus = (location, complete, fail, success) => {
if (!auth()) { if (!auth()) {
page.map((item) => { page.map((item) => {
console.log(item.path == path)
if (item.path == path) { if (item.path == path) {
isAuth = true isAuth = true
} }
@ -416,14 +386,7 @@ export const handleLoginStatus = (location, complete, fail, success) => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
if (isAuth) { if (isAuth) {
console.log('有权限')
// 登录了有权限 // 登录了有权限
console.log({
url: parseUrl(location),
complete,
fail,
success
})
resolve({ resolve({
url: parseUrl(location), url: parseUrl(location),
complete, complete,
@ -431,7 +394,6 @@ export const handleLoginStatus = (location, complete, fail, success) => {
success success
}) })
} else { } else {
console.log('无权限')
// 未登录没有权限 // 未登录没有权限
replaceLogin() replaceLogin()
reject() reject()
@ -443,7 +405,6 @@ export const handleLoginStatus = (location, complete, fail, success) => {
export function push(location, complete, fail, success) { export function push(location, complete, fail, success) {
handleLoginStatus(location, complete, fail, success).then(params => { handleLoginStatus(location, complete, fail, success).then(params => {
console.log(params)
uni.navigateTo(params) uni.navigateTo(params)
}).catch(error => { }).catch(error => {
// 没有权限 // 没有权限
@ -453,7 +414,6 @@ export function push(location, complete, fail, success) {
export function replace(location, complete, fail, success) { export function replace(location, complete, fail, success) {
handleLoginStatus(location, complete, fail, success).then(params => { handleLoginStatus(location, complete, fail, success).then(params => {
console.log(params)
uni.redirectTo(params) uni.redirectTo(params)
}).catch(error => { }).catch(error => {
// 没有权限 // 没有权限
@ -476,9 +436,7 @@ export function back() {
} }
export function switchTab(location, complete, fail, success) { export function switchTab(location, complete, fail, success) {
console.log(location)
handleLoginStatus(location, complete, fail, success).then(params => { handleLoginStatus(location, complete, fail, success).then(params => {
console.log(params)
uni.switchTab(params) uni.switchTab(params)
}).catch(error => { }).catch(error => {
// 没有权限 // 没有权限
@ -529,14 +487,12 @@ const getImageInfo = (images) => {
src: item, src: item,
fail: function (res) { fail: function (res) {
imageAry[index] = null imageAry[index] = null
console.log(res)
if (imageAry.length == images.length) { if (imageAry.length == images.length) {
resolve(imageAry) resolve(imageAry)
} }
}, },
success: function (res) { success: function (res) {
imageAry[index] = res imageAry[index] = res
console.log(res)
if (Object.keys(imageAry).length == images.length) { if (Object.keys(imageAry).length == images.length) {
resolve(imageAry) resolve(imageAry)
} }
@ -562,7 +518,6 @@ export const PosterCanvas = (store, successCallBack) => {
mask: true mask: true
}); });
getImageInfo([store.image, store.code]).then(res => { getImageInfo([store.image, store.code]).then(res => {
console.log(res)
let contentHh = 48 * 1.3 let contentHh = 48 * 1.3
const ctx = uni.createCanvasContext('myCanvas') const ctx = uni.createCanvasContext('myCanvas')
ctx.clearRect(0, 0, 0, 0); ctx.clearRect(0, 0, 0, 0);
@ -591,7 +546,6 @@ export const PosterCanvas = (store, successCallBack) => {
ctx.setTextAlign('center') ctx.setTextAlign('center')
ctx.setFontSize(22); ctx.setFontSize(22);
ctx.setFillStyle('#333333'); ctx.setFillStyle('#333333');
console.log('长按识别二维码立即购买')
ctx.fillText('长按识别二维码立即购买', WIDTH / 2, 1167); ctx.fillText('长按识别二维码立即购买', WIDTH / 2, 1167);
ctx.save(); ctx.save();
ctx.draw(true, () => { ctx.draw(true, () => {

2
utils/request.js

@ -55,8 +55,6 @@ function baseRequest(options) {
return fly.request(url, params || data, { return fly.request(url, params || data, {
...option ...option
}).then(res => { }).then(res => {
console.log(res)
// console.log(url,params,data, ...option)
const data = res.data || {}; const data = res.data || {};
if (res.status !== 200) { if (res.status !== 200) {
return Promise.reject({ msg: "请求失败", res, data }); return Promise.reject({ msg: "请求失败", res, data });

Loading…
Cancel
Save