|
|
@@ -0,0 +1,669 @@
|
|
|
+<template>
|
|
|
+ <basic-container>
|
|
|
+ <div>
|
|
|
+ <el-steps :active="active" align-center>
|
|
|
+ <el-step title="商户法人信息"></el-step>
|
|
|
+ <el-step title="商户主体信息"></el-step>
|
|
|
+ <el-step title="商户经营地址"></el-step>
|
|
|
+ <el-step title="结算银行卡"></el-step>
|
|
|
+ <el-step v-if="totalStep==5" title="产品信息"></el-step>
|
|
|
+ </el-steps>
|
|
|
+
|
|
|
+
|
|
|
+ <div v-show="active==1" style="margin-top: 50px;">
|
|
|
+ <el-form :model="merchantCorporationForm" :rules="merchantCorporationRules" ref="merchantCorporationForm"
|
|
|
+ label-width="170px" class="demo-ruleForm">
|
|
|
+ <el-form-item prop="idCardFront" label="法人身份证件正面照片" style="width: 45%;">
|
|
|
+ <el-upload :headers="headers" name="image" class="avatar-uploader" action="/api/ocr/idcard"
|
|
|
+ :show-file-list="false" :on-success="handleUploadLegalLicenceFront">
|
|
|
+ <img v-if="merchantCorporationForm.idCardFront" :src="merchantCorporationForm.idCardFront" class="avatar">
|
|
|
+ <i v-else class="el-icon-plus avatar-uploader-icon"></i>
|
|
|
+ </el-upload>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item prop="idCardContrary" label="法人身份证件反面照片" style="width: 45%;">
|
|
|
+ <el-upload :headers="headers" name="image" class="avatar-uploader" action="/api/ocr/idcard"
|
|
|
+ :show-file-list="false" :on-success="handleUploadLegalLicenceBack">
|
|
|
+ <img v-if="merchantCorporationForm.idCardContrary" :src="merchantCorporationForm.idCardContrary"
|
|
|
+ class="avatar">
|
|
|
+ <i v-else class="el-icon-plus avatar-uploader-icon"></i>
|
|
|
+ </el-upload>
|
|
|
+ </el-form-item>
|
|
|
+
|
|
|
+ <el-form-item :required="true" label="法人姓名" prop="legalPerson">
|
|
|
+ <el-input v-model="merchantCorporationForm.legalPerson"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item :required="true" label="法人证件号码" prop="legalLicenceNo">
|
|
|
+ <el-input v-model="merchantCorporationForm.legalLicenceNo"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item :required="true" label="法人电话" prop="mobile">
|
|
|
+ <el-input v-model="merchantCorporationForm.mobile"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-show="active==2" style="margin-top: 50px;">
|
|
|
+ <el-form :model="merchantSubjectInfo" :rules="merchantSubjectRules" ref="merchantSubjectInfo"
|
|
|
+ label-width="150px"
|
|
|
+ class="demo-ruleForm">
|
|
|
+ <el-form-item :required="true" label="商场全称" prop="signName">
|
|
|
+ <el-input v-model="merchantSubjectInfo.signName"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item :required="true" label="商场简称" prop="shortName">
|
|
|
+ <el-input v-model="merchantSubjectInfo.shortName"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-show="active==3" style="margin-top: 50px;">
|
|
|
+ <el-form :model="businessAddressForm" :rules="businessAddressRules" ref="businessAddressForm"
|
|
|
+ label-width="150px"
|
|
|
+ class="demo-ruleForm">
|
|
|
+ <el-form-item label="省份" :required="true" prop="province">
|
|
|
+ <el-select v-model="businessAddressForm.province" placeholder="请选择省份">
|
|
|
+ <el-option v-for="(item,index) in province" :key="index" :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="市区" :required="true" prop="city">
|
|
|
+ <el-select v-model="businessAddressForm.city" placeholder="请选择市区">
|
|
|
+ <el-option v-for="(item,index) in city" :key="index" :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="区省" :required="true" prop="district">
|
|
|
+ <el-select v-model="businessAddressForm.district" placeholder="请选择区县">
|
|
|
+ <el-option v-for="(item,index) in district" :key="index" :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item :required="true" label="详情地址" prop="address">
|
|
|
+ <el-input v-model="businessAddressForm.address"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-show="active==4" style="margin-top: 50px;">
|
|
|
+ <el-form :model="accountInfoForm" :rules="accountInfoRules" ref="accountInfoForm"
|
|
|
+ label-width="150px">
|
|
|
+ <el-form-item :required="true" label="银行账户号码" prop="bankCardNo">
|
|
|
+ <el-input v-model="accountInfoForm.bankCardNo"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="银行账户类型">
|
|
|
+ <el-select @change="bankAccountTypeChange" v-model="accountInfoForm.bankAccountTypeLabel"
|
|
|
+ placeholder="请选择银行账户类型">
|
|
|
+ <el-option v-for="(item,index) in bankAccountTypeList" :key="index" :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="银行账户开户总行">
|
|
|
+ <el-select filterable remote :remote-method="remoteMethod" @change="bankCodeChange"
|
|
|
+ v-model="accountInfoForm.bankCodeLabel" placeholder="请选择银行账户开户总行">
|
|
|
+ <el-option v-for="(item,index) in bankCodeList" :key="index" :label="item.label" :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-show="active==5" style="margin-top: 50px;">
|
|
|
+ <el-form :model="productInfoForm" :rules="productInfoRules" ref="productInfoForm"
|
|
|
+ label-width="150px">
|
|
|
+ <el-tooltip placement="right" effect="light">
|
|
|
+ <div slot="content">
|
|
|
+ 例如:<br/>
|
|
|
+ <pre>{{ this.tooltip }}</pre>
|
|
|
+ </div>
|
|
|
+ <el-form-item :required="true" label="开通产品信息json" prop="productInfo" style="width: 800px;">
|
|
|
+ <el-input type="textarea" :rows="6" v-model="productInfoForm.productInfo"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-tooltip>
|
|
|
+ </el-form>
|
|
|
+
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div style="display: flex;justify-content: flex-end;margin-top: 50px">
|
|
|
+ <el-button v-if="active!=1" @click="active--">上一步</el-button>
|
|
|
+ <el-button v-if="active!=totalStep" type="primary" @click="next">下一步</el-button>
|
|
|
+ <el-button :disabled="confirm" v-else type="primary" @click="next">确认</el-button>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ </div>
|
|
|
+ </basic-container>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+import {dictionaryPage} from "../../api/system/dictbiz.js";
|
|
|
+import {getLazyTree} from "../../api/base/region";
|
|
|
+import {inviteMicro} from "../../api/desk/artificial-invite-micro";
|
|
|
+
|
|
|
+export default {
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ active: 1,
|
|
|
+ confirm: false,
|
|
|
+ totalStep: 5,
|
|
|
+ mallDetail: {},
|
|
|
+ province: [],
|
|
|
+ city: [],
|
|
|
+ district: [],
|
|
|
+ //商户法人信息
|
|
|
+ merchantCorporationForm: {
|
|
|
+ /**
|
|
|
+ * 法人姓名【legalName】
|
|
|
+ */
|
|
|
+ legalPerson: "",
|
|
|
+ /**
|
|
|
+ * 法人证件类型
|
|
|
+ */
|
|
|
+ legalLicenceType: "ID_CARD",
|
|
|
+ /**
|
|
|
+ * 法人证件号码
|
|
|
+ */
|
|
|
+ legalLicenceNo: "",
|
|
|
+ /**
|
|
|
+ * 身份证-正面【legalLicenceFrontUrl】
|
|
|
+ */
|
|
|
+ idCardFront: "",
|
|
|
+ /**
|
|
|
+ * 身份证-反面【legalLicenceBackUrl】
|
|
|
+ */
|
|
|
+ idCardContrary: "",
|
|
|
+ /**
|
|
|
+ * 性别
|
|
|
+ */
|
|
|
+ gender: "",
|
|
|
+ /**
|
|
|
+ * 住址
|
|
|
+ */
|
|
|
+ addr: "",
|
|
|
+ /**
|
|
|
+ * 民族
|
|
|
+ */
|
|
|
+ nationality: "",
|
|
|
+ /**
|
|
|
+ * 有效日期
|
|
|
+ */
|
|
|
+ validDate: "",
|
|
|
+ /**
|
|
|
+ * 法人电话
|
|
|
+ */
|
|
|
+ mobile: "",
|
|
|
+ },
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 商户主体信息
|
|
|
+ */
|
|
|
+ merchantSubjectInfo: {
|
|
|
+ /**
|
|
|
+ * 商户签约名称
|
|
|
+ */
|
|
|
+ signName: "",
|
|
|
+ /**
|
|
|
+ * 商户简称
|
|
|
+ */
|
|
|
+ shortName: "",
|
|
|
+ },
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 商城经营地址
|
|
|
+ */
|
|
|
+ businessAddressForm: {
|
|
|
+ /**
|
|
|
+ * 省
|
|
|
+ */
|
|
|
+ province: "",
|
|
|
+ /**
|
|
|
+ * 市
|
|
|
+ */
|
|
|
+ city: "",
|
|
|
+ /**
|
|
|
+ * 区
|
|
|
+ */
|
|
|
+ district: "",
|
|
|
+ /**
|
|
|
+ * 详情地址
|
|
|
+ */
|
|
|
+ address: "",
|
|
|
+ },
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 结算账户信息
|
|
|
+ */
|
|
|
+ accountInfoForm: {
|
|
|
+ /**
|
|
|
+ * 结算方向
|
|
|
+ */
|
|
|
+ settlementDirection: "",
|
|
|
+ /**
|
|
|
+ * 银行账户类型
|
|
|
+ */
|
|
|
+ bankAccountType: "",
|
|
|
+ bankAccountTypeLabel: "",
|
|
|
+ /**
|
|
|
+ * 银行账户号码
|
|
|
+ */
|
|
|
+ bankCardNo: "",
|
|
|
+ /**
|
|
|
+ * 银行账户开户总行编码
|
|
|
+ */
|
|
|
+ bankCode: "",
|
|
|
+ bankCodeLabel: ""
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * 产品信息
|
|
|
+ */
|
|
|
+ productInfoForm: {
|
|
|
+ productInfo: "",
|
|
|
+ },
|
|
|
+
|
|
|
+ //银行账户开户总行编码
|
|
|
+ bankCodeList: [],
|
|
|
+ //账户类型
|
|
|
+ bankAccountTypeList: [{label: "借记卡", value: "DEBIT_CARD"}],
|
|
|
+
|
|
|
+ merchantCorporationRules: {
|
|
|
+ idCardFront: [{
|
|
|
+ required: true,
|
|
|
+ message: '请上传法人身份证件正面照片',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ idCardContrary: [{
|
|
|
+ required: true,
|
|
|
+ message: '请上传法人身份证件反面照片',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ legalPerson: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入法人姓名',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ legalLicenceNo: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入法人证件号码',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ mobile: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入法人手机号码',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ },
|
|
|
+ businessAddressRules: {
|
|
|
+ province: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入省',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ city: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入市',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ district: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入区',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ address: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入详情地址',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ },
|
|
|
+ merchantSubjectRules: {
|
|
|
+ signName: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入商场全称',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ shortName: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入商场简称',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ },
|
|
|
+ accountInfoRules: {
|
|
|
+ bankAccountType: [{
|
|
|
+ required: true,
|
|
|
+ message: '请选择银行账户类型',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ bankCardNo: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入银行账户号码',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ bankCode: [{
|
|
|
+ required: true,
|
|
|
+ message: '请选择银行账户开户总行',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ },
|
|
|
+ productInfoRules: {
|
|
|
+ productInfo: [{
|
|
|
+ required: true,
|
|
|
+ message: "请输入产品信息json",
|
|
|
+ trigger: 'blur',
|
|
|
+ }]
|
|
|
+ },
|
|
|
+ headers: {},
|
|
|
+ tooltip: "",
|
|
|
+ };
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ this.init()
|
|
|
+ },
|
|
|
+ watch: {
|
|
|
+ "businessAddressForm.province": {
|
|
|
+ handler(value) {
|
|
|
+ let parentCode = this.province.find(ele => {
|
|
|
+ return ele.title === value;
|
|
|
+ });
|
|
|
+ if (parentCode == null) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ parentCode = parentCode.key;
|
|
|
+ this.cascadeMenuChange(parentCode, this.city);
|
|
|
+ }
|
|
|
+ },
|
|
|
+ "businessAddressForm.city": {
|
|
|
+ handler(value) {
|
|
|
+ let parentCode = this.city.find(ele => {
|
|
|
+ return ele.title === value;
|
|
|
+ });
|
|
|
+ if (parentCode == null) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ parentCode = parentCode.key;
|
|
|
+ this.cascadeMenuChange(parentCode, this.district);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ init() {
|
|
|
+ this.headers = {
|
|
|
+ "Authorization": "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
|
|
|
+ "Blade-Auth": JSON.parse(localStorage.getItem("saber-token")).content
|
|
|
+ }
|
|
|
+ this.getBankCode();
|
|
|
+ this.cascadeMenuChange("00", this.province);
|
|
|
+
|
|
|
+ // this.getBankAccountType()
|
|
|
+ this.accountInfoForm.bankCode = this.bankAccountTypeList[0].value
|
|
|
+ this.accountInfoForm.bankCodeLabel = this.bankAccountTypeList[0].label
|
|
|
+ const jsonData = "[\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"fixedRate\":\"\",\n" +
|
|
|
+ " \"paymentMethod\":\"REAL_TIME\",\n" +
|
|
|
+ " \"percentRate\":\"0.28\",\n" +
|
|
|
+ " \"productCode\":\"USER_SCAN_WECHAT_OFFLINE\",\n" +
|
|
|
+ " \"rateType\":\"SINGLE_PERCENT\",\n" +
|
|
|
+ " \"undertaker\":\"SETTLED_MERCHANT\"\n" +
|
|
|
+ " },\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"fixedRate\":\"\",\n" +
|
|
|
+ " \"paymentMethod\":\"REAL_TIME\",\n" +
|
|
|
+ " \"percentRate\":\"0.28\",\n" +
|
|
|
+ " \"productCode\":\"USER_SCAN_ALIPAY_OFFLINE\",\n" +
|
|
|
+ " \"rateType\":\"SINGLE_PERCENT\",\n" +
|
|
|
+ " \"undertaker\":\"SETTLED_MERCHANT\"\n" +
|
|
|
+ " },\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"fixedRate\":\"\",\n" +
|
|
|
+ " \"paymentMethod\":\"REAL_TIME\",\n" +
|
|
|
+ " \"percentRate\":\"0.28\",\n" +
|
|
|
+ " \"productCode\":\"WECHAT_OFFIACCOUNT_WECHAT_OFFLINE\",\n" +
|
|
|
+ " \"rateType\":\"SINGLE_PERCENT\",\n" +
|
|
|
+ " \"undertaker\":\"SETTLED_MERCHANT\"\n" +
|
|
|
+ " },\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"fixedRate\":\"\",\n" +
|
|
|
+ " \"paymentMethod\":\"REAL_TIME\",\n" +
|
|
|
+ " \"percentRate\":\"0.28\",\n" +
|
|
|
+ " \"productCode\":\"MINI_PROGRAM_WECHAT_OFFLINE\",\n" +
|
|
|
+ " \"rateType\":\"SINGLE_PERCENT\",\n" +
|
|
|
+ " \"undertaker\":\"SETTLED_MERCHANT\"\n" +
|
|
|
+ " },\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"fixedRate\":\"\",\n" +
|
|
|
+ " \"paymentMethod\":\"REAL_TIME\",\n" +
|
|
|
+ " \"percentRate\":\"0.28\",\n" +
|
|
|
+ " \"productCode\":\"MINI_PROGRAM_ALIPAY_OFFLINE\",\n" +
|
|
|
+ " \"rateType\":\"SINGLE_PERCENT\",\n" +
|
|
|
+ " \"undertaker\":\"SETTLED_MERCHANT\"\n" +
|
|
|
+ " },\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"fixedRate\":\"1\",\n" +
|
|
|
+ " \"paymentMethod\":\"REAL_TIME\",\n" +
|
|
|
+ " \"percentRate\":\"\",\n" +
|
|
|
+ " \"productCode\":\"D1_MANUAL\",\n" +
|
|
|
+ " \"rateType\":\"SINGLE_FIXED\",\n" +
|
|
|
+ " \"undertaker\":\"SETTLED_MERCHANT\"\n" +
|
|
|
+ " },\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"fixedRate\":\"1\",\n" +
|
|
|
+ " \"paymentMethod\":\"REAL_TIME\",\n" +
|
|
|
+ " \"percentRate\":\"1\",\n" +
|
|
|
+ " \"productCode\":\"ENTERPRISE_WITHDRAW_STANDARD_REALTIME\",\n" +
|
|
|
+ " \"rateType\":\"SINGLE_FIXED\",\n" +
|
|
|
+ " \"undertaker\":\"SETTLED_MERCHANT\"\n" +
|
|
|
+ " }\n" +
|
|
|
+ " ]";
|
|
|
+ this.tooltip = JSON.stringify(JSON.parse(jsonData), null, 4);
|
|
|
+ },
|
|
|
+
|
|
|
+ /**
|
|
|
+ *
|
|
|
+ * 省市区级联菜单改变
|
|
|
+ * @param parentId
|
|
|
+ * @param index
|
|
|
+ */
|
|
|
+ cascadeMenuChange(parentCode, dic) {
|
|
|
+ getLazyTree(parentCode).then((res) => {
|
|
|
+ dic.length = 0;
|
|
|
+ res.data.data.forEach(ele => {
|
|
|
+ ele.label = ele.title;
|
|
|
+ ele.value = ele.title;
|
|
|
+ dic.push(ele);
|
|
|
+ })
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
+ //银行信息 begin
|
|
|
+ getBankCode(keyword) {
|
|
|
+ let params = {
|
|
|
+ current: 1,
|
|
|
+ size: 300,
|
|
|
+ code: 'bank_type',
|
|
|
+ keyword
|
|
|
+ }
|
|
|
+ dictionaryPage(params).then(res => {
|
|
|
+ let list = res.data.data.records
|
|
|
+ if (this.$isEmpty(keyword)) {
|
|
|
+ list.shift()
|
|
|
+ }
|
|
|
+ list.forEach((item, index) => {
|
|
|
+ let obj = {
|
|
|
+ label: JSON.parse(item.dictValue).name,
|
|
|
+ value: item.dictKey
|
|
|
+ }
|
|
|
+ this.bankCodeList.push(obj)
|
|
|
+ })
|
|
|
+ if (this.$isNotEmpty(this.bankCodeList)) {
|
|
|
+ this.accountInfoForm.bankCode = this.bankCodeList[0].value
|
|
|
+ this.accountInfoForm.bankCodeLabel = this.bankCodeList[0].label
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ getBankAccountType() {
|
|
|
+ let params = {
|
|
|
+ current: 1,
|
|
|
+ size: 10,
|
|
|
+ code: 'bank_account_type',
|
|
|
+ }
|
|
|
+ dictionaryPage(params).then(res => {
|
|
|
+ let list = res.data.data.records
|
|
|
+ list.shift()
|
|
|
+ list.forEach((item, index) => {
|
|
|
+ let obj = {
|
|
|
+ label: item.dictValue,
|
|
|
+ value: item.dictKey
|
|
|
+ }
|
|
|
+ this.bankAccountTypeList.push(obj)
|
|
|
+ })
|
|
|
+ if (this.$isNotEmpty(this.bankAccountTypeList)) {
|
|
|
+ this.accountInfoForm.bankAccountType = this.bankAccountTypeList[0].value
|
|
|
+ this.accountInfoForm.bankAccountTypeLabel = this.bankAccountTypeList[0].label
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ bankAccountTypeChange(e) {
|
|
|
+ let list = this.bankAccountTypeList.filter(item => item.value == e)
|
|
|
+ this.accountInfoForm.bankAccountTypeLabel = list[0].label
|
|
|
+ this.accountInfoForm.bankAccountType = list[0].value
|
|
|
+ this.$forceUpdate()
|
|
|
+ },
|
|
|
+ bankCodeChange(e) {
|
|
|
+ let list = this.bankCodeList.filter(item => item.value == e)
|
|
|
+ this.accountInfoForm.bankCodeLabel = list[0].label
|
|
|
+ this.accountInfoForm.bankCode = list[0].value
|
|
|
+ this.$forceUpdate()
|
|
|
+ },
|
|
|
+ remoteMethod(query) {
|
|
|
+ console.log(query);
|
|
|
+ this.bankCodeList = []
|
|
|
+ this.getBankCode(query)
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
+ preview() {
|
|
|
+ this.active--
|
|
|
+ },
|
|
|
+ //下一步
|
|
|
+ next() {
|
|
|
+ switch (this.active) {
|
|
|
+ case 1:
|
|
|
+ this.validForm('merchantCorporationForm')
|
|
|
+ break;
|
|
|
+ case 2:
|
|
|
+ this.validForm('merchantSubjectInfo')
|
|
|
+ break;
|
|
|
+ case 3:
|
|
|
+ this.validForm('businessAddressForm')
|
|
|
+ break;
|
|
|
+ case 4:
|
|
|
+ this.validForm('accountInfoForm')
|
|
|
+ break;
|
|
|
+ case 5:
|
|
|
+ this.validForm('productInfoForm')
|
|
|
+ break;
|
|
|
+ default:
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ validForm(formName) {
|
|
|
+ this.$refs[formName].validate((valid) => {
|
|
|
+ if (!valid) {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ if (this.active == this.totalStep) {
|
|
|
+ this.submit()
|
|
|
+ } else {
|
|
|
+ this.active++
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ resetForm(formName) {
|
|
|
+ this.$refs[formName].resetFields();
|
|
|
+ },
|
|
|
+ async submit() {
|
|
|
+ this.confirm = true;
|
|
|
+
|
|
|
+ const auditForm = {};
|
|
|
+ auditForm.merchantCorporationInfo = this.merchantCorporationForm;
|
|
|
+ auditForm.merchantSubjectInfo = this.merchantSubjectInfo;
|
|
|
+ auditForm.businessAddressInfo = this.businessAddressForm;
|
|
|
+ auditForm.accountInfo = this.accountInfoForm;
|
|
|
+ auditForm.productInfo = JSON.parse(this.productInfoForm.productInfo);
|
|
|
+ inviteMicro(auditForm).then(res => {
|
|
|
+ this.$message({
|
|
|
+ type: "success",
|
|
|
+ message: "提交成功!",
|
|
|
+ data: res.data.data
|
|
|
+ });
|
|
|
+ })
|
|
|
+ this.$emit("finish", {});
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * 上传法人身份证正面照
|
|
|
+ * @param {Object} e
|
|
|
+ */
|
|
|
+ handleUploadLegalLicenceFront(e) {
|
|
|
+ let source = e.data[0]
|
|
|
+ if (source.errmsg != "ok") {
|
|
|
+ this.$message.error('非法证件照');
|
|
|
+ return
|
|
|
+ }
|
|
|
+ //商场法人信息
|
|
|
+ this.merchantCorporationForm = {
|
|
|
+ legalPerson: source.name,
|
|
|
+ legalLicenceType: "ID_CARD",
|
|
|
+ legalLicenceNo: source.id,
|
|
|
+ idCardFront: e.data[1].link,
|
|
|
+ idCardContrary: "",
|
|
|
+ gender: source.gender,
|
|
|
+ addr: source.addr,
|
|
|
+ nationality: source.nationality,
|
|
|
+ validDate: source.validDate,
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 上传法人身份证反面
|
|
|
+ * @param {Object} e
|
|
|
+ */
|
|
|
+ handleUploadLegalLicenceBack(e) {
|
|
|
+ if (e.data[0].errmsg != "ok") {
|
|
|
+ this.$message.error('非法证件照');
|
|
|
+ return
|
|
|
+ }
|
|
|
+ this.merchantCorporationForm.validDate = e.data[0].validDate
|
|
|
+ this.merchantCorporationForm.idCardContrary = e.data[1].link
|
|
|
+ },
|
|
|
+ }
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style>
|
|
|
+.avatar-uploader .el-upload {
|
|
|
+ border: 1px dashed #d9d9d9;
|
|
|
+ border-radius: 6px;
|
|
|
+ cursor: pointer;
|
|
|
+ position: relative;
|
|
|
+ overflow: hidden;
|
|
|
+}
|
|
|
+
|
|
|
+.avatar-uploader .el-upload:hover {
|
|
|
+ border-color: #409EFF;
|
|
|
+}
|
|
|
+
|
|
|
+.avatar-uploader-icon {
|
|
|
+ font-size: 28px;
|
|
|
+ color: #8c939d;
|
|
|
+ width: 178px;
|
|
|
+ height: 178px;
|
|
|
+ line-height: 178px;
|
|
|
+ text-align: center;
|
|
|
+}
|
|
|
+
|
|
|
+.avatar {
|
|
|
+ width: 178px;
|
|
|
+ height: 178px;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+</style>
|