Commit fc0281959e5ce160ee886687ad84afc56c092a76

Authored by 曾国涛
2 parents 80092cd1 e0b4e44b

Merge branch 'master' into warning

# Conflicts:
#	src/pages/Invoice/Invoice/components/AddBankStatementModal.tsx
#	src/pages/Invoice/Invoice/components/InvoiceVerificationModal.tsx
#	src/pages/Invoice/Invoice/components/invoiceWriteOffModal.tsx
#	src/pages/Invoice/InvoiceVerification/index.tsx
#	src/pages/Order/Order/index.tsx
#	src/services/request.ts

Too many changes to show.

To preserve performance only 9 of 10 files are displayed.

src/pages/Invoice/Invoice/components/AddBankStatementModal.tsx
@@ -14,11 +14,21 @@ export default ({ getRows, onFinish }) => { @@ -14,11 +14,21 @@ export default ({ getRows, onFinish }) => {
14 dataIndex: 'id', 14 dataIndex: 'id',
15 }, 15 },
16 { 16 {
  17 + title: '编号',
  18 + hideInTable: true,
  19 + dataIndex: 'id',
  20 + },
  21 + {
17 title: '流水号', 22 title: '流水号',
18 hideInSearch: true, 23 hideInSearch: true,
19 dataIndex: 'serialNumber', 24 dataIndex: 'serialNumber',
20 }, 25 },
21 { 26 {
  27 + title: '流水号',
  28 + hideInTable: true,
  29 + dataIndex: 'serialNumber',
  30 + },
  31 + {
22 title: '收款时间', 32 title: '收款时间',
23 dataIndex: 'collectionDatetime', 33 dataIndex: 'collectionDatetime',
24 hideInSearch: true, 34 hideInSearch: true,
@@ -26,7 +36,7 @@ export default ({ getRows, onFinish }) => { @@ -26,7 +36,7 @@ export default ({ getRows, onFinish }) => {
26 }, 36 },
27 { 37 {
28 title: '收款方', 38 title: '收款方',
29 - hideInTable: true, 39 + hideInSearch: true,
30 dataIndex: 'payeeText', 40 dataIndex: 'payeeText',
31 }, 41 },
32 { 42 {
src/pages/Invoice/Invoice/components/InvoiceVerificationModal.tsx
@@ -20,7 +20,6 @@ export default ({ invoiceId, setVisible, onClose }) => { @@ -20,7 +20,6 @@ export default ({ invoiceId, setVisible, onClose }) => {
20 const [bankChooseModalVisible, setBankChooseModalVisible] = useState(false); 20 const [bankChooseModalVisible, setBankChooseModalVisible] = useState(false);
21 const [invoiceInfo, setInvoiceInfo] = useState({}); 21 const [invoiceInfo, setInvoiceInfo] = useState({});
22 const [relationOrderIds, setRelationOrderIds] = useState([]); 22 const [relationOrderIds, setRelationOrderIds] = useState([]);
23 - const [setRelationBankStatements] = useState([]);  
24 const actionRef = useRef<ActionType>(); 23 const actionRef = useRef<ActionType>();
25 24
26 const loadInvoiceData = async () => { 25 const loadInvoiceData = async () => {
@@ -31,7 +30,6 @@ export default ({ invoiceId, setVisible, onClose }) =&gt; { @@ -31,7 +30,6 @@ export default ({ invoiceId, setVisible, onClose }) =&gt; {
31 setInvoiceInfo(res.data); 30 setInvoiceInfo(res.data);
32 setRelationOrderIds(res.data.mainOrderIds); 31 setRelationOrderIds(res.data.mainOrderIds);
33 console.log('bs:' + res.data.bankStatementDtos); 32 console.log('bs:' + res.data.bankStatementDtos);
34 - setRelationBankStatements(res.data.bankStatementDtos);  
35 } 33 }
36 }; 34 };
37 35
@@ -117,6 +115,18 @@ export default ({ invoiceId, setVisible, onClose }) =&gt; { @@ -117,6 +115,18 @@ export default ({ invoiceId, setVisible, onClose }) =&gt; {
117 }, 115 },
118 { 116 {
119 key: '11', 117 key: '11',
  118 + label: '订单类型',
  119 + children: invoiceInfo?.orderTypeText,
  120 + span: 12,
  121 + },
  122 + {
  123 + key: '12',
  124 + label: '绑定流水号',
  125 + children: invoiceInfo?.serialNumbersTextByOrder,
  126 + span: 12,
  127 + },
  128 + {
  129 + key: '13',
120 label: '备注', 130 label: '备注',
121 children: invoiceInfo?.notes, 131 children: invoiceInfo?.notes,
122 span: 24, 132 span: 24,
src/pages/Invoice/Invoice/components/invoiceWriteOffModal.tsx
@@ -30,24 +30,29 @@ export default ({ getData, triggerButton, readOnly }) =&gt; { @@ -30,24 +30,29 @@ export default ({ getData, triggerButton, readOnly }) =&gt; {
30 { 30 {
31 title: '发票号码', 31 title: '发票号码',
32 dataIndex: 'invoiceNumber', 32 dataIndex: 'invoiceNumber',
  33 + ellipsis: true,
33 }, 34 },
34 { 35 {
35 title: '收款方', 36 title: '收款方',
36 dataIndex: 'payeeText', 37 dataIndex: 'payeeText',
  38 + ellipsis: true,
37 }, 39 },
38 { 40 {
39 title: '付款方', 41 title: '付款方',
40 dataIndex: 'purchaser', 42 dataIndex: 'purchaser',
  43 + ellipsis: true,
41 }, 44 },
42 { 45 {
43 title: '金额', 46 title: '金额',
44 dataIndex: 'money', 47 dataIndex: 'money',
45 valueType: 'money', 48 valueType: 'money',
  49 + ellipsis: true,
46 }, 50 },
47 { 51 {
48 title: '日期', 52 title: '日期',
49 dataIndex: 'invoicingTime', 53 dataIndex: 'invoicingTime',
50 valueType: 'date', 54 valueType: 'date',
  55 + ellipsis: true,
51 }, 56 },
52 ]; 57 ];
53 if (!readOnly) { 58 if (!readOnly) {
@@ -84,24 +89,29 @@ export default ({ getData, triggerButton, readOnly }) =&gt; { @@ -84,24 +89,29 @@ export default ({ getData, triggerButton, readOnly }) =&gt; {
84 { 89 {
85 title: '流水号', 90 title: '流水号',
86 dataIndex: 'serialNumber', 91 dataIndex: 'serialNumber',
  92 + ellipsis: true,
87 }, 93 },
88 { 94 {
89 title: '收款方', 95 title: '收款方',
90 dataIndex: 'payeeText', 96 dataIndex: 'payeeText',
  97 + ellipsis: true,
91 }, 98 },
92 { 99 {
93 title: '付款方', 100 title: '付款方',
94 dataIndex: 'payer', 101 dataIndex: 'payer',
  102 + ellipsis: true,
95 }, 103 },
96 { 104 {
97 title: '金额', 105 title: '金额',
98 dataIndex: 'amount', 106 dataIndex: 'amount',
99 valueType: 'money', 107 valueType: 'money',
  108 + ellipsis: true,
100 }, 109 },
101 { 110 {
102 title: '日期', 111 title: '日期',
103 dataIndex: 'collectionDatetime', 112 dataIndex: 'collectionDatetime',
104 valueType: 'date', 113 valueType: 'date',
  114 + ellipsis: true,
105 }, 115 },
106 ]; 116 ];
107 columns.push({ 117 columns.push({
@@ -153,9 +163,9 @@ export default ({ getData, triggerButton, readOnly }) =&gt; { @@ -153,9 +163,9 @@ export default ({ getData, triggerButton, readOnly }) =&gt; {
153 return getData(); 163 return getData();
154 }} 164 }}
155 /*initialValues={{ 165 /*initialValues={{
156 - invoiceWriteOffId:invoiceWriteOffId,  
157 - invoices:originInvoices,  
158 - }}*/ 166 + invoiceWriteOffId:invoiceWriteOffId,
  167 + invoices:originInvoices,
  168 + }}*/
159 > 169 >
160 <ProFormText name={'invoiceWriteOffId'} hidden={true}></ProFormText> 170 <ProFormText name={'invoiceWriteOffId'} hidden={true}></ProFormText>
161 171
src/pages/Invoice/Invoice/index.tsx
@@ -11,6 +11,7 @@ import { @@ -11,6 +11,7 @@ import {
11 postServiceInvoiceGetWriteOffRecord, 11 postServiceInvoiceGetWriteOffRecord,
12 postServiceInvoiceQueryInvoice, 12 postServiceInvoiceQueryInvoice,
13 } from '@/services'; 13 } from '@/services';
  14 +import { orderExport } from '@/services/order';
14 import { enumValueToLabel, formatDateTime } from '@/utils'; 15 import { enumValueToLabel, formatDateTime } from '@/utils';
15 import { formatDate } from '@/utils/time'; 16 import { formatDate } from '@/utils/time';
16 import { ActionType, ProTable } from '@ant-design/pro-components'; 17 import { ActionType, ProTable } from '@ant-design/pro-components';
@@ -23,6 +24,7 @@ const InvoiceRecord = () =&gt; { @@ -23,6 +24,7 @@ const InvoiceRecord = () =&gt; {
23 const [invoiceVerificationVisible, setInvoiceVerificationVisible] = 24 const [invoiceVerificationVisible, setInvoiceVerificationVisible] =
24 useState(false); 25 useState(false);
25 const [invoiceId, setInvoiceId] = useState(undefined); 26 const [invoiceId, setInvoiceId] = useState(undefined);
  27 + const [messageApi, contextHolder] = message.useMessage();
26 const reloadInvoiceTable = () => { 28 const reloadInvoiceTable = () => {
27 invoiceActionRef.current?.reload(); 29 invoiceActionRef.current?.reload();
28 }; 30 };
@@ -216,6 +218,31 @@ const InvoiceRecord = () =&gt; { @@ -216,6 +218,31 @@ const InvoiceRecord = () =&gt; {
216 rowKey="id" 218 rowKey="id"
217 search={{ 219 search={{
218 labelWidth: 'auto', 220 labelWidth: 'auto',
  221 + optionRender: (searchConfig, formProps, dom) => [
  222 + ...dom.reverse(),
  223 + <Button
  224 + key="out"
  225 + onClick={() => {
  226 + const values = searchConfig?.form?.getFieldsValue();
  227 + messageApi.open({
  228 + type: 'loading',
  229 + content: '导出中...',
  230 + duration: 0,
  231 + });
  232 + orderExport(
  233 + '/api/service/invoice/exportInvoices',
  234 + '发票.xlsx',
  235 + 'POST',
  236 + values,
  237 + () => {
  238 + messageApi.destroy();
  239 + },
  240 + );
  241 + }}
  242 + >
  243 + 导出
  244 + </Button>,
  245 + ],
219 }} 246 }}
220 options={{ 247 options={{
221 setting: { 248 setting: {
@@ -265,6 +292,7 @@ const InvoiceRecord = () =&gt; { @@ -265,6 +292,7 @@ const InvoiceRecord = () =&gt; {
265 ) : ( 292 ) : (
266 '' 293 ''
267 )} 294 )}
  295 + {contextHolder}
268 </div> 296 </div>
269 ); 297 );
270 }; 298 };
src/pages/Invoice/InvoiceVerification/index.tsx
@@ -16,6 +16,7 @@ import { @@ -16,6 +16,7 @@ import {
16 postServiceBankStatementQueryBankStatement, 16 postServiceBankStatementQueryBankStatement,
17 postServiceInvoiceGetWriteOffRecord, 17 postServiceInvoiceGetWriteOffRecord,
18 } from '@/services'; 18 } from '@/services';
  19 +import { orderExport } from '@/services/order';
19 import { enumValueToLabel, formatDateTime } from '@/utils'; 20 import { enumValueToLabel, formatDateTime } from '@/utils';
20 import { formatDate } from '@/utils/time'; 21 import { formatDate } from '@/utils/time';
21 import { PlusOutlined } from '@ant-design/icons'; 22 import { PlusOutlined } from '@ant-design/icons';
@@ -29,6 +30,7 @@ const InvoiceRecord = () =&gt; { @@ -29,6 +30,7 @@ const InvoiceRecord = () =&gt; {
29 const [bankImportModalVisible, setBankImportModalVisible] = useState(false); 30 const [bankImportModalVisible, setBankImportModalVisible] = useState(false);
30 const [invoiceVerificationVisible, setInvoiceVerificationVisible] = 31 const [invoiceVerificationVisible, setInvoiceVerificationVisible] =
31 useState(false); 32 useState(false);
  33 + const [messageApi, contextHolder] = message.useMessage();
32 const [invoiceId] = useState(undefined); 34 const [invoiceId] = useState(undefined);
33 const [invoiceRecordDetailVisible, setInvoiceRecordDetailVisible] = 35 const [invoiceRecordDetailVisible, setInvoiceRecordDetailVisible] =
34 useState(false); 36 useState(false);
@@ -139,6 +141,7 @@ const InvoiceRecord = () =&gt; { @@ -139,6 +141,7 @@ const InvoiceRecord = () =&gt; {
139 btns.push( 141 btns.push(
140 <InvoiceWriteOffModal 142 <InvoiceWriteOffModal
141 getData={async () => { 143 getData={async () => {
  144 + console.log(record.writeOffId);
142 const res = await postServiceInvoiceGetWriteOffRecord({ 145 const res = await postServiceInvoiceGetWriteOffRecord({
143 data: { id: record.writeOffId }, 146 data: { id: record.writeOffId },
144 }); 147 });
@@ -225,6 +228,31 @@ const InvoiceRecord = () =&gt; { @@ -225,6 +228,31 @@ const InvoiceRecord = () =&gt; {
225 rowKey="id" 228 rowKey="id"
226 search={{ 229 search={{
227 labelWidth: 'auto', 230 labelWidth: 'auto',
  231 + optionRender: (searchConfig, formProps, dom) => [
  232 + ...dom.reverse(),
  233 + <Button
  234 + key="out"
  235 + onClick={() => {
  236 + const values = searchConfig?.form?.getFieldsValue();
  237 + messageApi.open({
  238 + type: 'loading',
  239 + content: '导出中...',
  240 + duration: 0,
  241 + });
  242 + orderExport(
  243 + '/api/service/invoice/exportBankStatements',
  244 + '银行流水.xlsx',
  245 + 'POST',
  246 + values,
  247 + () => {
  248 + messageApi.destroy();
  249 + },
  250 + );
  251 + }}
  252 + >
  253 + 导出
  254 + </Button>,
  255 + ],
228 }} 256 }}
229 options={{ 257 options={{
230 setting: { 258 setting: {
@@ -283,6 +311,7 @@ const InvoiceRecord = () =&gt; { @@ -283,6 +311,7 @@ const InvoiceRecord = () =&gt; {
283 ) : ( 311 ) : (
284 '' 312 ''
285 )} 313 )}
  314 + {contextHolder}
286 </div> 315 </div>
287 ); 316 );
288 }; 317 };
src/pages/Invoice/constant.tsx
@@ -78,6 +78,43 @@ export const INVOICE_COLUMNS = [ @@ -78,6 +78,43 @@ export const INVOICE_COLUMNS = [
78 hideInTable: true, 78 hideInTable: true,
79 }, 79 },
80 { 80 {
  81 + title: '订单状态',
  82 + dataIndex: 'orderTypeText',
  83 + valueType: 'text',
  84 + width: 180,
  85 + },
  86 + {
  87 + title: '绑定流水号',
  88 + dataIndex: 'serialNumbersTextByOrder',
  89 +
  90 + valueType: 'text',
  91 + width: 180,
  92 + },
  93 + {
  94 + title: '是否预付款',
  95 + dataIndex: 'orderIsPrePay',
  96 + valueType: 'select',
  97 + valueEnum: {
  98 + true: {
  99 + text: '是',
  100 + status: true,
  101 + },
  102 + false: {
  103 + text: '否',
  104 + status: false,
  105 + },
  106 + },
  107 + hideInTable: true,
  108 + width: 180,
  109 + },
  110 + {
  111 + title: '绑定流水号',
  112 + dataIndex: 'serialNumberLike',
  113 + hideInTable: true,
  114 + valueType: 'text',
  115 + width: 180,
  116 + },
  117 + {
81 title: '购买方', 118 title: '购买方',
82 dataIndex: 'purchaser', 119 dataIndex: 'purchaser',
83 valueType: 'text', 120 valueType: 'text',
src/pages/Order/Order/index.tsx
@@ -211,6 +211,7 @@ const OrderPage = () =&gt; { @@ -211,6 +211,7 @@ const OrderPage = () =&gt; {
211 const [ids, setIds] = useState([]); 211 const [ids, setIds] = useState([]);
212 const [recordOptNode, setRecordOptNode] = useState(null); 212 const [recordOptNode, setRecordOptNode] = useState(null);
213 const roleCode = userInfo?.roleSmallVO?.code; 213 const roleCode = userInfo?.roleSmallVO?.code;
  214 + const roles = userInfo?.roles;
214 const canMergeInvoicing = useMemo(() => { 215 const canMergeInvoicing = useMemo(() => {
215 if (subOrderSelectedMap.size === 0) { 216 if (subOrderSelectedMap.size === 0) {
216 return false; 217 return false;
@@ -224,6 +225,7 @@ const OrderPage = () =&gt; { @@ -224,6 +225,7 @@ const OrderPage = () =&gt; {
224 .every((subItem) => subItem.paths.includes('applyInvoicing_old')); 225 .every((subItem) => subItem.paths.includes('applyInvoicing_old'));
225 }, [selectedSubOrderKeys]); 226 }, [selectedSubOrderKeys]);
226 227
  228 + console.log(JSON.stringify(userInfo));
227 const triggerRecordOptNode = async (id) => { 229 const triggerRecordOptNode = async (id) => {
228 const res = await postServiceOrderGetCurrentOptNode({ 230 const res = await postServiceOrderGetCurrentOptNode({
229 query: { 231 query: {
@@ -2092,8 +2094,9 @@ const OrderPage = () =&gt; { @@ -2092,8 +2094,9 @@ const OrderPage = () =&gt; {
2092 title="已和客户确认发票??" 2094 title="已和客户确认发票??"
2093 text="确认发票" 2095 text="确认发票"
2094 onConfirm={async () => { 2096 onConfirm={async () => {
  2097 + let body = { ids: [optRecord.id] };
2095 const data = await postServiceOrderConfirmInvoice({ 2098 const data = await postServiceOrderConfirmInvoice({
2096 - data: [optRecord.id], 2099 + data: body,
2097 }); 2100 });
2098 if (data.result === RESPONSE_CODE.SUCCESS) { 2101 if (data.result === RESPONSE_CODE.SUCCESS) {
2099 message.success(data.message); 2102 message.success(data.message);
@@ -2104,7 +2107,6 @@ const OrderPage = () =&gt; { @@ -2104,7 +2107,6 @@ const OrderPage = () =&gt; {
2104 ) : ( 2107 ) : (
2105 '' 2108 ''
2106 )} 2109 )}
2107 -  
2108 {optRecord.paths?.includes('orderCancel') ? ( 2110 {optRecord.paths?.includes('orderCancel') ? (
2109 <ButtonConfirm 2111 <ButtonConfirm
2110 className="p-0" 2112 className="p-0"
@@ -3885,12 +3887,15 @@ const OrderPage = () =&gt; { @@ -3885,12 +3887,15 @@ const OrderPage = () =&gt; {
3885 title="已和客户确认发票?" 3887 title="已和客户确认发票?"
3886 text="确认发票" 3888 text="确认发票"
3887 onConfirm={async () => { 3889 onConfirm={async () => {
3888 - const data = await postServiceOrderConfirmInvoice({  
3889 - data: [ 3890 + let body = {
  3891 + ids: [
3890 ...record.subOrderInformationLists.map( 3892 ...record.subOrderInformationLists.map(
3891 (subOrder) => subOrder.id, 3893 (subOrder) => subOrder.id,
3892 ), 3894 ),
3893 ], 3895 ],
  3896 + };
  3897 + const data = await postServiceOrderConfirmInvoice({
  3898 + data: body,
3894 }); 3899 });
3895 if (data.result === RESPONSE_CODE.SUCCESS) { 3900 if (data.result === RESPONSE_CODE.SUCCESS) {
3896 message.success(data.message); 3901 message.success(data.message);
@@ -4038,7 +4043,7 @@ const OrderPage = () =&gt; { @@ -4038,7 +4043,7 @@ const OrderPage = () =&gt; {
4038 /** 4043 /**
4039 * 采购的订单状态筛选内容 4044 * 采购的订单状态筛选内容
4040 */ 4045 */
4041 - if (roleCode === 'procure' && item.dataIndex === 'orderStatus') { 4046 + if (roles.includes('PROCURE') && item.dataIndex === 'orderStatus') {
4042 item.valueEnum = enumToProTableEnumValue( 4047 item.valueEnum = enumToProTableEnumValue(
4043 PROCURE_PRIMARY_ORDER_STATUS_OPTIONS, 4048 PROCURE_PRIMARY_ORDER_STATUS_OPTIONS,
4044 ); 4049 );
@@ -4050,7 +4055,12 @@ const OrderPage = () =&gt; { @@ -4050,7 +4055,12 @@ const OrderPage = () =&gt; {
4050 /** 4055 /**
4051 * 采购可以筛选供应商备注 4056 * 采购可以筛选供应商备注
4052 */ 4057 */
4053 - if ((roleCode === 'procure' || roleCode === 'admin') && !isSupplier()) { 4058 + if (
  4059 + (roleCode === 'procure' ||
  4060 + roles.includes('PROCURE') ||
  4061 + roleCode === 'admin') &&
  4062 + !isSupplier()
  4063 + ) {
4054 mainOrdersColumns.push({ 4064 mainOrdersColumns.push({
4055 title: '供应商备注', 4065 title: '供应商备注',
4056 width: 120, 4066 width: 120,
@@ -4063,7 +4073,12 @@ const OrderPage = () =&gt; { @@ -4063,7 +4073,12 @@ const OrderPage = () =&gt; {
4063 /** 4073 /**
4064 * 采购可以筛选其他采购 4074 * 采购可以筛选其他采购
4065 */ 4075 */
4066 - if ((roleCode === 'procure' || roleCode === 'admin') && !isSupplier()) { 4076 + if (
  4077 + (roleCode === 'procure' ||
  4078 + roles.includes('PROCURE') ||
  4079 + roleCode === 'admin') &&
  4080 + !isSupplier()
  4081 + ) {
4067 mainOrdersColumns.push({ 4082 mainOrdersColumns.push({
4068 title: '采购名称', 4083 title: '采购名称',
4069 width: 120, 4084 width: 120,
@@ -4083,7 +4098,12 @@ const OrderPage = () =&gt; { @@ -4083,7 +4098,12 @@ const OrderPage = () =&gt; {
4083 /** 4098 /**
4084 * 排除采购 4099 * 排除采购
4085 */ 4100 */
4086 - if ((roleCode === 'procure' || roleCode === 'admin') && !isSupplier()) { 4101 + if (
  4102 + (roleCode === 'procure' ||
  4103 + roles.includes('PROCURE') ||
  4104 + roleCode === 'admin') &&
  4105 + !isSupplier()
  4106 + ) {
4087 mainOrdersColumns.push({ 4107 mainOrdersColumns.push({
4088 title: '采购排除', 4108 title: '采购排除',
4089 width: 120, 4109 width: 120,
@@ -4118,7 +4138,11 @@ const OrderPage = () =&gt; { @@ -4118,7 +4138,11 @@ const OrderPage = () =&gt; {
4118 } 4138 }
4119 4139
4120 //判断是否是采购,是的话新增一个筛选条件 4140 //判断是否是采购,是的话新增一个筛选条件
4121 - if (roleCode === 'procure' || roleCode === 'admin') { 4141 + if (
  4142 + roleCode === 'procure' ||
  4143 + roles.includes('PROCURE') ||
  4144 + roleCode === 'admin'
  4145 + ) {
4122 mainOrdersColumns.push({ 4146 mainOrdersColumns.push({
4123 title: isSupplier() ? '下单状态' : '采购下单状态', 4147 title: isSupplier() ? '下单状态' : '采购下单状态',
4124 dataIndex: 'procureOrderStatus', 4148 dataIndex: 'procureOrderStatus',
@@ -4147,7 +4171,7 @@ const OrderPage = () =&gt; { @@ -4147,7 +4171,7 @@ const OrderPage = () =&gt; {
4147 } 4171 }
4148 4172
4149 //采购可以筛选出需要处理的订单 4173 //采购可以筛选出需要处理的订单
4150 - if (roleCode === 'procure' && !isSupplier()) { 4174 + if (roles.includes('PROCURE') && !isSupplier()) {
4151 radios.push(<Radio value={60}>其他采购</Radio>); 4175 radios.push(<Radio value={60}>其他采购</Radio>);
4152 radios.push(<Radio value={10}>待处理</Radio>); 4176 radios.push(<Radio value={10}>待处理</Radio>);
4153 } 4177 }
@@ -4331,7 +4355,7 @@ const OrderPage = () =&gt; { @@ -4331,7 +4355,7 @@ const OrderPage = () =&gt; {
4331 key="out" 4355 key="out"
4332 onClick={() => { 4356 onClick={() => {
4333 setIsMainOrder(true); 4357 setIsMainOrder(true);
4334 - if (roleCode === 'procure') { 4358 + if (roles.includes('PROCURE')) {
4335 setProcureCheckModalVisible(true); 4359 setProcureCheckModalVisible(true);
4336 } 4360 }
4337 4361
src/pages/ResearchGroup/components/ResearchGroupAddModal.tsx
@@ -267,9 +267,15 @@ export default ({ setVisible, researchGroupId, onClose }) =&gt; { @@ -267,9 +267,15 @@ export default ({ setVisible, researchGroupId, onClose }) =&gt; {
267 let uidIdMap = new Map( 267 let uidIdMap = new Map(
268 accounts.map((item: any) => [item.accountId, item.id]), 268 accounts.map((item: any) => [item.accountId, item.id]),
269 ); 269 );
270 - let res = await postCanrdApiUserList({  
271 - data: { uids: accountIds, phones: phones },  
272 - }); 270 + let data = {};
  271 + if (accountIds.length > 0) {
  272 + data = { ...data, uids: accountIds };
  273 + }
  274 + if (phones.length > 0) {
  275 + data = { ...data, phones: phones };
  276 + }
  277 +
  278 + let res = await postCanrdApiUserList({ data });
273 if (res && res.result === RESPONSE_CODE.SUCCESS) { 279 if (res && res.result === RESPONSE_CODE.SUCCESS) {
274 let accountList = res?.data?.data; 280 let accountList = res?.data?.data;
275 console.log(accountList); 281 console.log(accountList);
src/services/definition.ts
@@ -3,82 +3,82 @@ @@ -3,82 +3,82 @@
3 /** Do not modify manually. 3 /** Do not modify manually.
4 content is generated automatically by `ts-gear`. */ 4 content is generated automatically by `ts-gear`. */
5 export type ModelAndViewStatus = 5 export type ModelAndViewStatus =
6 - | "100 CONTINUE"  
7 - | "101 SWITCHING_PROTOCOLS"  
8 - | "102 PROCESSING"  
9 - | "103 CHECKPOINT"  
10 - | "200 OK"  
11 - | "201 CREATED"  
12 - | "202 ACCEPTED"  
13 - | "203 NON_AUTHORITATIVE_INFORMATION"  
14 - | "204 NO_CONTENT"  
15 - | "205 RESET_CONTENT"  
16 - | "206 PARTIAL_CONTENT"  
17 - | "207 MULTI_STATUS"  
18 - | "208 ALREADY_REPORTED"  
19 - | "226 IM_USED"  
20 - | "300 MULTIPLE_CHOICES"  
21 - | "301 MOVED_PERMANENTLY"  
22 - | "302 FOUND"  
23 - | "302 MOVED_TEMPORARILY"  
24 - | "303 SEE_OTHER"  
25 - | "304 NOT_MODIFIED"  
26 - | "305 USE_PROXY"  
27 - | "307 TEMPORARY_REDIRECT"  
28 - | "308 PERMANENT_REDIRECT"  
29 - | "400 BAD_REQUEST"  
30 - | "401 UNAUTHORIZED"  
31 - | "402 PAYMENT_REQUIRED"  
32 - | "403 FORBIDDEN"  
33 - | "404 NOT_FOUND"  
34 - | "405 METHOD_NOT_ALLOWED"  
35 - | "406 NOT_ACCEPTABLE"  
36 - | "407 PROXY_AUTHENTICATION_REQUIRED"  
37 - | "408 REQUEST_TIMEOUT"  
38 - | "409 CONFLICT"  
39 - | "410 GONE"  
40 - | "411 LENGTH_REQUIRED"  
41 - | "412 PRECONDITION_FAILED"  
42 - | "413 PAYLOAD_TOO_LARGE"  
43 - | "413 REQUEST_ENTITY_TOO_LARGE"  
44 - | "414 URI_TOO_LONG"  
45 - | "414 REQUEST_URI_TOO_LONG"  
46 - | "415 UNSUPPORTED_MEDIA_TYPE"  
47 - | "416 REQUESTED_RANGE_NOT_SATISFIABLE"  
48 - | "417 EXPECTATION_FAILED"  
49 - | "418 I_AM_A_TEAPOT"  
50 - | "419 INSUFFICIENT_SPACE_ON_RESOURCE"  
51 - | "420 METHOD_FAILURE"  
52 - | "421 DESTINATION_LOCKED"  
53 - | "422 UNPROCESSABLE_ENTITY"  
54 - | "423 LOCKED"  
55 - | "424 FAILED_DEPENDENCY"  
56 - | "425 TOO_EARLY"  
57 - | "426 UPGRADE_REQUIRED"  
58 - | "428 PRECONDITION_REQUIRED"  
59 - | "429 TOO_MANY_REQUESTS"  
60 - | "431 REQUEST_HEADER_FIELDS_TOO_LARGE"  
61 - | "451 UNAVAILABLE_FOR_LEGAL_REASONS"  
62 - | "500 INTERNAL_SERVER_ERROR"  
63 - | "501 NOT_IMPLEMENTED"  
64 - | "502 BAD_GATEWAY"  
65 - | "503 SERVICE_UNAVAILABLE"  
66 - | "504 GATEWAY_TIMEOUT"  
67 - | "505 HTTP_VERSION_NOT_SUPPORTED"  
68 - | "506 VARIANT_ALSO_NEGOTIATES"  
69 - | "507 INSUFFICIENT_STORAGE"  
70 - | "508 LOOP_DETECTED"  
71 - | "509 BANDWIDTH_LIMIT_EXCEEDED"  
72 - | "510 NOT_EXTENDED"  
73 - | "511 NETWORK_AUTHENTICATION_REQUIRED"; 6 + | '100 CONTINUE'
  7 + | '101 SWITCHING_PROTOCOLS'
  8 + | '102 PROCESSING'
  9 + | '103 CHECKPOINT'
  10 + | '200 OK'
  11 + | '201 CREATED'
  12 + | '202 ACCEPTED'
  13 + | '203 NON_AUTHORITATIVE_INFORMATION'
  14 + | '204 NO_CONTENT'
  15 + | '205 RESET_CONTENT'
  16 + | '206 PARTIAL_CONTENT'
  17 + | '207 MULTI_STATUS'
  18 + | '208 ALREADY_REPORTED'
  19 + | '226 IM_USED'
  20 + | '300 MULTIPLE_CHOICES'
  21 + | '301 MOVED_PERMANENTLY'
  22 + | '302 FOUND'
  23 + | '302 MOVED_TEMPORARILY'
  24 + | '303 SEE_OTHER'
  25 + | '304 NOT_MODIFIED'
  26 + | '305 USE_PROXY'
  27 + | '307 TEMPORARY_REDIRECT'
  28 + | '308 PERMANENT_REDIRECT'
  29 + | '400 BAD_REQUEST'
  30 + | '401 UNAUTHORIZED'
  31 + | '402 PAYMENT_REQUIRED'
  32 + | '403 FORBIDDEN'
  33 + | '404 NOT_FOUND'
  34 + | '405 METHOD_NOT_ALLOWED'
  35 + | '406 NOT_ACCEPTABLE'
  36 + | '407 PROXY_AUTHENTICATION_REQUIRED'
  37 + | '408 REQUEST_TIMEOUT'
  38 + | '409 CONFLICT'
  39 + | '410 GONE'
  40 + | '411 LENGTH_REQUIRED'
  41 + | '412 PRECONDITION_FAILED'
  42 + | '413 PAYLOAD_TOO_LARGE'
  43 + | '413 REQUEST_ENTITY_TOO_LARGE'
  44 + | '414 URI_TOO_LONG'
  45 + | '414 REQUEST_URI_TOO_LONG'
  46 + | '415 UNSUPPORTED_MEDIA_TYPE'
  47 + | '416 REQUESTED_RANGE_NOT_SATISFIABLE'
  48 + | '417 EXPECTATION_FAILED'
  49 + | '418 I_AM_A_TEAPOT'
  50 + | '419 INSUFFICIENT_SPACE_ON_RESOURCE'
  51 + | '420 METHOD_FAILURE'
  52 + | '421 DESTINATION_LOCKED'
  53 + | '422 UNPROCESSABLE_ENTITY'
  54 + | '423 LOCKED'
  55 + | '424 FAILED_DEPENDENCY'
  56 + | '425 TOO_EARLY'
  57 + | '426 UPGRADE_REQUIRED'
  58 + | '428 PRECONDITION_REQUIRED'
  59 + | '429 TOO_MANY_REQUESTS'
  60 + | '431 REQUEST_HEADER_FIELDS_TOO_LARGE'
  61 + | '451 UNAVAILABLE_FOR_LEGAL_REASONS'
  62 + | '500 INTERNAL_SERVER_ERROR'
  63 + | '501 NOT_IMPLEMENTED'
  64 + | '502 BAD_GATEWAY'
  65 + | '503 SERVICE_UNAVAILABLE'
  66 + | '504 GATEWAY_TIMEOUT'
  67 + | '505 HTTP_VERSION_NOT_SUPPORTED'
  68 + | '506 VARIANT_ALSO_NEGOTIATES'
  69 + | '507 INSUFFICIENT_STORAGE'
  70 + | '508 LOOP_DETECTED'
  71 + | '509 BANDWIDTH_LIMIT_EXCEEDED'
  72 + | '510 NOT_EXTENDED'
  73 + | '511 NETWORK_AUTHENTICATION_REQUIRED';
74 export type ProcureReturnBillDtoSendStore = 74 export type ProcureReturnBillDtoSendStore =
75 - | "DALANG_WAREHOUSE"  
76 - | "HOUJIE_WAREHOUSE"; 75 + | 'DALANG_WAREHOUSE'
  76 + | 'HOUJIE_WAREHOUSE';
77 export type ProcureReturnBillDtoStatus = 77 export type ProcureReturnBillDtoStatus =
78 - | "AUDIT_NOTPASS"  
79 - | "WAIT_SEND"  
80 - | "SENDED"  
81 - | "WAIT_AUDIT"; 78 + | 'AUDIT_NOTPASS'
  79 + | 'WAIT_SEND'
  80 + | 'SENDED'
  81 + | 'WAIT_AUDIT';
82 export interface AdminAuthRoleVO { 82 export interface AdminAuthRoleVO {
83 menuIds?: Array<number>; 83 menuIds?: Array<number>;
84 /** @format int64 */ 84 /** @format int64 */
@@ -1465,11 +1465,20 @@ export interface InvoiceDto { @@ -1465,11 +1465,20 @@ export interface InvoiceDto {
1465 invoiceStatus?: string; 1465 invoiceStatus?: string;
1466 /** 1466 /**
1467 * @description 1467 * @description
  1468 + * 发票类型
  1469 + */
  1470 + invoiceStatusText?: string;
  1471 + /**
  1472 + * @description
1468 * 开票日期 1473 * 开票日期
1469 * @format date-time 1474 * @format date-time
1470 */ 1475 */
1471 invoicingTime?: string; 1476 invoicingTime?: string;
1472 invoicingType?: string; 1477 invoicingType?: string;
  1478 + /**
  1479 + * @description
  1480 + * 开具类型
  1481 + */
1473 invoicingTypeText?: string; 1482 invoicingTypeText?: string;
1474 logicDelete?: boolean; 1483 logicDelete?: boolean;
1475 /** 1484 /**
@@ -1501,6 +1510,11 @@ export interface InvoiceDto { @@ -1501,6 +1510,11 @@ export interface InvoiceDto {
1501 payeeText?: string; 1510 payeeText?: string;
1502 /** 1511 /**
1503 * @description 1512 * @description
  1513 + * 收款单位
  1514 + */
  1515 + payeeText?: string;
  1516 + /**
  1517 + * @description
1504 * 购买方 1518 * 购买方
1505 */ 1519 */
1506 purchaser?: string; 1520 purchaser?: string;
@@ -3693,6 +3707,9 @@ export interface SubOrder { @@ -3693,6 +3707,9 @@ export interface SubOrder {
3693 id?: number; 3707 id?: number;
3694 image?: string; 3708 image?: string;
3695 invoiceApplyUsername?: string; 3709 invoiceApplyUsername?: string;
  3710 + invoiceConfirmStatus?: string;
  3711 + /** @format date-time */
  3712 + invoiceConfirmStatusDatetime?: string;
3696 invoiceInformation?: string; 3713 invoiceInformation?: string;
3697 /** @format int64 */ 3714 /** @format int64 */
3698 invoiceRecordId?: number; 3715 invoiceRecordId?: number;