Commit 406b66c4 by 张立顺

错误提示修改

1 parent 17b0476d
# 开发调试流程
本地开发需要联系运维给配置一个https地址映射到本地的某个开发地址 调试调试要在支付宝客户端可以在路由里面去除
https://zlsdev.glsx.com.cn/#/alipay
# 配置中心获取的对应环境的appid
开发环境 2021003146603701
......
......@@ -11,7 +11,7 @@ axios.defaults.withCredentials = true
// 创建一个错误
export function errorCreate(msg) {
const error = new Error(msg)
errorLog(error)
errorLog(msg)
throw error
}
// 记录和显示错误
......@@ -29,10 +29,11 @@ function errorLog(error) {
log.danger('>>>>>> Error >>>>>>')
console.log(error)
}
// console.log(error.message)
// 显示提示
Notify({
message: error.message,
type: 'error',
message: error,
type: 'danger',
duration: 5 * 1000
})
}
......@@ -115,6 +116,7 @@ service.interceptors.response.use(
// solution: "将添加会话ID请求参数",
// subErrors: null
// }
const dataAxios = response.data
console.log('dataAxios', dataAxios)
const ruleResult = baseConfig.axios.result
......
......@@ -39,7 +39,7 @@ import {
// Cascader,
// Checkbox,
// CheckboxGroup,
// Notify,
Notify,
// Icon,
// Empty,
// PullRefresh,
......@@ -52,7 +52,7 @@ import {
Toast
} from 'vant'
export const components = [
Toast
Toast,
// Button,
// List,
// Cell,
......@@ -84,7 +84,7 @@ export const components = [
// Cascader,
// Checkbox,
// CheckboxGroup,
// Notify,
Notify
// Icon,
// Empty,
// PullRefresh,
......
......@@ -208,7 +208,7 @@ export default {
},
// 隐藏键盘
handleHiddenKey() {
this.keyHidden = true
// this.keyHidden = true
},
// 显示键盘
handleShowKey() {
......@@ -287,10 +287,16 @@ export default {
duration: 0
})
createWxPayH5(params).then((result) => {
const { tradeNO } = JSON.parse(result.jsapiPayInfo)
this.tradeNO = tradeNO
console.log('tradeNO', tradeNO)
this.tradeNO && this.aliPayment()
console.log(result, 'result')
const { code, data, message } = result
if (code == 0) {
const { tradeNO } = JSON.parse(result.jsapiPayInfo)
this.tradeNO = tradeNO
console.log('tradeNO', tradeNO)
this.tradeNO && this.aliPayment()
} else {
this.$toast.fail(message || '支付失败')
}
}).catch((err) => {
console.log(err)
}).finally(() => {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!