app-xiangsonghua/app-saas-src/script/feature/logQuery/operateTicketDetail.js

46 lines
1.0 KiB
JavaScript
Raw Normal View History

2024-12-26 17:00:06 +08:00
apiready = function(){
var ctrl = {
init : {}, //初始化
bind : {}, //事件绑定
toast : {}, //弹出提示框
};
ctrl.init = function() {
// 适配安卓状态栏
CommonModel.fitInStatusBar();
ctrl.bind();
}
ctrl.bind = function(){
//点击返回按钮
$api.addEvt($api.dom("#back"), "touchend", function() {
api.closeWin();
})
//打开frame
var id = api.pageParam.id;
//计算frame显示的位置和尺寸
var windowWidth = parseInt($api.cssVal($api.dom("body"), "width"));
var windowHeight = parseInt($api.cssVal($api.dom("body"), "height"));
var headerHeight = parseInt($api.cssVal($api.dom("#header"), "height"));
var frameX = 0;
var frameY = headerHeight;
var frameWidth = windowWidth;
var frameHeight = windowHeight - headerHeight;
api.openFrame({
name: 'operateTicketDetailFrame',
url: './operateTicketDetailFrame.html',
rect: {
x: frameX,
y: frameY,
w: frameWidth,
h: frameHeight
},
scaleEnabled:true,
pageParam: {
id: id
}
});
}
ctrl.init();
}