apzl_leasing/WebContent/Common/WorkFlow/SignTaskOpinionInfo.jsp
2018-06-03 22:26:41 +08:00

89 lines
3.4 KiB
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<%@page import="com.amarsoft.app.lc.LCConstant"%>
<%@page import="com.amarsoft.biz.workflow.FlowTask"%>
<%@ page contentType="text/html; charset=GBK"%><%@ include file="/Frame/resources/include/include_begin_info.jspf"%><%
/*
Content: 签署意见
Input Param:
TaskNo任务流水号
ObjectNo对象编号
ObjectType对象类型
*/
//获取组件参数:任务流水号
String sSerialNo = CurPage.getParameter("TaskNo");
String sObjectNo = CurPage.getParameter("ObjectNo");
String sObjectType = CurPage.getParameter("ObjectType");
String sRightType = CurPage.getParameter("RightType");
if(sSerialNo == null) sSerialNo = "";
if(sObjectNo == null) sObjectNo = "";
if(sObjectType == null) sObjectType = "";
ASObjectModel doTemp = new ASObjectModel("SignTaskOpinionInfo");
if(!StringX.isEmpty(sSerialNo)){
doTemp.setDefaultValue("SerialNo", sSerialNo);
doTemp.setDefaultValue("OpinionNo", CurUser.getUserID());
FlowTask ft = new FlowTask(sSerialNo, Sqlca);
//贷审会阶段显示'结论',并且是必输项 //
if("MEETING".equalsIgnoreCase(ft.RelativeFlowPhase.NodeType)){
doTemp.setVisible("PhaseChoice", true);
doTemp.setRequired("PhaseChoice", true);
}
}
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
dwTemp.Style="2";//freeform形式
dwTemp.genHTMLObjectWindow(sSerialNo+","+CurUser.getUserID());
String sButtons[][] = {
{"ReadOnly".equalsIgnoreCase(sRightType)?"false":"true","","Button","保存","保存所有修改","saveRecord()","","","",""},
{"ReadOnly".equalsIgnoreCase(sRightType)?"false":"true","","Button","删除","删除意见","deleteRecord()","","","",""},
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
/*~[Describe=保存签署的意见;InputParam=无;OutPutParam=无;]~*/
function saveRecord(){
//不允许签署的意见为空白字符
if(/^\s*$/.exec(getItemValue(0,0,"PhaseOpinion"))){
alert("请签署意见!");
setItemValue(0,0,"PhaseOpinion","");
return;
}
setItemValue(0,0,"UpdateUser","<%=CurUser.getUserID()%>");
setItemValue(0,0,"UpdateTime","<%=StringFunction.getToday()%>");
as_save("myiframe0","closePage()");
}
function closePage(){
parent.AsDialog.ClosePage("SUCCESS");
}
/*~[Describe=删除已删除意见;InputParam=无;OutPutParam=无;]~*/
function deleteRecord(){
var sSerialNo=getItemValue(0,0,"SerialNo");
var sOpinionNo = getItemValue(0,0,"OpinionNo");
if (typeof(sOpinionNo)=="undefined" || sOpinionNo.length==0){
alert("您还没有签署意见,不能做删除意见操作!");
}else if(confirm("你确实要删除意见吗?")){
var sReturn = RunJavaMethodTrans("com.amarsoft.app.lc.workflow.action.SignOpinionAction","deleteSignOpinion","serialNo="+sSerialNo+",opinoinNo="+sOpinionNo);
if (sReturn=="<%=LCConstant.OPERATION_FLAG_SUCCESS%>"){
alert("删除意见成功!");
}else{
alert("删除意见失败!");
}
$("#PHASEOPINION").val("");
}
//reloadSelf();
}
/*~[Describe=插入一条新记录;InputParam=无;OutPutParam=无;]~*/
function initRow(){
if (getRowCount(0)==0){
setItemValue(0,0,"InputOrg","<%=CurOrg.getOrgID()%>");
setItemValue(0,0,"InputOrgName","<%=CurOrg.getOrgName()%>");
setItemValue(0,0,"InputUser","<%=CurUser.getUserID()%>");
setItemValue(0,0,"InputUserName","<%=CurUser.getUserName()%>");
setItemValue(0,0,"InputTime","<%=StringFunction.getToday()%>");
}
}
initRow();
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>