This commit is contained in:
hexiaomou 2018-06-20 15:12:50 +08:00
commit 6ca2cd9d98
16 changed files with 967 additions and 11 deletions

View File

@ -0,0 +1,56 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
ASObjectModel doTemp = new ASObjectModel("APP_FLOW_LIST");
doTemp.setLockCount(2); //锁定两列
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
dwTemp.Style="1"; //设置为Grid风格
dwTemp.ReadOnly = "1";//编辑模式
dwTemp.setPageSize(10);
dwTemp.ConvertCode2Title = "1";
dwTemp.genHTMLObjectWindow("");
String sButtons[][] = {
{"true","","Button","导入新流程","导入新流程","importNewFlow()","","","","btn_icon_add"},
{"true","","Button","取消流程","取消流程","delFlow()","","","","btn_icon_delete"},
{"true","","Button","流程配置","流程配置","configureFlow()","","","","btn_icon_workflow"},
};
%>
<%@include file="/Frame/resources/include/ui/include_list.jspf"%>
<script type="text/javascript">
function importNewFlow() {
AsDialog.selectCatalogDialog("SelectFlow", "", "", function(sReturn) {
if (typeof (sReturn) == "undefined" || sReturn.length == 0)
return;
sReturn = sReturn.split("@");
var FlowNo = sReturn[0];
var sResult = AsControl.RunJavaMethodTrans("com.amarsoft.app.check.AppFlow","checkFlowByFlowNo","flowNo="+FlowNo);
alert(sResult);
reloadSelf();
});
}
function delFlow() {
var flowno = getItemValue(0, getRow(), "flowno");
if (typeof (flowno) == "undefined" || flowno.length == 0) {
alert("请选择一条流程记录");
return;
}
var sResult = AsControl.RunJavaMethodTrans("com.amarsoft.app.check.AppFlow",
"DelFlowByFlowNo","flowNo="+flowno);
alert(sResult);
reloadSelf();
}
function configureFlow() {
var flowno = getItemValue(0, getRow(), "flowno");
if (typeof (flowno) == "undefined" || flowno.length == 0) {
alert("请选择一条流程记录");
return;
}
var sUrl = "/AppConfig/AppFlow/CatalogList.jsp";
AsControl.OpenTab(sUrl,"flowNo="+flowno,{title:"手机流程阶段配置"});
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,50 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_info.jspf"%><%
//获得参数
String flowNo = CurPage.getParameter("flowNo");
String phaseNo = CurPage.getParameter("phaseNo");
if (flowNo == null) flowNo = "";
if (phaseNo == null) phaseNo = "";
String id = CurPage.getParameter("id");
if (id == null) id = "";
String sUserID = CurPage.getParameter("UserID");
if (sUserID == null) sUserID = "";
java.util.Date dateNow = new java.util.Date();
SimpleDateFormat sdfTemp = new SimpleDateFormat("yyyy/MM/dd");
String date = sdfTemp.format(dateNow);
ASObjectModel doTemp = new ASObjectModel("APP_PRD_CATALOG_INFO");
doTemp.setDefaultValue("FLOWNO", flowNo);
doTemp.setReadOnly("FLOWNO", true);
if (!"".equals(phaseNo)) {
doTemp.setReadOnly("PHASENO", true);
} else {
doTemp.setReadOnly("PHASENO", false);
}
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
dwTemp.Style = "2"; //设置DW风格 1:Grid 2:Freeform
dwTemp.ReadOnly = "0"; //设置是否只读 1:只读 0:可写
dwTemp.genHTMLObjectWindow(id);
String sButtons[][] = {
{"true", "All", "Button", "保存","保存所有修改", "saveRecord()", "", "", "", "btn_icon_save"},
{"true", "All", "Button", "关闭","关闭", "goBack()", "", "", "", "btn_icon_close"},
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
function goBack(){
parent.AsDialog.ClosePage();
}
function saveRecord(sPostEvents) {
as_save("myiframe0", "goBack()");
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,63 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
String flowNo = CurPage.getParameter("flowNo");
if (null == flowNo) flowNo = "";
ASObjectModel doTemp = new ASObjectModel("APP_PRD_CATALOG_LIST");
doTemp.setLockCount(2); //锁定两列
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
dwTemp.Style="1"; //设置为Grid风格
dwTemp.ReadOnly = "1";//编辑模式
dwTemp.setPageSize(10);
dwTemp.ConvertCode2Title = "1";
dwTemp.genHTMLObjectWindow(flowNo);
String sButtons[][] = {
{"true","","Button","新增阶段","新增阶段","newRecord()","","","","btn_icon_add"},
{"true","","Button","取消阶段","取消阶段",
"if(confirm('确实要删除吗?'))as_delete(0,'')","","","","btn_icon_delete"},
{"true","","Button","编辑阶段","编辑阶段","viewAndEdit()","","","","btn_icon_edit"},
{"true","","Button","页签配置","页签配置","middleConfig()","","","","btn_icon_workflow"},
};
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
<script type="text/javascript">
function newRecord() {
var flowNo = getItemValue(0, getRow(0), 'flowno');
var phaseNo = "";
var sUrl = "/AppConfig/AppFlow/CatalogInfo.jsp";
AsDialog.PopView(sUrl, "flowNo="+flowNo+"&phaseNo="+phaseNo, "dialogWidth=600px;dialogHeight=450px;",
function(message) {
reloadSelf();
}, "新增阶段");
}
function viewAndEdit() {
var sUrl = "/AppConfig/AppFlow/CatalogInfo.jsp";
var id = getItemValue(0, getRow(0), 'id');
if (id == "" || typeof(id) == "undefined") {
alert("请选择一条阶段!");
return false;
}
var flowNo = getItemValue(0, getRow(0), 'flowno');
var phaseNo = getItemValue(0, getRow(0), 'phaseno');
AsDialog.PopView(sUrl, "id=" + id + "&flowNo="+flowNo+"&phaseNo="+phaseNo,
"dialogWidth=600px;dialogHeight=450px;", function(message) {
reloadSelf();
}, "编辑阶段");
}
function middleConfig() {
var id = getItemValue(0, getRow(0), 'id');
if (id == "" || typeof(id) == "undefined") {
alert("请选择一条阶段!");
return false;
}
var flowNo = getItemValue(0, getRow(0), 'flowno');
var phaseNo = getItemValue(0, getRow(0), 'phaseno');
var sUrl = "/AppConfig/AppFlow/MiddleList.jsp";
AsControl.OpenTab(sUrl,"id="+id + "&flowNo="+flowNo+"&phaseNo="+phaseNo, {title:"流程页签配置"});
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,39 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_info.jspf"%><%
//获得参数
String catalogId = CurPage.getParameter("catalogId");
String libraryId = CurPage.getParameter("libraryId");
if (catalogId == null) catalogId = "";
if (libraryId == null) libraryId = "";
String sUserID = CurPage.getParameter("UserID");
if (sUserID == null) sUserID = "";
java.util.Date dateNow = new java.util.Date();
SimpleDateFormat sdfTemp = new SimpleDateFormat("yyyy/MM/dd");
String date = sdfTemp.format(dateNow);
ASObjectModel doTemp = new ASObjectModel("APP_MIDDLE_INFO");
if (!"".equals(catalogId)) doTemp.setDefaultValue("APP_NODE_CATALOG_ID", catalogId);
if (!"".equals(libraryId)) doTemp.setDefaultValue("APP_NODE_LIBRARY_ID", libraryId);
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
dwTemp.Style = "2"; //设置DW风格 1:Grid 2:Freeform
dwTemp.ReadOnly = "0"; //设置是否只读 1:只读 0:可写
dwTemp.genHTMLObjectWindow(catalogId+","+libraryId);
String sButtons[][] = {
{"true", "All", "Button", "保存","保存所有修改", "saveRecord()", "", "", "", "btn_icon_save"}
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
function goBack(){
parent.AsDialog.ClosePage();
}
function saveRecord() {
as_save("myiframe0", "goBack()");
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,68 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
String id = CurPage.getParameter("id");
String flowNo = CurPage.getParameter("flowNo");
String phaseNo = CurPage.getParameter("phaseNo");
if (id == null) id = "";
if (null == flowNo) flowNo = "";
if (phaseNo == null) phaseNo = "";
String sUserID = CurPage.getParameter("UserID");
if (sUserID == null) sUserID = "";
ASObjectModel doTemp = new ASObjectModel("APP_MIDDLE_LIST");
doTemp.setLockCount(2); //锁定两列
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
dwTemp.Style="1"; //设置为Grid风格
dwTemp.ReadOnly = "1";//编辑模式
dwTemp.setPageSize(10);
dwTemp.ConvertCode2Title = "1";
dwTemp.genHTMLObjectWindow(id);
String sButtons[][] = {
{"true","","Button","新增页签","新增页签","newRecord()","","","","btn_icon_add"},
{"true","","Button","取消页签","取消页签",
"if(confirm('确实要删除吗?'))as_delete(0,'')","","","","btn_icon_delete"},
{"true","","Button","编辑页签","编辑页签","viewAndEdit()","","","","btn_icon_edit"}
};
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
<script type="text/javascript">
function newRecord() {
var catalogId = "<%=id%>"
var libraryId = "";
AsDialog.selectCatalogDialog("AppPageLibraryList", "", "", function(sReturn) {
if (typeof (sReturn) == "undefined" || sReturn.length == 0)
return;
sReturn = sReturn.split("@");
libraryId = sReturn[0];
var sUrl = "/AppConfig/AppFlow/MiddleInfo.jsp";
AsDialog.PopView(sUrl, "catalogId="+catalogId + "&libraryId="+libraryId, "dialogWidth=600px;dialogHeight=450px;",
function(message) {
reloadSelf();
}, "新增页签");
});
}
function viewAndEdit() {
var sUrl = "/AppConfig/AppFlow/MiddleInfo.jsp";
var catalogId = "<%=id%>"
var libraryId = getItemValue(0, getRow(0), 'APP_NODE_LIBRARY_ID');
if (catalogId == "" || typeof (catalogId) == "undefined") {
alert("请选择一条页签!");
return false;
}
if (libraryId == "" || typeof (libraryId) == "undefined") {
alert("请选择一条页签!");
return false;
}
AsDialog.PopView(sUrl, "catalogId=" + catalogId + "&libraryId="
+ libraryId, "dialogWidth=600px;dialogHeight=450px;", function(
message) {
reloadSelf();
}, "编辑页签");
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,56 @@
<%@page import="jbo.awe.AWE_DO_CATALOG"%>
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
//获得参数
String GROUP_CODE = CurPage.getParameter("GROUP_CODE");
if (GROUP_CODE == null)
GROUP_CODE = "";
ASObjectModel doTemp = new ASObjectModel(
"APP_BUSINESS_ADD");
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,
request);
dwTemp.Style = "2"; //设置DW风格 1:Grid 2:Freeform
dwTemp.ReadOnly = "0"; //设置是否只读 1:只读 0:可写
dwTemp.genHTMLObjectWindow(GROUP_CODE);
String sButtons[][] = {
{"true", "All", "Button", "添加","添加", "saveRecord()", "", "", "", "btn_icon_add"},
{"true", "All", "Button", "关闭","关闭", "goBack()", "", "", "", "btn_icon_close"},
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
function goBack() {
parent.AsDialog.ClosePage();
}
function saveRecord() {
var isList = getItemValue(0, getRow(0), 'ISLIST');
var selName = 'SelectDo';
var GROUP_CODE = "";
var dono = "";
var doname = "";
AsDialog.selectCatalogDialog(selName, "", "",
function(sReturn) {
if (typeof (sReturn) == "undefined" || sReturn.length == 0)
return;
sReturn = sReturn.split("@");
dono = sReturn[0];
doname = sReturn[1];
var param = "dono=" + dono
+ ",groupCode='',isList=" + isList;
var sResult = AsControl.RunJavaMethodTrans(
"com.amarsoft.app.check.AppFlow",
"importDonoGroup", param);
var array = sResult.split("@");
alert(array[1]);
if ("success" == array[0]) {
goBack();
}
});
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,44 @@
<%@page import="jbo.awe.AWE_DO_CATALOG"%>
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
//获得参数
String dono = CurPage.getParameter("dono");
if (dono == null) dono = "";
String doname = CurPage.getParameter("doname");
if (doname == null) doname = "";
String GROUP_CODE = CurPage.getParameter("GROUP_CODE");
if (GROUP_CODE == null) GROUP_CODE = "";
String sUserID = CurPage.getParameter("UserID");
if (sUserID == null) sUserID = "";
ASObjectModel doTemp = new ASObjectModel("APP_BUSINESS_GROUP_INFO");
doTemp.setReadOnly("GROUP_CODE", true);
doTemp.setRequired("GROUP_CODE", true);
doTemp.setRequired("GROUP_NAME", true);
doTemp.setVisible("DONO", false);
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
dwTemp.Style = "2"; //设置DW风格 1:Grid 2:Freeform
dwTemp.ReadOnly = "0"; //设置是否只读 1:只读 0:可写
dwTemp.genHTMLObjectWindow(GROUP_CODE);
String sButtons[][] = {
{"true", "All", "Button", "保存","保存所有修改", "saveRecord()", "", "", "", "btn_icon_save"},
{"true", "All", "Button", "关闭","关闭", "goBack()", "", "", "", "btn_icon_close"},
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
function goBack(){
parent.AsDialog.ClosePage();
}
function saveRecord(sPostEvents) {
as_save("myiframe0", "goBack()");
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,70 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
ASObjectModel doTemp = new ASObjectModel("APP_BUSINESS_GROUP_LIST");
doTemp.setLockCount(2); //锁定两列
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
dwTemp.Style="1"; //设置为Grid风格
dwTemp.ReadOnly = "1";//编辑模式
dwTemp.setPageSize(10);
dwTemp.ConvertCode2Title = "1";
dwTemp.genHTMLObjectWindow("");
String sButtons[][] = {
{"true","","Button","新增新模板分组","新增新模板分组","newRecord()","","","","btn_icon_add"},
{"true","","Button","取消模板分组","取消模板分组","if(confirm('确实要删除吗?'))del()","","","","btn_icon_delete"},
{"true","","Button","编辑模板分组","编辑模板分组","viewAndEdit()","","","","btn_icon_edit"},
{"true","","Button","模板分组配置","模板分组配置","templateConfig()","","","","btn_icon_workflow"},
};
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
<script type="text/javascript">
function newRecord() {
var sUrl = "/AppConfig/AppPage/AppLibraryAdd.jsp";
AsDialog.PopView(sUrl, "", "dialogWidth=600px;dialogHeight=450px;",
function(message) {
reloadSelf();
}, "新模板分组配置");
}
function viewAndEdit() {
var sUrl = "/AppConfig/AppPage/AppLibraryGroupInfo.jsp";
var GROUP_CODE = getItemValue(0, getRow(0), 'GROUP_CODE');
if (GROUP_CODE == "" || typeof (GROUP_CODE) == "undefined") {
alert("请选择一条分组!");
return false;
}
AsDialog.PopView(sUrl, "GROUP_CODE=" + GROUP_CODE + "&dono=''",
"dialogWidth=600px;dialogHeight=450px;", function(message) {
reloadSelf();
}, "模板分组配置");
}
function del() {
var GROUP_CODE = getItemValue(0, getRow(0), 'GROUP_CODE');
if (GROUP_CODE == "" || typeof (GROUP_CODE) == "undefined") {
alert("请选择一条分组!");
return false;
}
var sResult = AsControl.RunJavaMethodTrans(
"com.amarsoft.app.check.AppFlow", "delDonoGroup", "groupCode="+GROUP_CODE);
alert(sResult);
reloadSelf();
}
function templateConfig() {
var GROUP_CODE = getItemValue(0, getRow(0), 'GROUP_CODE');
if (GROUP_CODE == "" || typeof (GROUP_CODE) == "undefined") {
alert("请选择一条分组!");
return false;
}
var flowNo = getItemValue(0, getRow(0), 'flowno');
var phaseNo = getItemValue(0, getRow(0), 'phaseno');
var sUrl = "/AppConfig/AppPage/AppLibraryTemplateList.jsp";
AsControl.OpenTab(sUrl, "GROUP_CODE=" + GROUP_CODE, {title : "模板分组配置"});
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,43 @@
<%@page import="jbo.awe.AWE_DO_CATALOG"%>
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
//获得参数
String GROUP_CODE = CurPage.getParameter("GROUP_CODE");
if (GROUP_CODE == null) GROUP_CODE = "";
String DATA_CODE = CurPage.getParameter("DATA_CODE");
if (DATA_CODE == null) DATA_CODE = "";
ASObjectModel doTemp = new ASObjectModel("APP_BUSINESS_TEMPLATE_INFO");
if (!"".equals(DATA_CODE)) {
doTemp.setReadOnly("DONO", true);
doTemp.setReadOnly("COLINDEX", true);
doTemp.setReadOnly("SORTNO", true);
doTemp.setReadOnly("COLNAME", true);
doTemp.setReadOnly("DATA_CODE", true);
} else {
doTemp.setDefaultValue("GROUP_CODE", GROUP_CODE);
}
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
dwTemp.Style = "2"; //设置DW风格 1:Grid 2:Freeform
dwTemp.ReadOnly = "0"; //设置是否只读 1:只读 0:可写
dwTemp.genHTMLObjectWindow(GROUP_CODE+","+DATA_CODE);
String sButtons[][] = {
{"true", "All", "Button", "保存","保存所有修改", "saveRecord()", "", "", "", "btn_icon_save"},
{"true", "All", "Button", "关闭","关闭", "goBack()", "", "", "", "btn_icon_close"},
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
function goBack(){
parent.AsDialog.ClosePage();
}
function saveRecord(sPostEvents) {
as_save("myiframe0", "goBack()");
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,64 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
String GROUP_CODE = CurPage.getParameter("GROUP_CODE");
if (GROUP_CODE == null)
GROUP_CODE = "";
ASObjectModel doTemp = new ASObjectModel("APP_BUSINESS_TEMPLATE_LIST");
doTemp.setLockCount(2); //锁定两列
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
dwTemp.Style="1"; //设置为Grid风格
dwTemp.ReadOnly = "1";//编辑模式
dwTemp.setPageSize(10);
dwTemp.ConvertCode2Title = "1";
dwTemp.genHTMLObjectWindow(GROUP_CODE);
String sButtons[][] = {
{"true","","Button","新增字段","新增字段","newRecord()","","","","btn_icon_add"},
{"true","","Button","删除字段","删除字段","if(confirm('确实要删除吗?'))as_delete(0,'')","","","","btn_icon_delete"},
{"true","","Button","编辑字段","编辑字段","viewAndEdit()","","","","btn_icon_edit"},
};
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
<script type="text/javascript">
function newRecord() {
var GROUP_CODE = getItemValue(0, getRow(0), 'GROUP_CODE');
var sUrl = "/AppConfig/AppPage/AppLibraryTemplateInfo.jsp";
AsDialog.PopView(sUrl,"GROUP_CODE="+GROUP_CODE,
"dialogWidth=600px;dialogHeight=450px;", function(message) {
reloadSelf();
}, "新模板分组配置");
}
function viewAndEdit() {
var sUrl = "/AppConfig/AppPage/AppLibraryTemplateInfo.jsp";
var GROUP_CODE = getItemValue(0, getRow(0), 'GROUP_CODE');
var DATA_CODE = getItemValue(0, getRow(0), 'DATA_CODE');
alert(DATA_CODE);
if (DATA_CODE == "" || typeof (DATA_CODE) == "undefined") {
alert("请选择一条分组字段!");
return false;
}
AsDialog.PopView(sUrl,"GROUP_CODE="+GROUP_CODE+"&DATA_CODE="+DATA_CODE,
"dialogWidth=600px;dialogHeight=450px;", function(message) {
reloadSelf();
}, "模板分组配置");
}
function middleConfig() {
var id = getItemValue(0, getRow(0), 'id');
if (id == "" || typeof(id) == "undefined") {
alert("请选择一条阶段!");
return false;
}
var flowNo = getItemValue(0, getRow(0), 'flowno');
var phaseNo = getItemValue(0, getRow(0), 'phaseno');
var sUrl = "/AppConfig/AppFlow/MiddleList.jsp";
AsControl.OpenTab(sUrl,"id="+id + "&flowNo="+flowNo+"&phaseNo="+phaseNo, {title:"流程页签配置"});
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,40 @@
<%@page import="jbo.awe.AWE_DO_CATALOG"%>
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_info.jspf"%><%
//获得参数
String GROUP_CODE = CurPage.getParameter("GROUP_CODE");
if (GROUP_CODE == null) GROUP_CODE = "";
String id = CurPage.getParameter("id");
if (id == null) id = "";
ASObjectModel doTemp = new ASObjectModel("APP_NODEINFO_LIBRARY_APP_INFO");
doTemp.setReadOnly("APP_BUSINESS_GROUP_CODE", true);
if ("".equals(id)) {
doTemp.setDefaultValue("APP_BUSINESS_GROUP_CODE", GROUP_CODE);
/* doTemp.setHtmlEvent("ENABLE_CONDITION", "onchange", "openConditionShow"); */
}
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
dwTemp.Style = "2"; //设置DW风格 1:Grid 2:Freeform
dwTemp.ReadOnly = "0"; //设置是否只读 1:只读 0:可写
dwTemp.genHTMLObjectWindow(id);
String sButtons[][] = {
{"true", "All", "Button", "保存","保存所有修改", "saveRecord()", "", "", "", "btn_icon_save"},
{"true", "All", "Button", "关闭","关闭", "goBack()", "", "", "", "btn_icon_close"},
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
function goBack(){
parent.AsDialog.ClosePage();
}
function saveRecord(sPostEvents) {
as_save("myiframe0", "goBack()");
}
/* openConditionShow(); */
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -0,0 +1,58 @@
<%@ page contentType="text/html; charset=GBK"%><%@
include file="/Frame/resources/include/include_begin_list.jspf"%><%
ASObjectModel doTemp = new ASObjectModel("APP_NODEINFO_LIBRARY_APP_LIST");
doTemp.setLockCount(2); //锁定两列
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
dwTemp.Style="1"; //设置为Grid风格
dwTemp.ReadOnly = "1";//编辑模式
dwTemp.setPageSize(10);
dwTemp.ConvertCode2Title = "1";
dwTemp.genHTMLObjectWindow("");
String sButtons[][] = {
{"true","","Button","新增页面","新增页面","newRecord()","","","","btn_icon_add"},
{"true","","Button","编辑页面","编辑页面","viewAndEdit()","","","","btn_icon_edit"},
};
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
<script type="text/javascript">
function newRecord() {
var selName = "AppPageGroupList";
var GROUP_CODE = "";
var GROUP_NAME = "";
AsDialog.selectCatalogDialog(selName, "", "",
function(sReturn) {
if (typeof (sReturn) == "undefined" || sReturn.length == 0)
return;
sReturn = sReturn.split("@");
GROUP_CODE = sReturn[0];
GROUP_NAME = sReturn[1];
var param = "GROUP_CODE="+GROUP_CODE;
alert(param);
var sUrl = "/AppConfig/AppPage/AppNodeInfo.jsp";
AsDialog.PopView(sUrl, param, "dialogWidth=800px;dialogHeight=650px;",
function(message) {
reloadSelf();
}, "新增页面");
});
}
function viewAndEdit() {
debugger;
var sUrl = "/AppConfig/AppPage/AppNodeInfo.jsp";
var id = getItemValue(0, getRow(0), 'id');
if (id == "" || typeof (id) == "undefined") {
alert("请选择一条页面配置!");
return false;
}
AsDialog.PopView(sUrl, "id=" + id,
"dialogWidth=800px;dialogHeight=650px;", function(message) {
reloadSelf();
}, "编辑页面");
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -8,6 +8,7 @@
doTemp.setHtmlEvent("status","onchange","changeOtherRequired");
doTemp.setDefaultValue("rccurrency", "01");
doTemp.setDefaultValue("pccurrency", "01");
// doTemp.setDefaultValue("status", "checked","checked");
//初始化客户类别字段
BizObjectManager typeManager = JBOFactory.getBizObjectManager(CUSTOMER_TYPE.CLASS_NAME);
List<BizObject> types = typeManager.createQuery("customerid=:customerid and status='valid'").setParameter("customerid",customerId).getResultList(false);
@ -38,6 +39,7 @@
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
$(document).ready(function(){
$("#STATUS_0").prop("checked", true);
init();
changeOtherRequired();
})
@ -57,7 +59,7 @@
function changeOtherRequired(){
var status = getItemValue(0,getRow(),"status");
var country = getItemValue(0,getRow(),"countrycode");
if(status == "status02"){
// if(status == "status02"){
setItemRequired(0,"custkind",true);
setItemRequired(0,"custsource",true);
setItemRequired(0,"certtype",true);
@ -74,7 +76,7 @@
setItemRequired(0,"establish_date",true);
setItemRequired(0,"licensematurity",true);
setItemRequired(0,"operationperiod",true);
/*
}else{
setItemRequired(0,"custkind",false);
setItemRequired(0,"custsource",false);
@ -92,7 +94,7 @@
setItemRequired(0,"establish_date",false);
setItemRequired(0,"licensematurity",false);
setItemRequired(0,"operationperiod",false);
}
} */
if(status == "status02" && country=='CHN'){
/* setItemRequired(0,"provincecodename",true);
setItemRequired(0,"citycodename",true); */
@ -117,7 +119,7 @@
}
function changeRegisterInfo(){//客户状态为正式时注册信息必填,否则不必填
var status = getItemValue(0,getRow(),"status");
if(status == "status02"){
//if(status == "status02"){
setItemRequired(0,"economytypename",true);
setItemRequired(0,"orgnaturename",true);
setItemRequired(0,"orgnaturecategoryname",true);
@ -131,7 +133,7 @@
setItemRequired(0,"licensematurity",true);
setItemRequired(0,"operationperiod",true);
}else{
/* }else{
setItemRequired(0,"economytypename",false);
setItemRequired(0,"orgnaturename",false);
setItemRequired(0,"orgnaturecategoryname",false);
@ -144,7 +146,7 @@
setItemRequired(0,"establish_date",false);
setItemRequired(0,"licensematurity",false);
setItemRequired(0,"operationperiod",false);
}
} */
}
function saveRecord(){

View File

@ -17,6 +17,7 @@
String custname=CurPage.getParameter("custname");
System.out.print(custname+"=====================");
doTemp.setHtmlEvent("CERTID","onChange","changeCertid");
doTemp.setHtmlEvent("MARRIAGE","onChange","changeChildrensNumber");
String rightType = CurPage.getParameter("RightType");//Ò³ÃæÖ»¶ÁÓë·ñ
if(rightType==null)rightType="";
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
@ -39,9 +40,20 @@
};
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
if(getItemValue(0,0,"CERTTYPE") == null || getItemValue(0,0,"CERTTYPE") == ""){
setItemValue(0,0,"CERTTYPE","Ind01");
}
function changeChildrensNumber(){
var marriage = getItemValue(0,0,"MARRIAGE");
if("02" == marriage){
setItemValue(0,0,"childrens_number","");
$("#CHILDRENS_NUMBER").attr("ReadOnly","true");
}else{
$("#CHILDRENS_NUMBER").removeAttr("ReadOnly");
}
}
if(getItemValue(0,0,"CERTTYPE") == null || getItemValue(0,0,"CERTTYPE") == ""){
setItemValue(0,0,"CERTTYPE","Ind01");
}
$(document).ready(function(){
//init();

View File

@ -1305,7 +1305,7 @@
<attribute name="DEVICE_TYPE" label="设备类型" type="STRING" length="30"/>
<attribute name="EQUIP_NAME" label="设备名称" type="STRING" length="200"/>
<attribute name="BRAND" label="品牌" type="STRING" length="30"/>
<attribute name="MODEL" label="型号/规格" type="STRING" length="30"/>
<attribute name="MODEL" label="型号/规格" type="STRING" length="60"/>
<attribute name="EQUIP_NUM" label="数量" type="STRING" length="30"/>
<attribute name="PRICE" label="单价" type="STRING" length="30"/>
<attribute name="UNIT" label="单位" type="STRING" length="30"/>
@ -3374,7 +3374,7 @@
<attribute name="DEVICE_TYPE" label="车辆类型" type="STRING" length="30"/>
<attribute name="EQUIP_NAME" label="设备名称" type="STRING" length="200"/>
<attribute name="BRAND" label="车辆品牌" type="STRING" length="30"/>
<attribute name="MODEL" label="型号" type="STRING" length="30"/>
<attribute name="MODEL" label="型号" type="STRING" length="60"/>
<attribute name="EQUIP_NUM" label="数量" type="STRING" length="30"/>
<attribute name="PRICE" label="单价" type="STRING" length="30"/>
<attribute name="UNIT" label="单位" type="STRING" length="30"/>

View File

@ -0,0 +1,291 @@
package com.amarsoft.app.check;
import java.text.SimpleDateFormat;
import java.util.List;
import java.util.Random;
import jbo.app.APP_BUSINESS_GROUP;
import jbo.app.APP_BUSINESS_TEMPLATE;
import jbo.app.PRD_NODEINFO_CATALOG_APP;
import jbo.app.PRD_NODEINFO_MIDDLE_APP;
import jbo.awe.AWE_DO_CATALOG;
import jbo.sys.FLOW_MODEL;
import com.amarsoft.are.ARE;
import com.amarsoft.are.jbo.BizObject;
import com.amarsoft.are.jbo.BizObjectManager;
import com.amarsoft.are.jbo.BizObjectQuery;
import com.amarsoft.are.jbo.JBOFactory;
import com.amarsoft.are.jbo.JBOTransaction;
import com.tenwa.reckon.util.UUIDUtil;
public class AppFlow {
private String groupCode;
private String groupName;
private String isList;
private String dono;
public String getGroupCode() {
return groupCode;
}
public void setGroupCode(String groupCode) {
this.groupCode = groupCode;
}
public String getGroupName() {
return groupName;
}
public void setGroupName(String groupName) {
this.groupName = groupName;
}
public String getIsList() {
return isList;
}
public void setIsList(String isList) {
this.isList = isList;
}
public String getDono() {
return dono;
}
public void setDono(String dono) {
this.dono = dono;
}
public String generateRandomNumber() {
java.util.Date dateNow = new java.util.Date();
SimpleDateFormat sdfTemp1 = new SimpleDateFormat("yyyy");
SimpleDateFormat sdfTemp2 = new SimpleDateFormat("MM");
SimpleDateFormat sdfTemp3 = new SimpleDateFormat("dd");
SimpleDateFormat sdfTemp4 = new SimpleDateFormat("HH");
SimpleDateFormat sdfTemp5 = new SimpleDateFormat("mm");
String date1 = sdfTemp1.format(dateNow);
String date2 = sdfTemp2.format(dateNow);
String date3 = sdfTemp3.format(dateNow);
String date4 = sdfTemp4.format(dateNow);
String date5 = sdfTemp5.format(dateNow);
Random r = new Random();
int i = r.nextInt(10000) + 1;
String str = String.valueOf(i);
str = date1 + "" + date2 + "" + date3 + "" + date4 + "" + date5 + ""
+ "R" + str;
ARE.getLog().debug(str);
return str;
}
public String delDonoGroup(JBOTransaction tx) throws Exception {
BizObjectManager groupManage = JBOFactory
.getBizObjectManager(APP_BUSINESS_GROUP.CLASS_NAME);
BizObjectManager templateManage = JBOFactory
.getBizObjectManager(APP_BUSINESS_TEMPLATE.CLASS_NAME);
tx.join(groupManage);
tx.join(templateManage);
BizObject groupBo = groupManage.createQuery("GROUP_CODE=:GROUP_CODE")
.setParameter("GROUP_CODE", this.groupCode)
.getSingleResult(true);
List<BizObject> templateBos = templateManage
.createQuery("GROUP_CODE=:GROUP_CODE")
.setParameter("GROUP_CODE", this.groupCode).getResultList(true);
if (null != groupBo) {
groupManage.deleteObject(groupBo);
tx.commit();
}
if (templateBos.size() > 0) {
for (BizObject templateBo : templateBos) {
templateManage.deleteObject(templateBo);
tx.commit();
}
}
return "操作成功!";
}
public String importDonoGroup(JBOTransaction tx) throws Exception {
BizObjectManager doManage = JBOFactory
.getBizObjectManager(AWE_DO_CATALOG.CLASS_NAME);
BizObject doBo = doManage.createQuery("dono=:dono")
.setParameter("dono", this.dono).getSingleResult(false);
if (null == doBo)
return "fail@" + this.dono + "模板号无效,请填写正确的模板号!";
String doName = doBo.getAttribute("doName") == null ? "" : doBo
.getAttribute("doName").toString();
this.groupCode = this.dono + "" + generateRandomNumber();
this.groupName = this.groupName == null ? doName : this.groupName;
BizObjectManager groupManage = JBOFactory
.getBizObjectManager(APP_BUSINESS_GROUP.CLASS_NAME);
BizObjectManager templateManage = JBOFactory
.getBizObjectManager(APP_BUSINESS_TEMPLATE.CLASS_NAME);
tx.join(groupManage);
tx.join(templateManage);
BizObject groupBo = groupManage.createQuery("GROUP_CODE=:GROUP_CODE")
.setParameter("GROUP_CODE", this.groupCode)
.getSingleResult(true);
List<BizObject> templateBos = templateManage
.createQuery("GROUP_CODE=:GROUP_CODE")
.setParameter("GROUP_CODE", this.groupCode).getResultList(true);
if (null != groupBo) {
groupManage.deleteObject(groupBo);
tx.commit();
}
if (templateBos.size() > 0) {
for (BizObject templateBo : templateBos) {
templateManage.deleteObject(templateBo);
tx.commit();
}
}
groupBo = groupManage.newObject();
groupBo.setAttributeValue("GROUP_CODE", this.groupCode);
groupBo.setAttributeValue("GROUP_NAME", this.groupName);
groupBo.setAttributeValue("ISLIST", this.isList);
groupBo.setAttributeValue("GROUP_POSITION", "400000");
groupBo.setAttributeValue("GROUP_ENABLE", "Y");
groupManage.saveObject(groupBo);
tx.commit();
BizObjectManager libraryManage = JBOFactory
.getBizObjectManager(jbo.app.AWE_DO_LIBRARY.CLASS_NAME);
List<BizObject> libraryBos = libraryManage.createQuery("dono=:dono")
.setParameter("dono", this.dono).getResultList(false);
for (BizObject libraryBo : libraryBos) {
BizObject templateBo = templateManage.newObject();
// 绑定参数
templateBo.setAttributeValue("DONO", this.dono);
templateBo.setAttributeValue("COLINDEX",
libraryBo.getAttribute("COLINDEX").getValue());
templateBo.setAttributeValue("SORTNO",
libraryBo.getAttribute("SORTNO").getValue());
templateBo.setAttributeValue("COLNAME",
libraryBo.getAttribute("COLNAME").getValue());
// 主键外键
templateBo.setAttributeValue("GROUP_CODE", this.groupCode);
templateBo.setAttributeValue("DATA_CODE",
libraryBo.getAttribute("COLNAME").getValue());
// 显示配置参数
templateBo.setAttributeValue("DATA_NAME",
libraryBo.getAttribute("COLHEADER").getValue());
templateBo.setAttributeValue("ISLIST", this.isList);
templateBo.setAttributeValue("ISSHOW", "Y");
templateBo.setAttributeValue("DATA_POSITION", libraryBo
.getAttribute("SORTNO").getInt());
templateManage.saveObject(templateBo);
tx.commit();
}
return "success@" + this.groupCode + "分组保存成功!";
}
private String flowNo;
public String getFlowNo() {
return flowNo;
}
public void setFlowNo(String flowNo) {
this.flowNo = flowNo;
}
public String checkFlowByFlowNo(JBOTransaction tx) throws Exception {
try {
BizObjectManager bom = JBOFactory
.getBizObjectManager(PRD_NODEINFO_CATALOG_APP.CLASS_NAME);
BizObjectQuery boq = bom.createQuery("FLOWNO=:FLOWNO")
.setParameter("FLOWNO", flowNo);
BizObject bo = boq.getSingleResult(false);
if (null != bo) {
return "流程已导入, 可进入流程详情进行编辑!";
} else {
BizObjectManager fmManage = JBOFactory
.getBizObjectManager(FLOW_MODEL.CLASS_NAME);
BizObjectManager pManage = JBOFactory
.getBizObjectManager(PRD_NODEINFO_CATALOG_APP.CLASS_NAME);
BizObjectQuery fmQuery = fmManage.createQuery("flowno=:flowno")
.setParameter("flowno", flowNo);
List<BizObject> fms = fmQuery.getResultList(false);
tx.join(pManage);
for (BizObject fm : fms) {
BizObject p = pManage.newObject();
String uuid = UUIDUtil.getUUID();
p.setAttributeValue("id", uuid);
p.setAttributeValue("flowno", flowNo);
p.setAttributeValue("phaseno", fm.getAttribute("phaseno"));
p.setAttributeValue("config_type", "Project");
p.setAttributeValue("config_display", "APP流程详情");
p.setAttributeValue("ENABLE_OPERATION", "N");
p.setAttributeValue("SORTNO", fm.getAttribute("phaseno"));
pManage.saveObject(p);
tx.commit();
}
return "流程导入成功!";
}
} catch (Exception e) {
ARE.getLog().error(e);
tx.rollback();
return "流程导入失败,请联系管理员:" + e;
}
}
public String DelFlowByFlowNo(JBOTransaction tx) throws Exception {
try {
BizObjectManager bom = JBOFactory
.getBizObjectManager(PRD_NODEINFO_CATALOG_APP.CLASS_NAME);
tx.join(bom);
BizObjectQuery boq = bom.createQuery("FLOWNO=:FLOWNO")
.setParameter("FLOWNO", flowNo);
List<BizObject> bos = boq.getResultList(true);
if (bos.size() == 0) {
return "请选择一条流程记录!";
} else {
String ids = "";
for (BizObject bo : bos) {
String id = bo.getAttribute("id") == null ? "" : bo
.getAttribute("id").toString();
ids += "'" + id + "',";
}
if (ids.length() > 1) {
ids = ids.substring(0, ids.length() - 1);
}
BizObjectManager middleManage = JBOFactory
.getBizObjectManager(PRD_NODEINFO_MIDDLE_APP.CLASS_NAME);
List<BizObject> middles = middleManage.createQuery(
"APP_NODE_CATALOG_ID in (" + ids + ")").getResultList(
false);
if (middles.size() > 0) {
return "此流程尚有页签未取消,无法删除!";
}
boq = bom.createQuery("DELETE FROM O WHERE FLOWNO=:FLOWNO")
.setParameter("FLOWNO", flowNo);
boq.executeUpdate();
tx.commit();
return "流程取消成功!";
}
} catch (Exception e) {
ARE.getLog().error(e);
tx.rollback();
return "流程取消失败,请联系管理员:" + e;
}
}
}