Commit e6d31eb8e84bacf93f7950d622bf0db1dea8c048
1 parent
50f70e01
feat: update分期账单
Showing
9 changed files
with
55 additions
and
15 deletions
.umirc.ts
@@ -79,6 +79,13 @@ export default defineConfig({ | @@ -79,6 +79,13 @@ export default defineConfig({ | ||
79 | icon: 'BookOutlined', | 79 | icon: 'BookOutlined', |
80 | access: 'canReadLinda', | 80 | access: 'canReadLinda', |
81 | }, | 81 | }, |
82 | + // { | ||
83 | + // name: '区域管理', | ||
84 | + // path: '/zoning', | ||
85 | + // component: './ZoNing', | ||
86 | + // icon: 'BookOutlined', | ||
87 | + // access: 'canReadLinda', | ||
88 | + // }, | ||
82 | { | 89 | { |
83 | name: '打印', | 90 | name: '打印', |
84 | path: '/print', | 91 | path: '/print', |
src/access.ts
@@ -11,7 +11,7 @@ export default (initialState: API.UserInfo) => { | @@ -11,7 +11,7 @@ export default (initialState: API.UserInfo) => { | ||
11 | return { | 11 | return { |
12 | canReadAdmin: canReadAdmin, | 12 | canReadAdmin: canReadAdmin, |
13 | canReadProcure: canReadProcure, | 13 | canReadProcure: canReadProcure, |
14 | - canReadLinda: username === 'Linda' || username === '吴量', | 14 | + canReadLinda: username === 'Linda' || username === '吴量' || canReadAdmin, |
15 | canReadAdminAndFinance: canReadFinance || canReadAdmin, | 15 | canReadAdminAndFinance: canReadFinance || canReadAdmin, |
16 | canReadSales: canReadSales, | 16 | canReadSales: canReadSales, |
17 | canReadAdminAndFinanceAndSales: | 17 | canReadAdminAndFinanceAndSales: |
src/pages/Instalment/components/comfire/comfire.tsx
@@ -34,7 +34,7 @@ export default ({ currtDid, sureDelete }) => { | @@ -34,7 +34,7 @@ export default ({ currtDid, sureDelete }) => { | ||
34 | } | 34 | } |
35 | form={form} | 35 | form={form} |
36 | autoFocusFirstInput | 36 | autoFocusFirstInput |
37 | - width={190} | 37 | + width={280} |
38 | modalProps={{ | 38 | modalProps={{ |
39 | destroyOnClose: true, | 39 | destroyOnClose: true, |
40 | }} | 40 | }} |
src/pages/Instalment/components/upload/uploadApp.css
0 → 100644
src/pages/Instalment/components/upload/uploadApp.less
0 → 100644
src/pages/Instalment/components/upload/uploadApp.tsx
1 | import { InboxOutlined } from '@ant-design/icons'; | 1 | import { InboxOutlined } from '@ant-design/icons'; |
2 | import { Upload } from 'antd'; | 2 | import { Upload } from 'antd'; |
3 | import React from 'react'; | 3 | import React from 'react'; |
4 | +import './uploadApp.less'; | ||
4 | 5 | ||
5 | const App: React.FC = ({ uploadFile }) => { | 6 | const App: React.FC = ({ uploadFile }) => { |
6 | const { Dragger } = Upload; | 7 | const { Dragger } = Upload; |
@@ -15,18 +16,26 @@ const App: React.FC = ({ uploadFile }) => { | @@ -15,18 +16,26 @@ const App: React.FC = ({ uploadFile }) => { | ||
15 | }; | 16 | }; |
16 | 17 | ||
17 | return ( | 18 | return ( |
18 | - <Dragger {...props}> | ||
19 | - <p className="ant-upload-drag-icon"> | ||
20 | - <InboxOutlined /> | ||
21 | - </p> | ||
22 | - <p className="ant-upload-text"> | ||
23 | - Click or drag file to this area to upload | ||
24 | - </p> | ||
25 | - <p className="ant-upload-hint"> | ||
26 | - Support for a single or bulk upload. Strictly prohibited from uploading | ||
27 | - company data or other banned files. | ||
28 | - </p> | ||
29 | - </Dragger> | 19 | + <> |
20 | + <Dragger {...props}> | ||
21 | + <p className="ant-upload-drag-icon"> | ||
22 | + <InboxOutlined /> | ||
23 | + </p> | ||
24 | + <p className="ant-upload-text"> | ||
25 | + Click or drag file to this area to upload | ||
26 | + </p> | ||
27 | + <p className="ant-upload-hint"> | ||
28 | + Support for a single or bulk upload. Strictly prohibited from | ||
29 | + uploading company data or other banned files. | ||
30 | + </p> | ||
31 | + </Dragger> | ||
32 | + <a | ||
33 | + href="https://order-erp.oss-cn-qingdao.aliyuncs.com/%E5%88%86%E6%9C%9F%E4%BB%98%E6%AC%BE-%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx?Expires=2035527699&OSSAccessKeyId=LTAIZCPI7OaWud0m&Signature=npHyEhfRd6LugJ0St8OkvRmLYtQ%3D" | ||
34 | + className="modul-a" | ||
35 | + > | ||
36 | + 下载模板 | ||
37 | + </a> | ||
38 | + </> | ||
30 | ); | 39 | ); |
31 | }; | 40 | }; |
32 | 41 |
src/pages/Instalment/components/upload/uploadModel.tsx
@@ -27,7 +27,12 @@ export default ({ toReload }) => { | @@ -27,7 +27,12 @@ export default ({ toReload }) => { | ||
27 | }> | 27 | }> |
28 | title="新建表单" | 28 | title="新建表单" |
29 | trigger={ | 29 | trigger={ |
30 | - <Button type="primary"> | 30 | + <Button |
31 | + type="primary" | ||
32 | + onClick={() => { | ||
33 | + setUploadFile({}); | ||
34 | + }} | ||
35 | + > | ||
31 | <VerticalAlignBottomOutlined /> | 36 | <VerticalAlignBottomOutlined /> |
32 | 导入 | 37 | 导入 |
33 | </Button> | 38 | </Button> |
@@ -39,6 +44,9 @@ export default ({ toReload }) => { | @@ -39,6 +44,9 @@ export default ({ toReload }) => { | ||
39 | }} | 44 | }} |
40 | submitTimeout={2000} | 45 | submitTimeout={2000} |
41 | onFinish={async () => { | 46 | onFinish={async () => { |
47 | + if (!(uploadFile instanceof File)) { | ||
48 | + return false; | ||
49 | + } | ||
42 | const formData = new FormData(); | 50 | const formData = new FormData(); |
43 | formData.append('file', uploadFile as RcFile); | 51 | formData.append('file', uploadFile as RcFile); |
44 | const res = await postOrderErpOrderStagesImport({ | 52 | const res = await postOrderErpOrderStagesImport({ |
src/pages/ZoNing/components/table.tsx
0 → 100644