<template>
    <div class="company">
        <h3>企业信息</h3>
        <p
            class="resubmit-notice clearfix"
            v-if="userInfo.loginInfo.certificationStatus ==
                        'FIRST_TRIAL_FAILURE'"
        >
            <span>*审核未通过的信息：</span>
            <br />
            <span>{{ jsRemark }}</span>
        </p>
        <label class="upload-notice" style="margin-top:-22px;">
            <span>证件照片 （请确认信息无误，证件图片清晰可见，图片支持jpg、png、jpeg，文件不超过5MB）</span>
            <!-- <span>查看示例</span> -->
        </label>
        <files-upload
            :uploadUrl="uploadUrl3"
            :popoverImg="popoverImg3"
            :imageUrl="imageUrl3"
            :title="uploadTitle3"
            v-loading="loading3"
            @success="handleAvatarSuccess3"
            @error="handleAvatarError3"
            @before="beforeAvatarUpload3"
            class="mb22"
            placement="right"
        ></files-upload>
        <div class="clearfix"></div>
        <div class="form-verify">
            <el-form :model="ruleForm" :rules="rules" ref="ruleForm" class="form-ruleForm">
                <el-form-item prop="companyName">
                    <el-input
                        v-model.trim="ruleForm.companyName"
                        placeholder="请输入企业名称"
                        @blur="setEngName"
                        maxlength="60"
                    ></el-input>
                    <p class="notice">*请以您提现账户的开户企业注册</p>
                </el-form-item>
                <el-form-item prop="companyEngName">
                    <el-input
                        v-model="ruleForm.companyEngName"
                        placeholder="请输入企业英文名称"
                        maxlength="100"
                    ></el-input>
                </el-form-item>
                <el-form-item prop="creditCard">
                    <el-input
                        v-model.trim="ruleForm.creditCard"
                        placeholder="请输入统一社会信用代码"
                        maxlength="18"
                    ></el-input>
                </el-form-item>
                <el-form-item required>
                    <el-col :span="11">
                        <el-form-item prop="bizLicenseExpDateStart">
                            <el-date-picker
                                v-model="ruleForm.bizLicenseExpDateStart"
                                type="date"
                                placeholder="开始时间"
                                style="width: 100%;"
                            ></el-date-picker>
                        </el-form-item>
                    </el-col>
                    <el-col class="line" :span="2" style="text-align: center;">-</el-col>
                    <el-col :span="11">
                        <el-form-item prop="bizLicenseExpDateEnd">
                            <el-date-picker
                                v-model="ruleForm.bizLicenseExpDateEnd"
                                type="date"
                                placeholder="结束时间"
                                style="width: 100%;"
                                :picker-options="pickerOptions"
                            ></el-date-picker>
                        </el-form-item>
                    </el-col>
                </el-form-item>
                <el-form-item prop="companyAddress">
                    <el-input
                        v-model.trim="ruleForm.companyAddress"
                        maxlength="100"
                        placeholder="请输入企业经营地址"
                    ></el-input>
                </el-form-item>
                <el-form-item prop="companyType">
                    <el-select
                        v-model="ruleForm.companyType"
                        placeholder="选择企业性质"
                        @change="getCompanyTypeName(ruleForm.companyType)"
                    >
                        <el-option
                            :label="item.name"
                            :value="item.id"
                            v-for="(item) in companyList"
                            :key="item.id"
                        ></el-option>
                    </el-select>
                </el-form-item>
                <el-form-item prop="region" class="region">
                    <el-select
                        v-model="ruleForm.region"
                        placeholder="选择店铺经营类型"
                        @change="getStoreBusinessTypeName(ruleForm.region)"
                        class="store-business"
                    >
                        <el-option
                            :label="item.name"
                            :value="item.id"
                            v-for="(item) in storeList"
                            :key="item.id"
                        ></el-option>
                    </el-select>
                </el-form-item>
                <h3 class="mt22">法人信息</h3>
                <el-select v-model="cardValue" placeholder="选择证件类型">
                    <el-option
                        v-for="item in cardOptions"
                        :key="item.value"
                        :label="item.label"
                        :value="item.value"
                    ></el-option>
                </el-select>
                <label class="upload-notice">
                    <span>证件照片 （请确认信息无误，证件图片清晰可见，图片支持jpg、png、jpeg，文件不超过5MB）</span>
                    <!-- <span>查看示例</span> -->
                </label>
                <div class="upload-box clearfix">
                    <files-upload
                        :uploadUrl="uploadUrl"
                        :popoverImg="popoverImg"
                        :imageUrl="imageUrl"
                        :title="uploadTitle"
                        v-loading="loading"
                        @success="handleAvatarSuccess"
                        @error="handleAvatarError"
                        @before="beforeAvatarUpload"
                    ></files-upload>
                    <files-upload
                        :uploadUrl="uploadUrl2"
                        :popoverImg="popoverImg2"
                        :imageUrl="imageUrl2"
                        :title="uploadTitle2"
                        v-loading="loading2"
                        @success="handleAvatarSuccess2"
                        @error="handleAvatarError2"
                        @before="beforeAvatarUpload2"
                    ></files-upload>
                </div>
                <el-form-item prop="name" class="mt22">
                    <el-input v-model.trim="ruleForm.name" placeholder="请输入法定代表人姓名" maxlength="60"></el-input>
                </el-form-item>
                <el-form-item prop="idCard">
                    <el-input
                        v-model.trim="ruleForm.idCard"
                        placeholder="请输入法定代表人证件号码"
                        maxlength="18"
                    ></el-input>
                </el-form-item>
                <el-form-item required>
                    <el-col :span="11">
                        <el-form-item prop="startTime">
                            <el-date-picker
                                v-model="ruleForm.startTime"
                                type="date"
                                placeholder="身份证有效期"
                                style="width: 100%;"
                                @change="setStartTime(ruleForm.startTime)"
                            ></el-date-picker>
                        </el-form-item>
                    </el-col>
                    <el-col class="line" :span="2" style="text-align: center;">-</el-col>
                    <el-col :span="11">
                        <el-form-item prop="endTime">
                            <el-date-picker
                                v-model="ruleForm.endTime"
                                type="date"
                                placeholder="身份证有效期"
                                style="width: 100%;"
                                :disabled="longTime"
                            ></el-date-picker>
                        </el-form-item>
                    </el-col>
                </el-form-item>
                <el-form-item prop="resource">
                    <el-radio-group v-model="ruleForm.resource" @change="isLongTime">
                        <el-radio label="1">非长期</el-radio>
                        <el-radio label="2">长期</el-radio>
                    </el-radio-group>
                </el-form-item>
                <el-form-item prop="address">
                    <el-input
                        v-model.trim="ruleForm.address"
                        maxlength="100"
                        placeholder="请输入法定代表人住址"
                    ></el-input>
                </el-form-item>
                <el-form-item prop="agreement" class="check-box">
                    <el-checkbox name="type" v-model="ruleForm.agreement"></el-checkbox>
                    <p>
                        本人为将申请账户的公司法定代表人/董事，且已阅读并同
                        <router-link to="/agreement" target="_blank">《大麦及时雨收款用户协议》</router-link>
                    </p>
                </el-form-item>
                <el-form-item>
                    <el-button
                        type="primary"
                        @click="submitForm('ruleForm')"
                        :loading="subLoading"
                    >提交</el-button>
                </el-form-item>
            </el-form>
        </div>
    </div>
