泛微8.0建模开发行自定义按钮

阅读: 评论:0

泛微8.0建模开发⾏⾃定义按钮-⼀、效果图:
点击页⾯修改成功后,会刷新当前页⾯。
⼀、配置按钮功能点
⼆、前端代码实现
/**
* 根据台账id,更新台账已确认数据状态
* date:2021-08-20
* auther:null
* @param 台账id
*/
function updateFlightDataStatus(id){
var modeid = id;// 台账id
if(confirm("是否确认数据?")){
var returnStatus ="";
jQuery.ajax({正定隆兴寺简介
type:"get",
data:{"option":"updateCtrip_flight","modeid":modeid,"status":"0"},
url:"/interface/js/Ctrip_AjaxData.jsp?t="+new Date().getTime(),
async:false,赶集网房子租房子
contentType:"application/json",
success:function(data){
var retss =eval('('+ data +')');
if(retss.updateModeStauts !=''){
returnStatus = retss.updateModeStauts;
}
},error:function(msg){
}
});
if(returnStatus =="0"){
load();// 刷新当前页⾯.
}else if(returnStatus =="1"){
}
}
}
三、后端可以通过jsp去实现后台数据修改
<%@page import="net.sf.json.JSONArray"%>
<%@page import="java.util.*"%>
<%@page import="weaver.interfaces.swfa.AmountUtil"%>
<%@page import="java.math.BigDecimal"%>
<%@page import="java.util.List"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"%>
<%@ page import="al.*,weaver.hrm.*,SimpleDateFormat,java.util.Date"%>
<%@ page import="weaver.quest.RequestInfo"%>
<%@ page import="RecordSet,java.io.*,RecordSetDataSource,pany.DepartmentComInfo,al.F naSplitPageTransmethod"%>
<%@ page import="weaver.interfaces.swfa.HttpRestful"%>
<%@ page import="com.handler.form.FSelect"%>
<%
<%
String option = Util.Parameter("option"));
RecordSet rs =new RecordSet();
RecordSet rs0 =new RecordSet();
RecordSet rs1 =new RecordSet();
RecordSet rs2 =new RecordSet();
RecordSet rs3 =new RecordSet();
RecordSet rsd =new RecordSet();
RecordSet rst =new RecordSet();
RecordSetDataSource ncrs =new RecordSetDataSource("nc63");
String returnstr ="";
String dd ="";
int coutt =0;
String str ="";
//查询是否携程请款专员
if("queryQKZY".equals(option)){
String userid = Util.Parameter("userid"));// ⽤户id
String ysnf = Util.Parameter("ysnf"));// 年份
String qkyf = Util.Parameter("qkyf"));// 请款⽉份
String queryZY ="select resourceid  from hrmroles h1,hrmrolemembers  h2 where h1.id = h2.roleid  lesmark like '%携程请款专员%'  and h2. resourceid = '"+userid+"'  ";
String sczyid ="";那拉提草原介绍
()){
sczyid = Util.String("resourceid"));// 携程请款专员
}
returnstr ="{'sczyid':'"+ sczyid +"'}";
}
//查询是否材料供应公司
if("queryCLGYGS".equals(option)){
String qkgsid = Util.Parameter("gsid"));// 请款公司
String queryCLGYGS ="select * from (select * from hrmsubcompany  where  id = '692' or supsubcomid = '692'  and  canceled = '0' ) where id in ("+q kgsid+") ";
String gsid ="";
()){
gsid = Util.String("id"));// 公司id
}
returnstr ="{'gsid':'"+ gsid +"'}";
}
// 根据条件查询携程酒店结算明细和携程机票明细
if("queryCtripData".equals(option)){
String userid = Util.Parameter("userid"));// ⽤户id
String ysnf = Util.Parameter("qknf"));// 年份
String qkyf = Util.Parameter("qkyf"));// 请款⽉份
广东第一峰温泉度假村
String qkgs = Util.Parameter("qkgs"));// 请款公司
String qkgs = Util.Parameter("qkgs"));// 请款公司
String queryCtrip ="select 1 Ctrip_Type,t1.*,t2.*,t3.cost_center4,nvl((t3.POST_SERVICE_FEE+t3.amount),0) flightAmount ,t3.ids  ids \n"+ "from \n"+
"(select  h1.id gsid,h1.subcompanyname ,h2.id bmid,h2.departmentname  ,h2.departmentcode \n"+
"from hrmsubcompany h1,hrmdepartment h2 \n"+
"where h1.id = h2.subcompanyid1  and h1.id in  ("+qkgs+")  ) t1 \n"+
"left join \n"+
"(select  sum(AMOUNT) AMOUNT,sum(POST_SERVICE_FEE) POST_SERVICE_FEE,Cost_Center4 \n"+
"from uf_ods_ctrip_flight u1 \n"+
"where  u1.Cost_Center4  is not null  and u1.DAY_ID like '%"+ysnf+"-"+qkyf+"%'  group by cost_center4) t2 \n"+
"on t1.departmentcode =  t2.Cost_Center4 \n"+
"left join \n"+
"(\n"+
"select \n"+
" distinct cost_center4,listagg (id, ',') WITHIN GROUP (ORDER BY id)  ids \n"+
",sum(POST_SERVICE_FEE) POST_SERVICE_FEE,sum(amount) amount  \n"+
" from  uf_ods_ctrip_flight \n"+
" where    day_id like      '%"+ysnf+"-"+qkyf+"%' and Cost_Center4 in ( select h2.departmentcode from hrmsubcompany h1,hrmdepartment h2 w here h1.id = h2.subcompanyid1  and h1.id in ("+qkgs+")  )\n"+
" group by cost_center4 \n"+
") t3  \n"+
"on t1.departmentcode = t3.cost_center4  \n"+
深圳周边团建两天一夜
"where t3.amount > 0 \n"+
"\n"+
"union all \n"+
"\n"+
"select 0 Ctrip_Type,t1.*,t2.*,t4.cost_center4,nvl(t4.amount,0) hotelAmount,t4.ids ids \n"+
"from \n"+
"(select  h1.id gsid,h1.subcompanyname ,h2.id bmid,h2.departmentname  ,h2.departmentcode \n"+
"from hrmsubcompany h1,hrmdepartment h2 \n"+
首旅如家
"where h1.id = h2.subcompanyid1  and h1.id in  ("+qkgs+")  ) t1 \n"+
"left join \n"+
"(select  sum(AMOUNT) AMOUNT,sum(POST_SERVICE_FEE) POST_SERVICE_FEE,Cost_Center4 \n"+
"from uf_ods_ctrip_flight u1 \n"+
"where  u1.Cost_Center4  is not null  and u1.DAY_ID like '%"+ysnf+"-"+qkyf+"%'  group by cost_center4) t2 \n"+
"on t1.departmentcode =  t2.Cost_Center4 \n"+
"left join \n"+
"(\n"+
"select distinct Cost_Center4,listagg (id, ',') WITHIN GROUP (ORDER BY id)  ids ,sum(amount) amount\n"+
" from uf_ods_ctrip_hotel \n"+
"  where    day_id like      '%"+ysnf+"-"+qkyf+"%' and Cost_Center4 in ( select h2.departmentcode from hrmsubcompany h1,hrmdepartment h2 w here h1.id = h2.subcompanyid1  and h1.id in ("+qkgs+")  )\n"+
"  group by cost_center4  \n"+
")t4 \n"+
"on t1.departmentcode = t4.cost_center4 \n"+
"where  t4.amount > 0";
// XCLX字段携程台账类型 0:携程酒店台账  1:携程飞机票台账
List<Map<String, String>> datalist =new ArrayList<Map<String, String>>();
//rs1.writeLog("queryCtrip="+queryCtrip);
()){
Map<String, String> datamap =new HashMap<String, String>();
String Ctrip_Type = Util.String("Ctrip_Type"));// 携程类型
String ids = Util.String("ids"));// 携程台账id串
String GSID = Util.String("GSID"));// 公司ID
String SUBCOMPANYNAME = Util.String("SUBCOMPANYNAME"));// 公司名称
String BMID = Util.String("BMID"));// 部门ID
String DEPARTMENTNAME = Util.String("DEPARTMENTNAME"));// 部门名称
String FLIGHTAMOUNT = Util.String("FLIGHTAMOUNT"));// 机票合计⾦额
String HOTELAMOUNT = Util.String("HOTELAMOUNT"));// 酒店合计⾦额

本文发布于:2023-05-28 05:35:28,感谢您对本站的认可!

本文链接:http://www.035400.com/whly/4/145752.html

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。

标签:携程   数据   按钮   台账   查询   后台   修改
留言与评论(共有 0 条评论)
   
验证码:
推荐文章
排行榜
Copyright ©2024-2030 Comsenz Inc.Powered by © 文化旅游网 滇ICP备2022007236号-403 联系QQ:1103060800网站地图