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
e85d3cab
Commit
e85d3cab
authored
Dec 08, 2020
by
Bill
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:修改加工搜索
parent
ad67cfef
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
122 additions
and
110 deletions
+122
-110
index.tsx
src/pages/handling/assign/processStock/index.tsx
+31
-19
schema.tsx
src/pages/handling/assign/processStock/schema.tsx
+7
-7
index.tsx
src/pages/handling/components/Query/index.tsx
+16
-16
schema.tsx
src/pages/handling/components/Query/schema.tsx
+29
-29
index.tsx
src/pages/handling/confirm/Query/index.tsx
+11
-11
schema.tsx
src/pages/handling/confirm/Query/schema.tsx
+28
-28
No files found.
src/pages/handling/assign/processStock/index.tsx
View file @
e85d3cab
...
@@ -14,8 +14,8 @@ import { ColumnsType } from 'antd/es/table';
...
@@ -14,8 +14,8 @@ import { ColumnsType } from 'antd/es/table';
import
{
timeRange
}
from
'@/utils'
;
import
{
timeRange
}
from
'@/utils'
;
import
{
Link
,
history
}
from
'umi'
import
{
Link
,
history
}
from
'umi'
import
{
DOC_TYPE_PROCESS_INVOICE
,
DEPENDENT_DOC_PRODUCTION
,
DOC_TYPE_PROCESS_RECEIPT
}
from
'@/constants'
;
import
{
DOC_TYPE_PROCESS_INVOICE
,
DEPENDENT_DOC_PRODUCTION
,
DOC_TYPE_PROCESS_RECEIPT
}
from
'@/constants'
;
import
{
import
{
PROCESS_TITLE
,
PROCESS_TITLE
,
PENDING_ADD_PROCESS_PATH
,
PENDING_ADD_PROCESS_PATH
,
PROCESSING_INVOICE_TO_BE_ADD_PATH
,
PROCESSING_INVOICE_TO_BE_ADD_PATH
,
PENDING_ADD_LOGISTICS_PATH
,
PENDING_ADD_LOGISTICS_PATH
,
...
@@ -23,6 +23,7 @@ import {
...
@@ -23,6 +23,7 @@ import {
ASSIGN_PENDING_RECEIVE
,
ASSIGN_PENDING_RECEIVE
,
PENDING_RECEIPT_PATH
,
PENDING_RECEIPT_PATH
,
}
from
'../../common'
;
}
from
'../../common'
;
import
{
action
}
from
'mobx'
;
const
formActions
=
createFormActions
();
const
formActions
=
createFormActions
();
const
ADD_PROCESS_PATH
=
'/memberCenter/tranactionAbility/stockSellStorage/bills/add'
;
const
ADD_PROCESS_PATH
=
'/memberCenter/tranactionAbility/stockSellStorage/bills/add'
;
...
@@ -44,7 +45,10 @@ const SERVICE_MAPS = {
...
@@ -44,7 +45,10 @@ const SERVICE_MAPS = {
* 例子 3_15 此时 状态为待审核加工发货单, 那么对应的columns 的render组件是 <a>审核</a>
* 例子 3_15 此时 状态为待审核加工发货单, 那么对应的columns 的render组件是 <a>审核</a>
*/
*/
enum
OuterAndInnerStatus
{
enum
OuterAndInnerStatus
{
pending_add_process
=
'待新增加工发货单'
,
/**
* 待新增加工发货单
*/
pending_add_process
=
'3_14'
,
/**
/**
* 待审核加工发货单
* 待审核加工发货单
*/
*/
...
@@ -89,6 +93,7 @@ const processStock: React.FC<{}> = () => {
...
@@ -89,6 +93,7 @@ const processStock: React.FC<{}> = () => {
const
pathname
=
history
.
location
.
pathname
;
const
pathname
=
history
.
location
.
pathname
;
const
[
confirmLoading
,
setConfirmLoading
]
=
useState
<
boolean
>
(
false
);
const
[
confirmLoading
,
setConfirmLoading
]
=
useState
<
boolean
>
(
false
);
const
[
visibleID
,
setVisibleID
]
=
useState
<
null
|
number
>
(
null
);
const
[
visibleID
,
setVisibleID
]
=
useState
<
null
|
number
>
(
null
);
const
isAssign
=
[
PENDING_ADD_PROCESS_PATH
,
ASSIGN_PENDING_RECEIVE
].
includes
(
pathname
);
const
fetchData
=
useCallback
(
async
(
params
:
any
)
=>
{
const
fetchData
=
useCallback
(
async
(
params
:
any
)
=>
{
const
{
docTime
,
...
rest
}
=
params
;
const
{
docTime
,
...
rest
}
=
params
;
...
@@ -96,15 +101,15 @@ const processStock: React.FC<{}> = () => {
...
@@ -96,15 +101,15 @@ const processStock: React.FC<{}> = () => {
const
postData
=
{
const
postData
=
{
startTime
:
st
,
startTime
:
st
,
endTime
:
et
,
endTime
:
et
,
...
rest
...
rest
,
}
}
const
res
=
await
SERVICE_MAPS
[
pathname
](
postData
)
const
res
=
await
SERVICE_MAPS
[
pathname
](
postData
)
return
res
.
data
;
return
res
.
data
;
},
[
pathname
]);
},
[
pathname
]);
const
columns
:
ColumnsType
=
[
const
columns
:
ColumnsType
=
[
{
{
title
:
'通知单号'
,
title
:
'通知单号'
,
dataIndex
:
'noticeNo'
,
dataIndex
:
'noticeNo'
,
render
:
(
text
,
record
:
any
)
=>
{
render
:
(
text
,
record
:
any
)
=>
{
return
(
return
(
...
@@ -113,8 +118,9 @@ const processStock: React.FC<{}> = () => {
...
@@ -113,8 +118,9 @@ const processStock: React.FC<{}> = () => {
}
}
},
},
{
title
:
'通知单摘要'
,
dataIndex
:
'summary'
},
{
title
:
'通知单摘要'
,
dataIndex
:
'summary'
},
{
title
:
'加工企业名称'
,
dataIndex
:
'processName'
},
isAssign
{
title
:
'供应会员'
,
dataIndex
:
'supplierName'
},
?
{
title
:
'加工企业名称'
,
dataIndex
:
'processName'
}
:
{
title
:
'供应会员'
,
dataIndex
:
'supplierName'
},,
{
{
title
:
'单据时间'
,
title
:
'单据时间'
,
dataIndex
:
'createTime'
,
dataIndex
:
'createTime'
,
...
@@ -124,7 +130,7 @@ const processStock: React.FC<{}> = () => {
...
@@ -124,7 +130,7 @@ const processStock: React.FC<{}> = () => {
},
},
{
title
:
'发货批次'
,
dataIndex
:
'deliveryBatch'
},
{
title
:
'发货批次'
,
dataIndex
:
'deliveryBatch'
},
{
{
title
:
()
=>
pathname
==
PENDING_ADD_PROCESS_PATH
?
'入库单号'
:
'发货单号'
,
title
:
()
=>
pathname
==
PENDING_ADD_PROCESS_PATH
?
'入库单号'
:
'发货单号'
,
dataIndex
:
'deliveryNo'
,
dataIndex
:
'deliveryNo'
,
render
:
(
text
,
record
:
any
)
=>
{
render
:
(
text
,
record
:
any
)
=>
{
if
(
!
text
)
{
if
(
!
text
)
{
...
@@ -139,8 +145,8 @@ const processStock: React.FC<{}> = () => {
...
@@ -139,8 +145,8 @@ const processStock: React.FC<{}> = () => {
},
},
{
title
:
'外部状态'
,
dataIndex
:
'outerStatusName'
},
{
title
:
'外部状态'
,
dataIndex
:
'outerStatusName'
},
{
title
:
'内部状态'
,
dataIndex
:
'innerStatusName'
},
{
title
:
'内部状态'
,
dataIndex
:
'innerStatusName'
},
{
{
title
:
'操作'
,
title
:
'操作'
,
dataIndex
:
'action'
,
dataIndex
:
'action'
,
render
:
(
text
,
record
:
any
)
=>
{
render
:
(
text
,
record
:
any
)
=>
{
// 这里暂时不知道status的状态, 先用内部状态判断, 审核的先不处理, 感觉应该用入库单号去判断吧
// 这里暂时不知道status的状态, 先用内部状态判断, 审核的先不处理, 感觉应该用入库单号去判断吧
...
@@ -148,7 +154,7 @@ const processStock: React.FC<{}> = () => {
...
@@ -148,7 +154,7 @@ const processStock: React.FC<{}> = () => {
const
innerStatus
=
record
.
innerStatus
;
const
innerStatus
=
record
.
innerStatus
;
const
MAP
=
{
const
MAP
=
{
[
OuterAndInnerStatus
.
pending_add_process
]:
(
[
OuterAndInnerStatus
.
pending_add_process
]:
(
<
Link
<
Link
to=
{
`${ADD_PROCESS_PATH}?relevanceInvoicesId=${record.id}&invoicesTypeId=${DOC_TYPE_PROCESS_INVOICE}&relevanceInvoices=${DEPENDENT_DOC_PRODUCTION}`
}
to=
{
`${ADD_PROCESS_PATH}?relevanceInvoicesId=${record.id}&invoicesTypeId=${DOC_TYPE_PROCESS_INVOICE}&relevanceInvoices=${DEPENDENT_DOC_PRODUCTION}`
}
>
>
新增加工发货单
新增加工发货单
...
@@ -172,7 +178,7 @@ const processStock: React.FC<{}> = () => {
...
@@ -172,7 +178,7 @@ const processStock: React.FC<{}> = () => {
[
OuterAndInnerStatus
.
pending_confirm_logistics
]:
<
a
>
查看
<
/a>
,
[
OuterAndInnerStatus
.
pending_confirm_logistics
]:
<
a
>
查看
<
/a>
,
[
OuterAndInnerStatus
.
pending_confirm_deliver
]:
<
Link
to
=
{
`
${
PENDING_DELIVERD_PATH
}
/detail?id=
${
record
.
id
}
`
}
>
发货
<
/Link>
,
[
OuterAndInnerStatus
.
pending_confirm_deliver
]:
<
Link
to
=
{
`
${
PENDING_DELIVERD_PATH
}
/detail?id=
${
record
.
id
}
`
}
>
发货
<
/Link>
,
[
OuterAndInnerStatus
.
pending_add_process_in_warehouse
]:
(
[
OuterAndInnerStatus
.
pending_add_process_in_warehouse
]:
(
<
Link
<
Link
to=
{
`${ADD_DELIVERY_PATH}?relevanceInvoicesId=${record.id}&invoicesTypeId=${DOC_TYPE_PROCESS_RECEIPT}&relevanceInvoices=${DEPENDENT_DOC_PRODUCTION}`
}
to=
{
`${ADD_DELIVERY_PATH}?relevanceInvoicesId=${record.id}&invoicesTypeId=${DOC_TYPE_PROCESS_RECEIPT}&relevanceInvoices=${DEPENDENT_DOC_PRODUCTION}`
}
>
>
新增加工入库单
新增加工入库单
...
@@ -226,16 +232,18 @@ const processStock: React.FC<{}> = () => {
...
@@ -226,16 +232,18 @@ const processStock: React.FC<{}> = () => {
/**
/**
* 查询
* 查询
* @params values 表单字段
* @params values 表单字段
*/
*/
const
handleSearch
=
useCallback
((
values
:
any
)
=>
{
const
handleSearch
=
useCallback
((
values
:
any
)
=>
{
const
{
docTime
,
...
rest
}
=
values
;
const
{
docTime
,
memberName
,
...
rest
}
=
values
;
const
{
st
,
et
}
=
timeRange
(
docTime
);
const
{
st
,
et
}
=
timeRange
(
docTime
);
const
others
=
isAssign
?
{
processName
:
memberName
}
:
{
supplierName
:
memberName
}
let
searchData
=
{
let
searchData
=
{
...
rest
,
...
rest
,
startTime
:
st
,
startTime
:
st
,
endTtime
:
et
endTtime
:
et
,
...
others
}
}
console
.
log
(
searchData
)
console
.
log
(
searchData
)
ref
.
current
.
reload
(
searchData
)
ref
.
current
.
reload
(
searchData
)
...
@@ -273,6 +281,11 @@ const processStock: React.FC<{}> = () => {
...
@@ -273,6 +281,11 @@ const processStock: React.FC<{}> = () => {
onSubmit=
{
handleSearch
}
onSubmit=
{
handleSearch
}
effects=
{
(
$
,
actions
)
=>
{
effects=
{
(
$
,
actions
)
=>
{
useStateFilterSearchLinkageEffect
(
$
,
actions
,
'noticeNo'
,
FORM_FILTER_PATH
);
useStateFilterSearchLinkageEffect
(
$
,
actions
,
'noticeNo'
,
FORM_FILTER_PATH
);
$
(
'onFormMount'
).
subscribe
((
fieldState
)
=>
{
actions
.
setFieldState
(
'memberName'
,
state
=>
{
state
.
props
[
"x-component-props"
][
"placeholder"
]
=
isAssign
?
'加工企业'
:
'供应会员'
})
})
}
}
}
}
schema=
{
schema
}
schema=
{
schema
}
/>
/>
...
@@ -283,4 +296,4 @@ const processStock: React.FC<{}> = () => {
...
@@ -283,4 +296,4 @@ const processStock: React.FC<{}> = () => {
)
)
}
}
export
default
processStock
export
default
processStock
\ No newline at end of file
src/pages/handling/assign/processStock/schema.tsx
View file @
e85d3cab
...
@@ -18,8 +18,8 @@ export const schema: ISchema = {
...
@@ -18,8 +18,8 @@ export const schema: ISchema = {
'x-component'
:
'Search'
,
'x-component'
:
'Search'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'搜索'
,
placeholder
:
'搜索'
,
align
:
'flex-left'
,
align
:
'flex-left'
,
tip
:
'输入通知单号进行搜索'
,
tip
:
'输入通知单号进行搜索'
,
},
},
},
},
[
FORM_FILTER_PATH
]:
{
[
FORM_FILTER_PATH
]:
{
...
@@ -35,8 +35,8 @@ export const schema: ISchema = {
...
@@ -35,8 +35,8 @@ export const schema: ISchema = {
memberName
:
{
memberName
:
{
type
:
'string'
,
type
:
'string'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'
加工企业名'
,
placeholder
:
'
'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
summary
:
{
summary
:
{
...
@@ -50,11 +50,11 @@ export const schema: ISchema = {
...
@@ -50,11 +50,11 @@ export const schema: ISchema = {
default
:
0
,
default
:
0
,
enum
:
docTime
,
enum
:
docTime
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'单据时间(全部)'
,
placeholder
:
'单据时间(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
submit
:
{
submit
:
{
'x-component'
:
'Submit'
,
'x-component'
:
'Submit'
,
'x-mega-props'
:
{
'x-mega-props'
:
{
...
...
src/pages/handling/components/Query/index.tsx
View file @
e85d3cab
...
@@ -19,7 +19,7 @@ import { useAsyncSelect } from '@/formSchema/effects/useAsyncSelect';
...
@@ -19,7 +19,7 @@ import { useAsyncSelect } from '@/formSchema/effects/useAsyncSelect';
import
{
ColumnsType
}
from
'antd/es/table'
;
import
{
ColumnsType
}
from
'antd/es/table'
;
import
{
DownOutlined
,
DeleteOutlined
}
from
'@ant-design/icons'
;
import
{
DownOutlined
,
DeleteOutlined
}
from
'@ant-design/icons'
;
import
{
querySchema
,
tobeAddQuerySchema
,
pendingFirstQuerySchema
}
from
'./schema'
;
import
{
querySchema
,
tobeAddQuerySchema
,
pendingFirstQuerySchema
}
from
'./schema'
;
import
{
import
{
ASSIGN_QUERY
,
ASSIGN_QUERY
,
ASSIGN_TO_BE_ADD_QUERY
,
ASSIGN_TO_BE_ADD_QUERY
,
ASSIGN_PENDING_FIRST
,
ASSIGN_PENDING_FIRST
,
...
@@ -84,9 +84,9 @@ const Query: React.FC<{}> = (props) => {
...
@@ -84,9 +84,9 @@ const Query: React.FC<{}> = (props) => {
const
menu
=
(
const
menu
=
(
<
Menu
>
<
Menu
>
<
Menu
.
Item
<
Menu
.
Item
key=
"BatchDelete"
key=
"BatchDelete"
onClick=
{
()
=>
handleSubmitToReviewOrDelete
({
type
:
'delete'
})
}
onClick=
{
()
=>
handleSubmitToReviewOrDelete
({
type
:
'delete'
})
}
icon=
{
<
DeleteOutlined
/>
}
icon=
{
<
DeleteOutlined
/>
}
>
>
批量删除
批量删除
...
@@ -114,7 +114,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -114,7 +114,7 @@ const Query: React.FC<{}> = (props) => {
return
moment
(
text
).
format
(
'YYYY-MM-DD'
);
return
moment
(
text
).
format
(
'YYYY-MM-DD'
);
}
}
},
},
{
{
title
:
'外部状态'
,
title
:
'外部状态'
,
dataIndex
:
'outerStatusName'
,
dataIndex
:
'outerStatusName'
,
render
:
(
text
,
record
:
any
)
=>
{
render
:
(
text
,
record
:
any
)
=>
{
...
@@ -143,7 +143,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -143,7 +143,7 @@ const Query: React.FC<{}> = (props) => {
[
ASSIGN_PENDING_SECOND
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
审核
<
/Link>
,
[
ASSIGN_PENDING_SECOND
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
审核
<
/Link>
,
[
ASSIGN_PENDING_SUBMIT
]:
(<
Spin
spinning=
{
submitLoadingID
===
record
.
id
}
><
a
onClick=
{
()
=>
handleUpdateOrDelete
(
'review'
,
{
id
:
record
.
id
})
}
>
{
"提交通知单"
}
</
a
></
Spin
>),
[
ASSIGN_PENDING_SUBMIT
]:
(<
Spin
spinning=
{
submitLoadingID
===
record
.
id
}
><
a
onClick=
{
()
=>
handleUpdateOrDelete
(
'review'
,
{
id
:
record
.
id
})
}
>
{
"提交通知单"
}
</
a
></
Spin
>),
// [PENDING_RECEIVE]: <Link to={`${url}?id=${record.id}`}>收货</Link>
// [PENDING_RECEIVE]: <Link to={`${url}?id=${record.id}`}>收货</Link>
}
}
return
(
return
(
<
Space
>
<
Space
>
{
{
...
@@ -162,8 +162,8 @@ const Query: React.FC<{}> = (props) => {
...
@@ -162,8 +162,8 @@ const Query: React.FC<{}> = (props) => {
const
controllerBtns
=
()
=>
(
const
controllerBtns
=
()
=>
(
<
Space
>
<
Space
>
<
Button
<
Button
type=
"primary"
type=
"primary"
onClick=
{
()
=>
{
history
.
push
(
'/memberCenter/handling/assign/tobeAddQuery/add'
)
}
}
onClick=
{
()
=>
{
history
.
push
(
'/memberCenter/handling/assign/tobeAddQuery/add'
)
}
}
>
>
<
PlusOutlined
/>
新建
<
PlusOutlined
/>
新建
...
@@ -186,8 +186,8 @@ const Query: React.FC<{}> = (props) => {
...
@@ -186,8 +186,8 @@ const Query: React.FC<{}> = (props) => {
pathname
==
ASSIGN_PENDING_SUBMIT
pathname
==
ASSIGN_PENDING_SUBMIT
?
'批量提交'
?
'批量提交'
:
'批量提交审核'
:
'批量提交审核'
}
}
</
Button
>
</
Button
>
</
div
>
</
div
>
)
)
...
@@ -202,8 +202,8 @@ const Query: React.FC<{}> = (props) => {
...
@@ -202,8 +202,8 @@ const Query: React.FC<{}> = (props) => {
let
getParamsAndService
=
{
let
getParamsAndService
=
{
[
ASSIGN_TO_BE_ADD_QUERY
]:
()
=>
{
[
ASSIGN_TO_BE_ADD_QUERY
]:
()
=>
{
return
{
return
{
service
:
type
==
'review'
service
:
type
==
'review'
?
PublicApi
.
postEnhanceSupplierToBeAddBatchSubmitExam
?
PublicApi
.
postEnhanceSupplierToBeAddBatchSubmitExam
:
PublicApi
.
postEnhanceSupplierToBeAddBatchDelete
,
:
PublicApi
.
postEnhanceSupplierToBeAddBatchDelete
,
params
:
{
params
:
{
idList
:
selectedRowKeys
,
idList
:
selectedRowKeys
,
...
@@ -249,15 +249,15 @@ const Query: React.FC<{}> = (props) => {
...
@@ -249,15 +249,15 @@ const Query: React.FC<{}> = (props) => {
/**
/**
* 提交审核或者是删除, 用type做标识
* 提交审核或者是删除, 用type做标识
* @param values
* @param values
*/
*/
const
handleUpdateOrDelete
=
(
type
:
string
,
{
id
})
=>
{
const
handleUpdateOrDelete
=
(
type
:
string
,
{
id
})
=>
{
let
getParamsAndService
=
{
let
getParamsAndService
=
{
[
ASSIGN_TO_BE_ADD_QUERY
]:
()
=>
{
[
ASSIGN_TO_BE_ADD_QUERY
]:
()
=>
{
return
{
return
{
///enhance/supplier/toBeAdd/submitExam
///enhance/supplier/toBeAdd/submitExam
service
:
type
==
'review'
service
:
type
==
'review'
?
PublicApi
.
postEnhanceSupplierToBeAddSubmitExam
?
PublicApi
.
postEnhanceSupplierToBeAddSubmitExam
:
PublicApi
.
postEnhanceSupplierToBeAddDelete
,
:
PublicApi
.
postEnhanceSupplierToBeAddDelete
,
params
:
{
params
:
{
id
:
id
,
id
:
id
,
...
@@ -287,7 +287,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -287,7 +287,7 @@ const Query: React.FC<{}> = (props) => {
}
}
/**
/**
* 查询
* 查询
* @params values 表单字段
* @params values 表单字段
*/
*/
const
handleSearch
=
useCallback
((
values
:
any
)
=>
{
const
handleSearch
=
useCallback
((
values
:
any
)
=>
{
const
{
docTime
,
...
rest
}
=
values
;
const
{
docTime
,
...
rest
}
=
values
;
...
...
src/pages/handling/components/Query/schema.tsx
View file @
e85d3cab
...
@@ -3,7 +3,7 @@ import { FORM_FILTER_PATH } from '@/formSchema/const';
...
@@ -3,7 +3,7 @@ import { FORM_FILTER_PATH } from '@/formSchema/const';
// import { QUERY_SEARCH_NAME, TO_BE_ADD_QUERY_SEARCH_NAME, PENDING_FIRST_AND_SECOND_NOTICE } from './contants';
// import { QUERY_SEARCH_NAME, TO_BE_ADD_QUERY_SEARCH_NAME, PENDING_FIRST_AND_SECOND_NOTICE } from './contants';
import
{
docTime
}
from
'../../common'
;
import
{
docTime
}
from
'../../common'
;
/**
/**
* @author: Bill
* @author: Bill
* @description: 指派生产通知单查询页 schema - 生产通知单查询
* @description: 指派生产通知单查询页 schema - 生产通知单查询
*/
*/
...
@@ -19,8 +19,8 @@ export const querySchema: ISchema = {
...
@@ -19,8 +19,8 @@ export const querySchema: ISchema = {
'x-component'
:
'Search'
,
'x-component'
:
'Search'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'搜索'
,
placeholder
:
'搜索'
,
align
:
'flex-left'
,
align
:
'flex-left'
,
tip
:
'输入通知单号s进行搜索'
,
tip
:
'输入通知单号s进行搜索'
,
},
},
},
},
[
FORM_FILTER_PATH
]:
{
[
FORM_FILTER_PATH
]:
{
...
@@ -33,11 +33,11 @@ export const querySchema: ISchema = {
...
@@ -33,11 +33,11 @@ export const querySchema: ISchema = {
columns
:
6
,
columns
:
6
,
},
},
properties
:
{
properties
:
{
member
Name
:
{
process
Name
:
{
type
:
'string'
,
type
:
'string'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'加工企业名'
,
placeholder
:
'加工企业名'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
docTime
:
{
docTime
:
{
...
@@ -45,8 +45,8 @@ export const querySchema: ISchema = {
...
@@ -45,8 +45,8 @@ export const querySchema: ISchema = {
default
:
0
,
default
:
0
,
enum
:
docTime
,
enum
:
docTime
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'单据时间(全部)'
,
placeholder
:
'单据时间(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
outerStatus
:
{
outerStatus
:
{
...
@@ -54,8 +54,8 @@ export const querySchema: ISchema = {
...
@@ -54,8 +54,8 @@ export const querySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'外部状态(全部)'
,
placeholder
:
'外部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
innerStatus
:
{
innerStatus
:
{
...
@@ -63,8 +63,8 @@ export const querySchema: ISchema = {
...
@@ -63,8 +63,8 @@ export const querySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'内部状态(全部)'
,
placeholder
:
'内部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
submit
:
{
submit
:
{
...
@@ -126,11 +126,11 @@ export const tobeAddQuerySchema: ISchema = {
...
@@ -126,11 +126,11 @@ export const tobeAddQuerySchema: ISchema = {
},
},
},
},
properties
:
{
properties
:
{
member
Name
:
{
process
Name
:
{
type
:
'string'
,
type
:
'string'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'加工企业名称'
,
placeholder
:
'加工企业名称'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
docTime
:
{
docTime
:
{
...
@@ -138,8 +138,8 @@ export const tobeAddQuerySchema: ISchema = {
...
@@ -138,8 +138,8 @@ export const tobeAddQuerySchema: ISchema = {
default
:
0
,
default
:
0
,
enum
:
docTime
,
enum
:
docTime
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'单据时间(全部)'
,
placeholder
:
'单据时间(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
outerStatus
:
{
outerStatus
:
{
...
@@ -147,8 +147,8 @@ export const tobeAddQuerySchema: ISchema = {
...
@@ -147,8 +147,8 @@ export const tobeAddQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'外部状态(全部)'
,
placeholder
:
'外部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
innerStatus
:
{
innerStatus
:
{
...
@@ -156,8 +156,8 @@ export const tobeAddQuerySchema: ISchema = {
...
@@ -156,8 +156,8 @@ export const tobeAddQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'内部状态(全部)'
,
placeholder
:
'内部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
submit
:
{
submit
:
{
...
@@ -220,11 +220,11 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -220,11 +220,11 @@ export const pendingFirstQuerySchema: ISchema = {
},
},
},
},
properties
:
{
properties
:
{
n
ame
:
{
processN
ame
:
{
type
:
'string'
,
type
:
'string'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'加工企业名称'
,
placeholder
:
'加工企业名称'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
docTime
:
{
docTime
:
{
...
@@ -232,8 +232,8 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -232,8 +232,8 @@ export const pendingFirstQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'单据时间(全部)'
,
placeholder
:
'单据时间(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
outerStatus
:
{
outerStatus
:
{
...
@@ -241,8 +241,8 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -241,8 +241,8 @@ export const pendingFirstQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'外部状态(全部)'
,
placeholder
:
'外部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
innerStatus
:
{
innerStatus
:
{
...
@@ -250,8 +250,8 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -250,8 +250,8 @@ export const pendingFirstQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'内部状态(全部)'
,
placeholder
:
'内部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
submit
:
{
submit
:
{
...
...
src/pages/handling/confirm/Query/index.tsx
View file @
e85d3cab
...
@@ -37,7 +37,7 @@ const formActions = createFormActions();
...
@@ -37,7 +37,7 @@ const formActions = createFormActions();
* 待审核(二级),
* 待审核(二级),
* 待确认生产通知单
* 待确认生产通知单
* 根据他们的菜单路径获取schema, 获取列表页的service, 以及根据pathname跳到各自的详情页
* 根据他们的菜单路径获取schema, 获取列表页的service, 以及根据pathname跳到各自的详情页
*
*
*/
*/
// 根据 菜单路径, 获取相对应的schema
// 根据 菜单路径, 获取相对应的schema
export
const
SCHEMAS
=
{
export
const
SCHEMAS
=
{
...
@@ -57,7 +57,7 @@ const SERVICES = {
...
@@ -57,7 +57,7 @@ const SERVICES = {
[
CONFIRM_PENDING_CONFIRM
]:
PublicApi
.
getEnhanceProcessToBeConfirmList
,
[
CONFIRM_PENDING_CONFIRM
]:
PublicApi
.
getEnhanceProcessToBeConfirmList
,
}
}
const
Query
:
React
.
FC
<
{}
>
=
(
props
)
=>
{
const
Query
:
React
.
FC
<
{}
>
=
(
props
)
=>
{
const
pathname
=
history
.
location
.
pathname
;
const
pathname
=
history
.
location
.
pathname
;
const
[
selectRow
,
selectRowFns
]
=
useRowSelectionTable
({
customKey
:
'id'
});
const
[
selectRow
,
selectRowFns
]
=
useRowSelectionTable
({
customKey
:
'id'
});
const
[
batchLoading
,
setBatchLoading
]
=
useState
(
false
)
const
[
batchLoading
,
setBatchLoading
]
=
useState
(
false
)
...
@@ -98,7 +98,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -98,7 +98,7 @@ const Query: React.FC<{}> = (props) => {
}
}
},
},
{
title
:
'通知单摘要'
,
dataIndex
:
'summary'
},
{
title
:
'通知单摘要'
,
dataIndex
:
'summary'
},
{
title
:
'
加工企业名称'
,
dataIndex
:
'process
Name'
},
{
title
:
'
供应会员'
,
dataIndex
:
'supplier
Name'
},
{
{
title
:
'单据时间'
,
title
:
'单据时间'
,
dataIndex
:
'createTime'
,
dataIndex
:
'createTime'
,
...
@@ -106,7 +106,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -106,7 +106,7 @@ const Query: React.FC<{}> = (props) => {
return
moment
(
text
).
format
(
'YYYY-MM-DD'
);
return
moment
(
text
).
format
(
'YYYY-MM-DD'
);
}
}
},
},
{
{
title
:
'外部状态'
,
title
:
'外部状态'
,
dataIndex
:
'outerStatusName'
,
dataIndex
:
'outerStatusName'
,
render
:
(
text
,
record
:
any
)
=>
{
render
:
(
text
,
record
:
any
)
=>
{
...
@@ -135,7 +135,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -135,7 +135,7 @@ const Query: React.FC<{}> = (props) => {
[
CONFIRM_PENDING_FIRST
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
审核
<
/Link>
,
[
CONFIRM_PENDING_FIRST
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
审核
<
/Link>
,
[
CONFIRM_PENDING_SECOND
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
审核
<
/Link>
,
[
CONFIRM_PENDING_SECOND
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
审核
<
/Link>
,
[
CONFIRM_PENDING_CONFIRM
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
确认通知单
<
/Link>
,
[
CONFIRM_PENDING_CONFIRM
]:
<
Link
to
=
{
`
${
url
}
?id=
${
record
.
id
}
`
}
>
确认通知单
<
/Link>
,
}
}
return
(
return
(
<
Space
>
<
Space
>
{
{
...
@@ -152,7 +152,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -152,7 +152,7 @@ const Query: React.FC<{}> = (props) => {
<
div
>
<
div
>
<
Button
loading=
{
batchLoading
}
onClick=
{
()
=>
handleSubmitToReviewOrDelete
()
}
>
<
Button
loading=
{
batchLoading
}
onClick=
{
()
=>
handleSubmitToReviewOrDelete
()
}
>
批量审核通过
批量审核通过
</
Button
>
</
Button
>
</
div
>
</
div
>
)
)
...
@@ -167,7 +167,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -167,7 +167,7 @@ const Query: React.FC<{}> = (props) => {
// }).then(({code, data}) => {
// }).then(({code, data}) => {
// formActions.submit();
// formActions.submit();
// })
// })
// }
// }
/**
/**
...
@@ -191,14 +191,14 @@ const Query: React.FC<{}> = (props) => {
...
@@ -191,14 +191,14 @@ const Query: React.FC<{}> = (props) => {
setBatchLoading
(
false
);
setBatchLoading
(
false
);
if
(
code
===
1000
)
{
if
(
code
===
1000
)
{
formActions
.
submit
();
formActions
.
submit
();
}
}
})
})
}
}
}
}
/**
/**
* 查询
* 查询
* @params values 表单字段
* @params values 表单字段
*/
*/
const
handleSearch
=
useCallback
((
values
:
any
)
=>
{
const
handleSearch
=
useCallback
((
values
:
any
)
=>
{
const
{
docTime
,
...
rest
}
=
values
;
const
{
docTime
,
...
rest
}
=
values
;
...
@@ -208,7 +208,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -208,7 +208,7 @@ const Query: React.FC<{}> = (props) => {
startTime
:
st
,
startTime
:
st
,
endTtime
:
et
endTtime
:
et
}
}
ref
.
current
.
reload
(
searchData
)
ref
.
current
.
reload
(
searchData
)
},
[
ref
])
},
[
ref
])
...
@@ -242,7 +242,7 @@ const Query: React.FC<{}> = (props) => {
...
@@ -242,7 +242,7 @@ const Query: React.FC<{}> = (props) => {
}
}
/>
/>
</
Card
>
</
Card
>
</
PageHeaderWrapper
>
</
PageHeaderWrapper
>
)
)
}
}
...
...
src/pages/handling/confirm/Query/schema.tsx
View file @
e85d3cab
...
@@ -3,7 +3,7 @@ import { FORM_FILTER_PATH } from '@/formSchema/const';
...
@@ -3,7 +3,7 @@ import { FORM_FILTER_PATH } from '@/formSchema/const';
// import { QUERY_SEARCH_NAME, TO_BE_ADD_QUERY_SEARCH_NAME, PENDING_FIRST_AND_SECOND_NOTICE } from './contants';
// import { QUERY_SEARCH_NAME, TO_BE_ADD_QUERY_SEARCH_NAME, PENDING_FIRST_AND_SECOND_NOTICE } from './contants';
import
{
docTime
}
from
'../../common'
;
import
{
docTime
}
from
'../../common'
;
/**
/**
* @author: Bill
* @author: Bill
* @description: 指派生产通知单查询页 schema - 生产通知单查询
* @description: 指派生产通知单查询页 schema - 生产通知单查询
*/
*/
...
@@ -19,8 +19,8 @@ export const querySchema: ISchema = {
...
@@ -19,8 +19,8 @@ export const querySchema: ISchema = {
'x-component'
:
'Search'
,
'x-component'
:
'Search'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'搜索'
,
placeholder
:
'搜索'
,
align
:
'flex-left'
,
align
:
'flex-left'
,
tip
:
'输入通知单号进行搜索'
,
tip
:
'输入通知单号进行搜索'
,
},
},
},
},
[
FORM_FILTER_PATH
]:
{
[
FORM_FILTER_PATH
]:
{
...
@@ -33,11 +33,11 @@ export const querySchema: ISchema = {
...
@@ -33,11 +33,11 @@ export const querySchema: ISchema = {
columns
:
6
,
columns
:
6
,
},
},
properties
:
{
properties
:
{
memb
erName
:
{
suppli
erName
:
{
type
:
'string'
,
type
:
'string'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'供应会员'
,
placeholder
:
'供应会员'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
docTime
:
{
docTime
:
{
...
@@ -45,8 +45,8 @@ export const querySchema: ISchema = {
...
@@ -45,8 +45,8 @@ export const querySchema: ISchema = {
default
:
0
,
default
:
0
,
enum
:
docTime
,
enum
:
docTime
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'单据时间(全部)'
,
placeholder
:
'单据时间(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
outerStatus
:
{
outerStatus
:
{
...
@@ -54,8 +54,8 @@ export const querySchema: ISchema = {
...
@@ -54,8 +54,8 @@ export const querySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'外部状态(全部)'
,
placeholder
:
'外部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
innerStatus
:
{
innerStatus
:
{
...
@@ -63,8 +63,8 @@ export const querySchema: ISchema = {
...
@@ -63,8 +63,8 @@ export const querySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'内部状态(全部)'
,
placeholder
:
'内部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
submit
:
{
submit
:
{
...
@@ -99,8 +99,8 @@ export const basicSchema: ISchema = {
...
@@ -99,8 +99,8 @@ export const basicSchema: ISchema = {
'x-component'
:
'Search'
,
'x-component'
:
'Search'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'搜索'
,
placeholder
:
'搜索'
,
align
:
'flex-left'
,
align
:
'flex-left'
,
tip
:
'输入通知单号进行搜索'
,
tip
:
'输入通知单号进行搜索'
,
},
},
},
},
[
FORM_FILTER_PATH
]:
{
[
FORM_FILTER_PATH
]:
{
...
@@ -113,11 +113,11 @@ export const basicSchema: ISchema = {
...
@@ -113,11 +113,11 @@ export const basicSchema: ISchema = {
columns
:
6
,
columns
:
6
,
},
},
properties
:
{
properties
:
{
memb
erName
:
{
suppli
erName
:
{
type
:
'string'
,
type
:
'string'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'供应会员'
,
placeholder
:
'供应会员'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
summary
:
{
summary
:
{
...
@@ -132,8 +132,8 @@ export const basicSchema: ISchema = {
...
@@ -132,8 +132,8 @@ export const basicSchema: ISchema = {
default
:
0
,
default
:
0
,
enum
:
docTime
,
enum
:
docTime
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'单据时间(全部)'
,
placeholder
:
'单据时间(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
submit
:
{
submit
:
{
...
@@ -196,11 +196,11 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -196,11 +196,11 @@ export const pendingFirstQuerySchema: ISchema = {
},
},
},
},
properties
:
{
properties
:
{
n
ame
:
{
supplierN
ame
:
{
type
:
'string'
,
type
:
'string'
,
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'供应会员'
,
placeholder
:
'供应会员'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
docTime
:
{
docTime
:
{
...
@@ -208,8 +208,8 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -208,8 +208,8 @@ export const pendingFirstQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'单据时间(全部)'
,
placeholder
:
'单据时间(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
outerStatus
:
{
outerStatus
:
{
...
@@ -217,8 +217,8 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -217,8 +217,8 @@ export const pendingFirstQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'外部状态(全部)'
,
placeholder
:
'外部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
innerStatus
:
{
innerStatus
:
{
...
@@ -226,8 +226,8 @@ export const pendingFirstQuerySchema: ISchema = {
...
@@ -226,8 +226,8 @@ export const pendingFirstQuerySchema: ISchema = {
default
:
undefined
,
default
:
undefined
,
enum
:
[],
enum
:
[],
'x-component-props'
:
{
'x-component-props'
:
{
placeholder
:
'内部状态(全部)'
,
placeholder
:
'内部状态(全部)'
,
allowClear
:
true
,
allowClear
:
true
,
},
},
},
},
submit
:
{
submit
:
{
...
...
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