|
@@ -29,7 +29,20 @@ import Z3upFiles from '@/components/Z3upFiles'
|
|
|
import ZupFileTable from '@/components/ZupFileTable'
|
|
|
import ZflowTable from '@/components/ZflowTable'
|
|
|
import ZRichTexts from '@/components/ZRichTexts'
|
|
|
+import { useDispatch, useSelector } from 'react-redux'
|
|
|
+import { RootState } from '@/store'
|
|
|
+import { D7_APIList } from '@/store/action/D7check'
|
|
|
function E3edit() {
|
|
|
+ // 相关盘点单下拉数据
|
|
|
+ // 从仓库拿数据
|
|
|
+ const dispatch = useDispatch()
|
|
|
+
|
|
|
+ useEffect(() => {
|
|
|
+ dispatch(D7_APIList({ pageNum: 1, pageSize: 99999 }))
|
|
|
+ }, [dispatch])
|
|
|
+
|
|
|
+ const relatedOrderNumArr = useSelector((state: RootState) => state.D7check.tableInfo.list)
|
|
|
+
|
|
|
const { key, id } = useParams<any>()
|
|
|
// key:1 新增 2编辑 3审批 4查看
|
|
|
|
|
@@ -440,13 +453,12 @@ function E3edit() {
|
|
|
disabled={['3', '4'].includes(key)}
|
|
|
placeholder={['3', '4'].includes(key) ? '空' : '请搜索盘点单编号'}
|
|
|
showSearch
|
|
|
- // filterOption={(input, option) => {
|
|
|
- // const txt = option!.label + option!.num
|
|
|
+ filterOption={(input, option) => {
|
|
|
+ const txt = option!.label
|
|
|
|
|
|
- // return txt.toLowerCase().includes(input.toLowerCase())
|
|
|
- // }}
|
|
|
- // 待完善相关盘点单
|
|
|
- options={[]}
|
|
|
+ return txt.toLowerCase().includes(input.toLowerCase())
|
|
|
+ }}
|
|
|
+ options={relatedOrderNumArr.map(v => ({ value: v.id + '', label: v.num }))}
|
|
|
// fieldNames={{ label: 'num', value: 'num' }}
|
|
|
allowClear={false}
|
|
|
value={topInfo.relatedOrderNum || null}
|