Commit 0616e6a5 by cen

fix: 更换请求连接

1 parent e872580d
......@@ -104,27 +104,33 @@ const djSecretKey = {
const signSecretKey = {
ip: {
appKey: 'App_PromoteBusiness',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b',
carBasrUrl: 'http://qcdidicb.glsx.com.cn/router'
},
dev: {
appKey: 'App_PromoteBusiness',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b',
carBasrUrl: 'http://qcdidicb.glsx.com.cn/router'
},
uat: {
appKey: 'App_PromoteBusiness',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b',
carBasrUrl: 'http://qcdidicb.glsx.com.cn/router'
},
beta: {
appKey: '48e5e13229b82c1b4e6e8c96151f0637',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b',
carBasrUrl: 'http://didicb.glsx.com.cn/router'
},
prod: {
appKey: 'd7ffc3346fc9a45bccaaa35300d59022',
secret: '4bc07f8868374c49a4661d603377e3106fc9a45bccaaa353'
secret: '4bc07f8868374c49a4661d603377e3106fc9a45bccaaa353',
carBasrUrl: 'http://didicb.glsx.com.cn/router'
},
pet: {
appKey: 'd7ffc3346fc9a45bccaaa35300d59022',
secret: '4bc07f8868374c49a4661d603377e3106fc9a45bccaaa353'
secret: '4bc07f8868374c49a4661d603377e3106fc9a45bccaaa353',
carBasrUrl: 'http://didicb.glsx.com.cn/router'
}
}[target[index]]
......
......@@ -150,6 +150,7 @@ import { throttle } from 'lodash'
import dayjs from 'dayjs'
import permision from '@/js_sdk/wa-permission/permission.js'
import { sign, md532, md516 } from 'utils/common'
import { signSecretKey } from '@/env.js'
export default {
name: 'AddEvaluationFrom',
components: {
......@@ -633,7 +634,7 @@ export default {
const signature = sign(params, secret)
uni.request({
url: 'http://qcdidicb.glsx.com.cn/router?method=glsx.accounts.base.car.brand.complete',
url: signSecretKey.carBasrUrl + '?method=glsx.accounts.base.car.brand.complete',
method: 'GET',
dataType: 'json',
data: {
......@@ -675,7 +676,7 @@ export default {
// 优化请求方式,避免重复请求
setTimeout(() => {
uni.request({
url: 'http://qcdidicb.glsx.com.cn/router?method=glsx.accounts.base.car.types',
url: signSecretKey.carBasrUrl + '?method=glsx.accounts.base.car.types',
method: 'GET',
dataType: 'json',
data: {
......
......@@ -187,13 +187,16 @@ export default {
}
if (field.key === 'depositPrice') {
// 过滤掉所有非数字字符
const filteredValue = value.replace(/[^1-9]/g, '')
if (filteredValue !== value) {
value = filteredValue
const filteredValue = value.replace(/[^\d]/g, '')
console.log('filteredValue', filteredValue)
// 确保是正整数(大于0)
const positiveIntValue = filteredValue && parseInt(filteredValue, 10) > 0 ? filteredValue : ''
console.log('positiveIntValue', positiveIntValue)
if (positiveIntValue !== value) {
if (field.targetObj) {
this.formData[field.targetObj][field.targetKey] = value
this.formData[field.targetObj][field.targetKey] = positiveIntValue
} else {
this.formData[field.targetKey] = value
this.formData[field.targetKey] = positiveIntValue
}
this.$emit('formDataChange', this.formData)
return
......
......@@ -114,6 +114,11 @@ export default {
let { status, districts } = JSON.parse(data.data)
if (status === 0 && districts) {
that.provinceData = districts[0].districts
const chongqingProvince = that.provinceData.find(province => province.code === '500000')
if (chongqingProvince && chongqingProvince.districts && chongqingProvince.districts.length > 1) {
chongqingProvince.districts = [chongqingProvince.districts[0]]
}
console.log('provinceData', that.provinceData)
that.updateSelectionWithLoadedData()
} else {
......
......@@ -697,11 +697,6 @@ export default {
const tabExists = this.tabs.some(tab => tab.key === key)
if (tabExists) {
this.activeTabKey = key
// 滚动到顶部
uni.pageScrollTo({
scrollTop: 0,
duration: 0
})
}
},
getFieldValue(obj, path) {
......
......@@ -613,8 +613,9 @@ export default {
cell: '元',
inputType: 'number',
disabled: false,
maxlength: 7,
isCell: true,
pattern: '^\\d*$' // 只允许数字输入
pattern: '^[1-9]\\d*$'
},
{
key: 'finalPrice',
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!