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.

191 lines
8.3 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 PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>备注</title>
<!--
1, 备注界面。
2需要 FK_Flow, FK_Node,WorkID, FID.
3, 调用方法 CC.htm?FK_Flow=001&FK_Node=103&WorkID=232&FID=23
-->
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="white" />
<link href="../js/mui/css/mui.css" rel="stylesheet" type="text/css" />
<script src="../js/jquery.js" type="text/javascript"></script>
<script src="../js/mui/js/mui.min.js" type="text/javascript"></script>
<script src="../Scripts/config.js" type="text/javascript"></script>
<script src="../Scripts/QueryString.js" type="text/javascript"></script>
<script src="../Comm/Gener.js" type="text/javascript"></script>
<script type="text/javascript" src="../Scripts/bootstrap/js/bootstrap.min.js"></script>
<script type="text/javascript" src="../Scripts/bootstrap/js/jquery.cokie.min.js"></script>
<style type="text/css">
</style>
<script type="text/javascript">
var param = {};
$(function () {
var _Html = "";
var fk_node = GetQueryString("FK_Node");
//获取节点属性
var btnLab = new Entity("BP.WF.Template.BtnLab", fk_node);
//获取备注历史信息
var handler = new HttpHandler("BP.WF.HttpHandler.WF_WorkOpt");
handler.AddUrlData();
var data = handler.DoMethodReturnString("Note_Init");
if (data.indexOf('err@') == 0) {
_Html +='<div class="mui-table-view-divider" style="background-color:#efeff4">'
_Html += '<h5>历史备注信息</h5>';
_Html += "<div class='mui-input-row' style='background-color:#fff'>";
_Html += " <label><p>"+data.replace("err@", "获取信息错误")+"</P></label>";
_Html += "</div>";
$("#historyInfo").append(_Html);
return;
}
var data = JSON.parse(data);
if (data.length == 0) {
_Html +='<div class="mui-table-view-divider" style="background-color:#efeff4">'
_Html += '<h5>历史备注信息</h5>';
_Html += "<div class='mui-input-row' style='background-color:#fff'>";
_Html += "<label><p>没有数据</P></label>";
_Html +="</div>"
if (btnLab.NoteEnable == 1) {
_Html += '<div class="mui-table-view-divider" style="background-color:#efeff4">'
_Html += '<h5>当前备注信息</h5>';
_Html += "</div>";
_Html += "<div class='mui-input-row' style='background-color:#fff'>";
_Html += '<textarea id="TB_Msg" name="TB_Msg" rows="5" placeholder="请输入当前节点的备注信息"></textarea>';
_Html += "</div>";
}
$("#historyInfo").append(_Html);
return;
}
_Html +='<div class="mui-table-view-divider" style="background-color:#efeff4">'
_Html += '<h5>历史备注信息</h5>';
_Html += "</div>";
var idx = 0;
var currTrack = null;
for (var i = 0; i < data.length; i++) {
var track = data[i];
if (track.NDFrom == fk_node) {
currTrack = track;
continue;
}
idx = idx + 1;
_Html += "<ul class='mui-table-view'>";
_Html += " <li class='mui-table-view-divider'>序号:" + idx + "</li>";
_Html += "</ul>";
_Html += "<div class='mui-input-row' style='background-color:#fff'>";
_Html += "<label><p>节点</P></label>";
_Html += "<label><p>"+track.NDFrom +"</P></label>";
_Html += "</div>";
_Html += "<div class='mui-input-row'style='background-color:#fff'>";
_Html += "<label><p>节点名称</P></label>";
_Html += "<label><p>"+track.NDFromT +"</P></label>";
_Html += "</div>";
_Html += "<div class='mui-input-row'style='background-color:#fff'>";
_Html += "<label><p>处理人</P></label>";
_Html += "<label><p>"+track.EmpFromT +"</P></label>";
_Html += "</div>";
_Html += "<div class='mui-input-row'style='background-color:#fff'>";
_Html += "<label><p>处理时间</P></label>";
_Html += "<label><p>"+track.RDT +"</P></label>";
_Html += "</div>";
_Html += "<div class='mui-input-row'style='background-color:#fff'>";
_Html += "<label><p>备注信息</P></label>";
_Html += "<label><p>"+track.Msg +"</P></label>";
_Html += "</div>";
}
if (idx == 0) {
_Html += "<div class='mui-input-row' style='background-color:#fff'>";
_Html += "<label><p>没有数据</P></label>";
_Html +="</div>"
}
if (btnLab.NoteEnable == 1) {
var msg = "";
if (currTrack != null)
msg = currTrack.Msg;
_Html += '<div class="mui-table-view-divider" style="background-color:#efeff4">'
_Html += '<h5>当前备注信息</h5>';
_Html += "</div>";
_Html += "<div class='mui-input-row' style='background-color:#fff'>";
_Html += '<textarea id="TB_Msg" name="TB_Msg" rows="5" placeholder="请输入当前节点的备注信息">'+msg+'</textarea>';
_Html += "</div>";
}
$("#historyInfo").append(_Html);
});
function AddNote() {
if ($("#TB_Msg").val() == null || $("#TB_Msg").val() == "" || $("#TB_Msg").val().trim().length == 0) {
alert("请填写备注信息!");
return;
}
var handler = new HttpHandler("BP.WF.HttpHandler.WF_WorkOpt");
handler.AddUrlData();
handler.AddPara("Msg", $("#TB_Msg").val());
var data = handler.DoMethodReturnString("Note_Save");
if (data.indexOf('err@') == 0) {
mui.toast(data);
return;
}
BackToWork();
}
function Back() {
var url = "../MyFlowGener.htm?WorkID=" + GetQueryString("WorkID") + "&FK_Flow=" + GetQueryString("FK_Flow") + "&FK_Node=" + GetQueryString("FK_Node") + "&ms=" + Math.random();
SetHref(url);
}
//返回我的工作.
function BackToWork() {
var url = "../MyFlowGener.htm?WorkID=" + GetQueryString("WorkID") + "&FK_Flow=" + GetQueryString("FK_Flow") + "&FK_Node=" + GetQueryString("FK_Node");
SetHref(url);
}
function BackTolist() {
var url = "../Todolist.htm?WorkID=" + GetQueryString("WorkID") + "&FK_Flow=" + GetQueryString("FK_Flow") + "&FK_Node=" + GetQueryString("FK_Node");
SetHref(url);
}
/**/</script>
</head>
<body>
<!--标题-->
<header class="mui-bar mui-bar-nav">
<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
<h1 class="mui-title">备注信息</h1>
</header>
<!--底部按钮-->
<nav class="mui-bar mui-bar-tab">
<a class="mui-tab-item" href="#" onclick="AddNote()">备注</a>
<a class="mui-tab-item" href="#" onclick="BackToWork()" )=)>返回我的工作</a>
<a class="mui-tab-item" href="#" onclick="BackTolist()" )=)>返回待办</a>
</nav>
<!--页面内容展示-->
<div class="mui-content">
<div class="mui-scroll-wrapper">
<div class="mui-scroll">
<!--显示历史备注信息-->
<div id="historyInfo" style="margin-top:45px"></div>
</div>
</div>
</div>
</body>
<script type="text/javascript">
//初始化单页的区域滚动
mui('.mui-scroll-wrapper').scroll();
</script>
</html>