javascript Pop画面


// 主页面
// 窗口打开个数
var open_flg = 0;
// 窗口状态
var resultValue = null;
// 出发地区选择
function popupHaisoum() {

// 高度
var height = 600;
// 宽度
var width = 1025;
// 地址
var url = "TrnAcceptanceGoodsDetailPop!retrieve.action?selectKbn=Haisoum";
// 标题
var title = "";
// 没有打开窗口的情况下打开窗口
if(open_flg ==0){
resultValue = window.open(url,title , 'height=' + height + ', width=' + width
+ ', top=' + ((window.screen.height - height) / 2 - 15)
+ ', left=' + ((window.screen.width - width) / 2 - 5)
+ ', location=no, toolbar=no, menubar=no, resizable=yes,location=no, status=no');

}else{

// 已打开窗口关闭
resultValue.close();
// 重新打开窗口
resultValue = window.open(url,title , 'height=' + height + ', width=' + width
+ ', top=' + ((window.screen.height - height) / 2 - 15)
+ ', left=' + ((window.screen.width - width) / 2 - 5)
+ ', location=no, toolbar=no, menubar=no, resizable=yes,location=no, status=no');
}
// 窗口个数自增
open_flg++;
}
// 出发地区选择回调函数
function setHaisoum(syozaiCode,syozaiName,zipCode,ninushiAdr,ninushiTel){

// 出发地编码
$("mapAcceptanceGoods.haisoumCode").value = syozaiCode;
// 出发地名称
$("mapAcceptanceGoods.haisoumName").value = syozaiName;
// 出发地邮政编码
$("mapAcceptanceGoods.haisoumZipCode").value = zipCode;
// 出发地地址
$("mapAcceptanceGoods.haisoumTel").value = ninushiTel;
// 出发地电话
$("mapAcceptanceGoods.haisoumAdr").value = ninushiAdr;

}
// 到达地区选择
function popupHaisous() {

// 高度
var height = 600;
// 宽度
var width = 1025;
// 地址
var url = "TrnAcceptanceGoodsDetailPop!retrieve.action?selectKbn=Haisous";
// 标题
var title = "";
// 没有打开窗口的情况下打开窗口
if(open_flg ==0){
resultValue = window.open(url,title , 'height=' + height + ', width=' + width
+ ', top=' + ((window.screen.height - height) / 2 - 15)
+ ', left=' + ((window.screen.width - width) / 2 - 5)
+ ', location=no, toolbar=no, menubar=no, resizable=yes,location=no, status=no');
}else{
// 已打开窗口关闭
resultValue.close();
// 重新打开窗口
resultValue = window.open(url,title , 'height=' + height + ', width=' + width
+ ', top=' + ((window.screen.height - height) / 2 - 15)
+ ', left=' + ((window.screen.width - width) / 2 - 5)
+ ', location=no, toolbar=no, menubar=no, resizable=yes,location=no, status=no');
}
// 窗口个数自增
open_flg++;
}



// pop页面

var js_select_syozaiCode = "";
var js_select_syozaiName = "";
var js_select_zipCode = "";
var js_select_ninushiAdr = "";
var js_select_ninushiTel = "";
function doSelect(syozaiCode,syozaiName,zipCode,ninushiAdr,ninushiTel){

js_select_syozaiCode = syozaiCode;
js_select_syozaiName = syozaiName;
js_select_zipCode = zipCode;
js_select_ninushiAdr = ninushiAdr;
js_select_ninushiTel = ninushiTel;

var selectKbn = $("selectKbn").value;

try{
if(selectKbn == "Haisoum"){
window.opener.setHaisoum(js_select_syozaiCode,js_select_syozaiName,
js_select_zipCode,js_select_ninushiAdr,js_select_ninushiTel);
}else if( selectKbn == "Haisous"){
window.opener.setHaisous(js_select_syozaiCode,js_select_syozaiName,
js_select_zipCode,js_select_ninushiAdr,js_select_ninushiTel);
}
}catch(e){alert(e);}

window.close();
return true;

}

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值