Commit 4e34cf47 authored by qinj's avatar qinj

rule校验修改

parent 453641a7
...@@ -53,7 +53,6 @@ ...@@ -53,7 +53,6 @@
<el-select v-if="formData.ExtProcessNode_SDK==2" <el-select v-if="formData.ExtProcessNode_SDK==2"
v-model="formData.ExtChannelType_SDK" v-model="formData.ExtChannelType_SDK"
style="width: 91%" style="width: 91%"
placeholder="请选择" placeholder="请选择"
no-match-text="无匹配数据"> no-match-text="无匹配数据">
<el-option v-for="item in cOptions" <el-option v-for="item in cOptions"
...@@ -165,7 +164,10 @@ export default { ...@@ -165,7 +164,10 @@ export default {
status: 0, status: 0,
loading: false, loading: false,
tableData2: [], tableData2: [],
formData: {}, formData: {
ExtLockRsp_SDK:[],
ExtLockCity_SDK:[],
},
province: [], province: [],
sections: [ sections: [
{ {
...@@ -340,8 +342,8 @@ export default { ...@@ -340,8 +342,8 @@ export default {
// 同 vue-ele-form // 同 vue-ele-form
rules: { rules: {
ExtChannelType_SDK: {required: true, message: '请选择签约渠道类型',trigger: 'change' }, ExtChannelType_SDK: {required: true, message: '请选择签约渠道类型',trigger: 'change' },
ExtLockRsp_SDK: { required: true, message: '请选择锁定RSP' }, ExtLockRsp_SDK: { required: true, message: '请选择锁定RSP',trigger: 'change' },
ExtLockCity_SDK: { required: true, message: '请选择城市覆盖范围' }, ExtLockCity_SDK: { required: true, message: '请选择城市覆盖范围',trigger: 'change' },
} }
} }
}, },
...@@ -370,9 +372,9 @@ export default { ...@@ -370,9 +372,9 @@ export default {
this.loading=true this.loading=true
getCustomer({ objectID: this.id }).then((resp) => { getCustomer({ objectID: this.id }).then((resp) => {
this.loading=false this.loading=false
resp.results[0].ExtChannelType_SDK=null
resp.results[0].ExtChannelType_SDKText=null
this.formData = resp.results[0] this.formData = resp.results[0]
this.formData.ExtLockRsp_SDK=[]
this.formData.ExtLockCity_SDK=[]
lockRsp({ extProvince_SDK: resp.results[0].ExtProvince_SDK }).then((resp) => { lockRsp({ extProvince_SDK: resp.results[0].ExtProvince_SDK }).then((resp) => {
this.province = resp.results this.province = resp.results
}) })
...@@ -427,8 +429,13 @@ export default { ...@@ -427,8 +429,13 @@ export default {
// this.$message.success('创建成功') // this.$message.success('创建成功')
}, },
approve() { approve() {
this.dialogFormVisible = true if(this.formData.ExtLockRsp_SDK.length==0||this.formData.ExtLockCity_SDK.length==0||this.formData.ExtChannelType_SDK.length==0){
this.status = 1 return this.$message.warning('请输入必填信息')
}else{
this.dialogFormVisible = true
this.status = 1
}
}, },
reject() { reject() {
this.dialogFormVisible = true this.dialogFormVisible = true
......
...@@ -126,7 +126,9 @@ export default { ...@@ -126,7 +126,9 @@ export default {
id: '', id: '',
status: 0, status: 0,
loading: false, loading: false,
formData: {}, formData: {
ExtLockCity_SDK:[]
},
province: [], province: [],
tableData2: [], tableData2: [],
sections: [ sections: [
...@@ -343,6 +345,7 @@ export default { ...@@ -343,6 +345,7 @@ export default {
getCustomer({ objectID: this.id }).then((resp) => { getCustomer({ objectID: this.id }).then((resp) => {
this.loading=false this.loading=false
this.formData = resp.results[0] this.formData = resp.results[0]
this.formData.ExtLockCity_SDK=[]
const app = { provinceCode: resp.results[0].ExtProvince_SDK } const app = { provinceCode: resp.results[0].ExtProvince_SDK }
this.$request(Country.searchCity, app).then((resp) => { this.$request(Country.searchCity, app).then((resp) => {
this.province = resp.results this.province = resp.results
...@@ -372,8 +375,14 @@ export default { ...@@ -372,8 +375,14 @@ export default {
// this.$message.success('创建成功') // this.$message.success('创建成功')
}, },
approve() { approve() {
this.dialogFormVisible = true console.log('formdadada',this.formData)
this.status = 1 if(this.formData.ExtLockCity_SDK.length==0){
return this.$message.warning('请输入必填信息')
}else{
this.dialogFormVisible = true
this.status = 1
}
}, },
reject() { reject() {
this.dialogFormVisible = true this.dialogFormVisible = true
......
...@@ -325,10 +325,10 @@ ...@@ -325,10 +325,10 @@
label="社会统一信用代码"> label="社会统一信用代码">
</el-table-column> </el-table-column>
</el-table> </el-table>
<pagination v-show="TotalRecords>0" <pagination v-show="page.TotalRecords>0"
:total="TotalRecords" :total="page.TotalRecords"
:page.sync="page.PageIndex" :page.sync="page.CurrentPage"
:limit.sync="page.pageSize" :limit.sync="page.PageSize"
@pagination="getList" /> @pagination="getList" />
</el-dialog> </el-dialog>
...@@ -379,9 +379,10 @@ export default { ...@@ -379,9 +379,10 @@ export default {
dialogTableVisible: false, dialogTableVisible: false,
TotalRecords: 0, TotalRecords: 0,
page: { page: {
currentPage: 0, TotalRecords: 0,
pageSize: 0, PageIndex: 0,
PageSize: 10,
CurrentPage:1
} }
} }
...@@ -399,12 +400,12 @@ export default { ...@@ -399,12 +400,12 @@ export default {
}, },
methods: { methods: {
getList() { getList() {
this.page.TotalRecords=null
this.page.searchKey = this.formInline.Name this.page.searchKey = this.formInline.Name
this.$request(Qcc.searchUrl, this.page).then((resp) => { this.$request(Qcc.searchUrl, this.page).then((resp) => {
if (resp.results.Result) { if (resp.results.Result) {
this.tableData = resp.results.Result this.tableData = resp.results.Result
this.page = resp.results.Paging this.page = resp.results.Paging
this.TotalRecords = resp.results.Paging.TotalRecords
} else { } else {
this.$message.warning('无相关公司!') this.$message.warning('无相关公司!')
} }
......
...@@ -18,6 +18,7 @@ ...@@ -18,6 +18,7 @@
<el-col :span="13" <el-col :span="13"
class="padding-bottom"> class="padding-bottom">
<el-form-item label="公司全称:" <el-form-item label="公司全称:"
prop="Name"
label-width="150px"> label-width="150px">
<el-input v-model="formData.name" <el-input v-model="formData.name"
readonly readonly
...@@ -304,7 +305,6 @@ ...@@ -304,7 +305,6 @@
label-width="120px"> label-width="120px">
<el-select v-model="formData.extChannelType_SDK" <el-select v-model="formData.extChannelType_SDK"
style="width: 91%" style="width: 91%"
filterable
placeholder="请选择" placeholder="请选择"
no-match-text="无匹配数据"> no-match-text="无匹配数据">
<el-option v-for="item in aOptions" <el-option v-for="item in aOptions"
...@@ -322,7 +322,6 @@ ...@@ -322,7 +322,6 @@
<el-select v-model="formData.extProductGroup_KUT" <el-select v-model="formData.extProductGroup_KUT"
style="width: 91%" style="width: 91%"
multiple multiple
filterable
placeholder="请选择" placeholder="请选择"
no-match-text="无匹配数据" no-match-text="无匹配数据"
@change="handSelect2"> @change="handSelect2">
...@@ -445,7 +444,10 @@ export default { ...@@ -445,7 +444,10 @@ export default {
}, },
data() { data() {
return { return {
formData: {}, formData: {
extProductGroup_KUT:[],
extTotalAgent_KUT:[]
},
inputEnter: false, inputEnter: false,
countryArea: '', countryArea: '',
formInline: {}, formInline: {},
...@@ -456,9 +458,9 @@ export default { ...@@ -456,9 +458,9 @@ export default {
countryOptions: [], countryOptions: [],
cityOptions: [], cityOptions: [],
disOptions: [], disOptions: [],
aOptions: [], aOptions: '',
bOptions: [], bOptions: '',
cOptions: [], cOptions: '',
supplierBaseRules: { supplierBaseRules: {
extSocialUnifiedCreditCode_SDK: [{ required: true, message: '请输入统一社会信用代码',trigger:'blur' }], extSocialUnifiedCreditCode_SDK: [{ required: true, message: '请输入统一社会信用代码',trigger:'blur' }],
// extRegisteredCapital_SDK: [{ required: true, message: '请输入注册资本(万元)' }], // extRegisteredCapital_SDK: [{ required: true, message: '请输入注册资本(万元)' }],
...@@ -479,9 +481,9 @@ export default { ...@@ -479,9 +481,9 @@ export default {
extBusinessPhone_SDK: [{ required: true, message: '请输入商务负责人电话', trigger: 'blur' }], extBusinessPhone_SDK: [{ required: true, message: '请输入商务负责人电话', trigger: 'blur' }],
extBusinessEmail_SDK: [{ required: true, message: '请输入商务负责人邮箱', trigger: 'blur' }, extBusinessEmail_SDK: [{ required: true, message: '请输入商务负责人邮箱', trigger: 'blur' },
{ type: 'email', message: '请输入正确的邮箱地址', trigger: ['blur', 'change'] }], { type: 'email', message: '请输入正确的邮箱地址', trigger: ['blur', 'change'] }],
extChannelType_SDK: [{ required: true, message: '请选择签约渠道类型' }], extChannelType_SDK: [{ required: true, message: '请选择签约渠道类型',trigger: 'change' }],
extProductGroup_KUT: [{ required: true, message: '请选择签约产品组' }], extProductGroup_KUT: [{ required: true, message: '请选择签约产品组',trigger: ["blur",'change'] }],
extTotalAgent_KUT: [{ required: true, message: '请选择签约总代' }], extTotalAgent_KUT: [{ required: true, message: '请选择签约总代',trigger: ["blur",'change'] }],
file: [{ required: true, message: '请上传附件' }], file: [{ required: true, message: '请上传附件' }],
}, },
dialogTableVisible: false, dialogTableVisible: false,
...@@ -502,6 +504,7 @@ export default { ...@@ -502,6 +504,7 @@ export default {
}, },
}, },
created() { created() {
this.$refs.formData && this.$refs.formData.resetFields();
this.selectCountry() this.selectCountry()
this.getCommon() this.getCommon()
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment