Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linweijiong
jinfa-platform
Commits
3de74a52
Commit
3de74a52
authored
Nov 15, 2021
by
前端-黄佳鑫
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'v2' of
http://10.0.0.22:3000/lingxi/lingxi-business-paltform
into v2
parents
11b8868a
7035053e
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
58 additions
and
123 deletions
+58
-123
index.tsx
...ges/afterService/components/ExchangeDeliverInfo/index.tsx
+2
-7
index.tsx
...es/afterService/components/ExchangeReceivedInfo/index.tsx
+2
-7
index.tsx
src/pages/afterService/components/ReturnAnalysis/index.tsx
+2
-7
useBusinessEffects.ts
...components/ReturnInfoDrawer/effects/useBusinessEffects.ts
+2
-10
index.tsx
src/pages/afterService/components/ReturnInfoDrawer/index.tsx
+2
-10
index.tsx
...rvice/exchangeApplication/components/DetailInfo/index.tsx
+2
-7
index.tsx
...cation/exchangePrSubmit/components/ExchangeForm/index.tsx
+2
-9
index.ts
.../exchangePrSubmit/components/ExchangeForm/schema/index.ts
+2
-7
index.tsx
...terService/exchangeManage/components/DetailInfo/index.tsx
+2
-7
index.tsx
...Service/repairApplication/components/DetailInfo/index.tsx
+2
-7
index.tsx
...pplication/repairPrSubmit/components/RepairForm/index.tsx
+2
-5
index.ts
...tion/repairPrSubmit/components/RepairForm/schema/index.ts
+2
-7
index.tsx
...afterService/repairManage/components/DetailInfo/index.tsx
+2
-7
index.tsx
...Service/returnApplication/components/DetailInfo/index.tsx
+2
-7
index.tsx
...pplication/returnPrSubmit/components/ReturnForm/index.tsx
+2
-5
index.ts
...tion/returnPrSubmit/components/ReturnForm/schema/index.ts
+2
-7
index.tsx
...afterService/returnManage/components/DetailInfo/index.tsx
+2
-7
utils.ts
src/pages/afterService/utils.ts
+24
-0
No files found.
src/pages/afterService/components/ExchangeDeliverInfo/index.tsx
View file @
3de74a52
...
...
@@ -28,8 +28,6 @@ import {
EXCHANGE_INNER_STATUS_UNCONFIRMED_REPLACE_RECEIPT
,
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
}
from
'@/constants/order'
;
import
{
...
...
@@ -37,6 +35,7 @@ import {
MAIL_INNER_STATUS_CONFIRMED_RECEIVING
,
MAIL_INNER_STATUS_CONFIRMED_DELIVER
,
}
from
'../../constants'
;
import
{
isMaterialOrder
}
from
'../../utils'
;
import
ReturnDeliverDrawer
,
{
AfterType
}
from
'../DeliverDrawer'
;
import
styles
from
'./index.less'
;
...
...
@@ -125,11 +124,7 @@ const ExchangeDeliverInfo: React.FC<ExchangeDeliverInfoProps> = ({
const
[
submitLoading
,
setSubmitLoading
]
=
useState
(
false
);
const
[
currentDetailed
,
setCurrentDetailed
]
=
useState
<
Detailed
|
null
>
(
null
);
const
isMateriel
=
(
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderType
);
const
commonColumns
:
EditableColumns
[]
=
[
...(
...
...
src/pages/afterService/components/ExchangeReceivedInfo/index.tsx
View file @
3de74a52
...
...
@@ -30,8 +30,6 @@ import {
EXCHANGE_INNER_STATUS_UNCONFIRMED_RETURN_RECEIPT
,
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
}
from
'@/constants/order'
;
import
{
...
...
@@ -39,6 +37,7 @@ import {
MAIL_INNER_STATUS_CONFIRMED_DELIVER
,
MAIL_INNER_STATUS_CONFIRMED_RECEIVING
,
}
from
'../../constants'
;
import
{
isMaterialOrder
}
from
'../../utils'
;
import
ReturnDeliverDrawer
,
{
AfterType
}
from
'../DeliverDrawer'
;
import
styles
from
'./index.less'
;
...
...
@@ -127,11 +126,7 @@ const ExchangeReceivedInfo: React.FC<ExchangeReceivedInfoProps> = ({
const
[
submitLoading
,
setSubmitLoading
]
=
useState
(
false
);
const
[
currentDetailed
,
setCurrentDetailed
]
=
useState
<
Detailed
|
null
>
(
null
);
const
isMateriel
=
(
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderType
);
const
commonColumns
:
EditableColumns
[]
=
[
...(
...
...
src/pages/afterService/components/ReturnAnalysis/index.tsx
View file @
3de74a52
...
...
@@ -30,8 +30,6 @@ import {
RETURN_INNER_STATUS_UNCONFIRMED_RETURN_RECEIPT
,
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
}
from
'@/constants/order'
;
import
{
...
...
@@ -39,6 +37,7 @@ import {
MAIL_INNER_STATUS_CONFIRMED_DELIVER
,
MAIL_INNER_STATUS_CONFIRMED_RECEIVING
,
}
from
'../../constants'
;
import
{
isMaterialOrder
}
from
'../../utils'
;
import
ReturnDeliverDrawer
,
{
AfterType
}
from
'../DeliverDrawer'
;
import
styles
from
'./index.less'
;
...
...
@@ -127,11 +126,7 @@ const ReturnInfo: React.FC<ReturnInfoProps> = ({
const
[
submitLoading
,
setSubmitLoading
]
=
useState
(
false
);
const
[
currentDetailed
,
setCurrentDetailed
]
=
useState
<
Detailed
|
null
>
(
null
);
const
isMateriel
=
(
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderType
);
const
commonColumns
:
EditableColumns
[]
=
[
...(
...
...
src/pages/afterService/components/ReturnInfoDrawer/effects/useBusinessEffects.ts
View file @
3de74a52
...
...
@@ -7,11 +7,7 @@
*/
import
BigNumber
from
'bignumber.js'
;
import
{
FormEffectHooks
}
from
'@formily/antd'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
}
from
'@/constants/order'
;
import
{
isMaterialOrder
}
from
'../../../utils'
;
const
{
onFieldInputChange$
,
...
...
@@ -39,11 +35,7 @@ export const useBusinessEffects = (context, actions) => {
const
orderTypeValue
=
await
getFieldValue
(
'orderType'
);
const
payListValue
=
await
getFieldValue
(
'payList'
)
||
[];
const
isMateriel
=
(
orderTypeValue
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderTypeValue
);
if
(
!
isMateriel
)
{
const
newData
=
[...
payListValue
].
map
(
item
=>
{
...
...
src/pages/afterService/components/ReturnInfoDrawer/index.tsx
View file @
3de74a52
...
...
@@ -11,14 +11,10 @@ import NiceForm from '@/components/NiceForm';
import
{
createAsyncFormActions
,
FormEffectHooks
}
from
'@formily/antd'
;
import
BigNumber
from
'bignumber.js'
;
import
{
PublicApi
}
from
'@/services/api'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
}
from
'@/constants/order'
;
import
schema
from
'./schema'
;
import
{
createEffects
}
from
'./effects'
;
import
Stamp
from
'../Stamp'
;
import
{
isMaterialOrder
}
from
'../../utils'
;
import
SteamerTicket
from
'./components/SteamerTicket'
;
const
schemaAction
=
createAsyncFormActions
();
...
...
@@ -186,11 +182,7 @@ const ReturnInfoDrawer: React.FC<ReturnInfoDrawerProps> = ({
if
(
!
applyInfo
||
!
applyInfo
.
orderId
)
{
return
;
}
const
isMateriel
=
(
applyInfo
.
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
applyInfo
.
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
applyInfo
.
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
applyInfo
.
orderType
);
if
(
isMateriel
)
{
schemaAction
.
setFieldState
(
'productName'
,
state
=>
{
state
.
title
=
'物料名称'
;
...
...
src/pages/afterService/exchangeApplication/components/DetailInfo/index.tsx
View file @
3de74a52
...
...
@@ -21,8 +21,6 @@ import {
ORDER_TYPE2_CHANNEL_POINTS
,
}
from
'@/constants/order'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE
,
}
from
'@/constants/order'
;
...
...
@@ -36,6 +34,7 @@ import {
EXCHANGE_OUTER_STATUS_TAG_MAP
,
EXCHANGE_INNER_STATUS_BADGE_MAP
,
}
from
'../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../utils'
;
const
ProductList
=
React
.
lazy
(()
=>
import
(
'../../../components/ProductList'
));
const
ExchangeReceivedInfo
=
React
.
lazy
(()
=>
import
(
'../../../components/ExchangeReceivedInfo'
));
...
...
@@ -90,11 +89,7 @@ const DetailInfo: React.FC<DetailInfoProps> = ({
const
[
infoLoading
,
setInfoloading
]
=
useState
(
false
);
const
isPointsOrder
=
detailInfo
?.
orderType
===
ORDER_TYPE2_POINTS
||
detailInfo
?.
orderType
===
ORDER_TYPE2_CHANNEL_POINTS
;
const
isMateriel
=
(
detailInfo
?.
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
detailInfo
?.
orderType
);
const
productColumns
:
EditableColumns
[]
=
[
{
...
...
src/pages/afterService/exchangeApplication/exchangePrSubmit/components/ExchangeForm/index.tsx
View file @
3de74a52
...
...
@@ -12,10 +12,6 @@ import { PublicApi } from '@/services/api';
import
{
GetAsReplaceGoodsPageReturnedGoodsResponseDetail
}
from
'@/services/AfterServiceV2Api'
;
import
{
normalizeFiledata
,
FileData
}
from
'@/utils'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE2
,
ORDER_TYPE2_POINTS
,
ORDER_TYPE2_CHANNEL_POINTS
,
}
from
'@/constants/order'
;
...
...
@@ -31,6 +27,7 @@ import {
EXCHANGE_OUTER_STATUS_TAG_MAP
,
EXCHANGE_INNER_STATUS_BADGE_MAP
,
}
from
'../../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../../utils'
;
const
addSchemaAction
=
createFormActions
();
const
{
...
...
@@ -194,11 +191,7 @@ const ExchangeForm: React.FC<BillsFormProps> = ({
const
[
orderTypeValue
,
setOrderTypeValue
]
=
useState
(
0
);
const
isPointsOrder
=
orderTypeValue
===
ORDER_TYPE2_POINTS
||
orderTypeValue
===
ORDER_TYPE2_CHANNEL_POINTS
;
const
isMateriel
=
(
orderTypeValue
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderTypeValue
);
const
tableColumn
:
ColumnType
<
any
>
[]
=
[
{
...
...
src/pages/afterService/exchangeApplication/exchangePrSubmit/components/ExchangeForm/schema/index.ts
View file @
3de74a52
...
...
@@ -11,12 +11,11 @@ import {
DELIVERY_TYPE_ENUM
,
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE2_POINTS
,
ORDER_TYPE2_CHANNEL_POINTS
,
}
from
'@/constants/order'
;
import
{
isMaterialOrder
}
from
'../../../../../utils'
;
// 供应会员列表列
const
supplierColumns
=
[
...
...
@@ -88,11 +87,7 @@ const orderTypeArr = GlobalConfig.web.orderType.map((item) => ({
export
const
addSchema
=
(
orderType
:
number
):
ISchema
=>
{
const
isPoints
=
orderType
===
ORDER_TYPE2_POINTS
||
orderType
===
ORDER_TYPE2_CHANNEL_POINTS
;
const
isMateriel
=
(
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderType
);
return
{
type
:
'object'
,
properties
:
{
...
...
src/pages/afterService/exchangeManage/components/DetailInfo/index.tsx
View file @
3de74a52
...
...
@@ -19,8 +19,6 @@ import {
EXCHANGE_INNER_STATUS_UNCOMMITTED
,
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE2_POINTS
,
ORDER_TYPE2_CHANNEL_POINTS
,
...
...
@@ -38,6 +36,7 @@ import {
EXCHANGE_OUTER_STATUS_TAG_MAP
,
EXCHANGE_INNER_STATUS_BADGE_MAP
,
}
from
'../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../utils'
;
const
ProductList
=
React
.
lazy
(()
=>
import
(
'../../../components/ProductList'
));
const
ExchangeReceivedInfo
=
React
.
lazy
(()
=>
import
(
'../../../components/ExchangeReceivedInfo'
));
...
...
@@ -99,11 +98,7 @@ const DetailInfo: React.FC<DetailInfoProps> = ({
const
[
returnAddress
,
setReturnAddress
]
=
useState
<
ReturnAddressValues
>
(
null
);
const
isPointsOrder
=
detailInfo
?.
orderType
===
ORDER_TYPE2_POINTS
||
detailInfo
?.
orderType
===
ORDER_TYPE2_CHANNEL_POINTS
;
const
isMateriel
=
(
detailInfo
?.
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
detailInfo
?.
orderType
);
// 获取换货申请详情
const
getDetailInfo
=
()
=>
{
...
...
src/pages/afterService/repairApplication/components/DetailInfo/index.tsx
View file @
3de74a52
...
...
@@ -13,8 +13,6 @@ import StatusTag from '@/components/StatusTag';
import
{
EditableColumns
}
from
'@/components/PolymericTable/interface'
;
import
{
REPAIR_OUTER_STATUS_FINISHED
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE
,
}
from
'@/constants/order'
;
...
...
@@ -22,6 +20,7 @@ import {
REPAIR_OUTER_STATUS_TAG_MAP
,
REPAIR_INNER_STATUS_BADGE_MAP
,
}
from
'../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../utils'
;
const
OuterCirculation
=
React
.
lazy
(()
=>
import
(
'../../../components/OuterCirculation'
));
const
ProductList
=
React
.
lazy
(()
=>
import
(
'../../../components/ProductList'
));
...
...
@@ -64,11 +63,7 @@ const DetailInfo: React.FC<DetailInfoProps> = ({
const
[
infoLoading
,
setInfoLoading
]
=
useState
(
false
);
const
[
repairGoodsLoading
,
setRepairGoodsLoading
]
=
useState
(
false
);
const
isMateriel
=
(
detailInfo
?.
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
detailInfo
?.
orderType
);
const
productColumns
:
EditableColumns
[]
=
[
{
...
...
src/pages/afterService/repairApplication/repairPrSubmit/components/RepairForm/index.tsx
View file @
3de74a52
...
...
@@ -30,6 +30,7 @@ import {
REPAIR_OUTER_STATUS_TAG_MAP
,
REPAIR_INNER_STATUS_BADGE_MAP
,
}
from
'../../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../../utils'
;
const
addSchemaAction
=
createFormActions
();
const
{
...
...
@@ -123,11 +124,7 @@ const RepairForm: React.FC<BillsFormProps> = ({
const
[
visibleDrawer
,
setVisibleDrawer
]
=
useState
(
false
);
const
[
orderTypeValue
,
setOrderTypeValue
]
=
useState
(
0
);
const
isMateriel
=
(
orderTypeValue
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderTypeValue
);
const
tableColumn
:
ColumnType
<
any
>
[]
=
[
{
...
...
src/pages/afterService/repairApplication/repairPrSubmit/components/RepairForm/schema/index.ts
View file @
3de74a52
...
...
@@ -6,12 +6,11 @@ import { UPLOAD_TYPE } from '@/constants';
import
{
PublicApi
}
from
'@/services/api'
;
import
{
GlobalConfig
}
from
'@/global/config'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE_POINTS
,
ORDER_TYPE_CHANNEL_POINTS
,
}
from
'@/constants/order'
;
import
{
isMaterialOrder
}
from
'../../../../../utils'
;
// 供应会员列表列
const
supplierColumns
=
[
...
...
@@ -82,11 +81,7 @@ const orderTypeArr = GlobalConfig.web.orderType.map((item) => ({
})).
filter
((
item
)
=>
(
item
.
value
!==
ORDER_TYPE_POINTS
&&
item
.
value
!==
ORDER_TYPE_CHANNEL_POINTS
));
export
const
addSchema
=
(
orderType
:
number
):
ISchema
=>
{
const
isMateriel
=
(
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderType
);
return
{
type
:
'object'
,
properties
:
{
...
...
src/pages/afterService/repairManage/components/DetailInfo/index.tsx
View file @
3de74a52
...
...
@@ -14,8 +14,6 @@ import AuditProcess from '@/components/AuditProcess';
import
{
EditableColumns
}
from
'@/components/PolymericTable/interface'
;
import
{
REPAIR_OUTER_STATUS_FINISHED
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE
,
}
from
'@/constants/order'
;
...
...
@@ -23,6 +21,7 @@ import {
REPAIR_OUTER_STATUS_TAG_MAP
,
REPAIR_INNER_STATUS_BADGE_MAP
,
}
from
'../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../utils'
;
const
ProductList
=
React
.
lazy
(()
=>
import
(
'../../../components/ProductList'
));
const
FileList
=
React
.
lazy
(()
=>
import
(
'../../../components/FileList'
));
...
...
@@ -65,11 +64,7 @@ const DetailInfo: React.FC<DetailInfoProps> = ({
const
[
infoLoading
,
setInfoLoading
]
=
useState
(
false
);
const
[
repairGoodsLoading
,
setRepairGoodsLoading
]
=
useState
(
false
);
const
isMateriel
=
(
detailInfo
?.
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
detailInfo
?.
orderType
);
const
productColumns
:
EditableColumns
[]
=
[
{
...
...
src/pages/afterService/returnApplication/components/DetailInfo/index.tsx
View file @
3de74a52
...
...
@@ -23,8 +23,6 @@ import {
RETURN_INNER_STATUS_UNCOMMITTED
,
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE
,
}
from
'@/constants/order'
;
...
...
@@ -40,6 +38,7 @@ import {
RETURN_OUTER_STATUS_TAG_MAP
,
RETURN_INNER_STATUS_BADGE_MAP
,
}
from
'../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../utils'
;
const
ProductList
=
React
.
lazy
(()
=>
import
(
'../../../components/ProductList'
));
const
ReturnAnalysis
=
React
.
lazy
(()
=>
import
(
'../../../components/ReturnAnalysis'
));
...
...
@@ -124,11 +123,7 @@ const DetailInfo: React.FC<DetailInfoProps> = ({
setVisibleReturnInfo
(
true
);
};
const
isMateriel
=
(
detailInfo
?.
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
detailInfo
?.
orderType
);
const
productColumns
:
EditableColumns
[]
=
[
{
...
...
src/pages/afterService/returnApplication/returnPrSubmit/components/ReturnForm/index.tsx
View file @
3de74a52
...
...
@@ -29,6 +29,7 @@ import {
RETURN_OUTER_STATUS_TAG_MAP
,
RETURN_INNER_STATUS_BADGE_MAP
,
}
from
'../../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../../utils'
;
const
addSchemaAction
=
createFormActions
();
const
{
...
...
@@ -197,11 +198,7 @@ const ReturnForm: React.FC<BillsFormProps> = ({
const
[
goodsValue
,
setGoodsValue
]
=
useState
([]);
const
[
orderTypeValue
,
setOrderTypeValue
]
=
useState
(
0
);
const
isMateriel
=
(
orderTypeValue
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderTypeValue
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderTypeValue
);
const
tableColumn
:
ColumnType
<
any
>
[]
=
[
{
...
...
src/pages/afterService/returnApplication/returnPrSubmit/components/ReturnForm/schema/index.ts
View file @
3de74a52
...
...
@@ -7,12 +7,11 @@ import { DELIVERY_TYPE_ENUM } from '@/constants/afterService';
import
{
PublicApi
}
from
'@/services/api'
;
import
{
GlobalConfig
}
from
'@/global/config'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE_POINTS
,
ORDER_TYPE_CHANNEL_POINTS
,
}
from
'@/constants/order'
;
import
{
isMaterialOrder
}
from
'../../../../../utils'
;
// 供应会员列表列
const
supplierColumns
=
[
...
...
@@ -87,11 +86,7 @@ const orderTypeArr = GlobalConfig.web.orderType.map((item) => ({
})).
filter
((
item
)
=>
(
item
.
value
!==
ORDER_TYPE_POINTS
&&
item
.
value
!==
ORDER_TYPE_CHANNEL_POINTS
));
export
const
addSchema
=
(
orderType
:
number
):
ISchema
=>
{
const
isMateriel
=
(
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
orderType
);
return
{
type
:
'object'
,
properties
:
{
...
...
src/pages/afterService/returnManage/components/DetailInfo/index.tsx
View file @
3de74a52
...
...
@@ -25,8 +25,6 @@ import {
RETURN_INNER_STATUS_UNCOMMITTED
,
}
from
'@/constants/afterService'
;
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE
,
}
from
'@/constants/order'
;
...
...
@@ -43,6 +41,7 @@ import {
RETURN_OUTER_STATUS_TAG_MAP
,
RETURN_INNER_STATUS_BADGE_MAP
,
}
from
'../../../constants'
;
import
{
isMaterialOrder
}
from
'../../../utils'
;
const
ProductList
=
React
.
lazy
(()
=>
import
(
'../../../components/ProductList'
));
const
ReturnAnalysis
=
React
.
lazy
(()
=>
import
(
'../../../components/ReturnAnalysis'
));
...
...
@@ -150,11 +149,7 @@ const DetailInfo: React.FC<DetailInfoProps> = ({
});
};
const
isMateriel
=
(
detailInfo
?.
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
detailInfo
?.
orderType
===
ORDER_TYPE_TENDER_CONTRACT
);
const
isMateriel
=
isMaterialOrder
(
detailInfo
?.
orderType
);
const
productColumns
:
EditableColumns
[]
=
[
{
...
...
src/pages/afterService/utils.ts
0 → 100644
View file @
3de74a52
/*
* @Author: XieZhiXiong
* @Date: 2021-11-15 10:20:22
* @LastEditors: XieZhiXiong
* @LastEditTime: 2021-11-15 10:25:34
* @Description: 售后服务相关工具函数
*/
import
{
ORDER_TYPE_INQUIRY_CONTRACT
,
ORDER_TYPE_BIDDING_CONTRACT
,
ORDER_TYPE_TENDER_CONTRACT
,
ORDER_TYPE_REQUISITION
,
}
from
'@/constants/order'
;
// 是否是采购订单
export
const
isMaterialOrder
=
(
orderType
:
number
)
=>
{
return
(
orderType
===
ORDER_TYPE_INQUIRY_CONTRACT
||
orderType
===
ORDER_TYPE_BIDDING_CONTRACT
||
orderType
===
ORDER_TYPE_TENDER_CONTRACT
||
orderType
===
ORDER_TYPE_REQUISITION
)
};
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment