diff --git a/src/views/daxpay/h5/onboarded/common/OnbMchApply.api.ts b/src/views/daxpay/h5/onboarded/common/OnbMchApply.api.ts index ecdbcf5..ac5da55 100644 --- a/src/views/daxpay/h5/onboarded/common/OnbMchApply.api.ts +++ b/src/views/daxpay/h5/onboarded/common/OnbMchApply.api.ts @@ -13,16 +13,15 @@ export function findAllProvinceAndCityAndArea() { /** * 提交进件申请 */ -export function submit(id, headers) { +export function submit(id, sign, headers) { return http.request({ url: '/onb/mch/apply/submit', method: 'post', - params: { id }, + params: { id, sign }, headers, }) } - /** * 身份证OCR */ diff --git a/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.api.ts b/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.api.ts index 34a6459..9426362 100644 --- a/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.api.ts +++ b/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.api.ts @@ -12,11 +12,11 @@ import type { /** * 查询 */ -export function findById(id, headers) { +export function findById(id, sign, headers) { return http.request>({ method: 'get', - url: '/hkrt/onb/apply/findById', - params: { id }, + url: '/hkrt/onb/apply/h5/findById', + params: { id, sign }, headers, }) } @@ -24,11 +24,12 @@ export function findById(id, headers) { /** * 保存信息 */ -export function save(param: MerchantApply, headers) { +export function save(param: MerchantApply, sign, headers) { return http.request>({ method: 'post', - url: '/hkrt/onb/apply/save', + url: '/hkrt/onb/apply/h5/save', data: param, + params: { sign }, headers, }) } diff --git a/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.vue b/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.vue index add5bce..4ed5637 100644 --- a/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.vue +++ b/src/views/daxpay/h5/onboarded/hkrt/HkrtApply.vue @@ -591,7 +591,7 @@ import type { WebHeaders } from '#/web' import router from '@/router' const route = useRoute() -const { id: applyId, token } = route.query +const { id: applyId, sign, token } = route.query // 请求头信息 const headers = { 'AccessToken': token, @@ -667,7 +667,11 @@ function initData() { * 获取数据 */ function getInfo() { - findById(applyId, headers).then(({ data }) => { + findById(applyId, sign, headers).then(({ code, data, msg }) => { + if (code !== 0) { + router.replace({ name: 'payFail', query: { msg, title: '获取信息失败' } }) + return + } form.value = data }) } @@ -698,7 +702,7 @@ function nextClick() { */ function saveTemp() { loading.value = true - save(form.value, headers).then(({ code, msg }) => { + save(form.value, sign, headers).then(({ code, msg }) => { if (code !== 0) { showNotify({ type: 'danger', message: msg }) } @@ -717,7 +721,7 @@ function submitClick() { .validate() .then(() => { // 执行下一步操作 - submit(form.value.applyId, headers).then(({ code, data }) => { + submit(form.value.applyId, sign, headers).then(({ code, data }) => { if (code !== 0) { showNotify({ type: 'danger', message: data }) } diff --git a/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.api.ts b/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.api.ts index 7201927..08e4212 100644 --- a/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.api.ts +++ b/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.api.ts @@ -12,11 +12,11 @@ import type { /** * 查询 */ -export function findById(id, headers) { +export function findById(id, sign, headers) { return http.request>({ method: 'get', - url: '/leshua/onb/apply/findById', - params: { id }, + url: '/leshua/onb/apply/h5/findById', + params: { id, sign }, headers, }) } @@ -24,11 +24,12 @@ export function findById(id, headers) { /** * 保存信息 */ -export function save(param: MerchantApply, headers) { +export function save(param: MerchantApply, sign, headers) { return http.request>({ method: 'post', - url: '/leshua/onb/apply/save', + url: '/leshua/onb/apply/h5/save', data: param, + params: { sign }, headers, }) } diff --git a/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.vue b/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.vue index ded7b88..25f9bad 100644 --- a/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.vue +++ b/src/views/daxpay/h5/onboarded/leshua/LeshuaApply.vue @@ -558,7 +558,7 @@ import type { WebHeaders } from '#/web' import router from '@/router' const route = useRoute() -const { id: applyId, token } = route.query +const { id: applyId, sign, token } = route.query // 请求头信息 const headers = { 'AccessToken': token, @@ -634,7 +634,11 @@ function initData() { * 获取数据 */ function getInfo() { - findById(applyId, headers).then(({ data }) => { + findById(applyId, sign, headers).then(({ code, data, msg }) => { + if (code !== 0) { + router.replace({ name: 'payFail', query: { msg, title: '获取信息失败' } }) + return + } form.value = data }) } @@ -665,7 +669,7 @@ function nextClick() { */ function saveTemp() { loading.value = true - save(form.value, headers).then(({ code, msg }) => { + save(form.value, sign, headers).then(({ code, msg }) => { if (code !== 0) { showNotify({ type: 'danger', message: msg }) } @@ -684,7 +688,7 @@ function submitClick() { .validate() .then(() => { // 执行下一步操作 - submit(form.value.applyId, headers).then(({ code, data }) => { + submit(form.value.applyId, sign, headers).then(({ code, data }) => { if (code !== 0) { showNotify({ type: 'danger', message: data }) } diff --git a/src/views/daxpay/h5/onboarded/vbill/VbillApply.api.ts b/src/views/daxpay/h5/onboarded/vbill/VbillApply.api.ts index 061c50d..12ab9d9 100644 --- a/src/views/daxpay/h5/onboarded/vbill/VbillApply.api.ts +++ b/src/views/daxpay/h5/onboarded/vbill/VbillApply.api.ts @@ -12,11 +12,11 @@ import type { /** * 查询 */ -export function findById(id, headers) { +export function findById(id, sign, headers) { return http.request>({ method: 'get', - url: '/vbill/onb/apply/findById', - params: { id }, + url: '/vbill/onb/apply/h5/findById', + params: { id, sign }, headers, }) } @@ -24,11 +24,12 @@ export function findById(id, headers) { /** * 保存信息 */ -export function save(param: MerchantApply, headers) { +export function save(param: MerchantApply, sign, headers) { return http.request>({ method: 'post', - url: '/vbill/onb/apply/save', + url: '/vbill/onb/apply/h5/save', data: param, + params: { sign }, headers, }) } diff --git a/src/views/daxpay/h5/onboarded/vbill/VbillApply.vue b/src/views/daxpay/h5/onboarded/vbill/VbillApply.vue index 65d4110..a1e1580 100644 --- a/src/views/daxpay/h5/onboarded/vbill/VbillApply.vue +++ b/src/views/daxpay/h5/onboarded/vbill/VbillApply.vue @@ -680,7 +680,7 @@ import type { WebHeaders } from '#/web' import router from '@/router' const route = useRoute() -const { id: applyId, token } = route.query +const { id: applyId, sign, token } = route.query // 请求头信息 const headers = { 'AccessToken': token, @@ -756,7 +756,11 @@ function initData() { * 获取数据 */ function getInfo() { - findById(applyId, headers).then(({ data }) => { + findById(applyId, sign, headers).then(({ code, data, msg }) => { + if (code !== 0) { + router.replace({ name: 'payFail', query: { msg, title: '获取信息失败' } }) + return + } form.value = data }) } @@ -787,7 +791,7 @@ function nextClick() { */ function saveTemp() { loading.value = true - save(form.value, headers).then(({ code, msg }) => { + save(form.value, sign, headers).then(({ code, msg }) => { if (code !== 0) { showNotify({ type: 'danger', message: msg }) } @@ -806,7 +810,7 @@ function submitClick() { .validate() .then(() => { // 执行下一步操作 - submit(form.value.applyId, headers).then(({ code, data }) => { + submit(form.value.applyId, sign, headers).then(({ code, data }) => { if (code !== 0) { showNotify({ type: 'danger', message: data }) }