forked from gzzfw/frontEnd/gzDyh

zhangyongtian
2024-09-08 3326977aa58fedbac88d3c009eac06c33020db0d
gz-customerSystem/src/views/register/visit/component/agentDialog.jsx
@@ -4,6 +4,7 @@
import KeyVisits from "@/components/personCard/KeyVisits";
import * as $$ from '@/utils/utility';
import ArcoUpload from '@/components/ArcoUpload';
import { Scrollbars } from "react-custom-scrollbars";
const FormItem = Form.Item;
const Option = Select.Option;
@@ -14,6 +15,10 @@
function getId() {
  return $$.ax.request({ url: `caseUtils/getNewTimeId`, type: 'get', service: 'utils' });
}
function delFile(id) {
  return $$.ax.request({ url: `fileInfo/deleteFileById`, type: 'delete', service: 'sys', data: { id } });
}
export default function AgentDialog(props) {
@@ -94,9 +99,17 @@
    }
  }
  //删除文件
  const handleDelFile = async (id) => {
    const res = await delFile(id)
    if (res.type) {
      $$.infoSuccess({ content: '删除成功!' });
    }
  }
  return (
    <div className="applyDialog">
      <div style={{ height: '590px', overflowY: 'scroll' }}>
      <Scrollbars style={{ height: '590px' }} autoHide>
        <Row gutter={[16, 16]} style={{ margin: '0 2px 0 0' }}>
          <Col span={24}>
            <Form
@@ -108,7 +121,7 @@
              scrollToFirstError
            >
              <Row gutter={[32, 0]} style={{ margin: '0 -10px' }}>
                <Col span={24}>
                <Col span={24} className="doubleFile">
                  <ArcoUpload
                    params={{
                      action: `${appUrl.fileUrl}/${appUrl.sys}/api/web/fileInfo/upload?mainId=${props.mainId}&ownerId=${id}&ownerType=22_00018-202`,
@@ -117,16 +130,19 @@
                    handleChangeFile={handleChangeFile}
                    label='身份证明材料'
                    editData={props.editData}
                    handleDelFile={handleDelFile}
                    ownerType='22_00018-202'
                  />
                </Col>
                <Col span={24}>
                <Col span={24} className="doubleFile">
                  <ArcoUpload
                    params={{
                      action: `${appUrl.fileUrl}/${appUrl.sys}/api/web/fileInfo/upload?mainId=${props.mainId}&ownerId=${id}&ownerType=22_00018-202`,
                      action: `${appUrl.fileUrl}/${appUrl.sys}/api/web/fileInfo/upload?mainId=${props.mainId}&ownerId=${id}&ownerType=22_00018-207`,
                    }}
                    field='file1'
                    label='代理人委托书'
                    editData={props.editData}
                    ownerType='22_00018-207'
                  />
                </Col>
                <Col span={12}>
@@ -304,10 +320,10 @@
        </Row>
        {/* 重复来访重点人员 */}
        <div style={{ width: 'calc(100% - 9px)', background: '#f2f3f5', marginBottom: '20px', padding: '12px' }}>
        {/* <div style={{ width: 'calc(100% - 9px)', background: '#f2f3f5', marginBottom: '20px', padding: '12px' }}>
          <KeyVisits />
        </div>
      </div>
        </div> */}
      </Scrollbars>
      <div className='dialogFooter'>
        <Button
          type="primary"