Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wms
Project
Project
Details
Activity
Releases
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
wuhao
wms
Commits
f0ef84bb
Commit
f0ef84bb
authored
Jul 20, 2022
by
左玲玲
😬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
表格联动
parent
b689d175
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
30 additions
and
38 deletions
+30
-38
index.jsx
src/components/EditTable/index.jsx
+3
-14
global.less
src/global.less
+2
-1
fields.js
src/pages/insertstore/Instore/fields.js
+7
-6
index.jsx
src/pages/system/Charactor/index.jsx
+18
-17
No files found.
src/components/EditTable/index.jsx
View file @
f0ef84bb
...
@@ -43,8 +43,6 @@ const EditTable = ({
...
@@ -43,8 +43,6 @@ const EditTable = ({
let
{
urlchangeval
}
=
linkconfig
??
{};
let
{
urlchangeval
}
=
linkconfig
??
{};
let
newvalue
=
[...
recordList
];
let
newvalue
=
[...
recordList
];
if
(
urlchangeval
&&
record
)
{
//根据url 改变 数据值
if
(
urlchangeval
&&
record
)
{
//根据url 改变 数据值
let
{
params
,
database
,
effectresult
}
=
urlchangeval
??
{},
let
{
params
,
database
,
effectresult
}
=
urlchangeval
??
{},
curvaluerow
=
value
&&
value
.
length
>
0
?
value
.
filter
(
it
=>
it
[
rowKey
]
==
record
[
rowKey
])[
0
]
:
{}
curvaluerow
=
value
&&
value
.
length
>
0
?
value
.
filter
(
it
=>
it
[
rowKey
]
==
record
[
rowKey
])[
0
]
:
{}
...
@@ -54,7 +52,9 @@ const EditTable = ({
...
@@ -54,7 +52,9 @@ const EditTable = ({
if
(
it
[
rowKey
]
==
record
[
rowKey
])
{
if
(
it
[
rowKey
]
==
record
[
rowKey
])
{
let
freshvals
=
{}
let
freshvals
=
{}
Object
.
keys
(
effectresult
).
map
(
its
=>
{
Object
.
keys
(
effectresult
).
map
(
its
=>
{
freshvals
[
its
]
=
value
[
i
][
its
]
// freshvals[its] = value[i][its];
freshvals
[
its
]
=
it
[
its
];
})
})
it
=
{
it
=
{
...
record
,
...
record
,
...
@@ -97,18 +97,7 @@ const EditTable = ({
...
@@ -97,18 +97,7 @@ const EditTable = ({
};
};
}
}
onChange
(
newvalue
);
onChange
(
newvalue
);
},
},
}
}
}
}
maxLength=
{
maxLength
??
1000
}
maxLength=
{
maxLength
??
1000
}
...
...
src/global.less
View file @
f0ef84bb
...
@@ -338,7 +338,8 @@ table {
...
@@ -338,7 +338,8 @@ table {
flex:1
flex:1
}
}
}
}
.ant-input-number-affix-wrapper{
.ant-input-number-affix-wrapper,
.ant-input-number{
width: 100% !important;
width: 100% !important;
}
}
...
...
src/pages/insertstore/Instore/fields.js
View file @
f0ef84bb
...
@@ -61,7 +61,8 @@ const EditUpload = ({ record, fid, storeId }) => {
...
@@ -61,7 +61,8 @@ const EditUpload = ({ record, fid, storeId }) => {
search
:
false
,
search
:
false
,
editable
:
(
text
,
record
,
index
)
=>
{
editable
:
(
text
,
record
,
index
)
=>
{
return
!
record
.
materieOutstoreDetailId
return
!
record
.
materieOutstoreDetailId
}
},
valueType
:
"digit"
},
},
{
{
title
:
"备注"
,
title
:
"备注"
,
...
@@ -213,12 +214,12 @@ const one = {
...
@@ -213,12 +214,12 @@ const one = {
"title"
:
<
span
>
入库数量
<
b
style
=
{{
color
:
"red"
}}
>*<
/b></
span
>
,
"title"
:
<
span
>
入库数量
<
b
style
=
{{
color
:
"red"
}}
>*<
/b></
span
>
,
"dataIndex"
:
"instroeNum"
,
"dataIndex"
:
"instroeNum"
,
"key"
:
"instroeNum"
,
"key"
:
"instroeNum"
,
valueType
:
"digit"
,
"formItemProps"
:
()
=>
{
"formItemProps"
:
()
=>
{
return
{
return
{
rules
:
[{
required
:
true
,
message
:
'此项为必填项'
}],
rules
:
[{
required
:
true
,
message
:
'此项为必填项'
}],
};
};
},
}
valueType
:
"digit"
},
},
{
{
"title"
:
"单位"
,
"title"
:
"单位"
,
...
@@ -761,7 +762,7 @@ const one = {
...
@@ -761,7 +762,7 @@ const one = {
title
:
"上架数量"
,
title
:
"上架数量"
,
dataIndex
:
"instroeNum"
,
dataIndex
:
"instroeNum"
,
key
:
"instroeNum"
,
key
:
"instroeNum"
,
search
:
false
,
search
:
false
}
}
]}
]}
dataSource
=
{
record
.
uploadList
}
dataSource
=
{
record
.
uploadList
}
...
@@ -847,7 +848,7 @@ const one = {
...
@@ -847,7 +848,7 @@ const one = {
title
:
"上架数量"
,
title
:
"上架数量"
,
dataIndex
:
"instroeNum"
,
dataIndex
:
"instroeNum"
,
key
:
"instroeNum"
,
key
:
"instroeNum"
,
search
:
false
,
search
:
false
}
}
,
,
{
{
...
@@ -955,7 +956,7 @@ const one = {
...
@@ -955,7 +956,7 @@ const one = {
title
:
"入库数量"
,
title
:
"入库数量"
,
dataIndex
:
"instroeNum"
,
dataIndex
:
"instroeNum"
,
key
:
"instroeNum"
,
key
:
"instroeNum"
,
search
:
false
,
search
:
false
},
},
{
{
title
:
"单位"
,
title
:
"单位"
,
...
...
src/pages/system/Charactor/index.jsx
View file @
f0ef84bb
import
React
,
{
useEffect
,
useRef
,
useReducer
}
from
"react"
;
import
React
,
{
useEffect
,
useRef
,
useReducer
}
from
"react"
;
import
{
Modal
,
Button
,
Drawer
,
Dropdown
,
Menu
}
from
"antd"
;
import
{
Modal
,
Button
,
Drawer
,
Dropdown
,
Menu
}
from
"antd"
;
import
AutoTable
from
"@/components/AutoTable"
;
import
AutoTable
from
"@/components/AutoTable"
;
import
Tables
from
"@/components/Tableform"
;
import
getPrem
from
"@/utils/getPrem"
;
//权限判断fn
import
getPrem
from
"@/utils/getPrem"
;
//权限判断fn
import
InitForm
from
"@/components/InitForm"
;
import
InitForm
from
"@/components/InitForm"
;
import
{
useRequest
}
from
"umi"
;
import
{
useRequest
}
from
"umi"
;
...
@@ -154,21 +155,21 @@ const Charactor = (props) => {
...
@@ -154,21 +155,21 @@ const Charactor = (props) => {
dataIndex
:
"departmentName"
,
dataIndex
:
"departmentName"
,
key
:
"departmentName"
,
key
:
"departmentName"
,
},
},
{
//
{
title
:
"负责车间"
,
//
title: "负责车间",
dataIndex
:
"shopNames"
,
//
dataIndex: "shopNames",
key
:
"shopNames"
,
//
key: "shopNames",
},
//
},
{
//
{
title
:
"负责产线"
,
//
title: "负责产线",
dataIndex
:
"productionLines"
,
//
dataIndex: "productionLines",
key
:
"productionLines"
,
//
key: "productionLines",
},
//
},
{
//
{
title
:
"负责工段"
,
//
title: "负责工段",
dataIndex
:
"sectionNames"
,
//
dataIndex: "sectionNames",
key
:
"sectionNames"
,
//
key: "sectionNames",
},
//
},
];
];
function
extraAction
(
text
,
record
,
_
,
action
)
{
function
extraAction
(
text
,
record
,
_
,
action
)
{
...
@@ -290,11 +291,11 @@ const Charactor = (props) => {
...
@@ -290,11 +291,11 @@ const Charactor = (props) => {
treeType=
{
iftype
.
val
}
treeType=
{
iftype
.
val
}
/>
/>
)
:
iftype
.
val
==
"staff"
?
(
)
:
iftype
.
val
==
"staff"
?
(
<
AutoTable
<
Tables
columns=
{
columnsc
}
columns=
{
columnsc
}
extraparams=
{
{
roleId
:
curitem
.
id
}
}
extraparams=
{
{
roleId
:
curitem
.
id
}
}
path=
"/ngic-auth/sysUser/query/pageByRoleId"
path=
"/ngic-auth/sysUser/query/pageByRoleId"
></
AutoTable
>
></
Tables
>
)
:
(
)
:
(
<></>
<></>
)
}
)
}
...
...
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