Commit db177304 by 宋祥

Merge branch 'dev' of http://129.211.46.84:8800/platform/hg-smart into master-dc

parents b0db18f0 019f183d
...@@ -52,12 +52,12 @@ public class ServiceHGWD002A extends ServiceEPBase { ...@@ -52,12 +52,12 @@ public class ServiceHGWD002A extends ServiceEPBase {
try { try {
Map queryMap = EiInfoUtils.getFirstRow(inInfo); Map queryMap = EiInfoUtils.getFirstRow(inInfo);
String fileId = MapUtils.getString(queryMap, HGWD001.FIELD_FILE_ID); String fileId = MapUtils.getString(queryMap, HGWD001.FIELD_FILE_ID);
String source = MapUtils.getString(queryMap, "source");
String node = MapUtils.getString(queryMap, CommonConstant.Field.NODE); String node = MapUtils.getString(queryMap, CommonConstant.Field.NODE);
String status = MapUtils.getString(queryMap, HGWD001.FIELD_STATUS);
if (CommonConstant.Field.ROOT.equals(node) || CommonConstant.Field.ROOT2.equals(node)) { if (CommonConstant.Field.ROOT.equals(node) || CommonConstant.Field.ROOT2.equals(node)) {
inInfo.addBlock(node).setRows(queryTopNode(node, fileId)); inInfo.addBlock(node).setRows(queryTopNode(node, fileId));
} else { } else {
inInfo.addBlock(node).setRows(queryChildNode(node,status)); inInfo.addBlock(node).setRows(queryChildNode(node, source));
} }
} catch (Exception e) { } catch (Exception e) {
LogUtils.setMsg(inInfo, e, "查询节点失败"); LogUtils.setMsg(inInfo, e, "查询节点失败");
...@@ -91,9 +91,10 @@ public class ServiceHGWD002A extends ServiceEPBase { ...@@ -91,9 +91,10 @@ public class ServiceHGWD002A extends ServiceEPBase {
* 查询叶子节点 * 查询叶子节点
* *
* @param parentId * @param parentId
* @param source 1=文档库,2=文件浏览
* @return * @return
*/ */
public List queryChildNode(String parentId, String status) { public List queryChildNode(String parentId, String source) {
List<Map> results = new ArrayList(); List<Map> results = new ArrayList();
Map queryMap = new HashMap(); Map queryMap = new HashMap();
queryMap.put("fileId", parentId); queryMap.put("fileId", parentId);
...@@ -103,11 +104,9 @@ public class ServiceHGWD002A extends ServiceEPBase { ...@@ -103,11 +104,9 @@ public class ServiceHGWD002A extends ServiceEPBase {
if (!(isSpare || HgWdUtils.HgWd009.isManager())) { if (!(isSpare || HgWdUtils.HgWd009.isManager())) {
queryMap.put("userId", UserSessionUtils.getLoginName()); queryMap.put("userId", UserSessionUtils.getLoginName());
} }
if (StringUtils.isEmpty(status) || !status.equals(HgWdConstant.FileStatus.S_0.toString())){ if (!"1".equals(source)) {
queryMap.put(HGWD001.FIELD_STATUS, HgWdConstant.FileStatus.S_1); queryMap.put(HGWD001.FIELD_STATUS, HgWdConstant.FileStatus.S_1);
} }
queryMap.put(HGWD001.FIELD_STATUS, HgWdConstant.FileStatus.S_1);
queryMap.put("orderBy", "B.DOC_TYPE ASC, B.DOC_NAME ASC"); queryMap.put("orderBy", "B.DOC_TYPE ASC, B.DOC_NAME ASC");
List<HGWD002> dbWd002s = dao.query(HGWD002.QUERY, queryMap); List<HGWD002> dbWd002s = dao.query(HGWD002.QUERY, queryMap);
if (CollectionUtils.isEmpty(dbWd002s)) { if (CollectionUtils.isEmpty(dbWd002s)) {
......
...@@ -1020,8 +1020,9 @@ function saveProtFunc() { ...@@ -1020,8 +1020,9 @@ function saveProtFunc() {
* 预览 * 预览
*/ */
let preview = function () { let preview = function () {
// source:1=文档库
let fileId = IPLATUI.EFTree.categoryTree.selectTreeNode.fileId; let fileId = IPLATUI.EFTree.categoryTree.selectTreeNode.fileId;
let url = "HGWD002A?inqu_status-0-fileId=" + fileId+"&inqu_status-0-status=0"; let url = "HGWD002A?inqu_status-0-fileId=" + fileId+"&inqu_status-0-source=0";
window.open(url, '_blank'); window.open(url, '_blank');
} }
......
...@@ -4,6 +4,7 @@ $(function () { ...@@ -4,6 +4,7 @@ $(function () {
"docTree": { "docTree": {
query: function (inInfo, model) { query: function (inInfo, model) {
inInfo.set("inqu_status-0-fileId", $("#inqu_status-0-fileId").val()); inInfo.set("inqu_status-0-fileId", $("#inqu_status-0-fileId").val());
inInfo.set("inqu_status-0-source", $("#inqu_status-0-source").val());
return inInfo; return inInfo;
}, },
select: function (e) { select: function (e) {
......
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
<div class="col-md-3"> <div class="col-md-3">
<EF:EFRegion title="文件目录树" id="tree" fitHeight="true"> <EF:EFRegion title="文件目录树" id="tree" fitHeight="true">
<EF:EFInput ename="fileId" cname="文件ID" blockId="inqu_status" row="0" type="hidden"/> <EF:EFInput ename="fileId" cname="文件ID" blockId="inqu_status" row="0" type="hidden"/>
<EF:EFInput ename="source" cname="来源" blockId="inqu_status" row="0" type="hidden"/>
<div id="menu" style="margin-top: 12px; margin-bottom: 8px"> <div id="menu" style="margin-top: 12px; margin-bottom: 8px">
<EF:EFTree bindId="docTree" ename="node" textField="text" valueField="label" hasChildren="leaf" <EF:EFTree bindId="docTree" ename="node" textField="text" valueField="label" hasChildren="leaf"
serviceName="HGWD002A" methodName="queryTree" expandLevel="1"> serviceName="HGWD002A" methodName="queryTree" expandLevel="1">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment