对于已发布的文件,被修改状态后,删除知识索引以及取消发布知识后,重新修改状态后,知识文件不发布问题

This commit is contained in:
Mr-wang 2023-12-19 12:20:43 +08:00
parent 33d3b62e22
commit c297e62873

View File

@ -106,8 +106,9 @@ public class UpateFileStateController {
createPermScopeData(plId , me);
SDK.getLogAPI().consoleInfo("修改为发布状态后同步权限数据到权限阅览成功===========>");
}
createFile(plId,me);
if (state.equals("1")){
createFile(plId,me);
}
} else if ("2".equals(type)) {
// 修改流程文件的审批状态
@ -482,6 +483,23 @@ public class UpateFileStateController {
DBSql.update("UPDATE APP_ACT_COE_PAL_PUBLISH_LIST SET TASKID='" + repetition_TaskId + "'WHERE PALREPOSITORYID='"
+ plId + "'");
}
}else {
String sql = "select EXT4 from APP_ACT_COE_PAL_REPOSITORY where ID = '"+plId+"'";
String ext4 = DBSql.getString(sql);
String sql_card_name = "select * from APP_ACT_KMS_CARD where ID = '"+ext4+"'";
RowMap rowMap = DBSql.getMap(sql_card_name);
String caed_name = rowMap.getString("CARDNAME");
String[] split_card = caed_name.split("V");
ProcessInstance processInstance = SDK.getProcessAPI().createProcessInstance("obj_a228b4816a7b4f58a862b9612299948c", "admin", "");
PublishKnow(processInstance, me, ext4,me.getSessionId());
JSONArray coontest = new JSONArray(new LinkedList<>());
JSONObject jsonObject = new JSONObject(new LinkedHashMap<>());
jsonObject.put("documentId", ext4);
jsonObject.put("content", "");//信息附件
//jsonObject.put("abstract", dcContext);//信息摘要
jsonObject.put("title", split_card[0]);//信息标题
coontest.add(jsonObject);
createIndexesByContent(processInstance,coontest,ext4);
}
System.err.println("重新生成手册成功=====》" + count);
}