You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
283 lines
13 KiB
Plaintext
283 lines
13 KiB
Plaintext
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>表单应用</title>
|
|
<meta name="renderer" content="webkit">
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
|
|
<script src="../../WF/Scripts/jquery-1.11.0.min.js"></script>
|
|
<link href="../FlowDesigner/css/icons.css" rel="stylesheet" />
|
|
<!--layui-->
|
|
<link href="../layuiadmin/layui/css/layui.css" rel="stylesheet" type="text/css" />
|
|
<link href="../layuiadmin/style/onFlow.css" rel="stylesheet" type="text/css" />
|
|
<script src="../layuiadmin/layui/layui.js" type="text/javascript"></script>
|
|
<link href="../layuiadmin/layui/css/modules/layer/default/layer.css" rel="stylesheet" />
|
|
<script src="../layuiadmin/layui/lay/modules/layer.js"></script>
|
|
<!-- 引用通用的js文件. -->
|
|
<script src="../../WF/Scripts/QueryString.js" type="text/javascript"></script>
|
|
<script src="../../WF/Scripts/config.js?v=1.0" type="text/javascript"></script>
|
|
<script src="../../WF/Comm/Gener.js?v=1.0" type="text/javascript"></script>
|
|
|
|
<!-- 处理多语言 -->
|
|
<script src="../../WF/Data/lang/load.js" type="text/javascript"></script>
|
|
<script src="../../WF/Data/lang/lang.js" type="text/javascript"></script>
|
|
<script src="../../WF/Data/lang/js/zh-cn.js" type="text/javascript"></script>
|
|
<script type="text/javascript" language="javascript">
|
|
layui.config({
|
|
base: '../layuiadmin/' //静态资源所在路径
|
|
}).extend({
|
|
index: 'lib/index' //主入口模块
|
|
}).use('index');
|
|
var frmID = GetQueryString("FrmID");
|
|
var fk_flow = GetQueryString("FK_Flow");
|
|
var workModel = GetQueryString("WorkModel");
|
|
//页面启动函数.
|
|
$(function () {
|
|
|
|
var webuser = new WebUser();
|
|
$("#mainBody").attr("src", "DataPanelDept.htm?FrmID=" + frmID+"&WorkModel="+workModel)
|
|
|
|
//流程应用的标志
|
|
var en = new Entity("BP.Cloud.Template.Flow");
|
|
en.SetPKVal(fk_flow);
|
|
if (en.RetrieveFromDBSources() == 0) {
|
|
layer.alert("系统中没有找到流程编号为" + fk_flow + "的流程,请联系管理员");
|
|
SetHref( "../Portal/Home.htm");
|
|
return;
|
|
}
|
|
var iconObj = [];
|
|
if (en.ICON.indexOf('@') >= 0) {//包含@符号,是按照规则组装的数据
|
|
iconObj = en.ICON.split("@");
|
|
}
|
|
|
|
$("#FlowLog").html("<img style='width: 35px' src='../FlowDesigner/FlowIcon/" + (iconObj == undefined ? "" : iconObj[0]) + ".png' class='" + (iconObj == undefined ? "" : iconObj[1]) + "' onerror=\"javascript:this.src = '../FlowDesigner/AppTemplate/DefaultIcon.png';\" '/><span> " + en.Name + "</span>");
|
|
|
|
|
|
//获取菜单数据
|
|
var handler = new HttpHandler("BP.Cloud.HttpHandler.App_OneFrm");
|
|
handler.AddPara("WorkModel", workModel);
|
|
handler.AddPara("FrmID", frmID);
|
|
var data = handler.DoMethodReturnString("Default_Menu");
|
|
if (data.indexOf("err@") == 0) {
|
|
layer.alert(data);
|
|
console.log(data);
|
|
return;
|
|
}
|
|
|
|
data = JSON.parse(data);
|
|
|
|
|
|
var sorts = data.Sorts;
|
|
var menus = data.Menus;
|
|
var _html = "";
|
|
for (var i = 0; i < sorts.length; i++) {
|
|
var sort = sorts[i];
|
|
_html += '<li data-name="' + sort.No + '" class="layui-nav-item layui-nav-itemed">';
|
|
_html += '<a href="javascript:;" lay-tips="' + sort.Name + '" lay-direction="2" style="">';
|
|
_html += "<img src='./MenuImg/" + sort.ICON + "' onerror=\"javascript:this.src = './MenuImg/DefaultDir.png';\" style='width:24px;height:24px;position: absolute;top:60%;left: 20px;margin-top:-19px;filter:contrast(8%) brightness(110%)'/>";
|
|
_html += '<cite>' + sort.Name + '</cite>';
|
|
_html += '</a>';
|
|
_html += '<dl class="layui-nav-child">'
|
|
$.each(menus, function (indx, item) {
|
|
if (item.SortNo == sort.No) {
|
|
var url = item.Url;
|
|
if (url.indexOf("?") == -1)
|
|
url += "?1=1";
|
|
url += "&FrmID=" + frmID + "&FK_MapData=" + frmID +"&WorkModel="+workModel;
|
|
_html += '<dd data-name="' + item.No + '">';
|
|
_html += "<a lay-href='" + url + "'><img src='./MenuImg/" + item.ICON + "' onerror=\"javascript:this.src = './MenuImg/Default.png';\" style='width:16px;height:16px;padding-right:5px;filter:contrast(8%) brightness(110%)'/>" + item.Name + "</a>";
|
|
_html += '</dd>';
|
|
}
|
|
|
|
});
|
|
_html += '</dl>';
|
|
_html += '</li>';
|
|
}
|
|
|
|
$("#LAY-system-side-menu").html(_html);
|
|
|
|
});
|
|
|
|
function OpenApps() {
|
|
var url = '../Apps.htm';
|
|
OpenWindowRight(url, "流程应用");
|
|
}
|
|
|
|
//退出流程应用
|
|
function logOut() {
|
|
|
|
//window.parent.focus();
|
|
//window.close();
|
|
SetHref( "../Portal/Home.htm");
|
|
}
|
|
|
|
function StartFlow() {
|
|
var frmBill = new Entity("BP.CCBill.FrmBill", frmID);
|
|
var workModel = GetQueryString("WorkModel");
|
|
var url = "";
|
|
if(workModel ==2)
|
|
url = "../../WF/CCBill/MyDict.htm?FrmID=" + frmID + "&FK_MapData=" + frmID;
|
|
if (workModel == 3) {
|
|
//选择实体表单然后填写单据
|
|
if (frmBill.RefDict != null && frmBill.RefDict != undefined && frmBill.RefDict != "") {
|
|
//关联实体表单,选择表单填写信息
|
|
var W = document.body.clientWidth - 40;
|
|
var H = document.body.clientHeight - 40;
|
|
var url = "../../WF/CCBill/RefDict.htm?FrmID=" + frmBill.RefDict + "&FK_MapData=" + frmBill.RefDict + "&BillID=" + frmID;
|
|
|
|
} else {
|
|
url = "../../WF/CCBill/MyBill.htm?FrmID=" + frmID + "&FK_MapData=" + frmID;
|
|
}
|
|
}
|
|
layer.open({
|
|
type: 2,
|
|
title:frmBill.Name,
|
|
content: url,
|
|
area: ['80%', '80%'],
|
|
end: function () {
|
|
//弹出窗销毁后,选中我创建的打开
|
|
OpenWindowRight("/App/OneFrm/FrmSearch.htm?SearchType=My&FrmID="+frmID+"&FK_MapData="+frmID+"&WorkModel="+workModel,"我创建的");
|
|
}
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
//已知URL,在右侧打开页面
|
|
function OpenWindowRight(url, title) {
|
|
if (top.layui.index) {
|
|
top.layui.index.openTabsPage(url, title)
|
|
} else {
|
|
window.open(url)
|
|
}
|
|
}
|
|
|
|
</script>
|
|
</head>
|
|
<body class="layui-layout-body">
|
|
<div id="LAY_app">
|
|
<div class="layui-layout layui-layout-admin">
|
|
<div class="layui-header" style="background-color: #fff;">
|
|
<!-- 头部区域 -->
|
|
<ul class="layui-nav layui-layout-left">
|
|
<li class="layui-nav-item layadmin-flexible" lay-unselect>
|
|
<a href="javascript:;" layadmin-event="flexible" title="侧边伸缩" style="color:#fff">
|
|
<i class="layui-icon layui-icon-shrink-right" id="LAY_app_flexible"></i>
|
|
</a>
|
|
</li>
|
|
|
|
<li class="layui-nav-item" lay-unselect>
|
|
<a href="javascript:;" layadmin-event="refresh" title="刷新" style="color:#fff">
|
|
<i class="layui-icon layui-icon-refresh-3"></i>
|
|
</a>
|
|
</li>
|
|
<li class="layui-nav-item layui-hide-xs" lay-unselect style="display:none">
|
|
<a href="javascript:;" layadmin-event="faqi" onclick="StartFlow()" title="创建实体、单据" style="color:#fff;">
|
|
|
|
<img src="./MenuImg/Start.png" style="width:16px;height:16px;filter: saturate(5) hue-rotate(500deg) grayscale(0.8) sepia(0.5) contrast(1.5) invert(0.4) brightness(2.8);" />
|
|
</a>
|
|
</li>
|
|
</ul>
|
|
<ul class="layui-nav layui-layout-right" lay-filter="layadmin-layout-right">
|
|
|
|
<li class="layui-nav-item layui-hide-xs" lay-unselect>
|
|
<a href="javascript:;" layadmin-event="fullscreen" style="color:#fff">
|
|
<i class="layui-icon layui-icon-screen-full"></i>
|
|
</a>
|
|
</li>
|
|
<li class="layui-nav-item" lay-unselect style="margin-right:20px;color:#fff">
|
|
<a href="javascript:;" onclick="logOut()">
|
|
<cite style="color:#fff !important">进入流程中心</cite>
|
|
</a>
|
|
|
|
</li>
|
|
|
|
<!--<li class="layui-nav-item layui-hide-xs" lay-unselect>
|
|
<a href="javascript:;" layadmin-event="about"><i class="layui-icon layui-icon-more-vertical"></i></a>
|
|
</li>
|
|
<li class="layui-nav-item layui-show-xs-inline-block layui-hide-sm" lay-unselect>
|
|
<a href="javascript:;" layadmin-event="more"><i class="layui-icon layui-icon-more-vertical"></i></a>
|
|
</li>-->
|
|
</ul>
|
|
</div>
|
|
|
|
<!-- 侧边菜单 -->
|
|
<div class="layui-side layui-side-menu" style="">
|
|
<div class="layui-side-scroll">
|
|
<div class="layui-logo" id="FlowLog" style="">
|
|
<span>CCFlow</span>
|
|
</div>
|
|
|
|
<ul class="layui-nav layui-nav-tree" lay-shrink="all" id="LAY-system-side-menu" lay-filter="layadmin-system-side-menu" style="">
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 页面标签 -->
|
|
<div class="layadmin-pagetabs" id="LAY_app_tabs">
|
|
<div class="layui-icon layadmin-tabs-control layui-icon-prev" layadmin-event="leftPage"></div>
|
|
<div class="layui-icon layadmin-tabs-control layui-icon-next" layadmin-event="rightPage"></div>
|
|
<div class="layui-icon layadmin-tabs-control layui-icon-down">
|
|
<ul class="layui-nav layadmin-tabs-select" lay-filter="layadmin-pagetabs-nav">
|
|
<li class="layui-nav-item" lay-unselect>
|
|
<a href="javascript:;"></a>
|
|
<dl class="layui-nav-child layui-anim-fadein">
|
|
<dd layadmin-event="closeThisTabs"><a href="javascript:;">关闭当前标签页</a></dd>
|
|
<dd layadmin-event="closeOtherTabs"><a href="javascript:;">关闭其它标签页</a></dd>
|
|
<dd layadmin-event="closeAllTabs"><a href="javascript:;">关闭全部标签页</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="layui-tab" lay-unauto lay-allowClose="true" lay-filter="layadmin-layout-tabs">
|
|
<ul class="layui-tab-title" id="LAY_app_tabsheader">
|
|
<li lay-id="/App/Apps.htm" lay-attr="/App/Apps.htm" class="layui-this"><i class="layui-icon layui-icon-home"></i></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- 主体内容 -->
|
|
<div class="layui-body" id="LAY_app_body">
|
|
<div class="layadmin-tabsbody-item layui-show">
|
|
<iframe src="DataPanelDept.htm" frameborder="0" class="layadmin-iframe" id="mainBody"></iframe>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 辅助元素,一般用于移动设备下遮罩 -->
|
|
<div class="layadmin-body-shade" layadmin-event="shade"></div>
|
|
</div>
|
|
</div>
|
|
<style id="LAY-system-side-menu" type="text/css">
|
|
.layui-layout-admin .layui-logo, .layui-layout-admin .layui-logo a {
|
|
color: #fff !important;
|
|
}
|
|
.layui-layout-admin .layui-header {
|
|
background-color: #AA3130 !important;
|
|
}
|
|
/** .layui-layout-admin .layui-logo {
|
|
background-color: rgb(255, 255, 255) !important;
|
|
}
|
|
.layui-nav .layui-nav-child a {
|
|
color: #333 !important;
|
|
}
|
|
.layui-nav-itemed > .layui-nav-child {
|
|
display: block;
|
|
background-color: white !important;
|
|
}
|
|
.layui-nav-tree .layui-this, .layui-nav-tree .layui-this > a, .layui-nav-tree .layui-nav-child dd.layui-this, .layui-nav-tree .layui-nav-child dd.layui-this a {
|
|
background-color: #e7eaec !important;
|
|
}
|
|
.layadmin-side-shrink .layui-side-menu .layui-nav > .layui-nav-itemed > a {
|
|
background: white !important;
|
|
}*/
|
|
</style>
|
|
</body>
|
|
|
|
|
|
</html>
|