فهرست منبع

好像改完了

shaogen1995 20 ساعت پیش
والد
کامیت
014f1f9b78
29فایلهای تغییر یافته به همراه237 افزوده شده و 119 حذف شده
  1. 0 1
      src/components/MyTable/form.tsx
  2. 0 1
      src/components/MyTable/index.tsx
  3. 0 2
      src/pages/Abench/A4proof/index.tsx
  4. 11 14
      src/pages/Cledger/C1ledger/index.tsx
  5. 6 7
      src/pages/Cledger/C2routing/index.tsx
  6. 11 12
      src/pages/Cledger/C3goodsInfo/index.tsx
  7. 9 0
      src/pages/Dmanage/D2edit/D2info/index.tsx
  8. 5 4
      src/pages/Eculture/E2story/index.tsx
  9. 1 1
      src/pages/Eculture/E3label/index.tsx
  10. 1 1
      src/pages/Fstorehouse/F1inStorage/F1edit/index.tsx
  11. 7 7
      src/pages/Fstorehouse/F1inStorage/index.module.scss
  12. 1 0
      src/pages/Fstorehouse/F1inStorage/index.tsx
  13. 1 1
      src/pages/Fstorehouse/F2moveStorage/F2edit/index.tsx
  14. 1 0
      src/pages/Fstorehouse/F2moveStorage/index.tsx
  15. 1 1
      src/pages/Fstorehouse/F3outStorage/F3edit/index.tsx
  16. 1 0
      src/pages/Fstorehouse/F3outStorage/index.tsx
  17. 1 1
      src/pages/Fstorehouse/F4check/F4edit/index.tsx
  18. 1 0
      src/pages/Fstorehouse/F4check/index.tsx
  19. 1 0
      src/pages/Fstorehouse/F5staff/index.tsx
  20. 66 29
      src/pages/Hexhibits/H1loan/H1detail/index.tsx
  21. 1 1
      src/pages/Layout/data.ts
  22. 4 3
      src/pages/ZgoodsInfo/data.ts
  23. 6 6
      src/pages/Zother/AddGoods/index.tsx
  24. 39 1
      src/pages/Zother/SelectGoods/index.tsx
  25. 20 22
      src/pages/Zother/SonGoodsList/data.ts
  26. 40 1
      src/pages/Zother/TableList/index.tsx
  27. 0 1
      src/store/action/Cledger/C1ledger.ts
  28. 1 1
      src/utils/dataChange.tsx
  29. 1 1
      src/utils/tableData.ts

+ 0 - 1
src/components/MyTable/form.tsx

@@ -262,7 +262,6 @@ const MyTable = forwardRef<MyTableMethods, MyTableProps>(
           connectTxt: (item: any) => {
             const txt1 = v[2] ? item[v[2]] || isNull : isNull
             const txt2 = v[3] ? item[v[3]] || isNull : isNull
-            console.log(txt1, txt2, item[v[2]], item[v[3]])
             return !item[v[2]] && !item[v[3]] ? isNull : `${txt1}-${txt2}`
           }
         }

+ 0 - 1
src/components/MyTable/index.tsx

