修改开发
This commit is contained in:
@@ -167,7 +167,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {getTemplate,getInfoByIdCard,caseApplicationInsert,updateComfire} from '../../../api/handlecase/index.js'
|
||||
import {getTemplate,getInfoByIdCard,caseApplicationInsert,updateComfire,caseApplicationSelectById} from '../../../api/handlecase/index.js'
|
||||
import {
|
||||
getToken
|
||||
} from '@/utils/auth'
|
||||
@@ -183,6 +183,7 @@
|
||||
columnValueList: [],
|
||||
caseAttachList: [],
|
||||
},
|
||||
ids:null,
|
||||
tempFilePaths: null,
|
||||
templateList:[],
|
||||
objectiJurisArr: [{
|
||||
@@ -210,7 +211,7 @@
|
||||
|
||||
validateFunction: (rule, value, data, callback) => {
|
||||
//判断手机号格式时候正确
|
||||
if (value.length<3) {
|
||||
if (value.length<1) {
|
||||
if(this.formData.affiliate.organizeFlag == 0){
|
||||
callback('请输入申请人姓名')
|
||||
}else{
|
||||
@@ -257,7 +258,12 @@
|
||||
},
|
||||
submitReasont(){
|
||||
this.$refs.form.validate().then(res=>{
|
||||
this.insertFn(this.formData)
|
||||
if(this.ids){
|
||||
this.modifyData(this.formData)
|
||||
}else{
|
||||
this.insertFn(this.formData)
|
||||
}
|
||||
|
||||
}).catch(err =>{
|
||||
|
||||
})
|
||||
@@ -271,6 +277,13 @@
|
||||
})
|
||||
});
|
||||
},
|
||||
/** 根据案件id获取对应信息 */
|
||||
caseApplicationSelectByIdFn(data) {
|
||||
caseApplicationSelectById(data).then(res=>{
|
||||
res.data.affiliate.respondentSex = Number(res.data.affiliate.respondentSex)
|
||||
this.formData = res.data
|
||||
})
|
||||
},
|
||||
// 被申请人获取性别出生年月
|
||||
handleBlur(){
|
||||
let idCards = {
|
||||
@@ -355,6 +368,13 @@
|
||||
}
|
||||
},
|
||||
onLoad(data) {
|
||||
this.ids = data.id
|
||||
if(this.ids){
|
||||
this.caseApplicationSelectByIdFn({id:data.id})
|
||||
uni.setNavigationBarTitle({title:"案件修改"})
|
||||
}else{
|
||||
uni.setNavigationBarTitle({title:"案件新增"})
|
||||
}
|
||||
this.getTemplateFn()
|
||||
},
|
||||
onReady() {
|
||||
|
||||
Reference in New Issue
Block a user