Commit c817895a by 李伟康

fix(Form): 更新表单组件中的只读属性为禁用属性

将 GlCell.vue 中的 `readonly` 属性替换为 `disabled`,以统一控制输入框状态。

feat(equity-form): 优化权益商品表单数据初始化逻辑

避免在 externalData 变化时重复覆盖 goodInfoList 数据,提升表单稳定性。

feat(equity-tire): 防止轮胎表单数据被意外重置

在监听 externalData 时增加判断,若 tireObj 已有数据则不再重新赋值,防止数据丢失。
1 parent 49e47de8
......@@ -73,7 +73,7 @@
:maxlength="item.maxlength ? item.maxlength : -1"
placeholder-class="input-placeholder"
@input="item.inputType === 'number' && item.maxlength ? (formData[item.value] = String($event.target.value).slice(0, item.maxlength)) : null"
:readonly="item.readonly || false"
:disabled="item.readonly || item.disabled || false"
/>
<view
v-if="item.valueIcon"
......
......@@ -176,7 +176,7 @@ export default {
watch: {
externalData: {
handler (val) {
this.goodInfoList = val.goodInfoList || []
if (!this.goodInfoList.length) this.goodInfoList = val.goodInfoList || []
},
deep: true,
immediate: true
......@@ -191,7 +191,7 @@ export default {
extendServiceFormList,
oilProFormList,
cellBoxStyle: 'background: #f5f7fa;',
goodInfoList:[],
goodInfoList: [],
viewKey: Date.now(),
currentData: {},
popupType: 0,
......
......@@ -64,6 +64,7 @@ export default {
watch: {
externalData: {
handler (val) {
if (Object.keys(this.tireObj).length) return
const keyList = [
'tireBrand', 'tireScale',
'leftFrontDTO', 'leftFrontBatch',
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!