【update】 增加是否是内部企业的判断

This commit is contained in:
fengchenchen
2022-04-26 11:43:33 +08:00
parent 56fc5b2f87
commit b2dc828593
2 changed files with 36 additions and 6 deletions
+5 -1
View File
@@ -46,6 +46,9 @@ const commonMemberCost = '2000'
// 会员五年期的缴费的费用
const vipMemberCost = '10000'
// 判断当前企业是否是内部企业
const judgeInternalEnterprise = (param) => getAction('/company/payCompanyManagement/getInternalEnterprise', param)
export {
queryCommonProjectById,
getMeetInfoById,
@@ -68,5 +71,6 @@ export {
getAllUserList,
queryContactByName,
commonMemberCost,
vipMemberCost
vipMemberCost,
judgeInternalEnterprise
}
+31 -5
View File
@@ -137,7 +137,7 @@
<a-radio-group v-decorator="['identity',validatorRules.identify]" @change="changeIdentify">
<a-radio :value="1">嘉宾</a-radio>
<a-radio :value="2">参会人</a-radio>
<a-radio :value="3">内部企业</a-radio>
<a-radio :value="3" :disabled="!isInternalEnterprise">内部企业</a-radio>
</a-radio-group>
</a-form-item>
</a-col>
@@ -156,7 +156,7 @@
<a-form-item label="身份" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-radio-group v-decorator="['identity',validatorRules.identify]" @change="changeIdentify">
<a-radio :value="2">参会人</a-radio>
<a-radio :value="3">内部企业</a-radio>
<a-radio :value="3" :disabled="!isInternalEnterprise">内部企业</a-radio>
</a-radio-group>
</a-form-item>
</a-col>
@@ -227,7 +227,7 @@
</template>
<script>
import {getMeetInfoById,validateStandard} from '@api/incomePaymentsApi'
import {getMeetInfoById,validateStandard, judgeInternalEnterprise} from '@api/incomePaymentsApi'
import SelectContacts from '@comp/company/SelectContacts'
import CompanySelect from '@comp/company/CompanySelect'
import {httpAction} from '@api/manage'
@@ -342,7 +342,9 @@ export default {
urlHaveIdBool: false,
url: {
add: '/meeting/payMeetingSituation/signUp'
}
},
// 当前参会企业是否是内部企业
isInternalEnterprise: false,
}
},
created() {
@@ -585,6 +587,10 @@ export default {
this.$refs.formother.clearFormItem()
}
// 判断当前企业是否是内部企业
console.log('------this.selectedCompany-----------', this.selectedCompany)
this.judgeInternalEnterprise(this.selectedCompany.id)
},
/*
* 选择联系人获取信息
@@ -609,6 +615,26 @@ export default {
})
},
/*
* 判断当前的企业是否是内部企业,如果是修改isInternalEnterprise
* */
judgeInternalEnterprise(id) {
let params = {
id: id
}
judgeInternalEnterprise(params).then(res => {
if(res.success) {
this.isInternalEnterprise = res.result !== 'false'
}
}).finally(() => {
// 清空form表单身份的数据
this.form.setFieldsValue({
identity: null
})
// 嘉宾类型置空
this.guestType = null
})
},
/*
* 是否有邀请码
* */
changeInviteCode(e) {
@@ -859,4 +885,4 @@ export default {
flex-shrink: 0;
}
}
</style>
</style>