Commit a98feb5e by cen

fix:身份证长度

1 parent baee65d5
...@@ -124,8 +124,8 @@ export default { ...@@ -124,8 +124,8 @@ export default {
uni.hideLoading() uni.hideLoading()
const fileExtension = res.tempFiles[0]?.name ? res.tempFiles[0]?.name.split('.').pop().toLowerCase() : res.tempFiles[0]?.path.split('.').pop().toLowerCase() // const fileExtension = res.tempFiles[0]?.name ? res.tempFiles[0]?.name.split('.').pop().toLowerCase() : res.tempFiles[0]?.path.split('.').pop().toLowerCase()
this.addMedia(field, { url, fileFormat: fileExtension || 'png', type: 'image', name: field.label }) this.addMedia(field, { url, fileFormat: 'png', type: 'image', name: field.label })
} }
} catch (error) { } catch (error) {
console.log('上传图片失败', error) console.log('上传图片失败', error)
...@@ -157,8 +157,8 @@ export default { ...@@ -157,8 +157,8 @@ export default {
const url = await uploadFile(tempFilePath) const url = await uploadFile(tempFilePath)
console.log('上传图片成功', url) console.log('上传图片成功', url)
uni.hideLoading() uni.hideLoading()
const fileExtension = res.tempFiles[0]?.name ? res.tempFiles[0]?.name.split('.').pop().toLowerCase() : res.tempFiles[0]?.path.split('.').pop().toLowerCase() // const fileExtension = res.tempFiles[0]?.name ? res.tempFiles[0]?.name.split('.').pop().toLowerCase() : res.tempFiles[0]?.path.split('.').pop().toLowerCase()
this.addMedia(field, { url, fileFormat: fileExtension, type: 'image', fileFormat: fileExtension || 'png', name: field.label }) this.addMedia(field, { url, fileFormat: 'png', type: 'image', name: field.label })
} }
} catch (error) { } catch (error) {
console.log('上传图片失败', error) console.log('上传图片失败', error)
...@@ -187,11 +187,11 @@ export default { ...@@ -187,11 +187,11 @@ export default {
uni.showLoading({ title: '上传中...' }) uni.showLoading({ title: '上传中...' })
const url = await uploadFile(res.tempFilePath) const url = await uploadFile(res.tempFilePath)
console.log('上传视频成功', url) console.log('上传视频成功', url)
const fileExtension = res.name ? res.name.split('.').pop().toLowerCase() : res.tempFilePath.split('.').pop().toLowerCase() // const fileExtension = res.name ? res.name.split('.').pop().toLowerCase() : res.tempFilePath.split('.').pop().toLowerCase()
this.addMedia(field, { this.addMedia(field, {
url, url,
type: 'video', type: 'video',
fileFormat: fileExtension || 'mp4', fileFormat: 'mp4',
name: field.label, name: field.label,
duration: res.duration, duration: res.duration,
size: res.size size: res.size
...@@ -224,14 +224,14 @@ export default { ...@@ -224,14 +224,14 @@ export default {
uni.showLoading({ title: '上传中...' }) uni.showLoading({ title: '上传中...' })
const url = await uploadFile(res.tempFilePath) const url = await uploadFile(res.tempFilePath)
console.log('上传视频成功', url) console.log('上传视频成功', url)
const fileExtension = res.name ? res.name.split('.').pop().toLowerCase() : res.tempFilePath.split('.').pop().toLowerCase() // const fileExtension = res.name ? res.name.split('.').pop().toLowerCase() : res.tempFilePath.split('.').pop().toLowerCase()
this.addMedia(field, { this.addMedia(field, {
url, url,
type: 'video', type: 'video',
name: field.label, name: field.label,
duration: res.duration, duration: res.duration,
size: res.size, size: res.size,
fileFormat: fileExtension || 'mp4' fileFormat: 'mp4'
}) })
uni.hideLoading() uni.hideLoading()
} catch (error) { } catch (error) {
......
...@@ -565,6 +565,10 @@ export default { ...@@ -565,6 +565,10 @@ export default {
// 判断编辑记录 // 判断编辑记录
that.tabs.find(i => i.key === 'editRecords').hidden = false that.tabs.find(i => i.key === 'editRecords').hidden = false
} }
if (that.detailsInfo.carHandoverInfo && that.detailsInfo.images.length > 0) {
// 判断交车确认
that.tabs.find(i => i.key === 'delivery').hidden = false
}
} else { } else {
uni.hideLoading() uni.hideLoading()
uni.showToast({ uni.showToast({
......
...@@ -625,7 +625,8 @@ export default { ...@@ -625,7 +625,8 @@ export default {
sourceKey: 'uuid', sourceKey: 'uuid',
targetKey: 'phone', targetKey: 'phone',
type: 'input', type: 'input',
inputType: 'number' inputType: 'number',
maxlength: 11
}, },
{ {
key: 'idCard', key: 'idCard',
...@@ -713,7 +714,8 @@ export default { ...@@ -713,7 +714,8 @@ export default {
sourceKey: 'uuid', sourceKey: 'uuid',
targetKey: 'phone', targetKey: 'phone',
type: 'input', type: 'input',
inputType: 'number' inputType: 'number',
maxlength: 11
}, },
{ {
key: 'idCard', key: 'idCard',
...@@ -724,7 +726,8 @@ export default { ...@@ -724,7 +726,8 @@ export default {
sourceNameKey: 'staffName', sourceNameKey: 'staffName',
sourceKey: 'uuid', sourceKey: 'uuid',
targetKey: 'idCard', targetKey: 'idCard',
type: 'input' type: 'input',
maxlength: 18
}, },
{ {
key: 'address', key: 'address',
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!