Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
WebPublic
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
前端开发小组
WebPublic
Commits
93c4167d
提交
93c4167d
authored
8月 12, 2022
作者:
姚鑫国
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' of
http://scjoyedu.eicp.net:9121/front-team/webPublic
上级
e857c82e
08055802
显示空白字符变更
内嵌
并排
正在显示
13 个修改的文件
包含
309 行增加
和
267 行删除
+309
-267
JustApply.js
FormInsertDiy/AffairPage/ApplyPage/JustApply.js
+1
-37
ImportUtil.js
one_stop_public/App/ImportUtil.js
+3
-3
SplitBase16Index.js
one_stop_public/Base16/SplitBase16Index.js
+2
-1
binaryEncode.js
one_stop_public/Base16/binaryEncode.js
+5
-4
DetailSplit.js
one_stop_public/DetailForAudit/DetailSplit.js
+186
-155
index.js
one_stop_public/ForZydApply/index.js
+2
-1
ZdyTable.jsx
one_stop_public/Table/ZdyTable.jsx
+1
-0
globalFunction.js
one_stop_public/Table/globalFunction.js
+6
-6
TableSelect.js
one_stop_public/libs/TableSelect.js
+76
-25
TreeList.js
one_stop_public/libs/formList/TreeList.js
+2
-24
giveVarcharLength.js
one_stop_public/tableCompon/Split_Index/giveVarcharLength.js
+3
-0
request.js
one_stop_public/utils/request.js
+5
-7
getHeaders.js
zyd_public/utils/getHeaders.js
+17
-4
没有找到文件。
FormInsertDiy/AffairPage/ApplyPage/JustApply.js
浏览文件 @
93c4167d
...
@@ -32,24 +32,6 @@ export default class AffairPage extends React.Component {
...
@@ -32,24 +32,6 @@ export default class AffairPage extends React.Component {
message
.
error
(
'您的数据未同步,请联系管理员!'
);
message
.
error
(
'您的数据未同步,请联系管理员!'
);
return
false
;
return
false
;
}
}
// window.addEventListener(
// 'message',
// (event) => {
// // 和Iframe页进行通迅
// if (event.data === 'returnList') {
// this.returnList(true);
// }
// if (event && event.data && event.data.indexOf && event.data.indexOf('iframeHeight') > -1) {
// let height = Number(event.data.split('-')[1]);
// const iframe = document.getElementById('applyIframeId');
// if (iframe) {
// iframe.height = height;
// }
// }
// },
// false,
// );
return
true
;
return
true
;
}
}
...
@@ -89,26 +71,8 @@ export default class AffairPage extends React.Component {
...
@@ -89,26 +71,8 @@ export default class AffairPage extends React.Component {
{...
this
.
props
}
{...
this
.
props
}
id
=
{
workId
}
id
=
{
workId
}
returnList
=
{
this
.
returnList
}
returnList
=
{
this
.
returnList
}
init
=
{
encodeURIComponent
(
JSON
.
stringify
(
init
))
}
init
=
{
init
}
/
>
/
>
{
/* <iframe
src={iframeUrl}
frameBorder={0}
id="applyIframeId"
name="applyIframe"
marginWidth="0"
marginHeight="0"
allowtransparency="yes"
seamless
scrolling={'auto'}
style={{
width: '100%',
minHeight: '800px',
overflowY: 'hidden',
backgroundColor: '#fff',
}}
/>*/
}
:
null
<
/div
>
<
/div
>
<
/PageHeaderWrapper
>
<
/PageHeaderWrapper
>
);
);
...
...
one_stop_public/App/ImportUtil.js
浏览文件 @
93c4167d
...
@@ -241,9 +241,9 @@ export default class ImportUtil extends React.PureComponent {
...
@@ -241,9 +241,9 @@ export default class ImportUtil extends React.PureComponent {
fetch
(
transformApi
,
{
fetch
(
transformApi
,
{
method
:
'POST'
,
method
:
'POST'
,
body
:
FormdataWrapper
(
newParams
.
datas
),
body
:
FormdataWrapper
(
newParams
.
datas
),
headers
:
{
//
headers: {
apis
:
headersApi
,
//
apis: headersApi,
},
//
},
})
})
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
console
.
log
(
res
.
status
);
console
.
log
(
res
.
status
);
...
...
one_stop_public/Base16/SplitBase16Index.js
浏览文件 @
93c4167d
...
@@ -35,10 +35,11 @@ function giveKey(key, datas) {
...
@@ -35,10 +35,11 @@ function giveKey(key, datas) {
}
}
export
async
function
countAllValues
(
datas
,
item
)
{
export
async
function
countAllValues
(
datas
,
item
)
{
// console.log(datas);
if
(
item
.
setNull
)
{
if
(
item
.
setNull
)
{
datas
.
allValues
=
JSON
.
stringify
({});
datas
.
allValues
=
JSON
.
stringify
({});
}
else
{
}
else
{
if
(
item
.
query
)
{
if
(
item
.
query
&&
!
datas
.
isMeta
)
{
if
(
datas
?.
sqlKey
.
length
<
13
)
{
if
(
datas
?.
sqlKey
.
length
<
13
)
{
const
response
=
await
apiRequest
(
'/SqlManageEntityApi/findParamsKey'
,
{
const
response
=
await
apiRequest
(
'/SqlManageEntityApi/findParamsKey'
,
{
sqlKey
:
datas
.
sqlKey
,
sqlKey
:
datas
.
sqlKey
,
...
...
one_stop_public/Base16/binaryEncode.js
浏览文件 @
93c4167d
...
@@ -8,7 +8,8 @@ import { countAllValues } from '@/webPublic/one_stop_public/Base16/SplitBase16In
...
@@ -8,7 +8,8 @@ import { countAllValues } from '@/webPublic/one_stop_public/Base16/SplitBase16In
import
{
getUrlInfo
}
from
'@/webPublic/one_stop_public/DetailForAudit/utils'
;
import
{
getUrlInfo
}
from
'@/webPublic/one_stop_public/DetailForAudit/utils'
;
import
{
getTransformApi
}
from
'@/webPublic/one_stop_public/2022beidianke/localstorageTransform'
;
import
{
getTransformApi
}
from
'@/webPublic/one_stop_public/2022beidianke/localstorageTransform'
;
import
{
strToBinary
}
from
'./strToBinary'
;
// 字符串转二进制 混淆代码
import
{
strToBinary
}
from
'./strToBinary'
;
// 字符串转二进制 混淆代码
import
{
binaryToStr
}
from
'./binaryToStr'
;
// 二进制字符串转JSON字符串 混淆代码
import
{
binaryToStr
}
from
'./binaryToStr'
;
import
{
getVisitorToken
}
from
'@/webPublic/zyd_public/utils/getHeaders'
;
// 二进制字符串转JSON字符串 混淆代码
const
test
=
!!
(
getUrlInfo
().
test
);
const
test
=
!!
(
getUrlInfo
().
test
);
...
@@ -93,8 +94,8 @@ export async function requestFileInfo(url, datas) {
...
@@ -93,8 +94,8 @@ export async function requestFileInfo(url, datas) {
// datas = await testPromise(datas);
// datas = await testPromise(datas);
// }
// }
const
formData
=
new
FormData
();
const
formData
=
new
FormData
();
if
(
getToken
())
{
if
(
get
Visitor
Token
())
{
datas
.
token
=
getToken
();
datas
.
token
=
get
Visitor
Token
();
}
}
for
(
let
key
in
datas
)
{
for
(
let
key
in
datas
)
{
formData
.
append
(
key
,
datas
[
key
]);
formData
.
append
(
key
,
datas
[
key
]);
...
@@ -115,7 +116,7 @@ export async function requestFileInfo(url, datas) {
...
@@ -115,7 +116,7 @@ export async function requestFileInfo(url, datas) {
headers
:
{
headers
:
{
Accept
:
'application/json'
,
Accept
:
'application/json'
,
...
getHeaders
(
transformApi
).
headers
,
...
getHeaders
(
transformApi
).
headers
,
apis
:
headersApi
,
//
apis: headersApi,
// axxx: `select * from user123 where id = 1`,
// axxx: `select * from user123 where id = 1`,
},
},
method
:
'POST'
,
method
:
'POST'
,
...
...
one_stop_public/DetailForAudit/DetailSplit.js
浏览文件 @
93c4167d
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
* 2019年9月19日
* 2019年9月19日
* 查看详情页面
* 查看详情页面
*/
*/
import
React
,
{
Component
,
Fragment
}
from
'react'
;
import
React
,
{
Component
,
Fragment
,
useEffect
,
useState
}
from
'react'
;
import
{
import
{
Row
,
Row
,
Col
,
Col
,
...
@@ -36,7 +36,12 @@ import styles from './styles.less';
...
@@ -36,7 +36,12 @@ import styles from './styles.less';
import
TrunToDetail
from
'./trunToDetail'
;
import
TrunToDetail
from
'./trunToDetail'
;
import
Countersign
from
'./components/Countersign'
;
import
Countersign
from
'./components/Countersign'
;
import
ChildTaskModel
from
'./ChildTaskModel'
;
import
ChildTaskModel
from
'./ChildTaskModel'
;
import
{
checkNeedFormValidateFieldsAndScroll
,
must
,
submitValues
,
checkNeedWriteAuditInfo
}
from
'./splitDetailSplit'
;
import
{
checkNeedFormValidateFieldsAndScroll
,
must
,
submitValues
,
checkNeedWriteAuditInfo
,
}
from
'./splitDetailSplit'
;
import
{
queryApiVersion
,
queryApiActionPath
}
from
'@/webPublic/one_stop_public/utils/queryConfig'
;
import
{
queryApiVersion
,
queryApiActionPath
}
from
'@/webPublic/one_stop_public/utils/queryConfig'
;
import
{
isJSON
}
from
'@/webPublic/zyd_public/utils/utils'
;
import
{
isJSON
}
from
'@/webPublic/zyd_public/utils/utils'
;
import
HistoryFormList
from
'@/webPublic/one_stop_public/DetailForAudit/HistoryFormList'
;
import
HistoryFormList
from
'@/webPublic/one_stop_public/DetailForAudit/HistoryFormList'
;
...
@@ -96,7 +101,7 @@ class DetailSplit extends Component {
...
@@ -96,7 +101,7 @@ class DetailSplit extends Component {
* @function 同步加签函数
* @function 同步加签函数
* @param { function } func 打开加签弹框函数
* @param { function } func 打开加签弹框函数
*/
*/
updateCountersignModal
=
func
=>
{
updateCountersignModal
=
(
func
)
=>
{
this
.
setState
({
this
.
setState
({
countersignModal
:
func
,
countersignModal
:
func
,
});
});
...
@@ -139,8 +144,8 @@ class DetailSplit extends Component {
...
@@ -139,8 +144,8 @@ class DetailSplit extends Component {
/**
/**
* @function 默认请求
* @function 默认请求
*/
*/
getInit
=
handleUser
=>
{
getInit
=
(
handleUser
)
=>
{
const
{
dispatch
}
=
this
.
props
;
const
{
dispatch
,
formPrepareData
}
=
this
.
props
;
const
id
=
this
.
props
.
history
.
location
.
state
&&
this
.
props
.
history
.
location
.
state
.
id
;
const
id
=
this
.
props
.
history
.
location
.
state
&&
this
.
props
.
history
.
location
.
state
.
id
;
const
code
=
this
.
props
.
history
.
location
.
state
&&
this
.
props
.
history
.
location
.
state
.
code
;
const
code
=
this
.
props
.
history
.
location
.
state
&&
this
.
props
.
history
.
location
.
state
.
code
;
const
queryId
=
this
.
props
.
history
.
location
.
query
&&
this
.
props
.
history
.
location
.
query
.
id
;
const
queryId
=
this
.
props
.
history
.
location
.
query
&&
this
.
props
.
history
.
location
.
query
.
id
;
...
@@ -153,24 +158,15 @@ class DetailSplit extends Component {
...
@@ -153,24 +158,15 @@ class DetailSplit extends Component {
return
;
return
;
}
}
}
}
const
val
=
formPrepareData
;
dispatch
({
if
(
val
)
{
type
:
'affair/getIdFormDetail'
,
payload
:
{
id
:
queryId
?
queryId
:
id
,
// 审批表Id
code
:
code
||
null
,
// 表单值
handleUser
:
handleUser
||
null
,
// 处理人
taskId
,
// 多任务流程会使用到,后续改为必须传入
lite
:
true
,
},
callback
:
val
=>
{
if
(
this
.
props
.
changeData
)
{
if
(
this
.
props
.
changeData
)
{
this
.
props
.
changeData
(
val
);
this
.
props
.
changeData
(
val
);
}
}
const
checkListOptions
=
[];
const
checkListOptions
=
[];
const
checkedConfimList
=
[];
const
checkedConfimList
=
[];
if
(
val
.
hisTaskForm
.
formKeys
)
{
if
(
val
.
hisTaskForm
.
formKeys
)
{
val
.
hisTaskForm
.
formKeys
.
map
(
item
=>
{
val
.
hisTaskForm
.
formKeys
.
map
((
item
)
=>
{
checkListOptions
.
push
({
checkListOptions
.
push
({
label
:
item
.
taskName
,
label
:
item
.
taskName
,
value
:
item
.
formKey
,
value
:
item
.
formKey
,
...
@@ -178,11 +174,11 @@ class DetailSplit extends Component {
...
@@ -178,11 +174,11 @@ class DetailSplit extends Component {
});
});
}
}
if
(
val
&&
!
val
.
taskInfo
)
{
if
(
val
&&
!
val
.
taskInfo
)
{
permRequest
(
'/UnifiedAppFormApi/getTaskInfos'
,
{
// 获取每一步的审核人.
permRequest
(
'/UnifiedAppFormApi/getTaskInfos'
,
{
// 获取每一步的审核人.
id
:
queryId
?
queryId
:
id
,
// 审批表Id
id
:
queryId
?
queryId
:
id
,
// 审批表Id
code
:
code
||
null
,
// 表单值
code
:
code
||
null
,
// 表单值
})
}).
then
((
res
)
=>
{
.
then
(
res
=>
{
val
.
taskInfo
=
res
.
taskInfo
;
val
.
taskInfo
=
res
.
taskInfo
;
this
.
setState
(
this
.
setState
(
{
{
...
@@ -211,13 +207,16 @@ class DetailSplit extends Component {
...
@@ -211,13 +207,16 @@ class DetailSplit extends Component {
this
.
props
.
dispatch
({
this
.
props
.
dispatch
({
type
:
'urge/GetMyBtn'
,
type
:
'urge/GetMyBtn'
,
payload
:
{},
payload
:
{},
callback
:
arr
=>
{
callback
:
(
arr
)
=>
{
this
.
setState
({
this
.
setState
(
{
btnList
:
arr
,
btnList
:
arr
,
radiovalue
:
val
.
formLevelId
?
val
.
formLevelId
:
arr
[
arr
.
length
-
1
].
id
,
radiovalue
:
val
.
formLevelId
?
val
.
formLevelId
:
arr
[
arr
.
length
-
1
].
id
,
},
()
=>
{
},
()
=>
{
// this.giveMessageTop();
// this.giveMessageTop();
});
},
);
},
},
});
});
}
else
{
}
else
{
...
@@ -225,20 +224,15 @@ class DetailSplit extends Component {
...
@@ -225,20 +224,15 @@ class DetailSplit extends Component {
}
}
},
},
);
);
});
});
}
}
}
},
});
dispatch
({
dispatch
({
type
:
'emailorphone/GetLogo'
,
type
:
'emailorphone/GetLogo'
,
payload
:
{
payload
:
{
configKeys
:
[
'isCloseUserDetail'
,
'isCloseFlowPath'
,
'isAllPrint'
,
'closeAutoSign'
],
configKeys
:
[
'isCloseUserDetail'
,
'isCloseFlowPath'
,
'isAllPrint'
,
'closeAutoSign'
],
},
},
callback
:
val
=>
{
callback
:
(
val
)
=>
{
const
closeAutoSign
=
!!
(
val
[
3
]
&&
val
[
3
].
configValue
===
'true'
);
const
closeAutoSign
=
!!
(
val
[
3
]
&&
val
[
3
].
configValue
===
'true'
);
this
.
setState
({
this
.
setState
({
isCloseUserDetail
:
!!
(
val
[
0
]
&&
val
[
0
].
configValue
===
'true'
),
isCloseUserDetail
:
!!
(
val
[
0
]
&&
val
[
0
].
configValue
===
'true'
),
...
@@ -246,14 +240,14 @@ class DetailSplit extends Component {
...
@@ -246,14 +240,14 @@ class DetailSplit extends Component {
closeAutoSign
,
closeAutoSign
,
});
});
if
(
!
closeAutoSign
)
{
if
(
!
closeAutoSign
)
{
/**
/**
* 获取设置的数据
* 获取设置的数据
*/
*/
this
.
props
.
dispatch
({
this
.
props
.
dispatch
({
type
:
'UserSetCenterApi/queryUserSet'
,
type
:
'UserSetCenterApi/queryUserSet'
,
payload
:
{},
payload
:
{},
callback
:
val
=>
{
callback
:
(
val
)
=>
{
this
.
setState
({
this
.
setState
({
setData
:
val
,
setData
:
val
,
});
});
...
@@ -277,10 +271,8 @@ class DetailSplit extends Component {
...
@@ -277,10 +271,8 @@ class DetailSplit extends Component {
});
});
}
}
}
}
};
};
/**
/**
* @function 用户点击确认执行相应操作
* @function 用户点击确认执行相应操作
* @description: 注意 用户点击状态时在点击动态配置按钮时进行了保存,并在该函数中最终提交给后端
* @description: 注意 用户点击状态时在点击动态配置按钮时进行了保存,并在该函数中最终提交给后端
...
@@ -292,16 +284,7 @@ class DetailSplit extends Component {
...
@@ -292,16 +284,7 @@ class DetailSplit extends Component {
*/
*/
affairOk
=
(
oldkey
,
btnValue
,
value
,
checked
,
callback
)
=>
{
affairOk
=
(
oldkey
,
btnValue
,
value
,
checked
,
callback
)
=>
{
const
{
dispatch
}
=
this
.
props
;
const
{
dispatch
}
=
this
.
props
;
const
{
const
{
radiovalue
,
isSecond
,
userInfo
,
setData
,
data
,
btns
,
taskId
,
code
}
=
this
.
state
;
radiovalue
,
isSecond
,
userInfo
,
setData
,
data
,
btns
,
taskId
,
code
,
}
=
this
.
state
;
const
{
handleUser
}
=
this
.
props
.
history
.
location
.
state
;
const
{
handleUser
}
=
this
.
props
.
history
.
location
.
state
;
const
isCloseFlowPath
=
sessionStorage
.
getItem
(
'isCloseFlowPath'
)
const
isCloseFlowPath
=
sessionStorage
.
getItem
(
'isCloseFlowPath'
)
?
JSON
.
parse
(
sessionStorage
.
getItem
(
'isCloseFlowPath'
))
?
JSON
.
parse
(
sessionStorage
.
getItem
(
'isCloseFlowPath'
))
...
@@ -310,12 +293,14 @@ class DetailSplit extends Component {
...
@@ -310,12 +293,14 @@ class DetailSplit extends Component {
callback
();
callback
();
}
}
let
checkSumbitInfo
=
checkNeedFormValidateFieldsAndScroll
({
// 检查是否必填表单值
let
checkSumbitInfo
=
checkNeedFormValidateFieldsAndScroll
({
// 检查是否必填表单值
btns
,
btns
,
btnValue
,
btnValue
,
});
});
let
needWriteAuditInfo
=
checkNeedWriteAuditInfo
({
// 检查是否必填审批理由
let
needWriteAuditInfo
=
checkNeedWriteAuditInfo
({
// 检查是否必填审批理由
btns
,
btns
,
btnValue
,
btnValue
,
});
});
...
@@ -345,23 +330,23 @@ class DetailSplit extends Component {
...
@@ -345,23 +330,23 @@ class DetailSplit extends Component {
handleUser
,
handleUser
,
};
};
if
(
!
checkSumbitInfo
)
{
// 如果不需要校验 直接提交数据
if
(
!
checkSumbitInfo
)
{
// 如果不需要校验 直接提交数据
const
values
=
this
.
props
.
form
.
getFieldsValue
();
const
values
=
this
.
props
.
form
.
getFieldsValue
();
argumentsSubmitValue
.
values
=
values
;
argumentsSubmitValue
.
values
=
values
;
submitValues
(
argumentsSubmitValue
);
submitValues
(
argumentsSubmitValue
);
}
else
{
}
else
{
this
.
props
.
form
.
validateFieldsAndScroll
((
err
,
values
)
=>
{
// 校验是否填了必填字段
this
.
props
.
form
.
validateFieldsAndScroll
((
err
,
values
)
=>
{
// 校验是否填了必填字段
if
(
!
err
)
{
if
(
!
err
)
{
argumentsSubmitValue
.
values
=
values
;
argumentsSubmitValue
.
values
=
values
;
submitValues
(
argumentsSubmitValue
);
submitValues
(
argumentsSubmitValue
);
}
}
});
});
}
}
};
};
onChange
=
e
=>
{
onChange
=
(
e
)
=>
{
this
.
setState
({
this
.
setState
({
radiovalue
:
e
.
target
.
value
,
radiovalue
:
e
.
target
.
value
,
});
});
...
@@ -371,7 +356,7 @@ class DetailSplit extends Component {
...
@@ -371,7 +356,7 @@ class DetailSplit extends Component {
* @function 复选框状态函数
* @function 复选框状态函数
* @event change
* @event change
*/
*/
onCheckChange
=
checkedValues
=>
{
onCheckChange
=
(
checkedValues
)
=>
{
this
.
setState
({
this
.
setState
({
checkedConfimList
:
checkedValues
,
checkedConfimList
:
checkedValues
,
});
});
...
@@ -388,15 +373,14 @@ class DetailSplit extends Component {
...
@@ -388,15 +373,14 @@ class DetailSplit extends Component {
* @function 通过用户复选框选择拼装为对应打印页面
* @function 通过用户复选框选择拼装为对应打印页面
*/
*/
changeTake
=
checked
=>
{
changeTake
=
(
checked
)
=>
{
this
.
setState
({
isTakeFlow
:
checked
});
this
.
setState
({
isTakeFlow
:
checked
});
};
};
changePadding
=
value
=>
{
changePadding
=
(
value
)
=>
{
this
.
setState
({
paddingBottom
:
value
});
this
.
setState
({
paddingBottom
:
value
});
};
};
render
()
{
render
()
{
const
{
const
{
stepFlow
,
stepFlow
,
...
@@ -456,29 +440,29 @@ class DetailSplit extends Component {
...
@@ -456,29 +440,29 @@ class DetailSplit extends Component {
width
:
'100%'
,
width
:
'100%'
,
display
:
'flex'
,
display
:
'flex'
,
justifyContent
:
'center'
,
justifyContent
:
'center'
,
}}
}}
>
>
<
div
style
=
{{
width
:
'100%'
}}
>
<
div
style
=
{{
width
:
'100%'
}}
>
<
div
<
div
className
=
{
styles
.
header
}
className
=
{
styles
.
header
}
style
=
{{
style
=
{{
position
:
'relative'
,
position
:
'relative'
,
}}
}}
>
>
{
isCloseFlowPath
?
null
:
(
// 关闭流程紧急度显示
{
isCloseFlowPath
?
null
:
(
// 关闭流程紧急度显示
<
span
<
span
style
=
{{
style
=
{{
position
:
'absolute'
,
position
:
'absolute'
,
left
:
0
,
left
:
0
,
top
:
'30%'
,
top
:
'30%'
,
}}
}}
>
>
{
isSecond
?
(
{
isSecond
?
(
<>
<>
<
span
style
=
{{
marginRight
:
12
}}
>
{
must
}
流程紧急度
<
/span
>
<
span
style
=
{{
marginRight
:
12
}}
>
{
must
}
流程紧急度
<
/span
>
<
Radio
.
Group
onChange
=
{
this
.
onChange
}
value
=
{
radiovalue
}
>
<
Radio
.
Group
onChange
=
{
this
.
onChange
}
value
=
{
radiovalue
}
>
{
btnList
.
length
>
0
{
btnList
.
length
>
0
?
btnList
.
map
(
item
=>
(
?
btnList
.
map
((
item
)
=>
(
<
Radio
key
=
{
item
.
id
+
Math
.
random
()}
value
=
{
item
.
id
}
>
<
Radio
key
=
{
item
.
id
+
Math
.
random
()}
value
=
{
item
.
id
}
>
<
span
style
=
{{
color
:
item
.
color
}}
>
{
item
.
name
}
<
/span
>
<
span
style
=
{{
color
:
item
.
color
}}
>
{
item
.
name
}
<
/span
>
<
/Radio
>
<
/Radio
>
...
@@ -493,8 +477,7 @@ class DetailSplit extends Component {
...
@@ -493,8 +477,7 @@ class DetailSplit extends Component {
style
=
{{
style
=
{{
color
:
formColor
||
''
,
color
:
formColor
||
''
,
marginLeft
:
21
,
marginLeft
:
21
,
}}
}}
>
>
{
formLevel
||
'暂无'
}
{
formLevel
||
'暂无'
}
<
/span
>
<
/span
>
<
/
>
<
/
>
...
@@ -531,7 +514,7 @@ class DetailSplit extends Component {
...
@@ -531,7 +514,7 @@ class DetailSplit extends Component {
表单间距
:
表单间距
:
<
InputNumber
<
InputNumber
min
=
{
0
}
min
=
{
0
}
size
=
'small'
size
=
"small"
value
=
{
paddingBottom
}
value
=
{
paddingBottom
}
onChange
=
{
this
.
changePadding
}
onChange
=
{
this
.
changePadding
}
/
>
/
>
...
@@ -546,9 +529,8 @@ class DetailSplit extends Component {
...
@@ -546,9 +529,8 @@ class DetailSplit extends Component {
<
/div
>
<
/div
>
<
/div
>
<
/div
>
}
}
okText
=
'确定'
okText
=
"确定"
cancelText
=
'取消'
cancelText
=
"取消"
>
>
{(
data
.
isPrint
==
null
||
data
.
isPrint
||
isAllPrint
)
&&
showPrint
!==
false
?
(
{(
data
.
isPrint
==
null
||
data
.
isPrint
||
isAllPrint
)
&&
showPrint
!==
false
?
(
<
Button
<
Button
style
=
{{
style
=
{{
...
@@ -556,8 +538,7 @@ class DetailSplit extends Component {
...
@@ -556,8 +538,7 @@ class DetailSplit extends Component {
right
:
200
,
right
:
200
,
top
:
'30%'
,
top
:
'30%'
,
}}
}}
type
=
'primary'
type
=
"primary"
>
>
打印预览
打印预览
<
/Button
>
<
/Button
>
)
:
(
)
:
(
...
@@ -571,8 +552,7 @@ class DetailSplit extends Component {
...
@@ -571,8 +552,7 @@ class DetailSplit extends Component {
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
{
isLoading
?
{
isLoading
?
(
(
<>
<>
<
Card
style
=
{{
width
:
'100%'
}}
>
<
Card
style
=
{{
width
:
'100%'
}}
>
{
!
isCloseUserDetail
&&
(
{
!
isCloseUserDetail
&&
(
...
@@ -586,72 +566,71 @@ class DetailSplit extends Component {
...
@@ -586,72 +566,71 @@ class DetailSplit extends Component {
data
.
userPhone
||
data
.
userPhone
||
data
.
userSchool
)
&&
(
data
.
userSchool
)
&&
(
<
Row
className
=
{
styles
.
row
}
>
<
Row
className
=
{
styles
.
row
}
>
{
data
&&
data
.
code
&&
(
{
data
&&
data
.
code
&&
(
<
Col
<
Col
style
=
{{
style
=
{{
marginBottom
:
12
,
marginBottom
:
12
,
}}
}}
span
=
{
8
}
span
=
{
8
}
>
>
<
span
className
=
{
styles
.
hea_title
}
>
单号
<
/span
>
<
span
className
=
{
styles
.
hea_title
}
>
单号
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
code
}
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
code
}
<
/span
>
<
/Col
>
<
/Col
>
)}
)}
{
data
&&
data
.
userName
&&
(
{
data
&&
data
.
userName
&&
(
<
Col
<
Col
style
=
{{
style
=
{{
marginBottom
:
12
,
marginBottom
:
12
,
}}
}}
span
=
{
8
}
span
=
{
8
}
>
>
<
span
className
=
{
styles
.
hea_title
}
>
用户姓名
<
/span
>
<
span
className
=
{
styles
.
hea_title
}
>
用户姓名
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userName
}
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userName
}
<
/span
>
<
/Col
>
<
/Col
>
)}
)}
{
data
&&
data
.
userPosition
&&
(
{
data
&&
data
.
userPosition
&&
(
<
Col
<
Col
style
=
{{
style
=
{{
marginBottom
:
12
,
marginBottom
:
12
,
}}
}}
span
=
{
8
}
span
=
{
8
}
>
>
<
span
className
=
{
styles
.
hea_title
}
>
职位
<
/span
>
<
span
className
=
{
styles
.
hea_title
}
>
职位
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userPosition
}
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userPosition
}
<
/span
>
<
/Col
>
<
/Col
>
)}
)}
{
data
&&
data
.
userSchool
&&
(
{
data
&&
data
.
userSchool
&&
(
<
Col
<
Col
span
=
{
8
}
span
=
{
8
}
style
=
{{
style
=
{{
marginBottom
:
12
,
marginBottom
:
12
,
}}
}}
>
>
<
span
className
=
{
styles
.
hea_title
}
>
学院
/
单位
<
/span
>
<
span
className
=
{
styles
.
hea_title
}
>
学院
/
单位
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userSchool
}
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userSchool
}
<
/span
>
<
/Col
>
<
/Col
>
)}
)}
{
data
&&
data
.
userPhone
&&
(
{
data
&&
data
.
userPhone
&&
(
<
Col
<
Col
span
=
{
8
}
span
=
{
8
}
style
=
{{
style
=
{{
marginBottom
:
12
,
marginBottom
:
12
,
}}
}}
>
>
<
span
className
=
{
styles
.
hea_title
}
>
联系电话
<
/span
>
<
span
className
=
{
styles
.
hea_title
}
>
联系电话
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userPhone
}
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
{
data
.
userPhone
}
<
/span
>
<
/Col
>
<
/Col
>
)}
)}
{
data
&&
data
.
createTime
&&
(
{
data
&&
data
.
createTime
&&
(
<
Col
<
Col
style
=
{{
style
=
{{
marginBottom
:
12
,
marginBottom
:
12
,
}}
}}
span
=
{
8
}
span
=
{
8
}
>
>
<
span
className
=
{
styles
.
hea_title
}
>
申请时间
<
/span
>
<
span
className
=
{
styles
.
hea_title
}
>
申请时间
<
/span
>
<
span
className
=
{
styles
.
hew_content
}
>
<
span
className
=
{
styles
.
hew_content
}
>
{
moment
(
data
.
createTime
)
{
moment
(
data
.
createTime
).
format
(
'YYYY-MM-DD HH:mm'
)}
.
format
(
'YYYY-MM-DD HH:mm'
)}
<
/span
>
<
/span
>
<
/Col
>
<
/Col
>
)}
)}
...
@@ -661,26 +640,26 @@ class DetailSplit extends Component {
...
@@ -661,26 +640,26 @@ class DetailSplit extends Component {
)}
)}
<
div
<
div
className
=
{
styles
.
HistoryFormList
}
className
=
{
styles
.
HistoryFormList
}
id
=
'card_table'
id
=
"card_table"
ref
=
{
el
=>
(
this
.
componentRef
=
el
)}
ref
=
{(
el
)
=>
(
this
.
componentRef
=
el
)}
style
=
{{
padding
:
!
isShowTitle
?
'50px'
:
''
}}
style
=
{{
padding
:
!
isShowTitle
?
'50px'
:
''
}}
>
>
<
HistoryFormList
<
HistoryFormList
data
=
{
data
}
data
=
{
data
}
formKeys
=
{
hisTaskFormKeys
?.
formKeys
}
formKeys
=
{
hisTaskFormKeys
?.
formKeys
}
isShowTitle
=
{
isShowTitle
}
isShowTitle
=
{
isShowTitle
}
routerState
=
{
routerState
}
routerState
=
{
routerState
}
formData
=
{
hisTaskFormKeys
?.
formData
}
formData
=
{
hisTaskFormKeys
?.
formData
}
/
>
/
>
{
isHandle
===
true
&&
!!
data
.
taskFormKey
&&
(
{
isHandle
===
true
&&
!!
data
.
taskFormKey
&&
(
<>
<>
{
isShowTitle
?
(
{
isShowTitle
?
(
<
h3
<
h3
style
=
{{
style
=
{{
display
:
'flex'
,
display
:
'flex'
,
alignItems
:
'center'
,
alignItems
:
'center'
,
}}
}}
>
>
<
SVG
name
=
"vertical"
color
=
"#999999"
height
=
"24"
/>
<
SVG
name
=
'vertical'
color
=
'#999999'
height
=
'24'
/>
当前流程
当前流程
<
/h3
>
<
/h3
>
)
:
(
)
:
(
...
@@ -690,9 +669,9 @@ class DetailSplit extends Component {
...
@@ -690,9 +669,9 @@ class DetailSplit extends Component {
<
ZdyTable
<
ZdyTable
key
=
{
data
.
taskFormKey
}
key
=
{
data
.
taskFormKey
}
postData
=
{
data
}
postData
=
{
data
}
get
=
'web'
get
=
"web"
obj
=
{
hisTaskFormKeys
.
formData
}
obj
=
{
hisTaskFormKeys
.
formData
}
table
=
'new'
table
=
"new"
form
=
{
this
.
props
.
form
}
form
=
{
this
.
props
.
form
}
routerState
=
{
routerState
}
routerState
=
{
routerState
}
/
>
/
>
...
@@ -705,16 +684,15 @@ class DetailSplit extends Component {
...
@@ -705,16 +684,15 @@ class DetailSplit extends Component {
<
/Card
>
<
/Card
>
<
Card
style
=
{{
width
:
'100%'
}}
>
<
Card
style
=
{{
width
:
'100%'
}}
>
<
div
className
=
{
styles
.
body_content
}
style
=
{{
minHeight
:
'300px'
}}
>
<
div
className
=
{
styles
.
body_content
}
style
=
{{
minHeight
:
'300px'
}}
>
<
div
id
=
{
'btnsModalMountDiv'
}
><
/div
>
<
div
id
=
{
'btnsModalMountDiv'
}
/
>
<
h3
>
<
h3
>
审批状态
<
span
onClick
=
{
this
.
examineFlow
}
>
查看流程图
<
/span
>
审批状态
<
span
onClick
=
{
this
.
examineFlow
}
>
查看流程图
<
/span
>
<
/h3
>
<
/h3
>
<
div
<
div
ref
=
{
el
=>
(
this
.
componentTwoRef
=
el
)}
ref
=
{(
el
)
=>
(
this
.
componentTwoRef
=
el
)}
style
=
{{
style
=
{{
padding
:
!
isShowTitle
?
'0 50px 50px 50px'
:
''
,
padding
:
!
isShowTitle
?
'0 50px 50px 50px'
:
''
,
}}
}}
>
>
<
Timeline
>
<
Timeline
>
{
stepFlow
!==
''
&&
steps
!==
''
{
stepFlow
!==
''
&&
steps
!==
''
?
stepFlow
.
map
((
item
,
index
)
=>
{
?
stepFlow
.
map
((
item
,
index
)
=>
{
...
@@ -726,39 +704,47 @@ class DetailSplit extends Component {
...
@@ -726,39 +704,47 @@ class DetailSplit extends Component {
dot
=
{
dot
=
{
<
Icon
<
Icon
type
=
{
type
=
{
[
'处理中'
,
'待处理'
].
includes
(
item
.
status
)
?
'clock-circle-o'
:
'check-circle'
[
'处理中'
,
'待处理'
].
includes
(
item
.
status
)
?
'clock-circle-o'
:
'check-circle'
}
}
style
=
{{
fontSize
:
'16px'
}}
style
=
{{
fontSize
:
'16px'
}}
/
>
/
>
}
}
className
=
{
styles
.
steps_step
}
className
=
{
styles
.
steps_step
}
key
=
{
item
.
id
}
key
=
{
item
.
id
}
>
>
<
p
className
=
{
styles
.
steps_title
}
>
<
p
className
=
{
styles
.
steps_title
}
>
{
item
.
assignee
}
{
item
.
assignee
}
<
span
>
<
span
>
{
item
.
endTime
{
item
.
endTime
?
moment
(
item
.
endTime
)
?
moment
(
item
.
endTime
).
format
(
'YYYY-MM-DD HH:mm'
)
.
format
(
'YYYY-MM-DD HH:mm'
)
:
'处理中'
}
:
'处理中'
}
<
/span
>
<
/span
>
<
/p
>
<
/p
>
{
{
queryApiVersion
()
===
'2.0'
&&
queryApiVersion
()
===
'2.0'
&&
[
'处理中'
,
'待处理'
].
includes
(
item
.
status
)
&&
!!
data
.
nextUsers
&&
(
[
'处理中'
,
'待处理'
].
includes
(
item
.
status
)
&&
<
p
>
审批人员
:
{
data
.
nextUsers
}
<
/p
>
!!
data
.
nextUsers
&&
<
p
>
审批人员
:
{
data
.
nextUsers
}
<
/p>
}
)
{
queryApiVersion
()
!==
'2.0'
&&
}
[
'处理中'
,
'待处理'
].
includes
(
item
.
status
)
&&
{
queryApiVersion
()
!==
'2.0'
&&
[
'处理中'
,
'待处理'
].
includes
(
item
.
status
)
&&
!!
item
.
nextUsers
&&
(
!!
item
.
nextUsers
&&
<
p
>
审批人员
:
{
item
.
nextUsers
}
<
/p>
}
<
p
>
审批人员
:
{
item
.
nextUsers
}
<
/p
>
<
p
>
)}
审批流程:
<
p
>
审批流程:
{
item
.
name
}
<
/p
>
{
item
.
name
}
<
p
className
=
{
styles
.
steps_body
}
>
审批状态:
{
item
.
status
}
<
/p
>
<
/p
>
<
p
className
=
{
styles
.
steps_body
}
>
审批状态:
{
item
.
status
}
<
/p
>
{
item
.
taskVariable
?.
reason
?
(
{
item
.
taskVariable
?.
reason
?
(
<
p
>
审批原因:
{
item
.
taskVariable
?.
reason
}
<
/p
>
<
p
>
审批原因:
{
item
.
taskVariable
?.
reason
}
<
/p
>
)
:
(
)
:
(
''
''
)}
)}
{
item
.
childTaskModel
&&
item
.
childTaskModel
.
length
>
0
&&
(
{
item
.
childTaskModel
&&
item
.
childTaskModel
.
length
>
0
&&
(
<
ChildTaskModel
data
=
{
item
.
childTaskModel
}
/
>
<
ChildTaskModel
data
=
{
item
.
childTaskModel
}
/
>
)}
)}
...
@@ -777,7 +763,7 @@ class DetailSplit extends Component {
...
@@ -777,7 +763,7 @@ class DetailSplit extends Component {
?
queryApiActionPath
()
+
item
.
taskVariable
?.
sign
?
queryApiActionPath
()
+
item
.
taskVariable
?.
sign
:
''
:
''
}
}
alt
=
''
alt
=
""
/>
/>
)
:
(
)
:
(
''
''
...
@@ -796,32 +782,40 @@ class DetailSplit extends Component {
...
@@ -796,32 +782,40 @@ class DetailSplit extends Component {
''
''
)
:
(
)
:
(
<
Icon
<
Icon
type
=
'check-circle'
type
=
"check-circle"
theme
=
'twoTone'
theme
=
"twoTone"
twoToneColor
=
'#52c41a'
twoToneColor
=
"#52c41a"
/>
/>
)
)
}
}
className
=
{
styles
.
steps_step
}
className
=
{
styles
.
steps_step
}
key
=
{
item
.
id
}
key
=
{
item
.
id
}
>
>
<
p
className
=
{
styles
.
steps_title
}
>
<
p
className
=
{
styles
.
steps_title
}
>
{
item
.
assignee
}
{
item
.
assignee
}
<
span
>
<
span
>
{
item
.
endTime
{
item
.
endTime
?
moment
(
item
.
endTime
)
?
moment
(
item
.
endTime
).
format
(
'YYYY-MM-DD HH:mm'
)
.
format
(
'YYYY-MM-DD HH:mm'
)
:
null
}
:
null
}
<
/span
>
<
/span
>
<
/p
>
<
/p
>
<
p
>
审批流程:
{
item
.
name
}
<
/p
>
<
p
>
<
p
className
=
{
styles
.
steps_body
}
>
审批状态:
{
item
.
status
}
<
/p
>
审批流程:
{
item
.
name
}
<
/p
>
<
p
className
=
{
styles
.
steps_body
}
>
审批状态:
{
item
.
status
}
<
/p
>
{
item
.
taskVariable
?.
reason
?
(
{
item
.
taskVariable
?.
reason
?
(
<
p
>
审批原因:
{
item
.
taskVariable
.
reason
}
<
/p
>
<
p
>
审批原因:
{
item
.
taskVariable
.
reason
}
<
/p
>
)
:
(
)
:
(
''
''
)}
)}
{
item
.
childTaskModel
&&
item
.
childTaskModel
.
length
>
0
&&
(
{
item
.
childTaskModel
&&
item
.
childTaskModel
.
length
>
0
&&
(
<
ChildTaskModel
data
=
{
item
.
childTaskModel
}
/
>
<
ChildTaskModel
data
=
{
item
.
childTaskModel
}
/
>
)}
)}
{
item
.
taskVariable
?.
sign
?
(
{
item
.
taskVariable
?.
sign
?
(
...
@@ -839,7 +833,7 @@ class DetailSplit extends Component {
...
@@ -839,7 +833,7 @@ class DetailSplit extends Component {
?
queryApiActionPath
()
+
item
.
taskVariable
?.
sign
?
queryApiActionPath
()
+
item
.
taskVariable
?.
sign
:
''
:
''
}
}
alt
=
''
alt
=
""
/>
/>
)
:
(
)
:
(
''
''
...
@@ -884,8 +878,7 @@ class DetailSplit extends Component {
...
@@ -884,8 +878,7 @@ class DetailSplit extends Component {
data
,
data
,
);
);
}}
}}
type
=
'primary'
type
=
"primary"
>
>
{
data
.
isHandle
&&
data
.
isOwner
{
data
.
isHandle
&&
data
.
isOwner
?
'转办'
?
'转办'
:
!
data
.
isHandle
&&
data
.
isOwner
:
!
data
.
isHandle
&&
data
.
isOwner
...
@@ -903,8 +896,7 @@ class DetailSplit extends Component {
...
@@ -903,8 +896,7 @@ class DetailSplit extends Component {
minWidth
:
90
,
minWidth
:
90
,
}}
}}
onClick
=
{
this
.
onClickCountersign
}
onClick
=
{
this
.
onClickCountersign
}
type
=
'primary'
type
=
"primary"
>
>
加签
加签
<
/Button
>
<
/Button
>
)}
)}
...
@@ -915,13 +907,15 @@ class DetailSplit extends Component {
...
@@ -915,13 +907,15 @@ class DetailSplit extends Component {
)
:
(
)
:
(
''
''
)}
)}
{
isTrunTo
&&
data
.
isSecond
!==
true
&&
!
data
.
isHandle
&&
data
.
isOwner
&&
(
{
isTrunTo
&&
data
.
isSecond
!==
true
&&
!
data
.
isHandle
&&
data
.
isOwner
&&
(
<
div
<
div
style
=
{{
style
=
{{
width
:
'100%'
,
width
:
'100%'
,
textAlign
:
'center'
,
textAlign
:
'center'
,
}}
}}
>
>
<
Button
<
Button
style
=
{{
style
=
{{
minHeight
:
32
,
minHeight
:
32
,
...
@@ -931,8 +925,7 @@ class DetailSplit extends Component {
...
@@ -931,8 +925,7 @@ class DetailSplit extends Component {
onClick
=
{()
=>
{
onClick
=
{()
=>
{
this
.
showTrunToModel
(
'撤回'
,
data
);
this
.
showTrunToModel
(
'撤回'
,
data
);
}}
}}
type
=
'primary'
type
=
"primary"
>
>
撤回
撤回
<
/Button
>
<
/Button
>
<
/div
>
<
/div
>
...
@@ -947,13 +940,12 @@ class DetailSplit extends Component {
...
@@ -947,13 +940,12 @@ class DetailSplit extends Component {
display
:
'flex'
,
display
:
'flex'
,
justifyContent
:
'center'
,
justifyContent
:
'center'
,
alignItems
:
'center'
,
alignItems
:
'center'
,
}}
}}
>
>
<
Spin
size
=
"large"
spinning
=
{
true
}
/
>
<
Spin
size
=
'large'
spinning
=
{
true
}
/
>
<
/div
>
<
/div
>
)}
)}
<
PortalFlowExamineModal
// 流程图
<
PortalFlowExamineModal
// 流程图
ref
=
{
node
=>
(
this
.
flowExamineModal
=
node
)}
ref
=
{(
node
)
=>
(
this
.
flowExamineModal
=
node
)}
affairId
=
{
id
}
affairId
=
{
id
}
id
=
{
appId
}
id
=
{
appId
}
code
=
{
code
}
code
=
{
code
}
...
@@ -978,10 +970,49 @@ class DetailSplit extends Component {
...
@@ -978,10 +970,49 @@ class DetailSplit extends Component {
}
}
}
}
export
default
function
Index
(
props
){
function
Index
(
props
)
{
console
.
log
(
window
.
zdyTableTemplateWillMountProps
?.
formCreateOptions
);
const
{
dispatch
,
history
}
=
props
;
const
[
prepare
,
setPrepare
]
=
useState
(
false
);
useEffect
(()
=>
{
const
id
=
history
.
location
.
state
&&
history
.
location
.
state
.
id
;
const
code
=
history
.
location
.
state
&&
history
.
location
.
state
.
code
;
const
queryId
=
history
.
location
.
query
&&
history
.
location
.
query
.
id
;
const
taskId
=
history
.
location
.
state
&&
history
.
location
.
state
.
taskId
;
if
(
!
id
&&
!
code
)
{
if
(
queryId
)
{
}
else
{
openToast
(
'error'
,
'数据已过期'
,
'当前页面数据已过期,请重新进入'
);
return
;
}
}
message
.
info
(
'正在加载数据,请等待。'
);
dispatch
({
type
:
'affair/getIdFormDetail'
,
payload
:
{
id
:
queryId
?
queryId
:
id
,
// 审批表Id
code
:
code
||
null
,
// 表单值
handleUser
:
null
,
// 处理人
taskId
,
// 多任务流程会使用到,后续改为必须传入
lite
:
true
,
},
callback
:
(
val
)
=>
{
if
(
val
)
{
setPrepare
(
val
);
}
},
});
},
[]);
if
(
!
prepare
)
{
return
<
Spin
size
=
"large"
spinning
=
{
true
}
/>
;
}
const
DetailSplitFormNew
=
Form
.
create
(
const
DetailSplitFormNew
=
Form
.
create
(
window
.
zdyTableTemplateWillMountProps
?.
formCreateOptions
||
undefined
,
window
.
zdyTableTemplateWillMountProps
?.
formCreateOptions
||
undefined
,
)(
DetailSplit
);
)(
DetailSplit
);
return
<
DetailSplitFormNew
{...
props
}
/>
;
return
<
DetailSplitFormNew
{...
props
}
formPrepareData
=
{
prepare
}
/>
;
}
}
export
default
connect
(()
=>
{
return
{};
})(
Index
);
one_stop_public/ForZydApply/index.js
浏览文件 @
93c4167d
...
@@ -49,7 +49,8 @@ export default class IframeForApply extends React.Component {
...
@@ -49,7 +49,8 @@ export default class IframeForApply extends React.Component {
}
=
props
;
}
=
props
;
this
.
state
=
{
this
.
state
=
{
id
,
// 传入id
id
,
// 传入id
init
:
init
&&
isJSON
(
init
)
?
JSON
.
parse
(
decodeURIComponent
(
init
))
:
undefined
,
init
:
init
||
undefined
,
// 2022年8月9日 发起页面的默认值可以通过这个init 传进来
value
:
''
,
// 紧急度选择
value
:
''
,
// 紧急度选择
btnList
:
[],
// 紧急度按钮返回数据
btnList
:
[],
// 紧急度按钮返回数据
noNeedApply
,
noNeedApply
,
...
...
one_stop_public/Table/ZdyTable.jsx
浏览文件 @
93c4167d
...
@@ -19,6 +19,7 @@ import getActiveJson from '@/webPublic/one_stop_public/Table/getActiveJson';
...
@@ -19,6 +19,7 @@ import getActiveJson from '@/webPublic/one_stop_public/Table/getActiveJson';
export
default
class
ZdyTable
extends
Component
{
export
default
class
ZdyTable
extends
Component
{
constructor
(
props
)
{
constructor
(
props
)
{
super
(
props
);
super
(
props
);
console
.
log
(
props
);
this
.
state
=
{
this
.
state
=
{
objRealTime
:
{},
objRealTime
:
{},
isChange
:
false
,
isChange
:
false
,
...
...
one_stop_public/Table/globalFunction.js
浏览文件 @
93c4167d
...
@@ -796,9 +796,9 @@ export async function downloadFile(url, params, fileName = '导出文件', ext =
...
@@ -796,9 +796,9 @@ export async function downloadFile(url, params, fileName = '导出文件', ext =
let
headers
=
{
let
headers
=
{
Authorization
:
`bearer
${
localStorage
.
getItem
(
'antd-pro-token-onestop'
)}
`
,
Authorization
:
`bearer
${
localStorage
.
getItem
(
'antd-pro-token-onestop'
)}
`
,
};
};
if
(
headersApi
){
//
if(headersApi){
headers
.
apis
=
headersApi
;
//
headers.apis = headersApi;
}
//
}
fetch
(
transformApi
,
{
fetch
(
transformApi
,
{
method
:
'POST'
,
method
:
'POST'
,
body
:
FormdataWrapper
(
params
),
body
:
FormdataWrapper
(
params
),
...
@@ -840,9 +840,9 @@ export async function downloadFileAndShowModal(url, params, fileName = '导出
...
@@ -840,9 +840,9 @@ export async function downloadFileAndShowModal(url, params, fileName = '导出
let
headers
=
{
let
headers
=
{
Authorization
:
`bearer
${
localStorage
.
getItem
(
'antd-pro-token-onestop'
)}
`
,
Authorization
:
`bearer
${
localStorage
.
getItem
(
'antd-pro-token-onestop'
)}
`
,
};
};
if
(
headersApi
){
//
if(headersApi){
headers
.
apis
=
headersApi
;
//
headers.apis = headersApi;
}
//
}
fetch
(
transformApi
,
{
fetch
(
transformApi
,
{
method
:
'POST'
,
method
:
'POST'
,
body
:
FormdataWrapper
(
params
),
body
:
FormdataWrapper
(
params
),
...
...
one_stop_public/libs/TableSelect.js
浏览文件 @
93c4167d
import
React
from
"react"
;
import
React
from
'react'
;
import
{
Button
,
message
,
Table
,
Tag
}
from
"antd"
;
import
{
Button
,
message
,
Table
,
Tag
}
from
'antd'
;
import
FormList
from
"./formList/index"
;
import
FormList
from
'./formList/index'
;
import
{
connect
}
from
"dva"
;
import
{
connect
}
from
'dva'
;
import
{
getModal
}
from
'@/webPublic/one_stop_public/utils/utils'
;
import
{
getModal
}
from
'@/webPublic/one_stop_public/utils/utils'
;
import
TableSelectNormal
from
'@/webPublic/one_stop_public/libs/Split/TableSelectNormal'
;
import
TableSelectNormal
from
'@/webPublic/one_stop_public/libs/Split/TableSelectNormal'
;
import
styles
from
'./Split/styles.less'
;
import
styles
from
'./Split/styles.less'
;
const
Modal
=
getModal
();
const
Modal
=
getModal
();
@
connect
(({
DataColumn
,
SqlManageEntity
,
loading
})
=>
({
@
connect
(({
DataColumn
,
SqlManageEntity
,
loading
})
=>
({
DataColumn
,
DataColumn
,
SqlManageEntity
,
SqlManageEntity
,
loading
:
loading
.
models
.
DataColumn
||
loading
.
models
.
SqlManageEntity
,
loading
:
loading
.
models
.
DataColumn
||
loading
.
models
.
SqlManageEntity
,
...
@@ -22,7 +27,7 @@ export default class TableSelect extends React.Component {
...
@@ -22,7 +27,7 @@ export default class TableSelect extends React.Component {
try
{
try
{
this
.
otherProps
=
new
Function
(
props
.
json
.
otherProps
)();
this
.
otherProps
=
new
Function
(
props
.
json
.
otherProps
)();
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
'TableSelect组件 otherProps 获取失败'
)
console
.
log
(
'TableSelect组件 otherProps 获取失败'
)
;
}
}
}
}
this
.
state
=
{
this
.
state
=
{
...
@@ -67,7 +72,10 @@ export default class TableSelect extends React.Component {
...
@@ -67,7 +72,10 @@ export default class TableSelect extends React.Component {
select
=
(
obj
)
=>
{
select
=
(
obj
)
=>
{
var
{
selects
}
=
this
.
state
;
var
{
selects
}
=
this
.
state
;
const
{
const
{
json
:
{
isMultiple
,
optionType
},
json
:
{
isMultiple
,
optionType
},
}
=
this
.
props
;
}
=
this
.
props
;
let
valueName
=
this
.
props
.
json
.
valueName
;
let
valueName
=
this
.
props
.
json
.
valueName
;
...
@@ -81,7 +89,12 @@ export default class TableSelect extends React.Component {
...
@@ -81,7 +89,12 @@ export default class TableSelect extends React.Component {
return
;
return
;
}
}
if
(
!
isMultiple
)
{
if
(
!
isMultiple
)
{
selects
=
{
[
kk
]:
{
...
obj
,
selectKey
:
kk
}
};
selects
=
{
[
kk
]:
{
...
obj
,
selectKey
:
kk
}
};
}
else
{
}
else
{
selects
[
kk
]
=
obj
;
selects
[
kk
]
=
obj
;
selects
[
kk
].
selectKey
=
kk
;
selects
[
kk
].
selectKey
=
kk
;
...
@@ -94,8 +107,14 @@ export default class TableSelect extends React.Component {
...
@@ -94,8 +107,14 @@ export default class TableSelect extends React.Component {
selectAll
=
()
=>
{
selectAll
=
()
=>
{
let
{
selects
}
=
this
.
state
;
let
{
selects
}
=
this
.
state
;
const
{
dataSource
,
json
}
=
this
.
props
;
const
{
let
{
valueName
,
optionType
}
=
json
;
dataSource
,
json
}
=
this
.
props
;
let
{
valueName
,
optionType
}
=
json
;
const
{
list
}
=
dataSource
;
const
{
list
}
=
dataSource
;
if
(
optionType
==
'reference'
&&
this
.
props
.
dataColumn
.
referenceObjId
)
{
if
(
optionType
==
'reference'
&&
this
.
props
.
dataColumn
.
referenceObjId
)
{
valueName
=
this
.
props
.
dataColumn
.
referenceCodeName
;
valueName
=
this
.
props
.
dataColumn
.
referenceCodeName
;
...
@@ -122,13 +141,22 @@ export default class TableSelect extends React.Component {
...
@@ -122,13 +141,22 @@ export default class TableSelect extends React.Component {
};
};
close
=
(
i
)
=>
{
close
=
(
i
)
=>
{
var
{
values
,
labels
}
=
this
.
state
;
var
{
values
,
labels
}
=
this
.
state
;
values
.
splice
(
i
,
1
);
values
.
splice
(
i
,
1
);
labels
.
splice
(
i
,
1
);
labels
.
splice
(
i
,
1
);
if
(
!
(
'value'
in
this
.
props
))
{
if
(
!
(
'value'
in
this
.
props
))
{
this
.
setState
({
values
,
labels
});
this
.
setState
({
values
,
labels
});
}
}
this
.
triggerChange
({
values
,
labels
});
this
.
triggerChange
({
values
,
labels
});
};
};
open
=
()
=>
{
open
=
()
=>
{
...
@@ -150,7 +178,10 @@ export default class TableSelect extends React.Component {
...
@@ -150,7 +178,10 @@ export default class TableSelect extends React.Component {
cancelOne
=
(
record
)
=>
{
cancelOne
=
(
record
)
=>
{
var
{
selects
}
=
this
.
state
;
var
{
selects
}
=
this
.
state
;
const
{
const
{
json
:
{
isMultiple
,
optionType
},
json
:
{
isMultiple
,
optionType
},
}
=
this
.
props
;
}
=
this
.
props
;
let
valueName
=
this
.
props
.
json
.
valueName
;
let
valueName
=
this
.
props
.
json
.
valueName
;
...
@@ -174,16 +205,25 @@ export default class TableSelect extends React.Component {
...
@@ -174,16 +205,25 @@ export default class TableSelect extends React.Component {
render
()
{
render
()
{
const
{
const
{
json
:
{
isMultiple
,
sql
,
optionType
,
showTable
,
isShowQuanXuan
},
json
:
{
isMultiple
,
sql
,
optionType
,
showTable
,
isShowQuanXuan
},
dataColumn
:
{
referenceObjId
},
dataColumn
:
{
referenceObjId
},
sqlModel
,
sqlModel
,
columns
,
columns
,
dataSource
,
dataSource
,
disabled
,
}
=
this
.
props
;
}
=
this
.
props
;
let
disabled
=
this
.
props
.
disabled
||
this
.
props
.
json
.
disabled
;
// 禅道 28713
const
{
cardSelectModalProps
=
{}
}
=
this
.
otherProps
;
const
{
cardSelectModalProps
=
{}
}
=
this
.
otherProps
;
let
{
valueName
,
labelName
}
=
this
.
props
.
json
;
let
{
valueName
,
labelName
}
=
this
.
props
.
json
;
if
(
optionType
==
'reference'
&&
referenceObjId
)
{
if
(
optionType
==
'reference'
&&
referenceObjId
)
{
valueName
=
this
.
props
.
dataColumn
.
referenceCodeName
;
valueName
=
this
.
props
.
dataColumn
.
referenceCodeName
;
labelName
=
this
.
props
.
dataColumn
.
referenceNameName
;
labelName
=
this
.
props
.
dataColumn
.
referenceNameName
;
...
@@ -191,21 +231,29 @@ export default class TableSelect extends React.Component {
...
@@ -191,21 +231,29 @@ export default class TableSelect extends React.Component {
if
(
valueName
==
null
||
valueName
==
''
)
{
if
(
valueName
==
null
||
valueName
==
''
)
{
return
<>
请指定取值的列名
<
/>
;
return
<>
请指定取值的列名
<
/>
;
}
}
const
{
selects
,
visiable
,
labels
}
=
this
.
state
;
const
{
selects
,
visiable
,
labels
}
=
this
.
state
;
const
keys
=
[];
const
keys
=
[];
for
(
let
i
in
selects
)
{
for
(
let
i
in
selects
)
{
keys
.
push
(
selects
[
i
][
valueName
]);
keys
.
push
(
selects
[
i
][
valueName
]);
}
}
const
columns2
=
[
const
columns2
=
[
...
columns
,
...
columns
,
{
];
if
(
!
disabled
)
{
columns2
.
push
({
title
:
'操作'
,
title
:
'操作'
,
render
:
(
val
,
record
)
=>
<
a
onClick
=
{
this
.
remove
.
bind
(
this
,
record
.
selectKey
)}
>
移除
<
/a>
,
render
:
(
val
,
record
)
=>
<
a
onClick
=
{
this
.
remove
.
bind
(
this
,
record
.
selectKey
)}
>
移除
<
/a>
,
},
},);
];
}
const
columns3
=
[
const
columns3
=
[
...
columns
,
...
columns
,
{
];
if
(
!
disabled
)
{
columns3
.
push
(
{
title
:
'操作'
,
title
:
'操作'
,
render
:
(
val
,
record
)
=>
render
:
(
val
,
record
)
=>
keys
.
includes
(
record
[
valueName
])
?
(
keys
.
includes
(
record
[
valueName
])
?
(
...
@@ -218,8 +266,10 @@ export default class TableSelect extends React.Component {
...
@@ -218,8 +266,10 @@ export default class TableSelect extends React.Component {
)
:
(
)
:
(
<
a
onClick
=
{
this
.
select
.
bind
(
this
,
record
)}
>
选择
<
/a
>
<
a
onClick
=
{
this
.
select
.
bind
(
this
,
record
)}
>
选择
<
/a
>
),
),
},
},);
];
}
const
custom
=
{
const
custom
=
{
isAll
:
this
.
state
.
isAll
,
isAll
:
this
.
state
.
isAll
,
querys
:
this
.
state
.
querys
,
querys
:
this
.
state
.
querys
,
...
@@ -260,7 +310,8 @@ export default class TableSelect extends React.Component {
...
@@ -260,7 +310,8 @@ export default class TableSelect extends React.Component {
pagination
=
{
false
}
pagination
=
{
false
}
/
>
/
>
)
:
(
)
:
(
Object
.
keys
(
selects
).
map
((
k
)
=>
(
Object
.
keys
(
selects
)
.
map
((
k
)
=>
(
<
Tag
key
=
{
k
}
closable
=
{
!
disabled
}
onClose
=
{
this
.
remove
.
bind
(
this
,
k
)}
>
<
Tag
key
=
{
k
}
closable
=
{
!
disabled
}
onClose
=
{
this
.
remove
.
bind
(
this
,
k
)}
>
{
selects
[
k
][
labelName
]}
{
selects
[
k
][
labelName
]}
<
/Tag
>
<
/Tag
>
...
...
one_stop_public/libs/formList/TreeList.js
浏览文件 @
93c4167d
...
@@ -248,18 +248,7 @@ class TreeList extends React.Component {
...
@@ -248,18 +248,7 @@ class TreeList extends React.Component {
});
});
},
},
});
});
// } else {
// router.push({
// pathname: '/admin/ddl/dataObj/formEdit',
// state: {
// id: this.state.objId,
// recordId: record[this.state.primaryKey],
// recordKey: this.state.primaryKey,
// isAdd: false,
// isView:false
// },
// });
// }
};
};
view
=
(
record
)
=>
{
view
=
(
record
)
=>
{
...
@@ -271,18 +260,7 @@ class TreeList extends React.Component {
...
@@ -271,18 +260,7 @@ class TreeList extends React.Component {
isAdd
:
false
,
isAdd
:
false
,
isView
:
true
,
isView
:
true
,
});
});
// } else {
// router.push({
// pathname: '/admin/ddl/dataObj/formEdit',
// state: {
// id: this.state.objId,
// recordId: record[this.state.primaryKey],
// recordKey: this.state.primaryKey,
// isAdd: false,
// isView:true
// },
// });
// }
};
};
isJSON
=
(
str
)
=>
{
isJSON
=
(
str
)
=>
{
...
...
one_stop_public/tableCompon/Split_Index/giveVarcharLength.js
浏览文件 @
93c4167d
...
@@ -18,6 +18,9 @@ export default function giveVarcharRules({
...
@@ -18,6 +18,9 @@ export default function giveVarcharRules({
res
.
push
({
res
.
push
({
max
:
dataColumn
.
length
,
max
:
dataColumn
.
length
,
message
:
`不能超过
${
dataColumn
.
length
}
个字符`
,
message
:
`不能超过
${
dataColumn
.
length
}
个字符`
,
transform
:
function
(
value
){
return
value
+
''
;
},
});
});
}
}
return
res
;
return
res
;
...
...
one_stop_public/utils/request.js
浏览文件 @
93c4167d
...
@@ -20,6 +20,7 @@ import { getUrlInfo } from '@/webPublic/one_stop_public/DetailForAudit/utils';
...
@@ -20,6 +20,7 @@ import { getUrlInfo } from '@/webPublic/one_stop_public/DetailForAudit/utils';
import
{
getHeaders
,
getIsBei_Dian
}
from
'@/webPublic/zyd_public/utils/utils'
;
import
{
getHeaders
,
getIsBei_Dian
}
from
'@/webPublic/zyd_public/utils/utils'
;
import
{
proxyChangeUrl
}
from
'@/webPublic/zyd_public/request/proxyChangeUrl'
;
import
{
proxyChangeUrl
}
from
'@/webPublic/zyd_public/request/proxyChangeUrl'
;
import
{
getTransformApi
}
from
'@/webPublic/one_stop_public/2022beidianke/localstorageTransform'
;
import
{
getTransformApi
}
from
'@/webPublic/one_stop_public/2022beidianke/localstorageTransform'
;
import
{
getVisitorToken
}
from
'@/webPublic/zyd_public/utils/getHeaders'
;
const
codeMessage
=
{
const
codeMessage
=
{
200
:
'服务器成功返回请求的数据。'
,
200
:
'服务器成功返回请求的数据。'
,
...
@@ -245,7 +246,7 @@ export async function requestOrigin(url, data, options = {}){
...
@@ -245,7 +246,7 @@ export async function requestOrigin(url, data, options = {}){
});
});
}
else
{
}
else
{
const
pp
=
{
const
pp
=
{
token
:
getToken
(),
// 部分接口 只需要传入假token 所以这里优先级是 data中的token > getToken;
token
:
get
Visitor
Token
(),
// 部分接口 只需要传入假token 所以这里优先级是 data中的token > getToken;
...
data
,
...
data
,
version_
:
version
,
version_
:
version
,
};
};
...
@@ -260,10 +261,7 @@ export async function requestOrigin(url, data, options = {}){
...
@@ -260,10 +261,7 @@ export async function requestOrigin(url, data, options = {}){
// 由于自动添加前缀 这里暂时修改getUrl(url)
// 由于自动添加前缀 这里暂时修改getUrl(url)
let
fetchRequest
=
url
.
indexOf
(
'UserApi/login'
)
>
-
1
?
loginUmiRequest
:
umiRequest
;
let
fetchRequest
=
url
.
indexOf
(
'UserApi/login'
)
>
-
1
?
loginUmiRequest
:
umiRequest
;
if
(
process
.
env
.
NODE_ENV
!==
'production'
&&
url
.
indexOf
(
'UserApi/login'
)
>
-
1
)
{
url
=
'/UserApi/login'
;
// 通过 proxy代理 解决登录接口本地跨域问题
options
.
prefix
=
''
;
}
if
(
getToken
())
{
if
(
getToken
())
{
options
.
headers
=
getHeaders
(
url
).
headers
;
options
.
headers
=
getHeaders
(
url
).
headers
;
}
}
...
@@ -273,11 +271,11 @@ export async function requestOrigin(url, data, options = {}){
...
@@ -273,11 +271,11 @@ export async function requestOrigin(url, data, options = {}){
if
(
options
.
headers
){
if
(
options
.
headers
){
options
.
headers
=
{
options
.
headers
=
{
...
options
.
headers
,
...
options
.
headers
,
apis
:
headersApi
,
//
apis: headersApi,
};
};
}
else
{
}
else
{
options
.
headers
=
{
options
.
headers
=
{
apis
:
headersApi
,
//
apis: headersApi,
};
};
}
}
}
}
...
...
zyd_public/utils/getHeaders.js
浏览文件 @
93c4167d
...
@@ -5,8 +5,18 @@ import { getUrlInfo } from '@/webPublic/one_stop_public/DetailForAudit/utils';
...
@@ -5,8 +5,18 @@ import { getUrlInfo } from '@/webPublic/one_stop_public/DetailForAudit/utils';
const
isTest
=
getUrlInfo
().
test
;
const
isTest
=
getUrlInfo
().
test
;
export
function
getVisitorToken
(){
let
token
=
getToken
();
const
visitor_client
=
sessionStorage
.
getItem
(
'visitor_client'
)
===
'true'
||
!!
getUrlInfo
().
visitor
;
if
(
visitor_client
&&
(
token
===
'null'
||
!
token
)){
// 访客token 欢哥喊加的
token
=
'704d693b-cc68-49a7-8888-4acc73b5ca73'
;
}
return
token
;
}
export
function
getHeaders
(
url
=
''
,
headersApi
=
undefined
)
{
export
function
getHeaders
(
url
=
''
,
headersApi
=
undefined
)
{
const
token
=
get
Token
();
let
token
=
getVisitor
Token
();
const
currentInfo
=
getCurrentUser
()
||
{};
const
currentInfo
=
getCurrentUser
()
||
{};
const
user
=
getUserInfo
()
||
{};
const
user
=
getUserInfo
()
||
{};
const
userId
=
user
.
id
||
currentInfo
.
xgUserId
;
const
userId
=
user
.
id
||
currentInfo
.
xgUserId
;
...
@@ -16,6 +26,9 @@ export function getHeaders(url = '', headersApi = undefined) {
...
@@ -16,6 +26,9 @@ export function getHeaders(url = '', headersApi = undefined) {
headers
:
{},
headers
:
{},
};
};
if
(
url
&&
typeof
url
===
'string'
&&
url
.
indexOf
(
'oauthPub=true'
)
>
-
1
){
// 公共接口不需要token
return
res
;
}
if
(
!
token
||
token
===
'null'
)
{
if
(
!
token
||
token
===
'null'
)
{
return
res
;
return
res
;
}
else
{
}
else
{
...
@@ -26,9 +39,9 @@ export function getHeaders(url = '', headersApi = undefined) {
...
@@ -26,9 +39,9 @@ export function getHeaders(url = '', headersApi = undefined) {
res
.
headers
.
Authorization
=
`bearer
${
token
}
`
;
res
.
headers
.
Authorization
=
`bearer
${
token
}
`
;
res
.
headers
.
auth
=
gg5xxxxx
(
secretString
);
res
.
headers
.
auth
=
gg5xxxxx
(
secretString
);
res
.
headers
.
timestamp
=
timestamp
;
res
.
headers
.
timestamp
=
timestamp
;
if
(
headersApi
)
{
//
if (headersApi) {
res
.
headers
.
apis
=
headersApi
;
//
res.headers.apis = headersApi;
}
//
}
}
}
return
res
;
return
res
;
}
}
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论