单选搞定
This commit is contained in:
@@ -48,13 +48,15 @@
|
||||
</div>
|
||||
|
||||
<!-- 单选 是 4 -->
|
||||
<div class="calendar" v-if="item.fieldType == 4">
|
||||
<div class="calendar" v-if="item.fieldDataType == 4">
|
||||
<div class="left">
|
||||
<span class="icon" v-if="item.mustFill == 1">*</span>
|
||||
<span> {{ item.fieldName }}:</span>
|
||||
</div>
|
||||
<div class="left">
|
||||
<u-input type="text" @click="timeSelect(index)" class="right" placeholder="请选择" disabled v-model="item.fieldValue"></u-input>
|
||||
<u-input type="text" @click="showStstus = true" class="right" placeholder="请选择" disabled v-model="item.fieldValue"></u-input>
|
||||
|
||||
<u-select v-model="showStstus" :list="$dict.getDict(item.dictionaryCode)" value-name="dictValue" label-name="dictName" @confirm="selectStatus"></u-select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -110,12 +112,12 @@ export default {
|
||||
filedIndex: 0,
|
||||
fileNameList: [],
|
||||
opinion: '',
|
||||
showStstus: false,
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
this.objid = options.id
|
||||
this.type = options.type
|
||||
|
||||
this.getList()
|
||||
},
|
||||
onShow() {
|
||||
@@ -131,15 +133,13 @@ export default {
|
||||
.post(`/app/approv-alapply-info/approval-popup?type=${this.type}&id=${this.objid}`)
|
||||
.then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.list = res.data.fieldInfos
|
||||
console.log(this.list)
|
||||
res.data.fieldInfos.map((item) => {
|
||||
// this.list.push(item)
|
||||
// if (item.fieldDataType == 1) {
|
||||
// item.fieldValue = ''
|
||||
// }
|
||||
// if (item.fieldType == 3) {
|
||||
// }
|
||||
if (item.fieldType != 3) {
|
||||
item.fieldValue = ''
|
||||
}
|
||||
if (item.fieldType == 3) {
|
||||
this.list.push(item)
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
@@ -162,6 +162,10 @@ export default {
|
||||
})
|
||||
},
|
||||
|
||||
selectStatus(e) {
|
||||
this.$set(this.list[index], 'fieldValue', this.value)
|
||||
},
|
||||
|
||||
btn() {
|
||||
// if (this.type == 0 && this.opinion == '') {
|
||||
// return uni.showToast({
|
||||
|
||||
Reference in New Issue
Block a user