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.

163 lines
7.0 KiB
Plaintext

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>基础资料修改流程</title>
<link rel="stylesheet" type="text/css" href="../../Portal/icons/font-icons.min.css" />
<!--- 引入代码. -->
<script src="../../Scripts/jquery-1.11.0.min.js"></script>
<script src="../../Scripts/QueryString.js" type="text/javascript"></script>
<script src="../../Scripts/config.js" type="text/javascript"></script>
<script src="../../Comm/Gener.js" type="text/javascript"></script>
<link href="../../js/mui/css/mui.min.css" rel="stylesheet" />
<script src="../../js/mui/js/mui.min.js" type="text/javascript"></script>
<script src="../../Scripts/vue.js" type="text/javascript"></script>
</head>
<body>
<div id="method">
<header class="mui-bar mui-bar-nav">
<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
<!--<a class=" mui-btn mui-btn-link mui-pull-right" onclick="SearchAdv()">高级查询</a>-->
<a class=" mui-btn mui-btn-link mui-pull-right" onclick="StartIt()">发起</a>
<h1 class="mui-title">{{title}}</h1>
</header>
<div class="mui-content">
<div class="mui-scroll-wrapper">
<div class="mui-scroll">
<ul class="mui-table-view mui-table-view-chevron" style="top:46px;height:auto">
<li class="mui-table-view-cell" style="padding-left:15px" v-for="(generWorkFlow,idx) in gwfs" :key="idx"
:data-id="generWorkFlow.WorkID">
<a @click.stop="OpenMyView(generWorkFlow.FK_Flow,generWorkFlow.WorkID)" target='_self'>
<h5 style="white-space:normal;line-height:20px;width:90%;word-wrap:break-word; word-break:break-all; color:#096BC1;">{{generWorkFlow.Title}}</h5>
<h6>发起人:{{generWorkFlow.StarterName}}</h6>
<h6>发起时间:{{generWorkFlow.RDT}}</h6>
<h6>停留节点:{{generWorkFlow.NodeName}}</h6>
<h6>处理人:{{generWorkFlow.TodoEmps}}</h6>
<h6>状态:{{generWorkFlow.IconTitle}}</h6>
</a>
</li>
</ul>
</div>
</div>
</div>
</div>
<script type="text/javascript">
new Vue({
el: '#method',
data: {
gwfs: [],
searchKey: '',
title:"",
},
watch: {
},
methods: {
OpenMyView: function (flowNo, workid) {
var handler = new HttpHandler("BP.WF.HttpHandler.WF_MyView");
handler.AddPara("WorkID", workid);
handler.AddPara("FK_Flow", flowNo);
var data = handler.DoMethodReturnString("MyView_Init");
if (data.indexOf('err@') == 0) {
alert(data);
return;
}
if (data.indexOf('url@') == 0) {
data = data.replace('url@', ''); //如果返回url就直接转向.
data = data.replace('?DoType=HttpHandler', '?');
data = data.replace('&DoType=HttpHandler', '');
data = data.replace('&DoMethod=MyView_Init', '');
data = data.replace('&HttpHandlerName=BP.WF.HttpHandler.WF_MyCC', '');
data = data.replace('?&', '?');
var url = "../../" + data;
//如果返回url就直接转向.
window.location.href = filterXSS(url); //
return;
}
},
startList: function () {
var frmID = GetQueryString("FrmID");
var workID = GetQueryString("WorkID");
var flowNo = GetQueryString("FlowNo");
var en = new Entity("BP.WF.Flow", flowNo);
this.title = en.Name;
var ens = new Entities("BP.WF.GenerWorkFlows");
ens.Retrieve("PWorkID", workID, "PFlowNo", frmID, "FK_Flow", flowNo, "RDT");
var ens = ens.TurnToArry();
var ens = $.grep(ens, function (en) {
return en.WFState > 1;
})
for (var i = 0; i < ens.length; i++) {
var gwf = ens[i];
if (gwf.WFState === 0) { gwf.Icon = "icon-clock"; gwf.IconTitle = "空白"; }//运行中的.
if (gwf.WFState === 1) { gwf.Icon = "icon-clock"; gwf.IconTitle = "草稿"; }//运行中的.
if (gwf.WFState === 2) { gwf.Icon = "icon-clock"; gwf.IconTitle = "运行中"; }//运行中的.
if (gwf.WFState === 3) { gwf.Icon = "icon-check"; gwf.IconTitle = "已完成"; }//已完成的.
if (gwf.WFState === 5) { gwf.Icon = "icon-action-undo"; gwf.IconTitle = "退回"; } //退回的.
}
this.gwfs = ens;
},
Search: function () {
this.startList();
this.searchKey = $("#TB_Key").val();
var venss = [];
var idx = 0;
for (var i = 0; i < this.gwfs.length; i++) {
var Titlebj = this.gwfs[i].Title;
if (Titlebj.indexOf(this.searchKey) == -1)
continue;
venss[idx] = this.gwfs[i];
idx++;
}
this.gwfs = venss;
}
},
mounted: function () {
this.startList();
}
})
function StartIt() {
var handler = new HttpHandler("BP.CCBill.WF_CCBill");
handler.AddPara("MethodNo", GetQueryString("MethodNo"));
handler.AddPara("WorkID", GetQueryString("WorkID"));
handler.AddPara("FrmID", GetQueryString("FrmID"));
var data = handler.DoMethodReturnString("MyDict_DoFlowBaseData_StartFlow");
if (data.indexOf('err@') == 0) {
alert(data);
return;
} else {
window.location.href = "../" + data;
}
}
//高级查询.
function SearchAdv() {
var url = "";
url = "../../../App/OneFlow/RptSearch.htm?FK_Flow=" + GetQueryString("FlowNo");
url += "&WorkID=" + GetQueryString("WorkID");
url += "&MethodNo=" + GetQueryString("MethodNo");
window.location.href = filterXSS(url);
}
</script>
</body>
</html>