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
shenshaokai
jinfa-platform
Commits
0a61b3f2
Commit
0a61b3f2
authored
Apr 20, 2022
by
wzy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 进销存新建仓库ui修改
parent
6c7e448d
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
136 additions
and
117 deletions
+136
-117
columns.ts
...on/stockSellStorage/bills/components/BillsForm/columns.ts
+28
-28
index.tsx
...ion/stockSellStorage/bills/components/BillsForm/index.tsx
+9
-9
index.ts
...ockSellStorage/bills/components/BillsForm/schema/index.ts
+0
-0
index.tsx
src/pages/transaction/stockSellStorage/bills/index.tsx
+7
-7
index.tsx
src/pages/transaction/stockSellStorage/billsType/index.tsx
+6
-6
index.tsx
src/pages/transaction/stockSellStorage/inventory/index.tsx
+12
-12
index.tsx
...kSellStorage/warehouse/components/WarehouseForm/index.tsx
+67
-48
index.ts
...torage/warehouse/components/WarehouseForm/schema/index.ts
+0
-0
index.tsx
src/pages/transaction/stockSellStorage/warehouse/index.tsx
+7
-7
No files found.
src/pages/transaction/stockSellStorage/bills/components/BillsForm/columns.ts
View file @
0a61b3f2
...
@@ -18,33 +18,33 @@ const intl = getIntl();
...
@@ -18,33 +18,33 @@ const intl = getIntl();
export
const
purchaseOrderColumns
:
any
[]
=
[
export
const
purchaseOrderColumns
:
any
[]
=
[
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanhao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanhao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'orderNo'
,
dataIndex
:
'orderNo'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhaiyao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhaiyao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'orderThe'
,
dataIndex
:
'orderThe'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huiyuanmingcheng'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huiyuanmingcheng'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'supplyMembersName'
,
dataIndex
:
'supplyMembersName'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.xiadanshijian'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.xiadanshijian'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'createTime'
,
dataIndex
:
'createTime'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanleixing'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanleixing'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'type'
,
dataIndex
:
'type'
,
render
:
text
=>
ORDER_TYPE2
[
text
],
render
:
text
=>
ORDER_TYPE2
[
text
],
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhuangtai'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'interiorState'
,
dataIndex
:
'interiorState'
,
render
:
text
=>
PurchaseOrderInsideWorkStateTexts
[
text
],
render
:
text
=>
PurchaseOrderInsideWorkStateTexts
[
text
],
},
},
...
@@ -56,33 +56,33 @@ export const purchaseOrderColumns: any[] = [
...
@@ -56,33 +56,33 @@ export const purchaseOrderColumns: any[] = [
export
const
salesOrderColumns
:
any
[]
=
[
export
const
salesOrderColumns
:
any
[]
=
[
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanhao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanhao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'orderNo'
,
dataIndex
:
'orderNo'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhaiyao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhaiyao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'orderThe'
,
dataIndex
:
'orderThe'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huiyuanmingcheng'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huiyuanmingcheng'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'createMemberName'
,
dataIndex
:
'createMemberName'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.xiadanshijian'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.xiadanshijian'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'createTime'
,
dataIndex
:
'createTime'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanleixing'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanleixing'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'type'
,
dataIndex
:
'type'
,
render
:
text
=>
ORDER_TYPE2
[
text
],
render
:
text
=>
ORDER_TYPE2
[
text
],
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.dingdanzhuangtai'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'interiorState'
,
dataIndex
:
'interiorState'
,
render
:
text
=>
PurchaseOrderInsideWorkStateTexts
[
text
],
render
:
text
=>
PurchaseOrderInsideWorkStateTexts
[
text
],
},
},
...
@@ -94,28 +94,28 @@ export const salesOrderColumns: any[] = [
...
@@ -94,28 +94,28 @@ export const salesOrderColumns: any[] = [
export
const
machiningWarehousingColumns
=
[
export
const
machiningWarehousingColumns
=
[
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanhao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanhao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'noticeNo'
,
dataIndex
:
'noticeNo'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanzhaiyao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanzhaiyao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'summary'
,
dataIndex
:
'summary'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.jiagongqiyemingcheng'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.jiagongqiyemingcheng'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'processName'
,
dataIndex
:
'processName'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjushijian'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjushijian'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'createTime'
,
dataIndex
:
'createTime'
,
render
:
text
=>
moment
(
text
).
format
(
'YYYY-MM-DD HH:mm:ss'
),
render
:
text
=>
moment
(
text
).
format
(
'YYYY-MM-DD HH:mm:ss'
),
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhuangtai'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'outerStatusName'
,
dataIndex
:
'outerStatusName'
,
},
},
];
];
...
@@ -126,28 +126,28 @@ export const machiningWarehousingColumns = [
...
@@ -126,28 +126,28 @@ export const machiningWarehousingColumns = [
export
const
machiningDeliveryColumns
=
[
export
const
machiningDeliveryColumns
=
[
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanhao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanhao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'noticeNo'
,
dataIndex
:
'noticeNo'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanzhaiyao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.tongzhidanzhaiyao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'summary'
,
dataIndex
:
'summary'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.gongyinghuiyuan'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.gongyinghuiyuan'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'supplierName'
,
dataIndex
:
'supplierName'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjushijian'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjushijian'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'createTime'
,
dataIndex
:
'createTime'
,
render
:
text
=>
moment
(
text
).
format
(
'YYYY-MM-DD HH:mm:ss'
),
render
:
text
=>
moment
(
text
).
format
(
'YYYY-MM-DD HH:mm:ss'
),
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhuangtai'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'outerStatusName'
,
dataIndex
:
'outerStatusName'
,
},
},
];
];
...
@@ -159,31 +159,31 @@ export const getAfterSaleColumns = (isPurchaser?: boolean) => {
...
@@ -159,31 +159,31 @@ export const getAfterSaleColumns = (isPurchaser?: boolean) => {
return
[
return
[
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanhao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanhao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'applyNo'
,
dataIndex
:
'applyNo'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhaiyao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhaiyao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'applyAbstract'
,
dataIndex
:
'applyAbstract'
,
},
},
isPurchaser
?
{
isPurchaser
?
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.gongyinghuiyuan'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.gongyinghuiyuan'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'supplierName'
,
dataIndex
:
'supplierName'
,
}
:
{
}
:
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caigouhuiyuan'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caigouhuiyuan'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'consumerName'
,
dataIndex
:
'consumerName'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjushijian'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjushijian'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'applyTime'
,
dataIndex
:
'applyTime'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.shenqingdanzhuangtai'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'outerStatusName'
,
dataIndex
:
'outerStatusName'
,
},
},
];
];
...
...
src/pages/transaction/stockSellStorage/bills/components/BillsForm/index.tsx
View file @
0a61b3f2
...
@@ -85,33 +85,33 @@ const BillsForm: React.FC<BillsFormProps> = ({
...
@@ -85,33 +85,33 @@ const BillsForm: React.FC<BillsFormProps> = ({
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huohao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huohao'
}),
dataIndex
:
'id'
,
dataIndex
:
'id'
,
align
:
'center'
,
//
align: 'center',
render
:
(
_
,
record
)
=>
record
.
code
,
render
:
(
_
,
record
)
=>
record
.
code
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huopinmingcheng'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huopinmingcheng'
}),
dataIndex
:
'name'
,
dataIndex
:
'name'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.materialGroup'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.materialGroup'
}),
dataIndex
:
[
'materialGroup'
,
'name'
],
dataIndex
:
[
'materialGroup'
,
'name'
],
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.guigexinghao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.guigexinghao'
}),
dataIndex
:
'type'
,
dataIndex
:
'type'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinlei'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinlei'
}),
dataIndex
:
[
'customerCategory'
,
'name'
],
dataIndex
:
[
'customerCategory'
,
'name'
],
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinpai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinpai'
}),
dataIndex
:
[
'brand'
,
'name'
],
dataIndex
:
[
'brand'
,
'name'
],
align
:
'center'
,
//
align: 'center',
},
},
];
];
...
@@ -309,7 +309,7 @@ const BillsForm: React.FC<BillsFormProps> = ({
...
@@ -309,7 +309,7 @@ const BillsForm: React.FC<BillsFormProps> = ({
:
[]
:
[]
}
}
/>
/>
<
Card
style=
{
{
margin
:
24
}
}
>
<
div
style=
{
{
margin
:
12
}
}
>
<
NiceForm
<
NiceForm
value=
{
billInfo
}
value=
{
billInfo
}
previewPlaceholder=
" "
previewPlaceholder=
" "
...
@@ -318,7 +318,7 @@ const BillsForm: React.FC<BillsFormProps> = ({
...
@@ -318,7 +318,7 @@ const BillsForm: React.FC<BillsFormProps> = ({
renderListTableRemove
,
renderListTableRemove
,
}
}
}
}
components=
{
{
components=
{
{
RadioGroup
:
Radio
.
Group
,
//
RadioGroup: Radio.Group,
ArrayTable
,
ArrayTable
,
Text
:
EllipsisText
,
Text
:
EllipsisText
,
}
}
}
}
...
@@ -337,7 +337,7 @@ const BillsForm: React.FC<BillsFormProps> = ({
...
@@ -337,7 +337,7 @@ const BillsForm: React.FC<BillsFormProps> = ({
actions=
{
addSchemaAction
}
actions=
{
addSchemaAction
}
schema=
{
addBillSchema
}
schema=
{
addBillSchema
}
/>
/>
</
Card
>
</
div
>
<
ModalTable
<
ModalTable
modalTitle=
{
intl
.
formatMessage
({
modalTitle=
{
intl
.
formatMessage
({
...
...
src/pages/transaction/stockSellStorage/bills/components/BillsForm/schema/index.ts
View file @
0a61b3f2
This diff is collapsed.
Click to expand it.
src/pages/transaction/stockSellStorage/bills/index.tsx
View file @
0a61b3f2
...
@@ -189,7 +189,7 @@ const Bills: React.FC<{}> = () => {
...
@@ -189,7 +189,7 @@ const Bills: React.FC<{}> = () => {
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuhao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuhao'
}),
dataIndex
:
'invoicesNo'
,
dataIndex
:
'invoicesNo'
,
align
:
'center'
,
//
align: 'center',
render
:
(
text
:
any
,
record
:
any
)
=>
(
render
:
(
text
:
any
,
record
:
any
)
=>
(
<
EyePreview
<
EyePreview
type=
{
AuthUrl
(
'bills.see'
)
?
'link'
:
'button'
}
type=
{
AuthUrl
(
'bills.see'
)
?
'link'
:
'button'
}
...
@@ -201,29 +201,29 @@ const Bills: React.FC<{}> = () => {
...
@@ -201,29 +201,29 @@ const Bills: React.FC<{}> = () => {
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuleixing'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuleixing'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'invoicesTypeName'
,
dataIndex
:
'invoicesTypeName'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuzhaiyao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuzhaiyao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'invoicesAbstract'
,
dataIndex
:
'invoicesAbstract'
,
ellipsis
:
true
,
ellipsis
:
true
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.duiyingcangku'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.duiyingcangku'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'warehouseName'
,
dataIndex
:
'warehouseName'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.jiaoyishijian'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.jiaoyishijian'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'invoicesTime'
,
dataIndex
:
'invoicesTime'
,
render
:
text
=>
(
text
?
moment
(
text
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
:
''
),
render
:
text
=>
(
text
?
moment
(
text
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
:
''
),
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuzhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuzhuangtai'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'state'
,
dataIndex
:
'state'
,
filters
:
[
filters
:
[
{
{
...
@@ -244,7 +244,7 @@ const Bills: React.FC<{}> = () => {
...
@@ -244,7 +244,7 @@ const Bills: React.FC<{}> = () => {
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caozuo'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caozuo'
}),
dataIndex
:
'actions'
,
dataIndex
:
'actions'
,
align
:
'center'
,
//
align: 'center',
render
:
(
_
,
record
:
any
)
=>
{
render
:
(
_
,
record
:
any
)
=>
{
return
record
.
source
===
1
?
(
return
record
.
source
===
1
?
(
<>
<>
...
...
src/pages/transaction/stockSellStorage/billsType/index.tsx
View file @
0a61b3f2
...
@@ -29,17 +29,17 @@ const billsType: React.FC<{}> = () => {
...
@@ -29,17 +29,17 @@ const billsType: React.FC<{}> = () => {
{
{
title
:
'ID'
,
title
:
'ID'
,
dataIndex
:
'id'
,
dataIndex
:
'id'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuleixingbianhao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjuleixingbianhao'
}),
dataIndex
:
'number'
,
dataIndex
:
'number'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjumingcheng'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danjumingcheng'
}),
dataIndex
:
'name'
,
dataIndex
:
'name'
,
align
:
'center'
,
//
align: 'center',
render
:
(
text
:
any
,
record
:
any
)
=>
{
render
:
(
text
:
any
,
record
:
any
)
=>
{
return
(
return
(
<
EyePreview
<
EyePreview
...
@@ -54,7 +54,7 @@ const billsType: React.FC<{}> = () => {
...
@@ -54,7 +54,7 @@ const billsType: React.FC<{}> = () => {
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.fangxiang'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.fangxiang'
}),
dataIndex
:
'direction'
,
dataIndex
:
'direction'
,
align
:
'center'
,
//
align: 'center',
render
:
text
=>
{
render
:
text
=>
{
return
<
span
>
{
DOC_DIRECTION
[
text
]
}
</
span
>;
return
<
span
>
{
DOC_DIRECTION
[
text
]
}
</
span
>;
},
},
...
@@ -62,7 +62,7 @@ const billsType: React.FC<{}> = () => {
...
@@ -62,7 +62,7 @@ const billsType: React.FC<{}> = () => {
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.zhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.zhuangtai'
}),
dataIndex
:
'status'
,
dataIndex
:
'status'
,
align
:
'center'
,
//
align: 'center',
sorter
:
(
a
,
b
)
=>
a
.
state
-
b
.
state
,
sorter
:
(
a
,
b
)
=>
a
.
state
-
b
.
state
,
render
:
(
text
:
any
,
record
:
any
)
=>
(
render
:
(
text
:
any
,
record
:
any
)
=>
(
...
@@ -79,7 +79,7 @@ const billsType: React.FC<{}> = () => {
...
@@ -79,7 +79,7 @@ const billsType: React.FC<{}> = () => {
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caozuo'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caozuo'
}),
dataIndex
:
'option'
,
dataIndex
:
'option'
,
align
:
'center'
,
//
align: 'center',
render
:
(
text
:
any
,
record
:
any
)
=>
(
render
:
(
text
:
any
,
record
:
any
)
=>
(
<>
<>
{
record
.
state
===
DOC_TYPE_STATUS_INVALID
&&
(
{
record
.
state
===
DOC_TYPE_STATUS_INVALID
&&
(
...
...
src/pages/transaction/stockSellStorage/inventory/index.tsx
View file @
0a61b3f2
...
@@ -61,60 +61,60 @@ const Inventory: React.FC<{}> = () => {
...
@@ -61,60 +61,60 @@ const Inventory: React.FC<{}> = () => {
const
columns
:
ColumnType
<
any
>
[]
=
[
const
columns
:
ColumnType
<
any
>
[]
=
[
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huohao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huohao'
}),
align
:
'center'
,
//
align: 'center',
dataIndex
:
'goodsNo'
,
dataIndex
:
'goodsNo'
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huopinmingcheng'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.huopinmingcheng'
}),
dataIndex
:
'goodsName'
,
dataIndex
:
'goodsName'
,
align
:
'center'
,
//
align: 'center',
render
:
(
text
:
any
,
record
:
any
)
=>
text
,
render
:
(
text
:
any
,
record
:
any
)
=>
text
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.materialGroup'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.materialGroup'
}),
dataIndex
:
'goodsGroup'
,
dataIndex
:
'goodsGroup'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.guigexinghao'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.guigexinghao'
}),
dataIndex
:
'specifications'
,
dataIndex
:
'specifications'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinlei'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinlei'
}),
dataIndex
:
'category'
,
dataIndex
:
'category'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinpai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.pinpai'
}),
dataIndex
:
'brand'
,
dataIndex
:
'brand'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danwei'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.danwei'
}),
dataIndex
:
'unit'
,
dataIndex
:
'unit'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.chengbenjia'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.chengbenjia'
}),
dataIndex
:
'costPrice'
,
dataIndex
:
'costPrice'
,
align
:
'center'
,
//
align: 'center',
render
:
text
=>
`¥
${
text
}
`
,
render
:
text
=>
`¥
${
text
}
`
,
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangku'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangku'
}),
dataIndex
:
'warehouseName'
,
dataIndex
:
'warehouseName'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.kucun'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.kucun'
}),
dataIndex
:
'inventoryCount'
,
dataIndex
:
'inventoryCount'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.jine'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.jine'
}),
dataIndex
:
'totalPrice'
,
dataIndex
:
'totalPrice'
,
align
:
'center'
,
//
align: 'center',
render
:
text
=>
`¥
${
text
}
`
,
render
:
text
=>
`¥
${
text
}
`
,
},
},
{
{
...
@@ -125,7 +125,7 @@ const Inventory: React.FC<{}> = () => {
...
@@ -125,7 +125,7 @@ const Inventory: React.FC<{}> = () => {
</
Space
>
</
Space
>
),
),
dataIndex
:
'safeInventoryCount'
,
dataIndex
:
'safeInventoryCount'
,
align
:
'center'
,
//
align: 'center',
render
:
(
text
,
record
)
=>
(
render
:
(
text
,
record
)
=>
(
<
div
<
div
className=
{
styles
.
safe
}
className=
{
styles
.
safe
}
...
...
src/pages/transaction/stockSellStorage/warehouse/components/WarehouseForm/index.tsx
View file @
0a61b3f2
...
@@ -9,22 +9,29 @@ import NiceForm from '@/components/NiceForm';
...
@@ -9,22 +9,29 @@ import NiceForm from '@/components/NiceForm';
import
{
warehouseDetailSchema
}
from
'./schema'
;
import
{
warehouseDetailSchema
}
from
'./schema'
;
import
{
useLinkEnumEffect
}
from
'@/components/NiceForm/linkages/linkEnum'
;
import
{
useLinkEnumEffect
}
from
'@/components/NiceForm/linkages/linkEnum'
;
import
{
useAsyncSelect
}
from
'@/formSchema/effects/useAsyncSelect'
;
import
{
useAsyncSelect
}
from
'@/formSchema/effects/useAsyncSelect'
;
import
{
getManageAreaAll
,
getManageCountryAreaGetTelCode
}
from
'@/services/ManageV2Api'
;
import
{
import
{
getProductWarehouseDetails
,
postProductWarehouseAddOrUpdate
}
from
'@/services/ProductV2Api'
;
getManageAreaAll
,
getManageCountryAreaGetTelCode
,
}
from
'@/services/ManageV2Api'
;
import
{
getProductWarehouseDetails
,
postProductWarehouseAddOrUpdate
,
}
from
'@/services/ProductV2Api'
;
import
styles
from
'./index.less'
;
import
styles
from
'./index.less'
;
import
FormDetailHeader
from
'@/components/FormDetailHeader'
;
import
{
FormDetailContext
}
from
'@/formSchema/context'
;
import
{
useFormDetail
}
from
'@/formSchema/effects/useFormDetail'
;
const
intl
=
getIntl
();
const
intl
=
getIntl
();
const
formActions
=
createFormActions
();
const
formActions
=
createFormActions
();
const
{
const
{
onFormInputChange$
}
=
FormEffectHooks
;
onFormInputChange$
,
}
=
FormEffectHooks
;
interface
WarehouseFormProps
{
interface
WarehouseFormProps
{
id
?:
string
;
id
?:
string
;
validateId
?:
string
;
validateId
?:
string
;
// 是否是编辑的
// 是否是编辑的
isEdit
?:
boolean
;
isEdit
?:
boolean
;
}
;
}
const
WarehouseForm
:
React
.
FC
<
WarehouseFormProps
>
=
({
const
WarehouseForm
:
React
.
FC
<
WarehouseFormProps
>
=
({
id
,
id
,
...
@@ -91,15 +98,17 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
...
@@ -91,15 +98,17 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
postProductWarehouseAddOrUpdate
({
postProductWarehouseAddOrUpdate
({
id
:
id
,
id
:
id
,
...
value
,
...
value
,
}).
then
(
res
=>
{
})
if
(
res
.
code
===
1000
)
{
.
then
(
res
=>
{
setTimeout
(()
=>
{
if
(
res
.
code
===
1000
)
{
history
.
goBack
();
setTimeout
(()
=>
{
},
800
);
history
.
goBack
();
};
},
800
);
}).
finally
(()
=>
{
}
setSubmitLoading
(
false
);
})
});
.
finally
(()
=>
{
setSubmitLoading
(
false
);
});
setUnsaved
(
false
);
setUnsaved
(
false
);
};
};
...
@@ -109,45 +118,48 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
...
@@ -109,45 +118,48 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
</
div
>
</
div
>
);
);
const
{
formContext
}
=
useFormDetail
();
const
providerValue
=
{
// detailData: initFormValue,
schemaActions
:
warehouseDetailSchema
,
formContext
,
};
return
(
return
(
<
Spin
spinning=
{
infoLoading
}
>
<
Spin
spinning=
{
infoLoading
}
>
<
PageHeaderWrapper
<
FormDetailContext
.
Provider
value=
{
providerValue
}
>
style=
{
{
<
FormDetailHeader
padding
:
24
,
title=
{
}
}
!
id
onBack=
{
()
=>
history
.
goBack
()
}
?
intl
.
formatMessage
({
id
:
'stockSellStorage.xinjiancangku'
})
backIcon=
{
<
ReutrnEle
description=
{
intl
.
formatMessage
({
id
:
'stockSellStorage.fanhui'
})
}
/>
}
:
isEdit
title=
{
?
intl
.
formatMessage
({
id
:
'stockSellStorage.bianjicangku'
})
!
id
?
:
intl
.
formatMessage
({
id
:
'stockSellStorage.zhakancangku'
})
intl
.
formatMessage
({
id
:
'stockSellStorage.xinjiancangku'
})
:
}
isEdit
?
schema=
{
warehouseDetailSchema
}
intl
.
formatMessage
({
id
:
'stockSellStorage.bianjicangku'
})
:
extraRight=
{
intl
.
formatMessage
({
id
:
'stockSellStorage.zhakancangku'
})
isEdit
||
!
id
}
?
[
extra=
{
<
Button
(
isEdit
||
!
id
)
key=
"1"
?
[
type=
"primary"
<
Button
icon=
{
<
SaveOutlined
/>
}
key=
"1"
loading=
{
submitLoading
}
type=
"primary"
onClick=
{
()
=>
formActions
.
submit
()
}
icon=
{
<
SaveOutlined
/>
}
>
loading=
{
submitLoading
}
{
intl
.
formatMessage
({
id
:
'stockSellStorage.baocun'
})
}
onClick=
{
()
=>
formActions
.
submit
()
}
</
Button
>,
>
]
{
intl
.
formatMessage
({
id
:
'stockSellStorage.baocun'
})
}
:
[]
</
Button
>,
}
]
/>
:
[]
<
Card
style=
{
{
margin
:
12
}
}
>
}
>
<
Card
>
<
NiceForm
<
NiceForm
previewPlaceholder=
"' '"
previewPlaceholder=
"' '"
editable=
{
isEdit
||
!
id
}
editable=
{
isEdit
||
!
id
}
expressionScope=
{
{
expressionScope=
{
{
AddressLabel
,
AddressLabel
,
}
}
}
}
effects=
{
(
$
,
{
setFieldState
}
)
=>
{
effects=
{
(
$
,
actions
)
=>
{
useLinkEnumEffect
(
'areaResponses'
,
result
=>
useLinkEnumEffect
(
'areaResponses'
,
result
=>
result
.
map
(
v
=>
({
result
.
map
(
v
=>
({
label
:
v
.
name
,
label
:
v
.
name
,
...
@@ -160,6 +172,8 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
...
@@ -160,6 +172,8 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
setUnsaved
(
true
);
setUnsaved
(
true
);
}
}
});
});
// 注入表单完成进度
formContext
.
useAttachmentChangeForContext
(
actions
);
}
}
}
}
initialValues=
{
info
}
initialValues=
{
info
}
onSubmit=
{
handleSubmit
}
onSubmit=
{
handleSubmit
}
...
@@ -167,8 +181,13 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
...
@@ -167,8 +181,13 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
schema=
{
warehouseDetailSchema
}
schema=
{
warehouseDetailSchema
}
/>
/>
</
Card
>
</
Card
>
</
PageHeaderWrapper
>
</
FormDetailContext
.
Provider
>
<
Prompt
when=
{
unsaved
}
message=
{
intl
.
formatMessage
({
id
:
'stockSellStorage.ninhaiyouweibaocundenei'
})
}
/>
<
Prompt
when=
{
unsaved
}
message=
{
intl
.
formatMessage
({
id
:
'stockSellStorage.ninhaiyouweibaocundenei'
,
})
}
/>
</
Spin
>
</
Spin
>
);
);
};
};
...
...
src/pages/transaction/stockSellStorage/warehouse/components/WarehouseForm/schema/index.ts
View file @
0a61b3f2
This diff is collapsed.
Click to expand it.
src/pages/transaction/stockSellStorage/warehouse/index.tsx
View file @
0a61b3f2
...
@@ -30,12 +30,12 @@ const WareHouse: React.FC<{}> = () => {
...
@@ -30,12 +30,12 @@ const WareHouse: React.FC<{}> = () => {
{
{
title
:
'ID'
,
title
:
'ID'
,
dataIndex
:
'id'
,
dataIndex
:
'id'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangkumingcheng'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangkumingcheng'
}),
dataIndex
:
'name'
,
dataIndex
:
'name'
,
align
:
'center'
,
//
align: 'center',
render
:
(
text
:
any
,
record
:
any
)
=>
{
render
:
(
text
:
any
,
record
:
any
)
=>
{
return
(
return
(
<
EyePreview
<
EyePreview
...
@@ -50,22 +50,22 @@ const WareHouse: React.FC<{}> = () => {
...
@@ -50,22 +50,22 @@ const WareHouse: React.FC<{}> = () => {
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangkudizhi'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangkudizhi'
}),
dataIndex
:
'address'
,
dataIndex
:
'address'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangkufuzhairen'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.cangkufuzhairen'
}),
dataIndex
:
'principal'
,
dataIndex
:
'principal'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.lianxidianhua'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.lianxidianhua'
}),
dataIndex
:
'tel'
,
dataIndex
:
'tel'
,
align
:
'center'
,
//
align: 'center',
},
},
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.zhuangtai'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.zhuangtai'
}),
dataIndex
:
'state'
,
dataIndex
:
'state'
,
align
:
'center'
,
//
align: 'center',
sorter
:
(
a
,
b
)
=>
a
.
state
-
b
.
state
,
sorter
:
(
a
,
b
)
=>
a
.
state
-
b
.
state
,
render
:
(
text
:
any
,
record
:
any
)
=>
{
render
:
(
text
:
any
,
record
:
any
)
=>
{
return
(
return
(
...
@@ -83,7 +83,7 @@ const WareHouse: React.FC<{}> = () => {
...
@@ -83,7 +83,7 @@ const WareHouse: React.FC<{}> = () => {
{
{
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caozuo'
}),
title
:
intl
.
formatMessage
({
id
:
'stockSellStorage.caozuo'
}),
dataIndex
:
'option'
,
dataIndex
:
'option'
,
align
:
'center'
,
//
align: 'center',
render
:
(
text
:
any
,
record
:
any
)
=>
(
render
:
(
text
:
any
,
record
:
any
)
=>
(
<>
<>
{
record
.
state
===
POSITION_STATUS_INVALID
&&
(
{
record
.
state
===
POSITION_STATUS_INVALID
&&
(
...
...
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