@@ -174,7 +174,6 @@ function MyTable({
         connectTxt: (item: any) => {
           const txt1 = v[2] ? item[v[2]] || isNull : isNull
           const txt2 = v[3] ? item[v[3]] || isNull : isNull
-          console.log(txt1, txt2, item[v[2]], item[v[3]])
           return !item[v[2]] && !item[v[3]] ? isNull : `${txt1}-${txt2}`
         }
       }

+ 0 - 2
src/pages/Abench/A4proof/index.tsx

@@ -1,8 +1,6 @@
 import React, { useMemo, useState, useEffect, useCallback } from 'react'
 import styles from './index.module.scss'
 import history from '@/utils/history'
-import { MessageFu } from '@/utils/message'
-import { authorityFu } from '@/utils/authority'
 import TableList from '@/pages/Zother/TableList'
 import { useSelector } from 'react-redux'
 import { RootState } from '@/store'

+ 11 - 14
src/pages/Cledger/C1ledger/index.tsx

@@ -5,7 +5,7 @@ import { selectObj, getDictFu, resJiLianFu } from '@/utils/dataChange'
 import history, { openLink } from '@/utils/history'
 import TableList from '@/pages/Zother/TableList'
 import { useSelector } from 'react-redux'
-import { RootState } from '@/store'
+import store, { RootState } from '@/store'
 import { API_getGoodsList, API_getGoodsListAll } from '@/store/action/Cledger/C1ledger'
 import { I1_APIwarehouseSimpleList } from '@/store/action/Isystem/I1storageSet'
 import { baseFormData } from '@/pages/Zother/data'
@@ -17,7 +17,6 @@ import C1Import from './C1Import'
 
 const C1baseFormData = {
   ...baseFormData,
-  typeDictId: '',
   ageDictId: '',
   textureDictId: ''
 }
@@ -116,10 +115,10 @@ function C1ledger() {
         placeholder: '搜索藏品登记号、藏品名称'
       },
       {
-        type: 'cascaderSS',
-        key: 'artDictId',
-        placeholder: `文创标签`
-        // options: getDictFu('藏品标签')
+        type: 'CascaderSS',
+        key: 'subArtDictIds',
+        placeholder: `文化标签`,
+        options: store.getState().E3label.treeData
       },
       {
         type: 'select',
@@ -127,13 +126,12 @@ function C1ledger() {
         placeholder: '级别',
         options: selectObj['藏品级别']
       },
-      // 待完善sg
-      // {
-      //   type: 'cascaderSS',
-      //   key: 'tagDictId',
-      //   placeholder: '藏品标签',
-      //   options: getDictFu('藏品标签')
-      // },
+      {
+        type: 'CascaderSS',
+        key: 'subTagIds',
+        placeholder: '藏品标签',
+        options: store.getState().E1tag.treeData
+      },
       {
         type: 'cascader',
         key: 'ageDictId',
@@ -273,7 +271,6 @@ function C1ledger() {
         藏品标签: item.tagDictId,
         藏品名称: item.name,
         级别: item.level,
-        类别: resJiLianFu(item.typeDictId),
         年代: resJiLianFu(item.ageDictId),
         质地: resJiLianFu(item.textureDictId),
         完残程度: item.tornLevel,

+ 6 - 7
src/pages/Cledger/C2routing/index.tsx

@@ -46,7 +46,6 @@ const C2topSearch = [
 
 const C2baseFormData = {
   ...baseFormData,
-  typeDictId: '',
   ageDictId: '',
   textureDictId: ''
 }
@@ -130,7 +129,7 @@ const C2siderLeftTree = ({ setExtraParams }: { setExtraParams: (params: any) =>
     [value]
   )
 
-  // 按节点名称筛选:藏品标签(树)、藏品年代、文标签(树)、藏品级别(平铺)
+  // 按节点名称筛选:藏品标签(树)、藏品年代、文标签(树)、藏品级别(平铺)
   const categoryFiltered = useMemo(() => {
     return value2 ? filterTreeByName(dictAll, value2) : dictAll
   }, [dictAll, value2])
@@ -151,7 +150,7 @@ const C2siderLeftTree = ({ setExtraParams }: { setExtraParams: (params: any) =>
     return list.filter((item: { label: string }) => item.label.toUpperCase().includes(key))
   }, [value2])
 
-  // 四个数据源合并为一棵树:藏品标签(树)、藏品年代、文标签(树)、藏品级别(平铺)(key 带前缀便于拆分为分类参数)
+  // 四个数据源合并为一棵树:藏品标签(树)、藏品年代、文标签(树)、藏品级别(平铺)(key 带前缀便于拆分为分类参数)
   const treeData = useMemo(() => {
     const rootCategory: TreeDataNode = {
       key: 'root-类别',
@@ -165,7 +164,7 @@ const C2siderLeftTree = ({ setExtraParams }: { setExtraParams: (params: any) =>
     }
     const rootTag: TreeDataNode = {
       key: 'root-标签',
-      title: '文标签',
+      title: '文标签',
       children: loopToTreeNodes(tagTreeFiltered, 'tag')
     }
     const rootLevel: TreeDataNode = {
@@ -182,11 +181,11 @@ const C2siderLeftTree = ({ setExtraParams }: { setExtraParams: (params: any) =>
 
   // 根据勾选 key 列表解析为后端需要的分类参数字符串(逗号隔开)
   const getExtraParamsFromKeys = useCallback((keyList: string[]) => {
-    const subTypeDictId = keyList.filter(k => k.startsWith('type-')).map(k => k.slice(5))
+    const subTagIds = keyList.filter(k => k.startsWith('type-')).map(k => k.slice(5))
     const subAgeDictId = keyList.filter(k => k.startsWith('age-')).map(k => k.slice(4))
-    const subTagIds = keyList.filter(k => k.startsWith('tag-')).map(k => k.slice(4))
+    const subArtDictIds = keyList.filter(k => k.startsWith('tag-')).map(k => k.slice(4))
     const subLevel = keyList.filter(k => k.startsWith('level-')).map(k => k.slice(6))
-    return { subTypeDictId, subAgeDictId, subTagIds, subLevel }
+    return { subTagIds, subAgeDictId, subArtDictIds, subLevel }
   }, [])
 
   // 首次有树数据时默认全部选中

+ 11 - 12
src/pages/Cledger/C3goodsInfo/index.tsx

@@ -4,7 +4,7 @@ import { selectObj, getDictFu } from '@/utils/dataChange'
 import { openLink } from '@/utils/history'
 import TableList from '@/pages/Zother/TableList'
 import { useSelector } from 'react-redux'
-import { RootState } from '@/store'
+import store, { RootState } from '@/store'
 import { API_getGoodsList } from '@/store/action/Cledger/C1ledger'
 import { baseFormData } from '@/pages/Zother/data'
 import { goodsSonTableC } from '@/utils/tableData'
@@ -17,9 +17,10 @@ const C1topSearch = [
     placeholder: '搜索藏品登记号、藏品名称'
   },
   {
-    type: 'input',
-    key: 'searchTagName',
-    placeholder: `搜索藏品标签`
+    type: 'CascaderSS',
+    key: 'subTagIds',
+    placeholder: '藏品标签',
+    options: store.getState().E1tag.treeData
   },
   {
     type: 'select',
@@ -27,13 +28,12 @@ const C1topSearch = [
     placeholder: '级别',
     options: selectObj['藏品级别']
   },
-  // // 待完善sg
-  // {
-  //   type: 'cascader',
-  //   key: 'typeDictId',
-  //   placeholder: '类别',
-  //   options: getDictFu('藏品类别')
-  // },
+  {
+    type: 'CascaderSS',
+    key: 'subArtDictIds',
+    placeholder: `文化标签`,
+    options: store.getState().E3label.treeData
+  },
   {
     type: 'cascader',
     key: 'ageDictId',
@@ -74,7 +74,6 @@ const C1topSearch = [
 
 const C1baseFormData = {
   ...baseFormData,
-  typeDictId: '',
   ageDictId: '',
   textureDictId: ''
 }

+ 9 - 0
src/pages/Dmanage/D2edit/D2info/index.tsx

@@ -41,6 +41,15 @@ function D2info() {
             if (resTxt) return resTagFu(resTxt, '藏品') || '(空)'
             return resTxt || '(空)'
           }
+        },
+        {
+          key: 'artDictId',
+          name: '文化标签',
+          resFu: (info: GoodsType) => {
+            let resTxt = info.artDictId
+            if (resTxt) return resTagFu(resTxt, '文创') || '(空)'
+            return resTxt || '(空)'
+          }
         }
       ]
 

+ 5 - 4
src/pages/Eculture/E2story/index.tsx

@@ -1,7 +1,7 @@
 import React, { useMemo, useCallback } from 'react'
 import styles from './index.module.scss'
 import { useSelector } from 'react-redux'
-import { RootState } from '@/store'
+import store, { RootState } from '@/store'
 import { E2_APIgetList, E2_APIdel, E2_APIgetListAll } from '@/store/action/Eculture/E2story'
 import { MessageFu } from '@/utils/message'
 import TableList from '@/pages/Zother/TableList'
@@ -20,9 +20,10 @@ const E2topSearch = [
     placeholder: `请输入故事标题、关联藏品`
   },
   {
-    type: 'input',
-    key: 'searchTagName',
-    placeholder: '搜索藏品标签'
+    type: 'CascaderSS',
+    key: 'subTagIds',
+    placeholder: '藏品标签',
+    options: store.getState().E1tag.treeData
   },
   {
     type: 'time',

+ 1 - 1
src/pages/Eculture/E3label/index.tsx

@@ -150,7 +150,7 @@ function E3label() {
 
   return (
     <div className={styles.E3label}>
-      <div className='pageTitle'>文标签</div>
+      <div className='pageTitle'>文标签</div>
 
       {/* 左侧 */}
       <div className='E3son E3ll'>

+ 1 - 1
src/pages/Fstorehouse/F1inStorage/F1edit/index.tsx

@@ -188,7 +188,7 @@ function F1editContent() {
             ['txtCTag', '藏品标签', 'tagDictId'],
             ['txt', '藏品名称', 'name'],
             ['select', '级别', 'level', selectObj['藏品级别']],
-            ['txtC', '类别', 'typeDictId'],
+            ['txtCTag', '文化标签', 'artDictId', '文创'],
             ['txtC', '年代', 'ageDictId'],
             ['txtC', '质地', 'textureDictId'],
             ['select', '完残程度', 'tornLevel', selectObj['完残程度']],

+ 7 - 7
src/pages/Fstorehouse/F1inStorage/index.module.scss

@@ -1,7 +1,7 @@
-.F1inStorage {
-  :global {
-    .table-list-table {
-      height: calc(100% - 119px);
-    }
-  }
-}
+// .F1inStorage {
+//   :global {
+//     .table-list-table {
+//       height: calc(100% - 119px);
+//     }
+//   }
+// }

+ 1 - 0
src/pages/Fstorehouse/F1inStorage/index.tsx

@@ -92,6 +92,7 @@ function F1inStorage() {
         rightBtnWidth={340}
         yHeight={585}
         searchDom={SEARCH_DOM}
+        leftRowWidth='20%'
         storyTableListToprr={({ clickSearch, resetSelectFu }) => (
           <>
             <Button type='primary' ghost onClick={() => tableBtnFu(null, '1')}>

+ 1 - 1
src/pages/Fstorehouse/F2moveStorage/F2edit/index.tsx

@@ -192,7 +192,7 @@ function F2editContent() {
             ['txtCTag', '藏品标签', 'tagDictId'],
             ['txt', '藏品名称', 'name'],
             ['select', '级别', 'level', selectObj['藏品级别']],
-            ['txtC', '类别', 'typeDictId'],
+            ['txtCTag', '文化标签', 'artDictId', '文创'],
             ['txtC', '年代', 'ageDictId'],
             ['txtC', '质地', 'textureDictId'],
             ['select', '完残程度', 'tornLevel', selectObj['完残程度']],

+ 1 - 0
src/pages/Fstorehouse/F2moveStorage/index.tsx

@@ -91,6 +91,7 @@ function F2moveStorage() {
         tableInfo={tableInfo}
         columnsTemp={moveStorageTableC}
         rightBtnWidth={340}
+        leftRowWidth='20%'
         yHeight={585}
         searchDom={SEARCH_DOM}
         storyTableListToprr={({ clickSearch, resetSelectFu }) => (

+ 1 - 1
src/pages/Fstorehouse/F3outStorage/F3edit/index.tsx

@@ -131,7 +131,7 @@ function F3editContent() {
             ['txtCTag', '藏品标签', 'tagDictId'],
             ['txt', '藏品名称', 'name'],
             ['select', '级别', 'level', selectObj['藏品级别']],
-            ['txtC', '类别', 'typeDictId'],
+            ['txtCTag', '文化标签', 'artDictId', '文创'],
             ['txtC', '年代', 'ageDictId'],
             ['txtC', '质地', 'textureDictId'],
             ['select', '完残程度', 'tornLevel', selectObj['完残程度']],

+ 1 - 0
src/pages/Fstorehouse/F3outStorage/index.tsx

@@ -60,6 +60,7 @@ function F3outStorage() {
         columnsTemp={outStorageTableC}
         rightBtnWidth={340}
         yHeight={585}
+        leftRowWidth='20%'
         searchDom={[
           {
             type: 'time',

+ 1 - 1
src/pages/Fstorehouse/F4check/F4edit/index.tsx

@@ -192,7 +192,7 @@ function F1editContent() {
             ['txtCTag', '藏品标签', 'tagDictId'],
             ['txt', '藏品名称', 'name'],
             ['select', '级别', 'level', selectObj['藏品级别']],
-            ['txtC', '类别', 'typeDictId'],
+            ['txtCTag', '文化标签', 'artDictId', '文创'],
             ['txtC', '年代', 'ageDictId'],
             ['txtC', '质地', 'textureDictId'],
             ['select', '完残程度', 'tornLevel', selectObj['完残程度']],

+ 1 - 0
src/pages/Fstorehouse/F4check/index.tsx

@@ -60,6 +60,7 @@ function F4check() {
         columnsTemp={checkTableC}
         rightBtnWidth={340}
         yHeight={585}
+        leftRowWidth='20%'
         searchDom={[
           {
             type: 'time',

+ 1 - 0
src/pages/Fstorehouse/F5staff/index.tsx

@@ -84,6 +84,7 @@ function F5staff() {
       <div className='pageTitle'>人员出入库</div>
 
       <TableList
+        leftRowWidth='20%'
         ref={tableListRef}
         baseFormData={F5baseFormData}
         getListAPI={F5_APIgetList}

+ 66 - 29
src/pages/Hexhibits/H1loan/H1detail/index.tsx

@@ -19,8 +19,10 @@ import dayjs from 'dayjs'
 import { baseURL } from '@/utils/http'
 import { FileListType } from '@/components/Z3upFiles/data'
 import MyTable from '@/components/MyTable'
-import { getDictFu, selectObj } from '@/utils/dataChange'
+import { selectObj } from '@/utils/dataChange'
 import { showGoodTableC } from '@/utils/tableData'
+import store from '@/store'
+import { tagApiArr } from '@/pages/ZgoodsInfo/data'
 
 type DetailInfo = {
   id?: number
@@ -140,9 +142,10 @@ function H1detail() {
     searchKey: '',
     searchTagName: '',
     level: undefined as string | undefined,
-    typeDictId: undefined as (string | number)[] | undefined,
     region: undefined as string | undefined,
-    status: undefined as number | undefined
+    status: undefined as number | undefined,
+    subTagIds: '',
+    subArtDictIds: ''
   })
   const goodFormDataRef = useRef(goodFormData)
   useEffect(() => {
@@ -159,9 +162,17 @@ function H1detail() {
       ...fd,
       showId: info.id
     }
-    if (Array.isArray(fd.typeDictId) && fd.typeDictId.length) {
-      params.typeDictId = fd.typeDictId[fd.typeDictId.length - 1]
-    }
+
+    // 针对 多个标签的数据处理
+    tagApiArr.forEach(v => {
+      if (params[v] && typeof params[v] === 'string') {
+        params[v] = params[v]
+          .replaceAll(';', ',')
+          .split(',')
+          .map((v: any) => Number(v))
+      }
+    })
+
     const res = await H1_APIgetShowGoodPage(params)
     if (res?.code === 0) {
       setGoodList(res.data?.records || [])
@@ -185,9 +196,10 @@ function H1detail() {
       searchKey: '',
       searchTagName: '',
       level: undefined,
-      typeDictId: undefined,
       region: undefined,
-      status: undefined
+      status: undefined,
+      subTagIds: '',
+      subArtDictIds: ''
     })
     setTimeout(() => setGoodTimeKey(Date.now()), 50)
   }, [])
@@ -259,15 +271,6 @@ function H1detail() {
     return arr.map(v => ({ label: v, value: v }))
   }, [info.region])
 
-  const typeDictOptions = useMemo(() => {
-    // 待完善sg
-    try {
-      return getDictFu('藏品类别') || []
-    } catch {
-      return []
-    }
-  }, [])
-
   return (
     <div className={styles.H1detail}>
       <div className='H1detailMain'>
@@ -354,12 +357,30 @@ function H1detail() {
             allowClear
             style={{ width: 250 }}
           />
-          <Input
-            placeholder='搜索藏品标签'
-            value={goodFormData.searchTagName}
-            onChange={e => setGoodFormData(d => ({ ...d, searchTagName: e.target.value }))}
-            allowClear
-            style={{ width: 200 }}
+          <Cascader
+            changeOnSelect
+            options={store.getState().E1tag.treeData}
+            placeholder='藏品标签'
+            fieldNames={{ label: 'name', value: 'id', children: 'children' }}
+            allowClear={true}
+            showSearch={true}
+            value={
+              goodFormData.subTagIds
+                ? goodFormData.subTagIds.split(';').map((item: string) => item.split(','))
+                : []
+            }
+            onChange={e => {
+              const seLectArr: any = e || []
+              let temp = ''
+              if (seLectArr.length) {
+                seLectArr.forEach((v: string[], i: number) => {
+                  temp += v.join(',') + (i === seLectArr.length - 1 ? '' : ';')
+                })
+              }
+              setGoodFormData({ ...goodFormData, subTagIds: temp })
+            }}
+            multiple
+            maxTagCount='responsive'
           />
           <Select
             placeholder='级别'
@@ -370,13 +391,29 @@ function H1detail() {
             style={{ width: 120 }}
           />
           <Cascader
-            placeholder='类别'
-            allowClear
-            value={goodFormData.typeDictId}
-            onChange={(v: any) => setGoodFormData(d => ({ ...d, typeDictId: v }))}
-            options={typeDictOptions}
+            changeOnSelect
+            options={store.getState().E3label.treeData}
+            placeholder='文化标签'
             fieldNames={{ label: 'name', value: 'id', children: 'children' }}
-            style={{ width: 160 }}
+            allowClear={true}
+            showSearch={true}
+            value={
+              goodFormData.subArtDictIds
+                ? goodFormData.subArtDictIds.split(';').map((item: string) => item.split(','))
+                : []
+            }
+            onChange={e => {
+              const seLectArr: any = e || []
+              let temp = ''
+              if (seLectArr.length) {
+                seLectArr.forEach((v: string[], i: number) => {
+                  temp += v.join(',') + (i === seLectArr.length - 1 ? '' : ';')
+                })
+              }
+              setGoodFormData({ ...goodFormData, subArtDictIds: temp })
+            }}
+            multiple
+            maxTagCount='responsive'
           />
           <Select
             placeholder='展区'

+ 1 - 1
src/pages/Layout/data.ts

@@ -185,7 +185,7 @@ const tabLeftArr: RouterType = [
       },
       {
         id: 603,
-        name: '文标签',
+        name: '文标签',
         path: '/label',
         Com: React.lazy(() => import('../Eculture/E3label'))
       }

+ 4 - 3
src/pages/ZgoodsInfo/data.ts

@@ -4,6 +4,9 @@ import { myTableTransferSize, resJiLianFu } from '@/utils/dataChange'
 
 const isNull = '(空)'
 
+// 多个标签发请求改变数据结果 //藏品标签   文化标签
+export const tagApiArr = ['subTagIds', 'subArtDictIds']
+
 export const GIrowArr = [
   { key: 'num', name: '藏品登记号' },
   { key: 'oldName', name: '藏品原名' },
@@ -14,8 +17,6 @@ export const GIrowArr = [
   },
   { key: 'makeUser', name: '制档人' },
   { key: 'level', name: '藏品级别' },
-  // // 待完善sg
-  // { key: 'typeDictId', name: '藏品类别', resFu: (info: GoodsType) => resJiLianFu(info.typeDictId) },
   { key: 'ageDictId', name: '藏品年代', resFu: (info: GoodsType) => resJiLianFu(info.ageDictId) },
   { key: 'ageInfo', name: '具体年代' },
   {
@@ -34,7 +35,7 @@ export const GIrowArr = [
   },
   { key: 'tornLevel', name: '完残程度' },
   { key: 'tornInfo', name: '完残状况' },
-  { key: 'keep', name: '保存状态', full: true },
+  { key: 'keep', name: '保存状态' },
   { key: 'keepInfo', name: '保护修复情况', full: true },
   {
     key: ['sizeL', 'sizeW', 'sizeH'],

+ 6 - 6
src/pages/Zother/AddGoods/index.tsx

@@ -89,7 +89,7 @@ function AddGoods({
         if (!obj[v]) obj[v] = null
       })
 
-      // 处理文标签
+      // 处理文标签
       if (obj.artDictId) {
         const artDictId = obj.artDictId.split(';').map((item: string) => item.split(','))
         obj.artDictId = artDictId
@@ -149,8 +149,8 @@ function AddGoods({
       // 2个日期的格式处理
       let makeDate = ''
       if (values.makeDate) makeDate = dayjs(values.makeDate).format('YYYY-MM-DD')
-      let inGoodYear = ''
-      if (values.inGoodYear) inGoodYear = dayjs(values.inGoodYear).format('YYYY')
+      let inGoodYear: any = ''
+      if (values.inGoodYear) inGoodYear = Number(dayjs(values.inGoodYear).format('YYYY'))
 
       const obj = {
         ...values,
@@ -172,7 +172,7 @@ function AddGoods({
         if (values[v]) obj[v] = values[v].join(',')
       })
 
-      // 文标签-级联多选特殊处理
+      // 文标签-级联多选特殊处理
       let artDictId = ''
       if (obj.artDictId.length) {
         obj.artDictId.forEach((v: string[], i: number) => {
@@ -198,7 +198,7 @@ function AddGoods({
         if (oldInfoObj.makeDate)
           oldInfoObj.makeDate = dayjs(oldInfoObj.makeDate).format('YYYY-MM-DD')
         if (oldInfoObj.inGoodYear)
-          oldInfoObj.inGoodYear = dayjs(oldInfoObj.inGoodYear).format('YYYY')
+          oldInfoObj.inGoodYear = Number(dayjs(values.inGoodYear).format('YYYY'))
 
         const keyArr: string[] = []
 
@@ -290,7 +290,7 @@ function AddGoods({
               <Input placeholder='请输入' showCount maxLength={30} />
             </Form.Item>
 
-            <Form.Item label='文标签' name='artDictId'>
+            <Form.Item label='文标签' name='artDictId'>
               <Cascader
                 changeOnSelect
                 options={E3tree}

+ 39 - 1
src/pages/Zother/SelectGoods/index.tsx

@@ -8,6 +8,7 @@ import MyTable from '@/components/MyTable'
 import MyPopconfirm from '@/components/MyPopconfirm'
 import AddClues from '../AddClues'
 import { FileUpInfoType } from '../data'
+import { tagApiArr } from '@/pages/ZgoodsInfo/data'
 
 type Props = {
   API_getList: any
@@ -48,10 +49,11 @@ function SelectGoods({
 
   // 点击搜索
   const clickSearch = useCallback(() => {
+    setFormData({ ...formData, pageNum: 1 })
     setTimeout(() => {
       setTimeKey(Date.now())
     }, 50)
-  }, [])
+  }, [formData])
 
   // 点击重置
   const resetSelectFu = useCallback(() => {
@@ -73,6 +75,16 @@ function SelectGoods({
       ...canObjTemp
     }
 
+    // 针对 多个标签的数据处理
+    tagApiArr.forEach(v => {
+      if (obj[v] && typeof obj[v] === 'string') {
+        obj[v] = obj[v]
+          .replaceAll(';', ',')
+          .split(',')
+          .map((v: any) => Number(v))
+      }
+    })
+
     // 第一次进来,获取到所有数据
     if (timeKey === 0) obj.pageSize = 99999
 
@@ -209,6 +221,32 @@ function SelectGoods({
                 value={formData[item.key] ? formData[item.key].split(',') : []}
                 onChange={e => setFormData({ ...formData, [item.key]: e ? e.join(',') : '' })}
               />
+            ) : item.type === 'CascaderSS' ? (
+              <Cascader
+                changeOnSelect
+                options={item.options}
+                placeholder={item.name}
+                fieldNames={{ label: 'name', value: 'id', children: 'children' }}
+                allowClear={!item.must}
+                showSearch={true}
+                value={
+                  formData[item.key]
+                    ? formData[item.key].split(';').map((item: string) => item.split(','))
+                    : []
+                }
+                onChange={e => {
+                  const seLectArr: any = e || []
+                  let temp = ''
+                  if (seLectArr.length) {
+                    seLectArr.forEach((v: string[], i: number) => {
+                      temp += v.join(',') + (i === seLectArr.length - 1 ? '' : ';')
+                    })
+                  }
+                  setFormData({ ...formData, [item.key]: temp })
+                }}
+                multiple
+                maxTagCount='responsive'
+              />
             ) : null}
           </div>
         )

+ 20 - 22
src/pages/Zother/SonGoodsList/data.ts

@@ -55,7 +55,7 @@ export type GoodsType = {
   thumbPc: string
   tornInfo: string
   tornLevel: string
-  typeDictId: string
+  subTagIds: string
   updateTime: string
 
   // 不用录数据库,新增和编辑 用这个区分
@@ -68,7 +68,7 @@ export type GoodsType = {
   // 库存信息id
   storageId: number
 
-  // 文标签
+  // 文标签
   artDictId: string
 }
 
@@ -78,7 +78,7 @@ export const sgBaseFormData = {
   pageSize: 10,
 
   searchKey: '',
-  typeDictId: '',
+  subTagIds: '',
   ageDictId: '',
   tornLevel: ''
 }
@@ -89,13 +89,12 @@ export const sgTopSelectDom = [
     key: 'searchKey',
     type: 'Input'
   },
-  // 待完善sg
-  // {
-  //   name: '初定类别',
-  //   key: 'typeDictId',
-  //   type: 'Cascader',
-  //   options: getDictFu('藏品类别')
-  // },
+  {
+    name: '初定藏品标签',
+    key: 'subTagIds',
+    type: 'CascaderSS',
+    options: store.getState().E1tag.treeData
+  },
   {
     name: '初定年代',
     key: 'ageDictId',
@@ -116,9 +115,9 @@ export const sgBaseFormDataGood = {
   pageSize: 10,
 
   searchKey: '',
-  tagIds: '',
+  subTagIds: '',
   level: '',
-  typeDictId: '',
+  subArtDictIds: '',
   ageDictId: '',
   textureDictId: '',
   tornLevel: ''
@@ -132,9 +131,9 @@ export const sgTopSelectDomGood = [
     width: 240
   },
   {
-    name: '搜索藏品标签',
-    key: 'tagIds',
-    type: 'Cascader',
+    name: '藏品标签',
+    key: 'subTagIds',
+    type: 'CascaderSS',
     options: store.getState().E1tag.treeData
   },
   {
@@ -143,13 +142,12 @@ export const sgTopSelectDomGood = [
     type: 'Select',
     options: selectObj['藏品级别']
   },
-  // 待完善sg
-  // {
-  //   name: '类别',
-  //   key: 'typeDictId',
-  //   type: 'Cascader',
-  //   options: getDictFu('藏品类别')
-  // },
+  {
+    name: '文化标签',
+    key: 'subArtDictIds',
+    type: 'CascaderSS',
+    options: store.getState().E3label.treeData
+  },
   {
     name: '年代',
     key: 'ageDictId',

+ 40 - 1
src/pages/Zother/TableList/index.tsx

@@ -14,6 +14,7 @@ import { Button, DatePicker, Input, Select, Cascader } from 'antd'
 import { tableListAuditBtnFu } from '@/utils/authority'
 import MyTable from '@/components/MyTable'
 import dayjs from 'dayjs'
+import { tagApiArr } from '@/pages/ZgoodsInfo/data'
 const { RangePicker } = DatePicker
 
 type Props = {
@@ -107,6 +108,16 @@ const TableList = forwardRef<any, Props>(function TableList(props, ref) {
         params[item.key] = params[item.key][params[item.key].length - 1]
       }
     })
+    // 针对 多个标签的数据处理
+    tagApiArr.forEach(v => {
+      if (params[v] && typeof params[v] === 'string') {
+        params[v] = params[v]
+          .replaceAll(';', ',')
+          .split(',')
+          .map((v: any) => Number(v))
+      }
+    })
+
     dispatch(getListAPI(params))
   }, [dispatch, getListAPI, extraParams])
 
@@ -226,13 +237,41 @@ const TableList = forwardRef<any, Props>(function TableList(props, ref) {
                   onChange={e => setFormData({ ...formData, [item.key]: e })}
                   options={item.options}
                 />
+              ) : item.type === 'CascaderSS' ? (
+                <Cascader
+                  changeOnSelect
+                  options={item.options}
+                  placeholder={item.placeholder}
+                  fieldNames={{ label: 'name', value: 'id', children: 'children' }}
+                  allowClear={!item.must}
+                  showSearch={true}
+                  value={
+                    formData[item.key]
+                      ? formData[item.key].split(';').map((item: string) => item.split(','))
+                      : []
+                  }
+                  onChange={e => {
+                    const seLectArr: any = e || []
+                    let temp = ''
+                    if (seLectArr.length) {
+                      seLectArr.forEach((v: string[], i: number) => {
+                        temp += v.join(',') + (i === seLectArr.length - 1 ? '' : ';')
+                      })
+                    }
+                    setFormData({ ...formData, [item.key]: temp })
+                  }}
+                  multiple
+                  maxTagCount='responsive'
+                />
               ) : null}
             </div>
           ))}
         </div>
         <div
           className='TableListToprr'
-          style={{ width: typeof rightBtnWidth === 'string' ? rightBtnWidth : `${rightBtnWidth}px` }}
+          style={{
+            width: typeof rightBtnWidth === 'string' ? rightBtnWidth : `${rightBtnWidth}px`
+          }}
         >
           {storyTableListToprr ? (
             storyTableListToprr({ clickSearch, resetSelectFu })

+ 0 - 1
src/store/action/Cledger/C1ledger.ts

@@ -68,7 +68,6 @@ export const API_getGoodsListAll = () => {
     startTime: '',
     endTime: '',
     status: '',
-    typeDictId: '',
     ageDictId: '',
     textureDictId: ''
   })

+ 1 - 1
src/utils/dataChange.tsx

@@ -201,7 +201,7 @@ export const resJiLianFu = (idTemp: string, type?: 'tag', isNull?: string) => {
   } else return isNull || '(空)'
 }
 
-// 藏品标签回显 、文标签回显
+// 藏品标签回显 、文标签回显
 export function resTagFu(idString: string, type: '藏品' | '文创'): any {
   const dataList =
     type === '藏品' ? store.getState().E1tag.treeData : store.getState().E3label.treeData

+ 1 - 1
src/utils/tableData.ts

@@ -48,7 +48,7 @@ export const goodsSonTableC = (loc?: boolean) => {
     ['txt', '藏品登记号', 'num'],
     ['img', '封面', 'thumb'],
     ['txtCTag', '藏品标签', 'tagDictId', '藏品'],
-    ['txtCTag', '文标签', 'artDictId', '文创'],
+    ['txtCTag', '文标签', 'artDictId', '文创'],
     ['txt', '藏品名称', 'name'],
     ['select', '级别', 'level', selectObj['藏品级别']],
     ['txtC', '年代', 'ageDictId'],