Commit 19c6b071abbc14cd7fa3fd01b7239407ae8da36f

Authored by zhongnanhuang
1 parent 7780aaa4

feat: update

src/app.ts
@@ -23,8 +23,8 @@ export const layout = () => { @@ -23,8 +23,8 @@ export const layout = () => {
23 headerRender: true, 23 headerRender: true,
24 // rightContentRender: () => <RightContent />, 24 // rightContentRender: () => <RightContent />,
25 // footerRender: () => <Footer />, 25 // footerRender: () => <Footer />,
26 - siderWidth: 190,  
27 }, 26 },
  27 + collapsed: true,
28 }; 28 };
29 }; 29 };
30 30
src/pages/Order/constant.ts
@@ -94,6 +94,8 @@ export const SALES_CODE_OPTIONS = [ @@ -94,6 +94,8 @@ export const SALES_CODE_OPTIONS = [
94 { label: 'W-8_Andy', value: 'W-8_Andy' }, 94 { label: 'W-8_Andy', value: 'W-8_Andy' },
95 { label: 'CQ_Peter', value: 'CQ_Peter' }, 95 { label: 'CQ_Peter', value: 'CQ_Peter' },
96 { label: 'MA_A_Mao', value: 'MA_A_Mao' }, 96 { label: 'MA_A_Mao', value: 'MA_A_Mao' },
  97 + { label: 'CQ-2', value: 'CQ-2' },
  98 + { label: 'JJ', value: 'JJ' },
97 ]; 99 ];
98 100
99 export const MAIN_ORDER_COLUMNS = [ 101 export const MAIN_ORDER_COLUMNS = [
src/pages/Order/index.tsx
@@ -51,6 +51,7 @@ import { @@ -51,6 +51,7 @@ import {
51 PAYMENT_CHANNEL_OPTIONS, 51 PAYMENT_CHANNEL_OPTIONS,
52 PAYMENT_METHOD_OPTIONS, 52 PAYMENT_METHOD_OPTIONS,
53 PRODUCT_BELONG_DEPARTMENT_OPTIONS, 53 PRODUCT_BELONG_DEPARTMENT_OPTIONS,
  54 + TAGS_COLOR,
54 } from './constant'; 55 } from './constant';
55 import './index.less'; 56 import './index.less';
56 import { OrderListItemType, OrderType } from './type.d'; 57 import { OrderListItemType, OrderType } from './type.d';
@@ -165,12 +166,24 @@ const OrderPage = () =&gt; { @@ -165,12 +166,24 @@ const OrderPage = () =&gt; {
165 const OrderTableHeader = () => { 166 const OrderTableHeader = () => {
166 return ( 167 return (
167 <Flex className="w-full"> 168 <Flex className="w-full">
168 - <Flex className="w-[24%] ml-[5%]">商品信息</Flex>  
169 - <Flex className="w-[15%]">交易金额</Flex>  
170 - <Flex className="w-[10%]">支付</Flex>  
171 - <Flex className="w-[13%]">其他</Flex>  
172 - <Flex className="w-[10%]">交易状态</Flex>  
173 - <Flex className="w-[23%]">操作</Flex> 169 + <Flex className="w-[29%] ml-[4%]">
  170 + <span className="font-medium">商品信息</span>
  171 + </Flex>
  172 + <Flex className="w-[16%]">
  173 + <span className="font-medium">交易金额</span>
  174 + </Flex>
  175 + <Flex className="w-[10%]">
  176 + <span className="font-medium">支付</span>
  177 + </Flex>
  178 + <Flex className="w-[14%]">
  179 + <span className="font-medium">其他</span>
  180 + </Flex>
  181 + <Flex className="w-[10%]">
  182 + <span className="font-medium">交易状态</span>
  183 + </Flex>
  184 + <Flex className="w-[17%]">
  185 + <span className="font-medium">操作</span>
  186 + </Flex>
174 </Flex> 187 </Flex>
175 ); 188 );
176 }; 189 };
@@ -178,9 +191,11 @@ const OrderPage = () =&gt; { @@ -178,9 +191,11 @@ const OrderPage = () =&gt; {
178 const SubOderRander = ({ record, optRecord }) => { 191 const SubOderRander = ({ record, optRecord }) => {
179 return ( 192 return (
180 <Flex className="w-full border-b-indigo-500"> 193 <Flex className="w-full border-b-indigo-500">
181 - <Flex vertical className="w-[26%]" gap="small"> 194 + <Flex vertical className="w-[31%]" gap="small">
182 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 195 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
183 - {optRecord.productName} 196 + <span className="text-black font-medium ">
  197 + {optRecord.productName}
  198 + </span>
184 </div> 199 </div>
185 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 200 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
186 <span className="text-gray-500">参数:{optRecord.parameters}</span> 201 <span className="text-gray-500">参数:{optRecord.parameters}</span>
@@ -200,48 +215,64 @@ const OrderPage = () =&gt; { @@ -200,48 +215,64 @@ const OrderPage = () =&gt; {
200 </Flex> 215 </Flex>
201 <Flex className="w-[16%]" vertical gap="small"> 216 <Flex className="w-[16%]" vertical gap="small">
202 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 217 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
203 - <span className="text-gray-500">单价:</span>¥  
204 - {optRecord.productPrice} 218 + <span className="text-gray-500">单价:</span>
  219 + <span className="text-slate-700">¥{optRecord.productPrice}</span>
205 </div> 220 </div>
206 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 221 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
207 - <span className="text-gray-500">数量:</span>x{optRecord.quantity} 222 + <span className="text-gray-500">数量:</span>
  223 + <span className="text-slate-700">x{optRecord.quantity}</span>
208 </div> 224 </div>
209 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 225 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
210 - <span className="text-gray-500">合计:</span>¥  
211 - {optRecord.subOrderPayment} 226 + <span className="text-gray-500">合计:</span>
  227 + <span className="text-slate-700">
  228 + ¥{optRecord.subOrderPayment}
  229 + </span>
212 </div> 230 </div>
213 </Flex> 231 </Flex>
214 <Flex className="w-[10%]" vertical gap="small"> 232 <Flex className="w-[10%]" vertical gap="small">
215 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 233 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
216 - {enumValueToLabel(optRecord.paymentMethod, PAYMENT_METHOD_OPTIONS)} 234 + <span className="text-slate-700">
  235 + {enumValueToLabel(
  236 + optRecord.paymentMethod,
  237 + PAYMENT_METHOD_OPTIONS,
  238 + )}
  239 + </span>
217 </div> 240 </div>
218 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 241 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
219 - {enumValueToLabel(  
220 - optRecord.paymentChannel,  
221 - PAYMENT_CHANNEL_OPTIONS,  
222 - )} 242 + <span className="text-slate-700">
  243 + {enumValueToLabel(
  244 + optRecord.paymentChannel,
  245 + PAYMENT_CHANNEL_OPTIONS,
  246 + )}
  247 + </span>
223 </div> 248 </div>
224 </Flex> 249 </Flex>
225 <Flex className="w-[15%]" vertical gap="small"> 250 <Flex className="w-[15%]" vertical gap="small">
226 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 251 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
227 - {enumValueToLabel(  
228 - optRecord.productBelongBusiness,  
229 - PRODUCT_BELONG_DEPARTMENT_OPTIONS,  
230 - )} 252 + <span className="text-slate-700">
  253 + {enumValueToLabel(
  254 + optRecord.productBelongBusiness,
  255 + PRODUCT_BELONG_DEPARTMENT_OPTIONS,
  256 + )}
  257 + </span>
231 </div> 258 </div>
232 </Flex> 259 </Flex>
233 <Flex className="w-[10%]" vertical gap="small"> 260 <Flex className="w-[10%]" vertical gap="small">
234 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 261 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
235 - {enumValueToLabel(  
236 - optRecord.invoicingStatus,  
237 - INVOCING_STATUS_OPTIONS,  
238 - )} 262 + <Tag color={TAGS_COLOR.get(optRecord.invoicingStatus)}>
  263 + {enumValueToLabel(
  264 + optRecord.invoicingStatus,
  265 + INVOCING_STATUS_OPTIONS,
  266 + )}
  267 + </Tag>
239 </div> 268 </div>
240 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> 269 <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis">
241 - {enumValueToLabel(optRecord.orderStatus, ORDER_STATUS_OPTIONS)} 270 + <Tag color={TAGS_COLOR.get(optRecord.orderStatus)}>
  271 + {enumValueToLabel(optRecord.orderStatus, ORDER_STATUS_OPTIONS)}
  272 + </Tag>
242 </div> 273 </div>
243 </Flex> 274 </Flex>
244 - <Flex className="w-[23%]" wrap="wrap" gap="small"> 275 + <Flex className="w-[18%]" wrap="wrap" gap="small">
245 {optRecord.subPath.includes('sendProduct') ? ( 276 {optRecord.subPath.includes('sendProduct') ? (
246 <Button 277 <Button
247 className="p-0" 278 className="p-0"
@@ -444,6 +475,7 @@ const OrderPage = () =&gt; { @@ -444,6 +475,7 @@ const OrderPage = () =&gt; {
444 options={false} 475 options={false}
445 dataSource={subOrders} 476 dataSource={subOrders}
446 pagination={false} 477 pagination={false}
  478 + tableAlertRender={false}
447 /> 479 />
448 ); 480 );
449 }; 481 };
@@ -467,7 +499,7 @@ const OrderPage = () =&gt; { @@ -467,7 +499,7 @@ const OrderPage = () =&gt; {
467 <Space split={<Divider type="vertical" />}> 499 <Space split={<Divider type="vertical" />}>
468 <div> 500 <div>
469 <span className="text-gray-500">订单号:</span> 501 <span className="text-gray-500">订单号:</span>
470 - <span>{record.id}</span> 502 + <span className="text-slate-700">{record.id}</span>
471 </div> 503 </div>
472 <span>{formatDateTime(record.createTime)}</span> 504 <span>{formatDateTime(record.createTime)}</span>
473 </Space> 505 </Space>
@@ -475,15 +507,17 @@ const OrderPage = () =&gt; { @@ -475,15 +507,17 @@ const OrderPage = () =&gt; {
475 <Space split={<Divider type="vertical" />}> 507 <Space split={<Divider type="vertical" />}>
476 <div> 508 <div>
477 <span className="text-gray-500">代表:</span> 509 <span className="text-gray-500">代表:</span>
478 - {record.salesCode} 510 + <span className="text-slate-700">{record.salesCode}</span>
479 </div> 511 </div>
480 <span> 512 <span>
481 <span className="text-gray-500">单位:</span> 513 <span className="text-gray-500">单位:</span>
482 - {record.institution} 514 + <span className="text-slate-700">{record.institution}</span>
483 </span> 515 </span>
484 <span> 516 <span>
485 <span className="text-gray-500">联系人:</span> 517 <span className="text-gray-500">联系人:</span>
486 - {record.institutionContactName} 518 + <span className="text-slate-700">
  519 + {record.institutionContactName}
  520 + </span>
487 </span> 521 </span>
488 </Space> 522 </Space>
489 </Flex> 523 </Flex>
@@ -509,8 +543,10 @@ const OrderPage = () =&gt; { @@ -509,8 +543,10 @@ const OrderPage = () =&gt; {
509 <Flex justify="flex-end"> 543 <Flex justify="flex-end">
510 <Flex wrap="wrap" gap="middle" align="center"> 544 <Flex wrap="wrap" gap="middle" align="center">
511 <div> 545 <div>
512 - <span>总金额:</span>  
513 - <span className="text-lg">{record.totalPayment}¥</span> 546 + <span className="text-gray-500">总金额:¥</span>
  547 + <span className="text-lg font-medium">
  548 + {record.totalPayment}
  549 + </span>
514 </div> 550 </div>
515 {rolePath?.includes('addOrder') ? ( 551 {rolePath?.includes('addOrder') ? (
516 <CopyTwoTone 552 <CopyTwoTone