</template>

<script>
import { mapState, mapMutations } from "vuex";
import {
    api_findDictionary,
    api_addCompany,
    api_getCertiInfo,
    api_convertToPinYin,
    api_getEnterprisePartners
} from "api/login.js";
import utils from "utils/utils.js";
import filesUpload from "./filesUpload";
let host = process.env.NODE_ENV == "development" ? "/api" : "";
export default {
    name: "ChinaCompany",
    components: { filesUpload },
    computed: {
        ...mapState(["userInfo"])
    },
    data() {
        var checkItCard = (rule, value, callback) => {
            if (value === "") {
                callback(new Error("请输入统一社会信用代码"));
            } else if (value.length < 18) {
                callback(new Error("统一社会信用代码格式错误"));
            } else {
                callback();
            }
        };
        var checkIdCard = (rule, value, callback) => {
            if (value === "") {
                callback(new Error("请输入法定代表人证件号码"));
            } else if (!utils.isvalidIdCard(value)) {
                callback(new Error("法定代表人证件号码格式错误"));
            } else if (utils.isAdult(value) < 18) {
                callback(new Error("此身份信息未满十八周岁"));
            } else {
                this.ruleForm.idCard = utils.toLocaleUpperCaseIdCard(value);
                callback();
            }
        };
        var regEngName = (rule, value, callback) => {
            if (value === "") {
                callback(new Error("请输入企业英文名称"));
            } else if (utils.regEngName(value)) {
                callback(new Error("请输入正确的企业英文名称"));
            } else {
                callback();
            }
        };
        var regCompanyName = (rule, value, callback) => {
            if (value === "") {
                callback(new Error("请输入企业名称"));
            } else if (utils.checkEng(value)) {
                callback(new Error("请输入正确的大陆企业名称"));
            } else {
                callback();
            }
        };
        return {
            ruleForm: {
                companyName: "",
                companyEngName: "",
                creditCard: "",
                region: "",
                companyType: "",
                name: "",
                idCard: "",
                startTime: "",
                endTime: "",
                resource: "1",
                bizLicenseExpDateStart: "",
                bizLicenseExpDateEnd: "",
                companyAddress: "",
                address: "",
                agreement: []
            },
            rules: {
                companyName: [{ validator: regCompanyName, trigger: "change" }],
                companyEngName: [{ validator: regEngName, trigger: "change" }],
                creditCard: [{ validator: checkItCard, trigger: "change" }],
                companyType: [
                    {
                        required: true,
                        message: "请选择企业性质",
                        trigger: "change"
                    }
                ],
                region: [
                    {
                        required: true,
                        message: "请选择店铺经营类别",
                        trigger: "change"
                    }
                ],
                name: [
                    {
                        required: true,
                        message: "请输入法定代表人姓名",
                        trigger: "change"
                    }
                ],
                idCard: [{ validator: checkIdCard, trigger: "change" }],
                startTime: [
                    {
                        type: "date",
                        required: true,
                        message: "请选择开始日期",
                        trigger: "change"
                    }
                ],
                endTime: [
                    {
                        type: "date",
                        required: true,
                        message: "请选择结束日期",
                        trigger: "change"
                    }
                ],
                bizLicenseExpDateStart: [
                    {
                        type: "date",
                        required: true,
                        message: "请选择开始日期",
                        trigger: "change"
                    }
                ],
                bizLicenseExpDateEnd: [
                    {
                        type: "date",
                        required: true,
                        message: "请选择结束日期",
                        trigger: "change"
                    }
                ],
                companyAddress: [
                    {
                        required: true,
                        message: "请输入企业经营地址",
                        trigger: "blur"
                    }
                ],
                address: [
                    {
                        required: true,
                        message: "请输入法定代表人住址",
                        trigger: "change"
                    }
                ],
                agreement: [
                    {
                        type: "array",
                        required: true,
                        message: "请阅读服务协议并选中",
                        trigger: "change"
                    }
                ]
            },
            pickerOptions: {
                shortcuts: [
                    {
                        text: "长期",
                        onClick(picker) {
                            const end = new Date(2099, 0, 1);
                            picker.$emit("pick", end);
                        }
                    }
                ]
            },
            //店铺经营类型列表和店铺经营类别中文描述
            storeList: [],
            storeBusinessTypeName: "",
            //企业性质列表和企业性质中文描述
            companyList: [],
            companyTypeName: "",
            //上传图片需要传的参数
            //需要改fileResourceType
            imageUrl: "",
            imageUrl2: "",
            imageUrl3: "",
            loading: false,
            loading2: false,
            loading3: false,
            browserIP: "",
            idCardFront: {}, //身份证
            idCardBack: {}, //身份证手持
            businessLicense: {}, //营业执照
            uploadUrl: `${host}/api/v1/authc/jsFile/upFile?fileResourceType=REAL_NAME_CERTIFICATE&fileType=IMAGE&certiFileType=CARD_FRONT_IMAGE`,
            popoverImg: require("assets/images/kyc-idcard-front.jpg"),
            uploadTitle: "身份证人像页",
            uploadUrl2: `${host}/api/v1/authc/jsFile/upFile?fileResourceType=REAL_NAME_CERTIFICATE&fileType=IMAGE&certiFileType=CARD_BACK_IMAGE`,
            popoverImg2: require("assets/images/kyc-idcard-back.jpg"),
            uploadTitle2: "身份证国徽页",
            uploadUrl3: `${host}/api/v1/authc/jsFile/upFile?fileResourceType=REAL_NAME_CERTIFICATE&fileType=IMAGE&certiFileType=BUSINESS_LICENSE_IMAGE`,
            popoverImg3: require("assets/images/kyc-business-license.jpg"),
            uploadTitle3: "营业执照照片",
            cardOptions: [
                {
                    value: "1",
                    label: "第二代居民身份证"
                }
            ],
            cardValue: "第二代居民身份证",
            longTime: false,
            subLoading: false,
            jsRemark: "",
            resubmitId: ""
        };
    },
    methods: {
        ...mapMutations(["setLoginInfo", "setKycCertiId"]),
        //上传身份证
        handleAvatarSuccess(res, file) {
            let ocrData = res.data.ocrData;
            if (ocrData !== null) {
                this.ruleForm.name = ocrData.name;
                this.ruleForm.idCard = ocrData.id;
                this.ruleForm.address = ocrData.address;
            } else {
                this.ruleForm.name = "";
                this.ruleForm.idCard = "";
                this.ruleForm.address = "";
            }
            this.loading = false;
            this.imageUrl = URL.createObjectURL(file.raw);
            this.idCardFront = Object.assign(file.response.data, {
                certiFileType: "CARD_FRONT_IMAGE"
            });
            this.$message.warning("请确认上传的是身份证正面照！");
        },
        handleAvatarError() {
            this.loading = false;
            this.$message.error("上传失败");
        },
        beforeAvatarUpload(file) {
            this.loading = true;
        },
        handleAvatarSuccess2(res, file) {
            let ocrData = res.data.ocrData;
            if (ocrData !== null) {
                if (ocrData.valid_date !== "") {
                    this.ruleForm.startTime = new Date(
                        Date.parse(
                            ocrData.valid_date.split("-")[0].replace(/\./g, "/")
                        )
                    );
                    this.ruleForm.endTime = new Date(
                        Date.parse(
                            ocrData.valid_date.split("-")[1].replace(/\./g, "/")
                        )
                    );
                } else {
                    this.ruleForm.startTime = "";
                    this.ruleForm.endTime = "";
                }
            }
            this.loading2 = false;
            this.imageUrl2 = URL.createObjectURL(file.raw);
            this.idCardBack = Object.assign(file.response.data, {
                certiFileType: "CARD_BACK_IMAGE"
            });
        },
        handleAvatarError2() {
            this.loading2 = false;
            this.$message.error("上传失败");
        },
        beforeAvatarUpload2(file) {
            this.loading2 = true;
        },
        //上传营业执照
        handleAvatarSuccess3(res, file) {
            let ocrData = res.data.ocrData;
            if (ocrData !== null) {
                ocrData.item_list.filter(item => {
                    if (item.item == "注册号") {
                        this.ruleForm.creditCard = item.itemstring;
                    } else if (item.item == "公司名称") {
                        this.ruleForm.companyName = item.itemstring;
                        this.setEngName();
                    } else if (item.item == "营业期限") {
                    }
                });
            } else {
                this.ruleForm.creditCard = "";
                this.ruleForm.companyName = "";
                this.ruleForm.companyEngName = "";
            }

            this.loading3 = false;
            this.imageUrl3 = URL.createObjectURL(file.raw);
            this.businessLicense = Object.assign(file.response.data, {
                certiFileType: "BUSINESS_LICENSE_IMAGE"
            });
        },
        handleAvatarError3() {
            this.loading3 = false;
            this.$message.error("上传失败");
        },
        beforeAvatarUpload3(file) {
            this.loading3 = true;
        },
        setLongTime(val) {},
        //汉字转拼音
        setEngName() {
            let convertToPinYinParams = {
                params: {
                    hanZi: this.ruleForm.companyName
                }
            };
            api_convertToPinYin(convertToPinYinParams).then(res => {
                this.ruleForm.companyEngName = res.data;
                if (this.ruleForm.companyEngName !== "") {
                    this.$message.warning("请核对英文名称是否正确！");
                }
            });
        },
        //选择企业性质
        getCompanyTypeName(val) {
            let companyType = this.companyList.filter(item => {
                return item.id === val;
            });
            this.companyTypeName = companyType[0].name;
        },
        //选择店铺经营类别
        getStoreBusinessTypeName(val) {
            let storeType = this.storeList.filter(item => {
                return item.id === val;
            });
            this.storeBusinessTypeName = storeType[0].name;
        },
        //选择身份证开始结束时间
        setStartTime(val) {
            let endDate = new Date(val);
            if (!this.longTime) {
                this.ruleForm.endTime = new Date(
                    endDate.setFullYear(endDate.getFullYear() + 20)
                );
            }
        },
        //选择身份证有效期
        isLongTime(val) {
            this.longTime = val == "1" ? false : true;
        },
        //提交
        submitForm(formName) {
            this.subLoading = true;
            let copyInitVuex = JSON.parse(localStorage.getItem("initVuex"));
            copyInitVuex.userInfo.loginInfo.certificationStatus =
                "SUBMIT_WATING";
            copyInitVuex.userInfo.loginInfo.certificationName = this.ruleForm.companyName;
            this.$refs[formName].validate(valid => {
                if (valid) {
                    if (
                        this.userInfo.loginInfo.certificationStatus !==
                        "FIRST_TRIAL_FAILURE"
                    ) {
                        if (
                            !this.idCardFront.id ||
                            !this.idCardBack.id ||
                            !this.businessLicense.id
                        ) {
                            this.subLoading = false;
                            this.$message.error("请上传证件照片！");
                            return false;
                        }
                    }

                    if (
                        this.userInfo.loginInfo.certificationStatus !==
                        "FIRST_TRIAL_FAILURE"
                    ) {
                        this.kycCertiLinkFileReqList = [
                            this.idCardFront,
                            this.idCardBack,
                            this.businessLicense
                        ];
                    }
                    let api_addCompanyData = {
                        data: {
                            companyName: this.ruleForm.companyName,
                            companyEngName: this.ruleForm.companyEngName,
                            unifiedSocialCreditCode: this.ruleForm.creditCard,
                            companyNatureId: this.ruleForm.companyType,
                            companyNatureName: this.companyTypeName,
                            companyAddress: this.ruleForm.companyAddress,
                            storeBusinessTypeId: this.ruleForm.region,
                            storeBusinessTypeName: this.storeBusinessTypeName,
                            certiCardType: "ID_CARD",
                            legalRepresentativeName: this.ruleForm.name,
                            legalRepresentativeIdNo: this.ruleForm.idCard,
                            legalRepresentativeAddress: this.ruleForm.address,
                            effectiveStartTime: utils.formatDate(
                                this.ruleForm.startTime,
                                "yyyy-MM-dd"
                            ),
                            effectiveEndTime:
                                this.ruleForm.resource === "1"
                                    ? utils.formatDate(
                                          this.ruleForm.endTime,
                                          "yyyy-MM-dd"
                                      )
                                    : "",
                            longFlag:
                                this.ruleForm.resource === "1" ? false : true,
                            kycCertiLinkFileReqList: this
                                .kycCertiLinkFileReqList,
                            browserIP: this.browserIp || "114.55.171.170",
                            bizLicenseExpDateStart: utils.formatDate(
                                this.ruleForm.bizLicenseExpDateStart,
                                "yyyy-MM-dd"
                            ),
                            bizLicenseExpDateEnd: utils.formatDate(
                                this.ruleForm.bizLicenseExpDateEnd,
                                "yyyy-MM-dd"
                            ),
                            id: this.resubmitId
                        }
                    };
                    api_addCompany(api_addCompanyData)
                        .then(res => {
                            if (res.success) {
                                this.$store.commit(
                                    "setLoginInfo",
                                    copyInitVuex.userInfo.loginInfo
                                );
                                localStorage.setItem(
                                    "initVuex",
                                    JSON.stringify(copyInitVuex)
                                );
                                this.$store.commit("setKycCertiId", res.data);
                                let getEnterprise25PartnersData = {
                                    params: {}
                                };
                                api_getEnterprisePartners(
                                    getEnterprise25PartnersData
                                ).then(res => {
                                    if (res.success) {
                                        if (res.data) {
                                            this.$router.replace({
                                                path: "/kycShareholder"
                                            });
                                        } else {
                                            this.$router.replace({
                                                path: "/kycSucc"
                                            });
                                        }
                                    } else {
                                        this.$router.replace({
                                            path: "/account"
                                        });
                                        this.$message.error(res.msg);
                                    }
                                    this.subLoading = false;
                                });
                            } else {
                                if (res.code == -33) {
                                    this.$router.push({
                                        path: "/account"
                                    });
                                } else {
                                    this.$message.error(res.msg);
                                }
                                this.subLoading = false;
                            }
                        })
                        .catch(err => {});
                } else {
                    this.subLoading = false;
                    return false;
                }
            });
        },
        firstTrialFailue() {
            let getCertiInfoParams = {
                params: {}
            };
            api_getCertiInfo(getCertiInfoParams).then(res => {
                this.ruleForm.companyName = res.data.companyName;
                this.ruleForm.companyEngName = res.data.companyEngName;
                this.ruleForm.creditCard = res.data.unifiedSocialCreditCode;
                this.ruleForm.companyType = res.data.companyNatureId;
                this.companyTypeName = res.data.companyNatureName;
                this.ruleForm.companyAddress = res.data.companyAddress;
                this.ruleForm.region = res.data.storeBusinessTypeId;
                this.storeBusinessTypeName = res.data.storeBusinessTypeName;
                this.ruleForm.name = res.data.legalRepresentativeName;
                this.ruleForm.idCard = res.data.legalRepresentativeIdNo;
                this.ruleForm.address = res.data.legalRepresentativeAddress;
                this.ruleForm.startTime = new Date(res.data.effectiveStartTime);
                this.ruleForm.endTime = new Date(res.data.effectiveEndTime);
                res.data.longFlag === false
                    ? (this.ruleForm.resource = "1")
                    : (this.ruleForm.resource = "2");
                this.ruleForm.bizLicenseExpDateStart = new Date(
                    res.data.bizLicenseExpDateStart
                );
                this.ruleForm.bizLicenseExpDateEnd = new Date(
                    res.data.bizLicenseExpDateEnd
                );
                this.kycCertiLinkFileReqList = res.data.kycCertiLinkFileReqList;
                this.imageUrl = `${host}/api/v1/anon/jsFile/downLoad?filePath=${res.data.CARD_FRONT_IMAGE}&fileName=abc.jpg`;
                this.imageUrl2 = `${host}/api/v1/anon/jsFile/downLoad?filePath=${res.data.CARD_BACK_IMAGE}&fileName=abc.jpg`;
                this.imageUrl3 = `${host}/api/v1/anon/jsFile/downLoad?filePath=${res.data.BUSINESS_LICENSE_IMAGE}&fileName=abc.jpg`;
                res.data.longFlag === true
                    ? (this.longTime = true)
                    : (this.longTime = false);
                this.jsRemark = res.data.jsRemark;
                this.resubmitId = res.data.id;
            });
        }
    },
    created() {
        let companyNature = {
            params: {
                type: "COMPANY_NATURE"
            }
        };
        api_findDictionary(companyNature)
            .then(res => {
                if (res.success) {
                    this.companyList = res.data;
                } else {
                    this.$message.error(res.msg);
                }
            })
            .catch(err => {});
        let storeBusinessType = {
            params: {
                type: "STORE_BUSINESS_TYPE"
            }
        };
        api_findDictionary(storeBusinessType)
            .then(res => {
                if (res.success) {
                    this.storeList = res.data;
                } else {
                    this.$message.error(res.msg);
                }
            })
            .catch(err => {});
        if (
            this.userInfo.loginInfo.certificationStatus ===
            "FIRST_TRIAL_FAILURE"
        ) {
            this.firstTrialFailue();
        }
    }
};
</script>

