From 957f01c7ed321b80fe6570c0e261965d0caa12f9 Mon Sep 17 00:00:00 2001 From: wangyidong Date: Wed, 3 Jul 2013 07:54:05 +0000 Subject: [PATCH] * Do not use colorbox when pager is in colorbox. --- module/bug/js/view.js | 2 +- module/company/js/view.js | 2 +- module/story/js/view.js | 2 +- module/task/js/view.js | 5 ++++- module/testcase/js/view.js | 4 ++-- 5 files changed, 9 insertions(+), 6 deletions(-) diff --git a/module/bug/js/view.js b/module/bug/js/view.js index 7d4ef4a971..3b686103d6 100644 --- a/module/bug/js/view.js +++ b/module/bug/js/view.js @@ -1,4 +1,4 @@ function setModal4List(colorboxClass, replaceID) { - $('.iframe').colorbox({width:900, height:500, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}}) + if(onlybody != 'yes') $('.iframe').colorbox({width:900, height:500, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}}) } diff --git a/module/company/js/view.js b/module/company/js/view.js index 1f4a745592..3bba3a1eb3 100644 --- a/module/company/js/view.js +++ b/module/company/js/view.js @@ -1,4 +1,4 @@ $(function() { - $('#editCompany').colorbox({width:750, height:500, iframe:true, transition:'none'}); + if(onlybody != 'yes') $('#editCompany').colorbox({width:750, height:500, iframe:true, transition:'none'}); }); diff --git a/module/story/js/view.js b/module/story/js/view.js index c9d99a16e9..cf8981a470 100644 --- a/module/story/js/view.js +++ b/module/story/js/view.js @@ -1,4 +1,4 @@ $(function() { - $(function(){$('.iframe').colorbox({width:900, height:500, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}});}) + if(onlybody != 'yes') $(function(){$('.iframe').colorbox({width:900, height:500, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}});}) }); diff --git a/module/task/js/view.js b/module/task/js/view.js index af9dd81a9b..17ced38b26 100644 --- a/module/task/js/view.js +++ b/module/task/js/view.js @@ -4,4 +4,7 @@ function assign(taskID, assignedTo) $('.assign').height(40); $('.assign').load(createLink('user', 'ajaxGetUser', 'taskID=' + taskID + '&assignedTo=' + assignedTo)); } -$(function(){$('.iframe').colorbox({width:900, height:500, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}});}) +$(function() +{ + if(onlybody != 'yes') $('.iframe').colorbox({width:900, height:500, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}}); +}) diff --git a/module/testcase/js/view.js b/module/testcase/js/view.js index f0f3d95f6c..5f20f003e0 100755 --- a/module/testcase/js/view.js +++ b/module/testcase/js/view.js @@ -1,5 +1,5 @@ $(document).ready(function() { - $(".runCase").colorbox({width:900, height:550, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}}); - $(".results").colorbox({width:900, height:550, iframe:true, transition:'none'}); + if(onlybody != 'yes')$(".runCase").colorbox({width:900, height:550, iframe:true, transition:'none', onCleanup:function(){parent.location.href=parent.location.href;}}); + if(onlybody != 'yes')$(".results").colorbox({width:900, height:550, iframe:true, transition:'none'}); })