Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
WebPublic
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
前端开发小组
WebPublic
Commits
dfa4fcf0
提交
dfa4fcf0
authored
4月 27, 2022
作者:
钟是志
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
定位组件增加判断. 是否必填
上级
34905ef7
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
457 行增加
和
398 行删除
+457
-398
index.jsx
one_stop_public/tableCompon/index.jsx
+457
-398
没有找到文件。
one_stop_public/tableCompon/index.jsx
浏览文件 @
dfa4fcf0
...
@@ -81,7 +81,12 @@ const giveRender = (column = {}) => {
...
@@ -81,7 +81,12 @@ const giveRender = (column = {}) => {
return
column
;
return
column
;
};
};
@
connect
(({
DataColumn
,
SqlManageEntity
,
formList
,
loading
})
=>
({
@
connect
(({
DataColumn
,
SqlManageEntity
,
formList
,
loading
,
})
=>
({
DataColumn
,
DataColumn
,
SqlManageEntity
,
SqlManageEntity
,
formList
,
formList
,
...
@@ -186,7 +191,12 @@ export default class tableCom extends Component {
...
@@ -186,7 +191,12 @@ export default class tableCom extends Component {
};
};
getColumnSearchProps
=
(
dataIndex
,
title
)
=>
({
getColumnSearchProps
=
(
dataIndex
,
title
)
=>
({
filterDropdown
:
({
setSelectedKeys
,
selectedKeys
,
confirm
,
clearFilters
})
=>
(
filterDropdown
:
({
setSelectedKeys
,
selectedKeys
,
confirm
,
clearFilters
,
})
=>
(
<
div
style=
{
{
padding
:
8
}
}
>
<
div
style=
{
{
padding
:
8
}
}
>
<
Input
<
Input
ref=
{
node
=>
{
ref=
{
node
=>
{
...
@@ -203,11 +213,11 @@ export default class tableCom extends Component {
...
@@ -203,11 +213,11 @@ export default class tableCom extends Component {
}
}
}
}
/>
/>
<
Button
<
Button
type=
"primary"
type=
'primary'
onClick=
{
()
=>
this
.
handleSearch
(
selectedKeys
,
confirm
)
}
onClick=
{
()
=>
this
.
handleSearch
(
selectedKeys
,
confirm
)
}
icon=
"search"
icon=
'search'
loading=
{
this
.
props
.
loading
}
loading=
{
this
.
props
.
loading
}
size=
"small"
size=
'small'
style=
{
{
style=
{
{
width
:
90
,
width
:
90
,
marginRight
:
8
,
marginRight
:
8
,
...
@@ -218,20 +228,20 @@ export default class tableCom extends Component {
...
@@ -218,20 +228,20 @@ export default class tableCom extends Component {
<
Button
<
Button
loading=
{
this
.
props
.
loading
}
loading=
{
this
.
props
.
loading
}
onClick=
{
()
=>
this
.
handleReset
(
clearFilters
)
}
onClick=
{
()
=>
this
.
handleReset
(
clearFilters
)
}
size=
"small"
size=
'small'
style=
{
{
width
:
90
}
}
style=
{
{
width
:
90
}
}
>
>
重置
重置
</
Button
>
</
Button
>
</
div
>
</
div
>
),
),
filterIcon
:
filtered
=>
<
Icon
type=
"search"
style=
{
{
color
:
filtered
?
'#1890ff'
:
'red'
}
}
/>,
filterIcon
:
filtered
=>
<
Icon
type=
'search'
style=
{
{
color
:
filtered
?
'#1890ff'
:
'red'
}
}
/>,
onFilter
:
(
value
,
record
)
=>
onFilter
:
(
value
,
record
)
=>
record
[
dataIndex
]
record
[
dataIndex
]
?
record
[
dataIndex
]
?
record
[
dataIndex
]
.
toString
()
.
toString
()
.
toLowerCase
()
.
toLowerCase
()
.
includes
(
value
.
toLowerCase
())
.
includes
(
value
.
toLowerCase
())
:
''
,
:
''
,
onFilterDropdownVisibleChange
:
visible
=>
{
onFilterDropdownVisibleChange
:
visible
=>
{
if
(
visible
)
{
if
(
visible
)
{
...
@@ -273,7 +283,11 @@ export default class tableCom extends Component {
...
@@ -273,7 +283,11 @@ export default class tableCom extends Component {
};
};
componentWillReceiveProps
(
props
)
{
componentWillReceiveProps
(
props
)
{
const
{
json
,
mapData
,
obj
}
=
props
;
const
{
json
,
mapData
,
obj
,
}
=
props
;
if
(
json
==
null
||
this
.
props
.
safe
)
{
if
(
json
==
null
||
this
.
props
.
safe
)
{
return
;
return
;
}
}
...
@@ -331,7 +345,7 @@ export default class tableCom extends Component {
...
@@ -331,7 +345,7 @@ export default class tableCom extends Component {
console
.
log
(
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:存在循环风险,1秒内执行超过10次,现已停止执行,请检查,`
,
1
}
列:存在循环风险,1秒内执行超过10次,现已停止执行,请检查,`
,
);
);
return
;
return
;
...
@@ -353,9 +367,9 @@ export default class tableCom extends Component {
...
@@ -353,9 +367,9 @@ export default class tableCom extends Component {
this
.
props
.
fatherCode
!=
null
this
.
props
.
fatherCode
!=
null
?
bindObj
?
bindObj
?
{
?
{
...
bindObj
,
...
bindObj
,
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
bindObj
.
base52
}
`
,
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
bindObj
.
base52
}
`
,
}
}
:
{
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
this
.
props
.
uuid
}
`
}
:
{
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
this
.
props
.
uuid
}
`
}
:
bindObj
;
:
bindObj
;
if
(
this
.
props
.
fatherCode
==
null
&&
dataColumn
==
null
)
{
if
(
this
.
props
.
fatherCode
==
null
&&
dataColumn
==
null
)
{
...
@@ -391,7 +405,10 @@ export default class tableCom extends Component {
...
@@ -391,7 +405,10 @@ export default class tableCom extends Component {
allValues
=
JSON
.
stringify
(
allValues
);
allValues
=
JSON
.
stringify
(
allValues
);
if
(
json
.
comName
===
'TableSelect'
)
{
if
(
json
.
comName
===
'TableSelect'
)
{
const
{
dispatch
}
=
this
.
props
;
const
{
dispatch
}
=
this
.
props
;
const
{
sqlKey
,
optionType
}
=
json
;
const
{
sqlKey
,
optionType
,
}
=
json
;
if
(
optionType
===
'sql'
)
{
if
(
optionType
===
'sql'
)
{
dispatch
({
dispatch
({
type
:
'SqlManageEntity/find'
,
type
:
'SqlManageEntity/find'
,
...
@@ -413,7 +430,8 @@ export default class tableCom extends Component {
...
@@ -413,7 +430,8 @@ export default class tableCom extends Component {
if
(
if
(
[
'DATE'
,
'DATETIME'
,
'TIME'
,
'TIMESTAMP'
,
'YEAR'
].
includes
(
datas
[
i
].
type
)
[
'DATE'
,
'DATETIME'
,
'TIME'
,
'TIMESTAMP'
,
'YEAR'
].
includes
(
datas
[
i
].
type
)
)
{
)
{
column
.
render
=
val
=>
moment
(
val
).
format
(
'YYYY-MM-DD HH:mm:ss'
);
column
.
render
=
val
=>
moment
(
val
)
.
format
(
'YYYY-MM-DD HH:mm:ss'
);
}
}
column
=
giveRender
(
column
);
column
=
giveRender
(
column
);
...
@@ -450,7 +468,8 @@ export default class tableCom extends Component {
...
@@ -450,7 +468,8 @@ export default class tableCom extends Component {
break
;
break
;
}
}
column
.
render
=
val
=>
moment
(
parseInt
(
val
)).
format
(
ff
);
column
.
render
=
val
=>
moment
(
parseInt
(
val
))
.
format
(
ff
);
}
}
if
(
cll
[
k
].
isQuery
)
{
if
(
cll
[
k
].
isQuery
)
{
column
=
{
column
=
{
...
@@ -497,7 +516,8 @@ export default class tableCom extends Component {
...
@@ -497,7 +516,8 @@ export default class tableCom extends Component {
column
.
title
=
datas
[
i
].
title
;
column
.
title
=
datas
[
i
].
title
;
column
.
dataIndex
=
datas
[
i
].
name
;
column
.
dataIndex
=
datas
[
i
].
name
;
if
([
'DATE'
,
'DATETIME'
,
'TIME'
,
'TIMESTAMP'
,
'YEAR'
].
includes
(
datas
[
i
].
type
))
{
if
([
'DATE'
,
'DATETIME'
,
'TIME'
,
'TIMESTAMP'
,
'YEAR'
].
includes
(
datas
[
i
].
type
))
{
column
.
render
=
val
=>
moment
(
val
).
format
(
'YYYY-MM-DD HH:mm:ss'
);
column
.
render
=
val
=>
moment
(
val
)
.
format
(
'YYYY-MM-DD HH:mm:ss'
);
}
}
column
=
giveRender
(
column
);
column
=
giveRender
(
column
);
columns
.
push
(
column
);
columns
.
push
(
column
);
...
@@ -636,7 +656,7 @@ export default class tableCom extends Component {
...
@@ -636,7 +656,7 @@ export default class tableCom extends Component {
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
e
,
e
,
);
);
}
}
...
@@ -730,7 +750,7 @@ export default class tableCom extends Component {
...
@@ -730,7 +750,7 @@ export default class tableCom extends Component {
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
console
.
log
(
`页面
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
`页面
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
1
}
列:公式配置有误,回调函数内部错误,`
,
e
,
e
,
);
);
}
}
...
@@ -764,78 +784,79 @@ export default class tableCom extends Component {
...
@@ -764,78 +784,79 @@ export default class tableCom extends Component {
data
:
requestParams
,
data
:
requestParams
,
method
:
method
,
method
:
method
,
requestType
:
'form'
,
requestType
:
'form'
,
}).
then
(
data
=>
{
})
// if (!data || !Array.isArray(data)) {
.
then
(
data
=>
{
// data = [];
// if (!data || !Array.isArray(data)) {
// }
// data = [];
const
{
reqUrls
}
=
this
.
state
;
// }
if
(
reqUrls
&&
reqUrls
[
url
])
{
const
{
reqUrls
}
=
this
.
state
;
reqUrls
[
url
].
data
=
data
;
if
(
reqUrls
&&
reqUrls
[
url
])
{
}
reqUrls
[
url
].
data
=
data
;
this
.
setState
(
}
{
this
.
setState
(
res
:
data
,
{
reqUrls
,
res
:
data
,
},
reqUrls
,
()
=>
{
},
if
(
callback
)
{
()
=>
{
if
(
json
.
optionType
&&
json
.
optionType
==
'func'
)
{
if
(
callback
)
{
const
res
=
callback
(
data
);
if
(
json
.
optionType
&&
json
.
optionType
==
'func'
)
{
if
(
res
!=
null
&&
!
(
typeof
res
===
'function'
))
{
const
res
=
callback
(
data
);
this
.
setState
(
if
(
res
!=
null
&&
!
(
typeof
res
===
'function'
))
{
{
this
.
setState
(
options
:
res
,
{
selectDis
:
false
,
options
:
res
,
},
selectDis
:
false
,
()
=>
{
},
if
(
orgCallback
)
orgCallback
();
()
=>
{
},
if
(
orgCallback
)
orgCallback
();
);
},
}
);
}
else
if
(
json
.
comName
==
'Button'
)
{
try
{
callback
(
data
);
}
catch
(
e
)
{
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
e
,
);
}
}
else
if
([
'Echart'
,
'QRCode'
,
'Graph'
].
includes
(
json
.
comName
))
{
try
{
const
x
=
callback
(
data
);
if
(
x
!=
null
)
{
this
.
setState
({
option
:
x
});
}
}
}
catch
(
e
)
{
}
else
if
(
json
.
comName
==
'Button'
)
{
console
.
log
(
try
{
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
callback
(
data
);
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
}
catch
(
e
)
{
e
,
console
.
log
(
);
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
}
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
}
else
{
e
,
if
(
base52
)
{
);
}
}
else
if
([
'Echart'
,
'QRCode'
,
'Graph'
].
includes
(
json
.
comName
))
{
try
{
try
{
const
x
=
callback
(
data
);
const
x
=
callback
(
data
);
// console.log(x, '757');
if
(
x
!=
null
)
{
if
(
x
==
null
||
x
!=
'NaN'
)
this
.
props
.
form
.
setFieldsValue
({
[
base52
]:
x
});
this
.
setState
({
option
:
x
});
}
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
json
.
comName
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
e
,
e
,
);
);
}
}
}
else
{
if
(
base52
)
{
try
{
const
x
=
callback
(
data
);
// console.log(x, '757');
if
(
x
==
null
||
x
!=
'NaN'
)
this
.
props
.
form
.
setFieldsValue
({
[
base52
]:
x
});
}
catch
(
e
)
{
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
e
,
);
}
}
}
}
}
}
}
},
},
);
);
});
});
return
'norefeshxxxxxxxxxxxxxxxxxxxx'
;
return
'norefeshxxxxxxxxxxxxxxxxxxxx'
;
};
};
...
@@ -955,62 +976,50 @@ export default class tableCom extends Component {
...
@@ -955,62 +976,50 @@ export default class tableCom extends Component {
if
(
getToken
()
!=
null
)
{
if
(
getToken
()
!=
null
)
{
pp
.
token
=
getToken
();
pp
.
token
=
getToken
();
}
}
uaaRequest
(
url
,
pp
).
then
(
data
=>
{
uaaRequest
(
url
,
pp
)
const
{
sqlKeys
}
=
this
.
state
;
.
then
(
data
=>
{
sqlKeys
[
sqlKey
].
data
=
data
;
const
{
sqlKeys
}
=
this
.
state
;
this
.
setState
({
sqlKeys
});
sqlKeys
[
sqlKey
].
data
=
data
;
if
(
data
==
null
)
{
this
.
setState
({
sqlKeys
});
return
;
if
(
data
==
null
)
{
}
return
;
}
if
(
callback
)
{
if
(
callback
)
{
if
(
json
.
optionType
&&
json
.
optionType
===
'func'
)
{
if
(
json
.
optionType
&&
json
.
optionType
===
'func'
)
{
const
res
=
callback
(
data
);
const
res
=
callback
(
data
);
if
(
res
!=
null
&&
!
(
typeof
res
===
'function'
))
{
if
(
res
!=
null
&&
!
(
typeof
res
===
'function'
))
{
this
.
setState
(
this
.
setState
(
{
{
options
:
res
,
options
:
res
,
selectDis
:
false
,
selectDis
:
false
,
},
},
()
=>
{
()
=>
{
if
(
orgCallback
)
orgCallback
();
if
(
orgCallback
)
orgCallback
();
},
},
);
);
}
}
else
if
(
json
.
comName
==
'Button'
)
{
try
{
callback
(
data
);
}
catch
(
e
)
{
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
e
,
);
}
}
else
if
(
json
.
comName
==
'Echart'
||
json
.
comName
==
'QRCode'
||
json
.
comName
==
'Graph'
)
{
try
{
const
x
=
callback
(
data
);
if
(
x
!=
null
)
{
this
.
setState
({
option
:
x
});
}
}
}
catch
(
e
)
{
}
else
if
(
json
.
comName
==
'Button'
)
{
console
.
log
(
try
{
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
callback
(
data
);
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
}
catch
(
e
)
{
e
,
console
.
log
(
);
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
}
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
}
else
{
e
,
if
(
base52
)
{
);
}
}
else
if
(
json
.
comName
==
'Echart'
||
json
.
comName
==
'QRCode'
||
json
.
comName
==
'Graph'
)
{
try
{
try
{
const
x
=
callback
(
data
);
const
x
=
callback
(
data
);
// console.log(x, 938);
if
(
x
!=
null
)
{
if
(
x
==
null
||
x
!=
'NaN'
)
this
.
props
.
form
.
setFieldsValue
({
[
base52
]:
x
});
this
.
setState
({
option
:
x
});
}
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
...
@@ -1018,10 +1027,23 @@ export default class tableCom extends Component {
...
@@ -1018,10 +1027,23 @@ export default class tableCom extends Component {
e
,
e
,
);
);
}
}
}
else
{
if
(
base52
)
{
try
{
const
x
=
callback
(
data
);
// console.log(x, 938);
if
(
x
==
null
||
x
!=
'NaN'
)
this
.
props
.
form
.
setFieldsValue
({
[
base52
]:
x
});
}
catch
(
e
)
{
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,回调函数内部错误,`
,
e
,
);
}
}
}
}
}
}
}
});
});
});
});
return
'norefeshxxxxxxxxxxxxxxxxxxxx'
;
return
'norefeshxxxxxxxxxxxxxxxxxxxx'
;
...
@@ -1151,14 +1173,19 @@ export default class tableCom extends Component {
...
@@ -1151,14 +1173,19 @@ export default class tableCom extends Component {
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
console
.
log
(
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
`页面
${
this
.
props
.
currentFormTitle
}
${
this
.
props
.
formKey
}
${
json
.
comName
}
第
${
this
.
props
.
i
+
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,暂存失败,`
,
1
}
行,第
${
this
.
props
.
j
+
1
}
列:公式配置有误,暂存失败,`
,
e
,
e
,
);
);
}
}
};
};
componentDidMount
()
{
componentDidMount
()
{
const
{
json
,
mapData
,
obj
,
init
}
=
this
.
props
;
const
{
json
,
mapData
,
obj
,
init
,
}
=
this
.
props
;
if
(
json
==
null
)
{
if
(
json
==
null
)
{
return
;
return
;
}
}
...
@@ -1179,9 +1206,9 @@ export default class tableCom extends Component {
...
@@ -1179,9 +1206,9 @@ export default class tableCom extends Component {
this
.
props
.
fatherCode
!=
null
this
.
props
.
fatherCode
!=
null
?
bindObj
?
bindObj
?
{
?
{
...
bindObj
,
...
bindObj
,
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
bindObj
.
base52
}
`
,
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
bindObj
.
base52
}
`
,
}
}
:
{
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
this
.
props
.
uuid
}
`
}
:
{
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
this
.
props
.
uuid
}
`
}
:
bindObj
;
:
bindObj
;
if
(
this
.
props
.
fatherCode
==
null
&&
dataColumn
==
null
)
{
if
(
this
.
props
.
fatherCode
==
null
&&
dataColumn
==
null
)
{
...
@@ -1406,7 +1433,10 @@ export default class tableCom extends Component {
...
@@ -1406,7 +1433,10 @@ export default class tableCom extends Component {
}
}
};
};
getColumn
=
key
=>
{
getColumn
=
key
=>
{
let
{
mapData
,
json
}
=
this
.
props
;
let
{
mapData
,
json
,
}
=
this
.
props
;
const
columnIds
=
json
.
columnIds
;
const
columnIds
=
json
.
columnIds
;
...
@@ -1449,8 +1479,20 @@ export default class tableCom extends Component {
...
@@ -1449,8 +1479,20 @@ export default class tableCom extends Component {
getCellValue
,
getCellValue
,
}
=
this
.
props
;
}
=
this
.
props
;
// console.log(this.props.datas);
// console.log(this.props.datas);
const
{
options
,
labels
,
selectDis
,
modalCode
,
modalTitle
,
modalInit
,
modalProps
}
=
this
.
state
;
const
{
const
{
getFieldDecorator
,
getFieldError
,
getFieldProps
}
=
this
.
props
.
form
;
options
,
labels
,
selectDis
,
modalCode
,
modalTitle
,
modalInit
,
modalProps
,
}
=
this
.
state
;
const
{
getFieldDecorator
,
getFieldError
,
getFieldProps
,
}
=
this
.
props
.
form
;
const
disabled
=
json
!=
null
?
json
.
disabled
:
false
;
const
disabled
=
json
!=
null
?
json
.
disabled
:
false
;
const
permRank
=
json
!=
null
?
(
json
.
permRank
!=
null
?
json
.
permRank
:
0
)
:
0
;
const
permRank
=
json
!=
null
?
(
json
.
permRank
!=
null
?
json
.
permRank
:
0
)
:
0
;
if
(
json
?.
label
===
'账号'
)
{
if
(
json
?.
label
===
'账号'
)
{
...
@@ -1504,7 +1546,7 @@ export default class tableCom extends Component {
...
@@ -1504,7 +1546,7 @@ export default class tableCom extends Component {
<>
<>
{
this
.
props
.
form
.
getFieldDecorator
(
this
.
props
.
uuid
,
{
{
this
.
props
.
form
.
getFieldDecorator
(
this
.
props
.
uuid
,
{
initialValue
:
fk
,
initialValue
:
fk
,
})(<
Input
type=
"hidden"
/>)
}{
' '
}
})(<
Input
type=
'hidden'
/>)
}{
' '
}
<
ZdyTable
<
ZdyTable
taskId=
{
this
.
props
.
taskId
}
taskId=
{
this
.
props
.
taskId
}
importExcel=
{
this
.
props
.
importExcel
}
importExcel=
{
this
.
props
.
importExcel
}
...
@@ -1580,7 +1622,7 @@ export default class tableCom extends Component {
...
@@ -1580,7 +1622,7 @@ export default class tableCom extends Component {
<>
<>
{
this
.
props
.
form
.
getFieldDecorator
(
uid
,
{
{
this
.
props
.
form
.
getFieldDecorator
(
uid
,
{
initialValue
:
obj
[
this
.
props
.
uuid
]
||
json
.
initialValue
,
initialValue
:
obj
[
this
.
props
.
uuid
]
||
json
.
initialValue
,
})(<
Input
type=
"hidden"
/>)
}
})(<
Input
type=
'hidden'
/>)
}
<
span
<
span
style=
{
{
style=
{
{
fontWeight
:
get
===
'mobile'
?
'bold'
:
''
,
fontWeight
:
get
===
'mobile'
?
'bold'
:
''
,
...
@@ -1597,7 +1639,7 @@ export default class tableCom extends Component {
...
@@ -1597,7 +1639,7 @@ export default class tableCom extends Component {
<>
<>
{
this
.
props
.
form
.
getFieldDecorator
(
uid
,
{
{
this
.
props
.
form
.
getFieldDecorator
(
uid
,
{
initialValue
:
this
.
props
.
form
.
getFieldsValue
()[
uid
]
||
json
.
initialValue
,
initialValue
:
this
.
props
.
form
.
getFieldsValue
()[
uid
]
||
json
.
initialValue
,
})(<
Input
type=
"hidden"
/>)
}
})(<
Input
type=
'hidden'
/>)
}
<
span
<
span
style=
{
{
style=
{
{
fontWeight
:
get
===
'mobile'
?
'bold'
:
''
,
fontWeight
:
get
===
'mobile'
?
'bold'
:
''
,
...
@@ -1690,7 +1732,8 @@ export default class tableCom extends Component {
...
@@ -1690,7 +1732,8 @@ export default class tableCom extends Component {
case
'DatePicker'
:
case
'DatePicker'
:
cm
=
value
?
(
cm
=
value
?
(
<
span
>
<
span
>
{
moment
(
parseInt
(
value
)).
format
(
'YYYY-MM-DD HH:mm:ss'
)
}
{
moment
(
parseInt
(
value
))
.
format
(
'YYYY-MM-DD HH:mm:ss'
)
}
{
get
===
'mobile'
?
<
br
/>
:
''
}
{
get
===
'mobile'
?
<
br
/>
:
''
}
</
span
>
</
span
>
)
:
(
)
:
(
...
@@ -1706,7 +1749,7 @@ export default class tableCom extends Component {
...
@@ -1706,7 +1749,7 @@ export default class tableCom extends Component {
{
filesX
.
map
((
f
,
index2
)
=>
{
{
filesX
.
map
((
f
,
index2
)
=>
{
return
(
return
(
<
li
key=
{
index2
}
>
<
li
key=
{
index2
}
>
<
a
target=
"_blank"
key=
{
f
.
path
}
href=
{
queryApiActionPath
()
+
f
.
path
}
>
<
a
target=
'_blank'
key=
{
f
.
path
}
href=
{
queryApiActionPath
()
+
f
.
path
}
>
{
f
.
name
}
{
f
.
name
}
</
a
>
</
a
>
</
li
>
</
li
>
...
@@ -1726,7 +1769,7 @@ export default class tableCom extends Component {
...
@@ -1726,7 +1769,7 @@ export default class tableCom extends Component {
{
files
.
map
((
f
,
index2
)
=>
{
{
files
.
map
((
f
,
index2
)
=>
{
return
(
return
(
<
li
key=
{
index2
}
>
<
li
key=
{
index2
}
>
<
a
target=
"_blank"
key=
{
f
.
path
}
href=
{
queryApiActionPath
()
+
f
.
path
}
>
<
a
target=
'_blank'
key=
{
f
.
path
}
href=
{
queryApiActionPath
()
+
f
.
path
}
>
{
f
.
name
}
{
f
.
name
}
</
a
>
</
a
>
</
li
>
</
li
>
...
@@ -1819,7 +1862,7 @@ export default class tableCom extends Component {
...
@@ -1819,7 +1862,7 @@ export default class tableCom extends Component {
</
MobileItem
>
</
MobileItem
>
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
initialValue
:
value
,
initialValue
:
value
,
})(<
Input
type=
"hidden"
/>)
}
})(<
Input
type=
'hidden'
/>)
}
</>
</>
);
);
}
}
...
@@ -1832,7 +1875,7 @@ export default class tableCom extends Component {
...
@@ -1832,7 +1875,7 @@ export default class tableCom extends Component {
{
cm
}
{
cm
}
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
initialValue
:
value
,
initialValue
:
value
,
})(<
Input
type=
"hidden"
/>)
}
})(<
Input
type=
'hidden'
/>)
}
</>
</>
);
);
}
}
...
@@ -1926,7 +1969,7 @@ export default class tableCom extends Component {
...
@@ -1926,7 +1969,7 @@ export default class tableCom extends Component {
</
Form
.
Item
>
</
Form
.
Item
>
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
initialValue
:
value
,
initialValue
:
value
,
})(<
Input
type=
"hidden"
/>)
}
})(<
Input
type=
'hidden'
/>)
}
</>
</>
);
);
}
}
...
@@ -1939,7 +1982,7 @@ export default class tableCom extends Component {
...
@@ -1939,7 +1982,7 @@ export default class tableCom extends Component {
{
cm
}
{
cm
}
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
{
this
.
props
.
form
.
getFieldDecorator
(
`defaultValues.${formKey}.${key}`
,
{
initialValue
:
value
,
initialValue
:
value
,
})(<
Input
type=
"hidden"
/>)
}
})(<
Input
type=
'hidden'
/>)
}
</>
</>
);
);
}
}
...
@@ -1955,9 +1998,9 @@ export default class tableCom extends Component {
...
@@ -1955,9 +1998,9 @@ export default class tableCom extends Component {
this
.
props
.
fatherCode
!=
null
this
.
props
.
fatherCode
!=
null
?
bindObj
?
bindObj
?
{
?
{
...
bindObj
,
...
bindObj
,
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
bindObj
.
base52
}
`
,
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
bindObj
.
base52
}
`
,
}
}
:
{
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
this
.
props
.
uuid
}
`
}
:
{
base52
:
`
${
this
.
props
.
fatherCode
}
.[
${
this
.
props
.
index
}
].
${
this
.
props
.
uuid
}
`
}
:
bindObj
;
:
bindObj
;
...
@@ -2089,18 +2132,18 @@ export default class tableCom extends Component {
...
@@ -2089,18 +2132,18 @@ export default class tableCom extends Component {
<
span
>
<
span
>
{
labels
!=
null
{
labels
!=
null
?
labels
.
map
((
r
,
i
)
=>
?
labels
.
map
((
r
,
i
)
=>
i
==
0
?
(
i
==
0
?
(
typeof
r
==
'string'
?
(
typeof
r
==
'string'
?
(
<
span
>
{
r
}
</
span
>
<
span
>
{
r
}
</
span
>
)
:
(
Object
.
values
(
r
)
)
)
:
typeof
r
==
'string'
?
(
<
span
style=
{
{
marginLeft
:
12
}
}
>
{
r
}
</
span
>
)
:
(
)
:
(
','
+
Object
.
values
(
r
)
Object
.
values
(
r
)
),
)
)
)
:
typeof
r
==
'string'
?
(
<
span
style=
{
{
marginLeft
:
12
}
}
>
{
r
}
</
span
>
)
:
(
','
+
Object
.
values
(
r
)
),
)
:
''
}
:
''
}
</
span
>
</
span
>
);
);
...
@@ -2124,7 +2167,7 @@ export default class tableCom extends Component {
...
@@ -2124,7 +2167,7 @@ export default class tableCom extends Component {
<
Table
<
Table
get=
{
get
}
get=
{
get
}
columns=
{
this
.
state
.
columns
}
columns=
{
this
.
state
.
columns
}
size=
"small"
size=
'small'
dataSource=
{
ds
}
dataSource=
{
ds
}
pagination=
{
false
}
pagination=
{
false
}
/>
/>
...
@@ -2157,13 +2200,15 @@ export default class tableCom extends Component {
...
@@ -2157,13 +2200,15 @@ export default class tableCom extends Component {
}
else
{
}
else
{
cm
=
(
cm
=
(
<
span
>
<
span
>
{
moment
(
parseInt
(
obj
[
begin
.
base52
])).
format
(
{
moment
(
parseInt
(
obj
[
begin
.
base52
]))
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
.
format
(
)
}{
' '
}
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
)
}{
' '
}
至
{
' '
}
至
{
' '
}
{
moment
(
parseInt
(
obj
[
end
.
base52
])).
format
(
{
moment
(
parseInt
(
obj
[
end
.
base52
]))
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
.
format
(
)
}
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
)
}
</
span
>
</
span
>
);
);
}
}
...
@@ -2176,16 +2221,18 @@ export default class tableCom extends Component {
...
@@ -2176,16 +2221,18 @@ export default class tableCom extends Component {
if
(
obj
[
dataColumn
.
base52
]
&&
obj
[
dataColumn
.
base52
].
indexOf
(
'-'
)
===
-
1
)
{
if
(
obj
[
dataColumn
.
base52
]
&&
obj
[
dataColumn
.
base52
].
indexOf
(
'-'
)
===
-
1
)
{
cm
=
(
cm
=
(
<
span
>
<
span
>
{
moment
(
parseInt
(
obj
[
dataColumn
.
base52
])).
format
(
{
moment
(
parseInt
(
obj
[
dataColumn
.
base52
]))
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
.
format
(
)
}
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
)
}
</
span
>
</
span
>
);
);
}
else
{
}
else
{
cm
=
(
cm
=
(
<
span
>
<
span
>
{
obj
[
dataColumn
.
base52
]
{
obj
[
dataColumn
.
base52
]
?
moment
(
+
new
Date
(
obj
[
dataColumn
.
base52
])).
format
(
?
moment
(
+
new
Date
(
obj
[
dataColumn
.
base52
]))
.
format
(
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
)
)
:
''
}
:
''
}
...
@@ -2230,18 +2277,18 @@ export default class tableCom extends Component {
...
@@ -2230,18 +2277,18 @@ export default class tableCom extends Component {
cm
=
(
cm
=
(
<
ul
className=
{
styles
.
imageUl
}
>
<
ul
className=
{
styles
.
imageUl
}
>
{
Array
.
isArray
(
files
)
&&
{
Array
.
isArray
(
files
)
&&
files
.
map
((
f
,
index2
)
=>
{
files
.
map
((
f
,
index2
)
=>
{
return
(
return
(
<
li
key=
{
f
.
path
}
>
<
li
key=
{
f
.
path
}
>
<
PictureSignature
<
PictureSignature
json=
{
json
}
json=
{
json
}
disabled=
{
true
}
// 只读模式
disabled=
{
true
}
// 只读模式
basicUrl=
{
queryApiActionPath
()
}
basicUrl=
{
queryApiActionPath
()
}
fileInfo=
{
f
}
fileInfo=
{
f
}
/>
/>
</
li
>
</
li
>
);
);
})
}
})
}
</
ul
>
</
ul
>
);
);
}
}
...
@@ -2293,7 +2340,7 @@ export default class tableCom extends Component {
...
@@ -2293,7 +2340,7 @@ export default class tableCom extends Component {
}
}
return
(
return
(
<
li
key=
{
index2
}
>
<
li
key=
{
index2
}
>
<
a
target=
"_blank"
key=
{
f
.
path
}
href=
{
queryApiActionPath
()
+
f
.
path
}
>
<
a
target=
'_blank'
key=
{
f
.
path
}
href=
{
queryApiActionPath
()
+
f
.
path
}
>
{
f
.
name
}
{
f
.
name
}
</
a
>
</
a
>
</
li
>
</
li
>
...
@@ -2306,39 +2353,39 @@ export default class tableCom extends Component {
...
@@ -2306,39 +2353,39 @@ export default class tableCom extends Component {
cm
=
(
cm
=
(
<
ul
className=
{
styles
.
imageUl
}
>
<
ul
className=
{
styles
.
imageUl
}
>
{
Array
.
isArray
(
files
)
&&
{
Array
.
isArray
(
files
)
&&
files
.
map
((
f
,
index2
)
=>
{
files
.
map
((
f
,
index2
)
=>
{
// if (f.filePath.indexOf('.png') != -1 || f.filePath.indexOf('.jpg') != -1)
{
// if (f.filePath.indexOf('.png') != -1 || f.filePath.indexOf('.jpg') != -1)
{
// return (
// return (
// <img
// <img
// key=
{
index2
}
// key=
{
index2
}
// style=
{{
width
:
100
,
height
:
100
}}
// style=
{{
width
:
100
,
height
:
100
}}
// src=
{
queryApiActionPath
()
+
f
.
filePath
}
// src=
{
queryApiActionPath
()
+
f
.
filePath
}
// />
// />
// );
// );
//
}
//
}
if
(
get
===
'web'
||
!
this
.
props
.
isPrint
)
{
if
(
get
===
'web'
||
!
this
.
props
.
isPrint
)
{
return
(
<
li
key=
{
index2
}
>
<
FilePreview
path=
{
queryApiActionPath
()
+
f
.
path
}
pathName=
{
f
.
name
}
type=
{
'UploadCom'
}
/>
</
li
>
);
}
return
(
return
(
<
li
key=
{
index2
}
>
<
li
key=
{
index2
}
>
<
a
<
FilePreview
target=
"_blank"
path=
{
queryApiActionPath
()
+
f
.
path
}
key=
{
f
.
filePath
}
pathName=
{
f
.
name
}
href=
{
queryApiActionPath
()
+
f
.
filePath
}
type=
{
'UploadCom'
}
>
/>
{
f
.
fileName
}
</
a
>
</
li
>
</
li
>
);
);
})
}
}
return
(
<
li
key=
{
index2
}
>
<
a
target=
'_blank'
key=
{
f
.
filePath
}
href=
{
queryApiActionPath
()
+
f
.
filePath
}
>
{
f
.
fileName
}
</
a
>
</
li
>
);
})
}
</
ul
>
</
ul
>
);
);
}
}
...
@@ -2490,7 +2537,7 @@ export default class tableCom extends Component {
...
@@ -2490,7 +2537,7 @@ export default class tableCom extends Component {
if
(
json
.
isLink
)
{
if
(
json
.
isLink
)
{
cm
=
<
a
{
...
ev
}
/>;
cm
=
<
a
{
...
ev
}
/>;
}
else
{
}
else
{
cm
=
<
Button
loading=
{
this
.
props
.
loading
}
type=
"primary"
{
...
ev
}
/>;
cm
=
<
Button
loading=
{
this
.
props
.
loading
}
type=
'primary'
{
...
ev
}
/>;
}
}
}
}
...
@@ -2576,7 +2623,7 @@ export default class tableCom extends Component {
...
@@ -2576,7 +2623,7 @@ export default class tableCom extends Component {
if
(
json
.
isLink
)
{
if
(
json
.
isLink
)
{
cm
=
<
a
{
...
ev
}
/>;
cm
=
<
a
{
...
ev
}
/>;
}
else
{
}
else
{
cm
=
<
Button
loading=
{
this
.
props
.
loading
}
type=
"primary"
{
...
ev
}
/>;
cm
=
<
Button
loading=
{
this
.
props
.
loading
}
type=
'primary'
{
...
ev
}
/>;
}
}
}
}
...
@@ -2597,11 +2644,11 @@ export default class tableCom extends Component {
...
@@ -2597,11 +2644,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
? json.vlds
? json.vlds
: [
: [
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
title
,
message
:
'请选择'
+
title
,
}
,
}
,
],
],
})}
})}
disabled=
{
disabled
}
disabled=
{
disabled
}
onClick=
{
checked
=>
{
onClick=
{
checked
=>
{
...
@@ -2633,11 +2680,11 @@ export default class tableCom extends Component {
...
@@ -2633,11 +2680,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
title
,
message
:
'请选择'
+
title
,
},
},
],
],
})(
})(
<
Switch
<
Switch
disabled=
{
disabled
}
disabled=
{
disabled
}
...
@@ -2664,11 +2711,11 @@ export default class tableCom extends Component {
...
@@ -2664,11 +2711,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请输入'
+
title
,
message
:
'请输入'
+
title
,
},
},
],
],
})(
})(
<
TextArea
<
TextArea
autoSize=
{
{
minRows
:
4
}
}
autoSize=
{
{
minRows
:
4
}
}
...
@@ -2703,11 +2750,11 @@ export default class tableCom extends Component {
...
@@ -2703,11 +2750,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请输入'
+
title
,
message
:
'请输入'
+
title
,
},
},
],
],
})(
})(
<
TextArea
<
TextArea
autoSize=
{
{
minRows
:
4
}
}
autoSize=
{
{
minRows
:
4
}
}
...
@@ -2726,11 +2773,11 @@ export default class tableCom extends Component {
...
@@ -2726,11 +2773,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请输入'
+
title
,
message
:
'请输入'
+
title
,
},
},
],
],
})(
})(
<
Input
<
Input
disabled=
{
disabled
}
disabled=
{
disabled
}
...
@@ -2761,7 +2808,7 @@ export default class tableCom extends Component {
...
@@ -2761,7 +2808,7 @@ export default class tableCom extends Component {
case
'InputHidden'
:
case
'InputHidden'
:
cm
=
getFieldDecorator
(
dataColumn
.
base52
,
{
cm
=
getFieldDecorator
(
dataColumn
.
base52
,
{
initialValue
:
initValue
,
initialValue
:
initValue
,
})(<
Input
type=
"hidden"
/>);
})(<
Input
type=
'hidden'
/>);
break
;
break
;
case
'InputNumber'
:
case
'InputNumber'
:
cm
=
getFieldDecorator
(
dataColumn
.
base52
,
{
cm
=
getFieldDecorator
(
dataColumn
.
base52
,
{
...
@@ -2770,11 +2817,11 @@ export default class tableCom extends Component {
...
@@ -2770,11 +2817,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请输入'
+
title
,
message
:
'请输入'
+
title
,
},
},
],
],
})(
})(
<
InputNumber
<
InputNumber
disabled=
{
disabled
}
disabled=
{
disabled
}
...
@@ -2816,11 +2863,11 @@ export default class tableCom extends Component {
...
@@ -2816,11 +2863,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
dataColumn
.
title
,
message
:
'请选择'
+
dataColumn
.
title
,
},
},
],
],
})(<
Radio
.
Group
options=
{
options
}
disabled=
{
disabled
}
/>);
})(<
Radio
.
Group
options=
{
options
}
disabled=
{
disabled
}
/>);
if
(
get
==
'mobile'
)
{
if
(
get
==
'mobile'
)
{
cm
=
<
div
>
{
cm
}
</
div
>;
cm
=
<
div
>
{
cm
}
</
div
>;
...
@@ -2849,18 +2896,18 @@ export default class tableCom extends Component {
...
@@ -2849,18 +2896,18 @@ export default class tableCom extends Component {
case
'Checkbox'
:
case
'Checkbox'
:
if
(
get
===
'mobile'
)
{
if
(
get
===
'mobile'
)
{
cm
=
(
cm
=
(
<
Flex
direction=
"column"
align=
"start"
>
<
Flex
direction=
'column'
align=
'start'
>
{
getFieldDecorator
(
dataColumn
.
base52
,
{
{
getFieldDecorator
(
dataColumn
.
base52
,
{
initialValue
:
initValue
,
// 默认值
initialValue
:
initValue
,
// 默认值
rules
:
rules
:
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
dataColumn
.
title
,
message
:
'请选择'
+
dataColumn
.
title
,
},
},
],
],
})(<
Checkbox
.
Group
options=
{
options
}
disabled=
{
disabled
}
/>)
}
})(<
Checkbox
.
Group
options=
{
options
}
disabled=
{
disabled
}
/>)
}
</
Flex
>
</
Flex
>
);
);
...
@@ -2891,11 +2938,11 @@ export default class tableCom extends Component {
...
@@ -2891,11 +2938,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
dataColumn
.
title
,
message
:
'请选择'
+
dataColumn
.
title
,
},
},
],
],
})(
})(
<
Checkbox
.
Group
<
Checkbox
.
Group
options=
{
options
}
options=
{
options
}
...
@@ -2920,11 +2967,11 @@ export default class tableCom extends Component {
...
@@ -2920,11 +2967,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
dataColumn
.
title
,
message
:
'请选择'
+
dataColumn
.
title
,
},
},
],
],
})(
})(
<
Select
<
Select
allowClear
allowClear
...
@@ -2932,44 +2979,45 @@ export default class tableCom extends Component {
...
@@ -2932,44 +2979,45 @@ export default class tableCom extends Component {
disabled=
{
selectDis
||
disabled
}
disabled=
{
selectDis
||
disabled
}
placeholder=
{
json
.
placeholder
}
placeholder=
{
json
.
placeholder
}
style=
{
{
width
:
json
.
width
}
}
style=
{
{
width
:
json
.
width
}
}
optionFilterProp=
"children"
optionFilterProp=
'children'
getPopupContainer=
{
getPopupContainer=
{
this
.
props
.
isDynamic
&&
document
.
querySelector
(
'#dynamic_div'
)
this
.
props
.
isDynamic
&&
document
.
querySelector
(
'#dynamic_div'
)
?
()
=>
{
?
()
=>
{
return
document
.
querySelector
(
'#dynamic_div'
);
return
document
.
querySelector
(
'#dynamic_div'
);
}
}
:
''
:
''
}
}
onFocus=
{
()
=>
{
onFocus=
{
()
=>
{
get
===
'mobile'
// 移动端取消输入键盘弹出
get
===
'mobile'
// 移动端取消输入键盘弹出
?
setTimeout
(()
=>
{
?
setTimeout
(()
=>
{
if
(
document
.
querySelectorAll
(
`.ant-select-search__field`
).
length
>
0
)
{
if
(
document
.
querySelectorAll
(
`.ant-select-search__field`
).
length
>
0
)
{
let
ary
=
[...
document
.
querySelectorAll
(
`.ant-select-search__field`
)];
let
ary
=
[...
document
.
querySelectorAll
(
`.ant-select-search__field`
)];
ary
.
map
(
item
=>
{
ary
.
map
(
item
=>
{
item
.
setAttribute
(
'readonly'
,
'readonly'
);
item
.
setAttribute
(
'readonly'
,
'readonly'
);
// setTimeout(() =>
{
// setTimeout(() =>
{
// ary.map(arr =>
{
// ary.map(arr =>
{
// arr.removeAttribute('readonly');
// arr.removeAttribute('readonly');
//
})
//
})
//
});
//
});
});
});
}
}
})
})
:
null
;
:
null
;
}
}
}
}
filterOption=
{
(
input
,
option
)
=>
filterOption=
{
(
input
,
option
)
=>
option
option
?
option
.
props
.
children
.
toLowerCase
().
indexOf
(
input
.
toLowerCase
())
>=
0
?
option
.
props
.
children
.
toLowerCase
()
.
indexOf
(
input
.
toLowerCase
())
>=
0
:
false
:
false
}
}
{
...
otherProps
}
{
...
otherProps
}
>
>
{
options
&&
options
instanceof
Array
{
options
&&
options
instanceof
Array
?
options
.
map
(
r
=>
(
?
options
.
map
(
r
=>
(
<
Option
key=
{
r
.
value
}
value=
{
r
.
value
}
>
<
Option
key=
{
r
.
value
}
value=
{
r
.
value
}
>
{
r
.
label
}
{
r
.
label
}
</
Option
>
</
Option
>
))
))
:
''
}
:
''
}
</
Select
>,
</
Select
>,
);
);
...
@@ -3008,7 +3056,8 @@ export default class tableCom extends Component {
...
@@ -3008,7 +3056,8 @@ export default class tableCom extends Component {
}
}
const
filterF
=
function
filter
(
inputValue
,
path
)
{
const
filterF
=
function
filter
(
inputValue
,
path
)
{
return
path
.
some
(
return
path
.
some
(
option
=>
option
?.
label
?.
toLowerCase
()?.
indexOf
(
inputValue
.
toLowerCase
())
>
-
1
,
option
=>
option
?.
label
?.
toLowerCase
()
?.
indexOf
(
inputValue
.
toLowerCase
())
>
-
1
,
);
);
};
};
cm
=
getFieldDecorator
(
dataColumn
.
base52
,
{
cm
=
getFieldDecorator
(
dataColumn
.
base52
,
{
...
@@ -3017,11 +3066,11 @@ export default class tableCom extends Component {
...
@@ -3017,11 +3066,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
dataColumn
.
title
,
message
:
'请选择'
+
dataColumn
.
title
,
},
},
],
],
})(
})(
<
Cascader
// 这里的options 获取方式存在bug 公式会重复调用
<
Cascader
// 这里的options 获取方式存在bug 公式会重复调用
options=
{
options
}
options=
{
options
}
...
@@ -3031,8 +3080,8 @@ export default class tableCom extends Component {
...
@@ -3031,8 +3080,8 @@ export default class tableCom extends Component {
getPopupContainer=
{
getPopupContainer=
{
this
.
props
.
isDynamic
&&
document
.
querySelector
(
'#dynamic_div'
)
this
.
props
.
isDynamic
&&
document
.
querySelector
(
'#dynamic_div'
)
?
()
=>
{
?
()
=>
{
return
document
.
querySelector
(
'#dynamic_div'
);
return
document
.
querySelector
(
'#dynamic_div'
);
}
}
:
''
:
''
}
}
placeholder=
{
json
.
placeholder
}
placeholder=
{
json
.
placeholder
}
...
@@ -3048,11 +3097,11 @@ export default class tableCom extends Component {
...
@@ -3048,11 +3097,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择'
+
dataColumn
.
title
,
message
:
'请选择'
+
dataColumn
.
title
,
},
},
],
],
})(<
MobileCascader
options=
{
options
}
label=
{
title
}
disabled=
{
disabled
}
json=
{
json
}
/>);
})(<
MobileCascader
options=
{
options
}
label=
{
title
}
disabled=
{
disabled
}
json=
{
json
}
/>);
}
}
...
@@ -3085,22 +3134,22 @@ export default class tableCom extends Component {
...
@@ -3085,22 +3134,22 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
validator
:
(
rule
,
value
,
callback
)
=>
{
validator
:
(
rule
,
value
,
callback
)
=>
{
let
errors
=
[];
let
errors
=
[];
if
(
if
(
(
Object
.
keys
(
value
).
length
==
0
||
(
Object
.
keys
(
value
).
length
==
0
||
Object
.
keys
(
value
.
selects
).
length
==
0
)
&&
Object
.
keys
(
value
.
selects
).
length
==
0
)
&&
required
!=
null
&&
required
!=
null
&&
required
required
)
{
)
{
errors
.
push
(
new
Error
(
'请选择至少一个'
,
rule
.
field
));
errors
.
push
(
new
Error
(
'请选择至少一个'
,
rule
.
field
));
}
}
callback
(
errors
);
callback
(
errors
);
},
required
:
required
,
},
},
],
required
:
required
,
},
],
})(
})(
<
TableSelect
<
TableSelect
get=
{
get
}
get=
{
get
}
...
@@ -3157,13 +3206,15 @@ export default class tableCom extends Component {
...
@@ -3157,13 +3206,15 @@ export default class tableCom extends Component {
if
(
!
isEdit
)
{
if
(
!
isEdit
)
{
cm
=
(
cm
=
(
<
span
>
<
span
>
{
moment
(
parseInt
(
obj
[
begin
.
base52
])).
format
(
{
moment
(
parseInt
(
obj
[
begin
.
base52
]))
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
.
format
(
)
}{
' '
}
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
)
}{
' '
}
至
{
' '
}
至
{
' '
}
{
moment
(
parseInt
(
obj
[
end
.
base52
])).
format
(
{
moment
(
parseInt
(
obj
[
end
.
base52
]))
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
.
format
(
)
}
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
,
)
}
</
span
>
</
span
>
);
);
}
else
{
}
else
{
...
@@ -3174,11 +3225,11 @@ export default class tableCom extends Component {
...
@@ -3174,11 +3225,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择起止时间'
,
message
:
'请选择起止时间'
,
},
},
],
],
})(<
MobileDate
disabled=
{
disabled
}
formate=
{
json
.
format
}
required=
{
required
}
/>);
})(<
MobileDate
disabled=
{
disabled
}
formate=
{
json
.
format
}
required=
{
required
}
/>);
if
(
if
(
((
json
.
isMobileLabel
!=
null
&&
json
.
isMobileLabel
)
||
((
json
.
isMobileLabel
!=
null
&&
json
.
isMobileLabel
)
||
...
@@ -3206,11 +3257,11 @@ export default class tableCom extends Component {
...
@@ -3206,11 +3257,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择起止时间'
,
message
:
'请选择起止时间'
,
},
},
],
],
})(
})(
<
RangePicker
<
RangePicker
showTime=
{
json
.
showTime
!=
null
?
json
.
showTime
:
true
}
showTime=
{
json
.
showTime
!=
null
?
json
.
showTime
:
true
}
...
@@ -3236,11 +3287,11 @@ export default class tableCom extends Component {
...
@@ -3236,11 +3287,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请选择起止时间'
,
message
:
'请选择起止时间'
,
},
},
],
],
})(
})(
<
DatePicker
<
DatePicker
disabled=
{
disabled
}
disabled=
{
disabled
}
...
@@ -3251,21 +3302,22 @@ export default class tableCom extends Component {
...
@@ -3251,21 +3302,22 @@ export default class tableCom extends Component {
onOpenChange=
{
onOpenChange=
{
get
===
'mobile'
get
===
'mobile'
?
()
=>
{
?
()
=>
{
// 取消唤起移动端小键盘
// 取消唤起移动端小键盘
setTimeout
(()
=>
{
setTimeout
(()
=>
{
if
(
document
.
querySelector
(
'.ant-calendar-input '
))
{
if
(
document
.
querySelector
(
'.ant-calendar-input '
))
{
document
.
querySelector
(
'.ant-calendar-input '
)
.
setAttribute
(
'readonly'
,
'readonly'
);
setTimeout
(()
=>
{
document
document
.
querySelector
(
'.ant-calendar-input '
)
.
querySelector
(
'.ant-calendar-input '
)
.
setAttribute
(
'readonly'
,
'readonly'
);
.
removeAttribute
(
'readonly'
);
setTimeout
(()
=>
{
});
document
}
.
querySelector
(
'.ant-calendar-input '
)
});
.
removeAttribute
(
'readonly'
);
}
});
:
()
=>
{
}
}
});
}
:
()
=>
{}
}
}
format=
{
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
}
format=
{
json
.
format
?
json
.
format
:
'YYYY-MM-DD HH:mm:ss'
}
/>,
/>,
...
@@ -3301,11 +3353,11 @@ export default class tableCom extends Component {
...
@@ -3301,11 +3353,11 @@ export default class tableCom extends Component {
json
?.
vlds
&&
json
?.
vlds
.
length
>
0
json
?.
vlds
&&
json
?.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
,
required
,
message
:
'请进行签章'
,
message
:
'请进行签章'
,
},
},
],
],
})(
})(
<
SignArray
// 签章组件 编辑模式
<
SignArray
// 签章组件 编辑模式
json=
{
json
}
json=
{
json
}
...
@@ -3390,11 +3442,11 @@ export default class tableCom extends Component {
...
@@ -3390,11 +3442,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请输入'
,
message
:
'请输入'
,
},
},
],
],
})(
})(
<
WangEditor
<
WangEditor
json=
{
json
}
json=
{
json
}
...
@@ -3411,11 +3463,11 @@ export default class tableCom extends Component {
...
@@ -3411,11 +3463,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请输入'
,
message
:
'请输入'
,
},
},
],
],
})(<
DraftEditorCom
placeholder=
{
json
.
placeholder
}
disabled=
{
json
.
disabled
}
/>);
})(<
DraftEditorCom
placeholder=
{
json
.
placeholder
}
disabled=
{
json
.
disabled
}
/>);
if
(
if
(
get
===
'mobile'
&&
get
===
'mobile'
&&
...
@@ -3443,11 +3495,11 @@ export default class tableCom extends Component {
...
@@ -3443,11 +3495,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请输入'
+
title
,
message
:
'请输入'
+
title
,
},
},
],
],
})(<
CronEditor
style=
{
{
width
:
600
}
}
/>);
})(<
CronEditor
style=
{
{
width
:
600
}
}
/>);
break
;
break
;
case
'LocationCom'
:
case
'LocationCom'
:
...
@@ -3456,12 +3508,19 @@ export default class tableCom extends Component {
...
@@ -3456,12 +3508,19 @@ export default class tableCom extends Component {
rules
:
rules
:
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[{
{
required
,
required
:
required
,
message
:
'请获取定位信息'
,
message
:
'请进行定位'
,
validator
:
(
rule
,
valueThis
,
callback
)
=>
{
},
let
errors
=
[];
],
console
.
log
(
valueThis
);
if
((
!
valueThis
||
!
JSON
.
stringify
(
valueThis
).
includes
(
'address'
))
&&
required
)
{
errors
.
push
(
new
Error
(
'请获取定位信息'
,
rule
.
field
));
}
callback
(
errors
);
},
},
],
})(
})(
<
LocationCom
<
LocationCom
get=
{
get
}
get=
{
get
}
...
@@ -3547,11 +3606,11 @@ export default class tableCom extends Component {
...
@@ -3547,11 +3606,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请上传图片'
,
message
:
'请上传图片'
,
},
},
],
],
})(<
ImgUploadCom
json=
{
json
}
disabled=
{
disabled
}
/>);
})(<
ImgUploadCom
json=
{
json
}
disabled=
{
disabled
}
/>);
if
(
if
(
get
===
'mobile'
&&
get
===
'mobile'
&&
...
@@ -3578,11 +3637,11 @@ export default class tableCom extends Component {
...
@@ -3578,11 +3637,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请上传视频'
,
message
:
'请上传视频'
,
},
},
],
],
})(<
VideoUploadCom
json=
{
json
}
disabled=
{
disabled
}
/>);
})(<
VideoUploadCom
json=
{
json
}
disabled=
{
disabled
}
/>);
if
(
if
(
get
===
'mobile'
&&
get
===
'mobile'
&&
...
@@ -3609,11 +3668,11 @@ export default class tableCom extends Component {
...
@@ -3609,11 +3668,11 @@ export default class tableCom extends Component {
json
.
vlds
&&
json
.
vlds
.
length
>
0
json
.
vlds
&&
json
.
vlds
.
length
>
0
?
json
.
vlds
?
json
.
vlds
:
[
:
[
{
{
required
:
required
,
required
:
required
,
message
:
'请进行签名'
,
message
:
'请进行签名'
,
},
},
],
],
})(
})(
<
Signature
<
Signature
width=
{
width=
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论