<template>
  <a-spin :spinning="loading">
    <JFormContainer :disabled="disabled">
      <template #detail>
        <a-form v-bind="formItemLayout" name="PuechaseInquiryFormForm" ref="formRef">
          <a-row>
            <a-col :span="12">
							<a-form-item label="询价单号(bill code)" v-bind="validateInfos.billCode" id="PuechaseInquiryFormForm-billCode" name="billCode">
								<a-input v-model:value="formData.billCode" placeholder="自动生成" disabled></a-input>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="单据日期(bill date)" v-bind="validateInfos.billDate" id="PuechaseInquiryFormForm-billDate" name="billDate" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
								<a-date-picker placeholder="请选择单据日期(bill date)"  v-model:value="formData.billDate"  value-format="YYYY-MM-DD"  style="width: 100%"  allow-clear />
							</a-form-item>
						</a-col>
						
						<a-col :span="12">
							<a-form-item label="询价项目(inquiry project)" v-bind="validateInfos.projectName" id="PuechaseInquiryFormForm-projectName" name="projectName">
								<a-input-search v-model:value="formData.projectName" placeholder="请输入询价项目(inquiry project)" AutoComplete="off" :disabled="notAllowEdit"  allow-clear enter-button="Search" @search="onSearchProject"></a-input-search>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="询价供应商(inquiry supplier)" v-bind="validateInfos.inquirySuppiler" id="PuechaseInquiryFormForm-inquirySuppiler" name="inquirySuppiler" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
                  <JSelectInput   v-model:value="formData.inquirySuppiler"  placeholder="请选择" allow-clear  :options="supplierOption" @change="changeSupplier"></JSelectInput>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="询价有效期(inquiry period)" v-bind="validateInfos.inquiryPeriodEnd" id="PuechaseInquiryFormForm-inquiryPeriodEnd" name="inquiryPeriodEnd">
                <a-range-picker v-model:value="inquiryPeriod" :format="['YYYY-MM-DD','YYYY-MM-DD']"  @change="onChangeInquiryPeriod" style="width: 100%" />
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="优先级(priority)" v-bind="validateInfos.priority" id="PuechaseInquiryFormForm-priority" name="priority" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
                <JDictSelectTag v-model:value="formData.priority" placeholder="请选择" dictCode="priority"/>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="产品分类(production class)" v-bind="validateInfos.productionClass" id="PuechaseInquiryFormForm-productionClass" name="productionClass">
                <JSelectInput   v-model:value="formData.productionClass"  placeholder="请选择" :options="classOption" ></JSelectInput>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="机型(model)" v-bind="validateInfos.model" id="PuechaseInquiryFormForm-model" name="model" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
                <JDictSelectTag v-model:value="formData.model" placeholder="请选择" dictCode="model_typer" disabled/>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="厂家(maker)" v-bind="validateInfos.maker" id="PuechaseInquiryFormForm-maker" name="maker">
								<a-input v-model:value="formData.maker" placeholder="请输入厂家(maker)"  allow-clear disabled></a-input>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="交货地点(place of delivery)" v-bind="validateInfos.placeDelivery" id="PuechaseInquiryFormForm-placeDelivery" name="placeDelivery" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
								<a-input v-model:value="formData.placeDelivery" placeholder=""  allow-clear AutoComplete="off" ></a-input>
							</a-form-item>
						</a-col>
            <a-col :span="12">
							<a-form-item label="付款条件(payment terms)" v-bind="validateInfos.paymentTerms" id="quotationFormForm-paymentTerms" name="paymentTerms" >
                <JDictSelectTag v-model:value="formData.paymentTerms" placeholder="请选择" dictCode="payment_terms" style="width: 100%;margin-right: 1%;"/>
							</a-form-item>
						</a-col>
            <!-- <a-col :span="12">
							<a-form-item label="报价有效期(quotation validity period)" v-bind="validateInfos.quotationValidity" id="PuechaseInquiryFormForm-quotationValidity" name="quotationValidity" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
                <a-input v-model:value="formData.quotationValidity" placeholder="请输入" />
							</a-form-item>
						</a-col> -->
            <a-col :span="12">
							<a-form-item label="发货方式(delivery)" v-bind="validateInfos.delivery" id="PuechaseInquiryFormForm-delivery" name="delivery" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
                <JDictSelectTag v-model:value="formData.delivery" placeholder="请选择" dictCode="delivery_methods" />
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="采购询价组(procurement inquiry team)" v-bind="validateInfos.inquiryTeamName"  id="PuechaseInquiryFormForm-inquiryTeamName" name="inquiryTeam">
                <!-- <JDictSelectTag v-model:value="formData.inquiryTeam" placeholder="请选择" dictCode="procurement_inquiry_team" disabled/> -->
                <a-input v-model:value="formData.inquiryTeamName" disabled></a-input>
							</a-form-item>
						</a-col>
            <a-col :span="12">
							<a-form-item label="询价备注(inquiry notes)" v-bind="validateInfos.inquiryNotes" id="PuechaseInquiryFormForm-inquiryNotes" name="inquiryNotes" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
								<a-input v-model:value="formData.inquiryNotes" placeholder="请输入询价备注(inquiry notes)"  allow-clear AutoComplete="off"></a-input>
							</a-form-item>
						</a-col>
						<a-col :span="12">
							<a-form-item label="附件(attachs)" v-bind="validateInfos.attachs" id="PuechaseInquiryFormForm-attachs" name="attachs" >
								<JUpload v-model:value="formData.attachs"></JUpload>
							</a-form-item>
						</a-col>
          </a-row>
        </a-form>
      </template>
    </JFormContainer>

		<!-- 子表单区域 -->
    <a-tabs v-model:activeKey="activeKey" animated  style=" padding: 24px;padding-top: 0px;">
      <a-tab-pane tab="采购询价单 - 产品明细(product details)" key="PuechaseInquiryFormProduct" :forceRender="true">
        <a-button type="primary" @click="SelectCustomerInquiry" style="margin-right: 1%;margin-bottom: 1%;"> 选择客户询价单(select customer inquiry form)</a-button>
        <a-button type="primary" @click="selectProducts" style="margin-right: 1%;margin-bottom: 1%;"> 选择产品(select product)</a-button>
        <j-vxe-table
          :keep-source="true"
          resizable
          ref="PuechaseInquiryFormProductTableRef"
          :loading="PuechaseInquiryFormProductTable.loading"
          :columns="PuechaseInquiryFormProductTable.columns"
          :dataSource="PuechaseInquiryFormProductTable.dataSource"
          :height="340"
          :disabled="disabled"
          :rowNumber="true"
          :rowSelection="true"
          asyncRemove
          >
          <template #action="props">
                <a-popconfirm title="确定删除吗？" @confirm="handleDelete1(props)">
                  <a>删除(delete)</a>
                </a-popconfirm>
            </template>
          </j-vxe-table>
      </a-tab-pane>
      <a-tab-pane tab="采购询价单 - 船明细(ship details)" key="PuechaseInquiryFormShip" :forceRender="true">
        <j-vxe-table
          :keep-source="true"
          resizable
          ref="PuechaseInquiryFormShipTableRef"
          :loading="PuechaseInquiryFormShipTable.loading"
          :columns="PuechaseInquiryFormShipTable.columns"
          :dataSource="PuechaseInquiryFormShipTable.dataSource"
          :height="340"
          :disabled="disabled"
          :rowNumber="true"
          :rowSelection="true"
          >
            <template #action="props" >
              <a @click="viewAccessory(props)" >查看配件信息(view accessory information)</a>
            </template>
          </j-vxe-table>
      </a-tab-pane>
      
    </a-tabs>
    <BaseShipArchiveAccessoriesModal ref="BaseShipArchiveAccessoriesListRef"></BaseShipArchiveAccessoriesModal>
    <SelectPrpductModal ref="SelectPrpductModalRef" @selectProduct="addProduct"></SelectPrpductModal>
    <SelectProjectModal ref="SelectProjectModalRef" @selectProject="addProject"></SelectProjectModal>
    <SelectCustomerInquiryModal ref="SelectCustomerInquiryModalRef" @selectCustomerInquiry="addProductFromCustomer"></SelectCustomerInquiryModal>
  </a-spin>