<style lang="less" scoped>
.company /deep/ .check-box {
    position: relative;
    .el-checkbox {
        margin-right: 10px;
    }
    .el-form-item__error {
        margin-top: -10px;
    }
    p {
        position: absolute;
        top: 0;
        left: 24px;
        width: 600px;
        color: #747474;
        a {
            color: #3d86e9;
        }
    }
}
.company /deep/ .el-button--primary {
    width: 330px;
}

.company /deep/ .el-form-item__error {
    width: 330px;
}
.el-date-editor {
    width: 330px;
}
.company {
    padding-top: 30px;
    h3 {
        margin-bottom: 8px;
    }
    .form-verify {
        .form-ruleForm {
            width: 330px;
        }
    }
    .notice {
        position: absolute;
        top: 0;
        left: 350px;
        width: 210px;
        color: #666;
    }
    .upload-notice {
        display: block;
        width: 900px;
        line-height: 56px;
        span {
            font-size: 14px;
            color: #999999;
            &:last-of-type {
                cursor: pointer;
                color: #3d86e9;
            }
        }
    }
    .company-type {
        .el-select {
            margin-top: 22px;
        }
    }
    .upload-box {
        width: 1080px;
    }
}
.mt22 {
    margin-top: 22px;
}
.mb22 {
    margin-bottom: 22px;
}
.resubmit-notice {
    margin: 20px 0;
    padding: 20px;
    line-height: 28px;
    border-radius: 6px;
    background: #fff8e8;
    color: #cc3333;
    span {
        &:first-child {
            font-weight: bold;
        }
        &:last-child {
            font-size: 16px;
        }
    }
}
</style>
