提交 594d095b authored 作者: 钟是志's avatar 钟是志

心理健康咨询预约填报 参数修改

上级 dd89de67
...@@ -15,19 +15,14 @@ const must = ( ...@@ -15,19 +15,14 @@ const must = (
color: '#FF5350', color: '#FF5350',
marginLeft: 5, marginLeft: 5,
marginRight: 5, marginRight: 5,
}} }}>
>
* *
</span> </span>
); );
// 检查是否启用表单校验 // 检查是否启用表单校验
const checkNeedFormValidateFieldsAndScroll = ({ const checkNeedFormValidateFieldsAndScroll = ({ btns, btnValue }) => {
btns, let btnInfo = btns.find((g) => g.value + '' === btnValue + '');
btnValue,
}) => {
let btnInfo = btns.find(g => g.value + '' === btnValue + '');
let checkSumbitInfo = true; let checkSumbitInfo = true;
if (btnInfo && btnInfo.isValidateForm === false) { if (btnInfo && btnInfo.isValidateForm === false) {
checkSumbitInfo = false; // 23425 学生事务/学生违纪管理/违纪上报/审核,2013010255 学生处干事选择驳回 这些字段不用填 checkSumbitInfo = false; // 23425 学生事务/学生违纪管理/违纪上报/审核,2013010255 学生处干事选择驳回 这些字段不用填
...@@ -36,11 +31,8 @@ const checkNeedFormValidateFieldsAndScroll = ({ ...@@ -36,11 +31,8 @@ const checkNeedFormValidateFieldsAndScroll = ({
}; };
// 校验是否该按钮需要填写审批意见 // 校验是否该按钮需要填写审批意见
const checkNeedWriteAuditInfo = ({ const checkNeedWriteAuditInfo = ({ btns, btnValue }) => {
btns, let btnInfo = btns.find((g) => g.value + '' === btnValue + '');
btnValue,
}) => {
let btnInfo = btns.find(g => g.value + '' === btnValue + '');
let needWrite = false; let needWrite = false;
if (btnInfo && isJSON(btnInfo?.documentation)) { if (btnInfo && isJSON(btnInfo?.documentation)) {
let documentation = JSON.parse(btnInfo.documentation); let documentation = JSON.parse(btnInfo.documentation);
...@@ -51,7 +43,6 @@ const checkNeedWriteAuditInfo = ({ ...@@ -51,7 +43,6 @@ const checkNeedWriteAuditInfo = ({
return needWrite; return needWrite;
}; };
const submitValues = ({ const submitValues = ({
values, values,
isCloseFlowPath, isCloseFlowPath,
...@@ -70,7 +61,7 @@ const submitValues = ({ ...@@ -70,7 +61,7 @@ const submitValues = ({
dispatch, dispatch,
that, that,
handleUser, handleUser,
}) => { }) => {
if (isCloseFlowPath) { if (isCloseFlowPath) {
} else if (!radiovalue && isSecond) { } else if (!radiovalue && isSecond) {
openToast('success', '请选择紧急度'); openToast('success', '请选择紧急度');
...@@ -105,13 +96,25 @@ const submitValues = ({ ...@@ -105,13 +96,25 @@ const submitValues = ({
apiData: data, apiData: data,
taskFormKey: data.taskFormKey, taskFormKey: data.taskFormKey,
userNowInfo: userInfo, userNowInfo: userInfo,
buttonInfo: btns && btns.length ? btns.find(x => x.value === btnValue) : {}, buttonInfo: btns && btns.length ? btns.find((x) => x.value === btnValue) : {},
token: getToken(), token: getToken(),
}; };
payload = callbackSubmitData(payload); payload = callbackSubmitData(payload);
beforeAuditSubmit(payload)
.then(resParams => {
/**
* 29943 北电]违纪-违纪上报辅导员,驳回修改的处分不生效
*
* */
const taskInfo = that.state?.data?.taskInfo;
if(Array.isArray(taskInfo) &&
taskInfo.length >= 2 &&
taskInfo[0].taskDefKey &&
taskInfo[0].taskDefKey === taskInfo[taskInfo.length - 1].taskDefKey){
console.log('驳回到发起人了');
}
beforeAuditSubmit(payload).then((resParams) => {
if (!resParams) { if (!resParams) {
that.setState({ that.setState({
isSumbitLoading: false, isSumbitLoading: false,
...@@ -121,7 +124,7 @@ const submitValues = ({ ...@@ -121,7 +124,7 @@ const submitValues = ({
dispatch({ dispatch({
type: 'affair/getExamineProcess', type: 'affair/getExamineProcess',
payload: resParams, payload: resParams,
callback: val => { callback: (val) => {
if (val) { if (val) {
// that.getInit(); // that.getInit();
that.setState({ that.setState({
...@@ -148,8 +151,6 @@ const submitValues = ({ ...@@ -148,8 +151,6 @@ const submitValues = ({
}); });
} }
}); });
}, },
); );
}; };
......
/**
* 审核回调函数.callbackSubmitInfoZhiYong;
* */
export function callbackSubmitData(infoData) { export function callbackSubmitData(infoData) {
// console.log(infoData); // console.log(infoData);
if (window.callbackSubmitInfoZhiYong && typeof window.callbackSubmitInfoZhiYong === 'function') { if (window.callbackSubmitInfoZhiYong && typeof window.callbackSubmitInfoZhiYong === 'function') {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论