</template>

<script lang="ts">
  import { defineComponent, ref, reactive, computed, toRaw, onMounted } from 'vue';
  import { defHttp } from '/@/utils/http/axios';
  import { useValidateAntFormAndTable } from '/@/hooks/system/useJvxeMethods';
  import { queryQurcodeInquiryFormShipListByMainId, queryPurcodeInquiryFormProductListByMainId, queryDataById, saveOrUpdate } from '../purchaseInquiryForm.api';
  import { JVxeTable } from '/@/components/jeecg/JVxeTable';
  import {PuechaseInquiryFormShipColumns, PuechaseInquiryFormProductColumns} from '../PurchaseInquiryForm.data';
  import BaseShipArchiveAccessoriesModal from '../../../publicComponents/BaseShipArchiveAccessoriesModal.vue';
  import SelectPrpductModal from '../../../publicComponents/SelectPrpductModal.vue';
  import SelectProjectModal from '../../../publicComponents/SelectProjectModal.vue';
  import SelectCustomerInquiryModal from './SelectCustomerInquiryModal.vue';
  import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
  import JUpload from '/@/components/Form/src/jeecg/components/JUpload/JUpload.vue';
  import { JDictSelectTag} from '/@/components/Form';
  import JSelectInput from '/@/components/Form/src/jeecg/components/JSelectInput.vue';
  import { Form ,message} from 'ant-design-vue';
  import moment from 'moment';
  const useForm = Form.useForm;
  export default defineComponent({
    name: "PuechaseInquiryFormForm",
    components:{
      JVxeTable,
			JFormContainer,
      BaseShipArchiveAccessoriesModal,
      SelectPrpductModal,
      JUpload,
      SelectProjectModal,
      JDictSelectTag,
      JSelectInput,
      SelectCustomerInquiryModal,
    },
    props:{
      formDisabled:{
        type: Boolean,
        default: false
      },
      formData: { type: Object, default: ()=>{} },
      formBpm: { type: Boolean, default: true }
    },
    emits:['success'],
    setup(props, {emit}) {
      var classOption = ref([]);
      const loading = ref(false);
      const formRef = ref();
      var SelectPrpductModalRef = ref()
      var SelectProjectModalRef = ref()
      var SelectCustomerInquiryModalRef = ref()
      var inquiryPeriod = ref([])
      const PuechaseInquiryFormShipTableRef = ref();
      const PuechaseInquiryFormShipTable = reactive<Record<string, any>>({
        loading: false,
        columns: PuechaseInquiryFormShipColumns,
        dataSource: []
      });
      const PuechaseInquiryFormProductTableRef = ref();
      const PuechaseInquiryFormProductTable = reactive<Record<string, any>>({
        loading: false,
        columns: PuechaseInquiryFormProductColumns,
        dataSource: []
      });
      var BaseShipArchiveAccessoriesListRef = ref();
      const activeKey = ref('PuechaseInquiryFormProduct');
      var notAllowEdit = ref(false);
      var supplierOption = ref([]);
      const formData = reactive<Record<string, any>>({
        id: '',
        status: undefined,
        delFlag: undefined,
        otherStatus: '',   
        submit: '',   
        billDate: moment(new Date()).format('YYYY-MM-DD'),   
        billCode: '',   
        inquiryProject: '',   
        inquirySuppiler:"",
        inquiryPeriodEnd: '',   
        inquiryPeriodBegin: ' ',  
        inquiryCustomer: '',           
        priority: '',   
        productionClass: '',   
        model: '',   
        maker: '',
        paymentTerms:'',
        delivery:'',
        deliveryTime: '',  
        inquiryTeam: '',   
        inquiryTeamName:'',
        quotationValidity:'',
        attachs: '',   
        inquiryNotes: '',   
        sourceCode:'',
        projectName:'',
        placeDelivery:'',
        suppilerName:'',
        saleAttachs:'',
        paymentTermsInfo:'',
        sourceId:""
      });

      //表单验证
      const validatorRules = reactive({
      });
      const {resetFields, validate, validateInfos} = useForm(formData, validatorRules, {immediate: false});
      const dbData = {};
      const formItemLayout = {
        labelCol: {xs: {span: 24}, sm: {span: 7}},
        wrapperCol: {xs: {span: 24}, sm: {span: 16}},
        labelCol1: {xs: {span: 24}, sm: {span: 9}},
        wrapperCol1: {xs: {span: 24}, sm: {span: 14}},
      };

      // 表单禁用
      const disabled = computed(()=>{
        if(props.formBpm === true){
          if(props.formData.disabled === false){
            return false;
          }else{
            return true;
          }
        }
        return props.formDisabled;
      });

      

      function add() {
        resetFields();
        PuechaseInquiryFormShipTable.dataSource = [];
        PuechaseInquiryFormProductTable.dataSource = [];
        activeKey.value = 'PuechaseInquiryFormProduct'
        getSupplierOption()
        getOptiom()
        inquiryPeriod.value = []
        notAllowEdit.value=false
      }

      async function edit(row) {
        //主表数据
        await queryMainData(row.id);
        //子表数据
        const PuechaseInquiryFormShipDataList = await queryQurcodeInquiryFormShipListByMainId(row['id']);
        PuechaseInquiryFormShipTable.dataSource = [...PuechaseInquiryFormShipDataList];
        const PuechaseInquiryFormProductDataList = await queryPurcodeInquiryFormProductListByMainId(row['id']);
        PuechaseInquiryFormProductTable.dataSource = [...PuechaseInquiryFormProductDataList];
        getSupplierOption()
        getOptiom()
        inquiryPeriod.value[0]=formData.inquiryPeriodBegin?moment(formData.inquiryPeriodBegin):''
        inquiryPeriod.value[1]=formData.inquiryPeriodEnd?moment(formData.inquiryPeriodEnd):''
        notAllowEdit.value=true
      }

      async function queryMainData(id) {
        const row = await queryDataById(id);
        resetFields();
        const tmpData = {};
        Object.keys(formData).forEach((key) => {
          if(row.hasOwnProperty(key)){
            tmpData[key] = row[key]
          }
        })
        //赋值
        Object.assign(formData,tmpData);
      }

      const {getSubFormAndTableData, transformData} = useValidateAntFormAndTable(activeKey, {
        'purInquiryFormShip': PuechaseInquiryFormShipTableRef,
        'purInquiryFormProduct': PuechaseInquiryFormProductTableRef,
      });

      async function getFormData() {
        try {
          // 触发表单验证
          await validate();
        } catch ({ errorFields }) {
          if (errorFields) {
            const firstField = errorFields[0];
            if (firstField) {
              formRef.value.scrollToField(firstField.name, { behavior: 'smooth', block: 'center' });
            }
          }
          return Promise.reject(errorFields);
        }
        return transformData(toRaw(formData))
      }

      async function submitForm() {
        if(formData.sourceCode==''){
          message.warning('请选择客户询价单')
        }else{
          const mainData = await getFormData();
          const subData = await getSubFormAndTableData();
          const values = Object.assign({}, dbData, mainData, subData);
          console.log('表单提交数据', values)
          const isUpdate = values.id ? true : false
          await saveOrUpdate(values, isUpdate);
          //关闭弹窗
          emit('success');
        }
      }
      
      function setFieldsValue(values) {
        if(values){
          Object.keys(values).map(k=>{
            formData[k] = values[k];
          });
        }
      }

      /**
       * 值改变事件触发-树控件回调
       * @param key
       * @param value
       */
      function handleFormChange(key, value) {
        formData[key] = value;
      }
      async function handleDelete(prop) {
        var newArray = [...PuechaseInquiryFormShipTable.dataSource]
        newArray.splice(prop.rowIndex, 1)
        PuechaseInquiryFormShipTable.dataSource = newArray 
      }
      async function handleDelete1(prop) {
        var newArray = [...PuechaseInquiryFormProductTable.dataSource]
        newArray.splice(prop.rowIndex, 1)
        PuechaseInquiryFormProductTable.dataSource = newArray  
        if( PuechaseInquiryFormProductTable.dataSource.length!==0){
          var arr = []
          PuechaseInquiryFormProductTable.dataSource.map(item=>{
            if(item.sourceId){
              arr.push(item.sourceId)
            } 
          })
          if(arr.length==0){
            formData.sourceCode = ''
            notAllowEdit.value=false
          }
        }else{
           notAllowEdit.value=false
           formData.sourceCode = ''
        }
      }
      function addShip(data){
        var arr = data.concat(PuechaseInquiryFormShipTable.dataSource)
        arr.map(item=>item.shipowner = item.relateCustomer)
        PuechaseInquiryFormShipTable.dataSource=arr        
        
      }
      function addProduct(data){
        data.map(item=>{
          item.productClass = item.classId_dictText
          item.productCode = item.code
          item.productId = item.id
          item.unit = item.measurementUnit
          item.needShip = '0'
          item.shipInspection =''
        })
        var arrProduct = data.concat(PuechaseInquiryFormProductTable.dataSource)
        PuechaseInquiryFormProductTable.dataSource=arrProduct      
      }
      function addProject(data) {
        if(data.length!==0){
          formData.inquiryProject = data[0].id
           formData.projectName = data[0].code
        }else{
          formData.inquiryProject = ''
          formData.projectName = ''
        }
        
      }
      function addProductFromCustomer(data){
        debugger
        data.map(item=>{
          item.productClass = item.productClass
          item.productCode = item.productCode
          item.unit = item.unit
          item.sourceId = item.childId
          item.model = item.childModel
          item.deliveryTime = formData.deliveryTime
        })
        var arrProduct = data.concat(PuechaseInquiryFormProductTable.dataSource)
        notAllowEdit.value=true
        inquiryPeriod.value[0]=data[0].inquiryPeriodBegin?moment(data[0].inquiryPeriodBegin):''
        inquiryPeriod.value[1]=data[0].inquiryPeriodEnd?moment(data[0].inquiryPeriodEnd):''
        console.log(inquiryPeriod);
        debugger
        formData.inquiryPeriodBegin=data[0].inquiryPeriodBegin?moment(data[0].inquiryPeriodBegin):''
        formData.inquiryPeriodEnd=data[0].inquiryPeriodEnd?moment(data[0].inquiryPeriodEnd):''
        PuechaseInquiryFormProductTable.dataSource=arrProduct     
        formData.inquiryProject = data[0].inquiryProject
        formData.projectName = data[0].projectName
        formData.sourceCode = data[0].billCode
        formData.priority = data[0].priority
        formData.model = data[0].headModel
        formData.maker = data[0].maker
        formData.inquiryTeam =  data[0].inquiryTeam
        formData.inquiryTeamName = data[0].inquiryTeam_dictText
        formData.productionClass =  data[0].productionClass
        formData.saleAttachs =data[0].attachs
        getShipList(data[0].headId)
      }
      function getShipList(id){
        let params = {id:id}
          defHttp.get({url:'/saleCode/saleInquiryForm/querySaleInquiryFormShipByMainId',params}, { isTransformResponse: false }).then(res=>{
            if(res){
             PuechaseInquiryFormShipTable.dataSource = res.result
            }
          })
      }
      function viewAccessory(prop){
        BaseShipArchiveAccessoriesListRef.value.getTable(prop.row)
      }
      function selectProducts(){
        SelectPrpductModalRef.value.getTable()
      }
      function setNeed(){
        const values = PuechaseInquiryFormProductTableRef.value.getSelectionData()        
        values.map(item=>{
          PuechaseInquiryFormProductTable.dataSource.map(event=>{
            if(item.id == event.id){
              event.needShip = 1
            }
          })
          const xTable = PuechaseInquiryFormProductTableRef.value!.getXTable();//关键代码 如果不更新 重新加载表格即可
          xTable.loadData(PuechaseInquiryFormProductTable.dataSource)

        })
      }
      function setNotNeed(){
        const values = PuechaseInquiryFormProductTableRef.value.getSelectionData()        
        values.map(item=>{
          PuechaseInquiryFormProductTable.dataSource.map(event=>{
            if(item.id == event.id){
              event.needShip = 0
            }
          })
          const xTable = PuechaseInquiryFormProductTableRef.value!.getXTable();//关键代码 如果不更新 重新加载表格即可
          xTable.loadData(PuechaseInquiryFormProductTable.dataSource)

        })
      }
      function onSearchProject(){
        SelectProjectModalRef.value.getTable()
      }
      function getSupplierOption(){
        defHttp
            .get({ url: '/cuspCode/cuspSupplierProfile/list'}, { isTransformResponse: false })
            .then((res) => {
                if (res.success) {
                  supplierOption.value = []
                  res.result.records.forEach(element => {
                      var obj = {
                        label: element.name?element.name:'无名称请维护',
                        value: element.id?element.id:'',
                        paymentTerms:element.paymentTerms?element.paymentTerms:''
                      };
                      supplierOption.value.push( obj)
                  });    
                }
            })
            .finally(() => {
                // loading.value = false;
            });
      }
      function onChangeInquiryPeriod(data){
        inquiryPeriod.value = data
        formData.inquiryPeriodBegin = data[0].format('YYYY-MM-DD')
        formData.inquiryPeriodEnd = data[1].format('YYYY-MM-DD')
      }
      function SelectCustomerInquiry(){
          SelectCustomerInquiryModalRef.value.getTable(formData)
      }
      function changeSupplier(prop){
        if(prop){
          supplierOption.value.map(item=>{
            if(item.value==prop){
              formData.suppilerName = item.label
              formData.paymentTerms = item.paymentTerms
            }
          })
        }else{
          formData.inquirySuppiler = ''
          formData.suppilerName = ''
        }
        
      }
      //  产品分类
      function getOptiom(){
        defHttp.get({ url: 'baseCode/baseProductClass/list'}, { isTransformResponse: false })
          .then((res) => {
           if (res.success) {
              classOption.value = []
              res.result.records.forEach(element => {
                  var obj = {
                    label: element.name?element.name:'无名称请维护',
                    value: element.id?element.id:''
                  };
                  classOption.value.push( obj)
              });    
            } 
          }).finally(() => {
                    // loading.value = false;
          });
      }
      return {
        PuechaseInquiryFormShipTableRef,
        PuechaseInquiryFormShipTable,
        PuechaseInquiryFormProductTableRef,
        PuechaseInquiryFormProductTable,
        validatorRules,
        validateInfos,
        activeKey,
        loading,
        formData,
        setFieldsValue,
        handleFormChange,
        formItemLayout,
        disabled,
        getFormData,
        submitForm,
        add,
        edit,
        formRef,
        addShip,
        addProduct,
        BaseShipArchiveAccessoriesListRef,
        viewAccessory,
        handleDelete,
        handleDelete1,
        selectProducts,
        setNeed,
        setNotNeed,
        SelectPrpductModalRef,
        SelectProjectModalRef,
        SelectCustomerInquiryModalRef,
        onSearchProject,
        addProject,
        getSupplierOption,
        supplierOption,
        inquiryPeriod,
        onChangeInquiryPeriod,
        SelectCustomerInquiry,
        addProductFromCustomer,
        changeSupplier,
        notAllowEdit,
        getOptiom,
        classOption
      }
    }
  });
</script>
<style lang="less" scoped>
  /** 时间和数字输入框样式 */
  :deep(.ant-input-number) {
    width: 100%;
  }

  :deep(.ant-calendar-picker) {
    width: 100%;
  }
  /deep/.vxe-table--body-wrapper{
    height: 100% !important;
  }
  /deep/.ant-modal-body{
    padding: 24px !important;
  }
  
  /deep/.ant-form-item{
    margin-bottom: 8px !important;
  }
      
</style>
