refactor(Order/List): 更新退款相关状态标签为更简洁的表达 #26
|
|
@ -14,3 +14,5 @@
|
|||
/package-lock.json
|
||||
/yarn.lock
|
||||
*.yaml
|
||||
#
|
||||
/docs
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ const isDev = process.env.NODE_ENV === 'development';
|
|||
const UMI_APP_API_URL = isDev
|
||||
? 'http://localhost:7001'
|
||||
: 'https://api.yoone.ca';
|
||||
import { codeInspectorPlugin } from 'code-inspector-plugin';
|
||||
|
||||
export default defineConfig({
|
||||
hash: true,
|
||||
|
|
@ -18,6 +19,13 @@ export default defineConfig({
|
|||
define: {
|
||||
UMI_APP_API_URL,
|
||||
},
|
||||
chainWebpack(config) {
|
||||
config.plugin('code-inspector-plugin').use(
|
||||
codeInspectorPlugin({
|
||||
bundler: 'webpack',
|
||||
})
|
||||
);
|
||||
},
|
||||
routes: [
|
||||
{ path: '/', redirect: '/home' },
|
||||
{ name: '追踪', path: '/track', component: './Track', layout: false },
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@
|
|||
"devDependencies": {
|
||||
"@types/react": "^18.0.33",
|
||||
"@types/react-dom": "^18.0.11",
|
||||
"code-inspector-plugin": "^1.2.10",
|
||||
"husky": "^9",
|
||||
"lint-staged": "^13.2.0",
|
||||
"prettier": "^2.8.7",
|
||||
|
|
|
|||
|
|
@ -128,12 +128,15 @@ const ListPage: React.FC = () => {
|
|||
label: '已申请退款',
|
||||
},
|
||||
{
|
||||
|
||||
key: 'refund_approved',
|
||||
label: '退款申请已通过',
|
||||
label: "已退款",
|
||||
// label: '退款申请已通过',
|
||||
},
|
||||
{
|
||||
key: 'refund_cancelled',
|
||||
label: '已取消退款',
|
||||
label: "已完成"
|
||||
// label: '已取消退款',
|
||||
},
|
||||
// {
|
||||
// key: 'pending_refund',
|
||||
|
|
@ -771,7 +774,8 @@ const Detail: React.FC<{
|
|||
<ProDescriptions.Item label="金额" dataIndex="total" />
|
||||
<ProDescriptions.Item label="客户邮箱" dataIndex="customer_email" />
|
||||
<ProDescriptions.Item label="联系电话" span={3}
|
||||
render={(_, record) => { return (
|
||||
render={(_, record) => {
|
||||
return (
|
||||
<div>
|
||||
<span>
|
||||
{record?.shipping?.phone || record?.billing?.phone || '-'}
|
||||
|
|
@ -1997,9 +2001,8 @@ const SalesChange: React.FC<{
|
|||
return { ...data};
|
||||
}}
|
||||
onFinish={async (formData: any) => {
|
||||
const { sales,items } = formData;
|
||||
const data ={sales,items }
|
||||
const res = await ordercontrollerUpdateorderitems({orderId:id}, data);
|
||||
const { sales } = formData;
|
||||
const res = await ordercontrollerUpdateorderitems({ orderId: id }, sales);
|
||||
if (!res.success) {
|
||||
message.error(`更新货物信息失败: ${res.message}`);
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Reference in New Issue