* fix UI for modal trigger and ajax replace.

This commit is contained in:
Catouse
2016-03-11 13:04:02 +08:00
parent cd760834af
commit 7e626c0b6b
10 changed files with 19 additions and 34 deletions
+2 -6
View File
@@ -942,8 +942,7 @@ class bug extends control
$bugs = $this->bug->getLinkedBugs($linkedBugs);
/* Build linkBug list.*/
$output = "<ul class='list-unstyled'>";
$output .= html::a(inlink('linkBugs', "bugID=$bugID&bugs=$bug->linkBug", '', true), $this->lang->bug->linkBugs, '', "class='iframe' data-width='85%'");
$output = '';
foreach($bugs as $bugId => $title)
{
$output .= '<li>';
@@ -951,7 +950,6 @@ class bug extends control
$output .= html::a("javascript:deleteLinkedBug($bugID, $bugId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
$output .= '</ul>';
die($output);
}
@@ -971,13 +969,11 @@ class bug extends control
$bugs = $this->bug->deleteLinkedBug($bugID, $deleteBug);
/* Build linkBug list. */
$output = "<ul class='list-unstyled'>";
$output .= html::a(inlink('linkBugs', "bugID=$bugID&bugs=$bug->linkBug", '', true), $this->lang->bug->linkBugs, '', "class='iframe' data-width='85%'");
$output = '';
foreach($bugs as $bugId => $title)
{
$output .= '<li>' . html::a(inlink('view', "bugID=$bugId"), "#$bugId " . $title) . html::a("javascript:deleteLinkedBug($bugID, $bugId)", '<i class="icon-remove"></i>', '', "style='float:right'");
}
$output .= '</ul>';
die($output);
}
+1 -1
View File
@@ -2,4 +2,4 @@
.col-side .chosen-container {width: 218px!important}
.col-side .chosen-container[id^="openedBuild"] {width: 172px!important}
.col-side .chosen-container[id^="resolvedBuild"] {width: 172px!important}
#linkBugBox > .list-unstyled > li {margin-left:-56px}
#linkBugBox > li {margin-left:-56px}
+2 -2
View File
@@ -232,9 +232,9 @@ js::set('oldResolvedBuild' , $bug->resolvedBuild);
<table class='table table-form'>
<tr class='text-top'>
<th class='w-80px'><?php echo $lang->bug->linkBug;?></th>
<td id='linkBugBox'>
<ul class='list-unstyled'>
<td>
<?php echo html::a($this->createLink('bug', 'linkBugs', "bugID=$bug->id&bugs=$bug->linkBug", '', true), $lang->bug->linkBugs, '', "data-toggle='modal' data-type='iframe' data-width='85%'");?>
<ul class='list-unstyled' id='linkBugBox'>
<?php
if(isset($bug->linkBugTitles))
{
-4
View File
@@ -30,10 +30,6 @@ class searchModel extends model
$searchParams['style'] = zget($searchConfig, 'style', 'full');
$searchParams['queryID'] = isset($searchConfig['queryID']) ? $searchConfig['queryID'] : 0;
/* remove onlybody for url*/
$onlybodyParam = $this->config->requestType == 'GET' ? '&onlybody=yes' : '?onlybody=yes';
$searchParams['actionURL'] = str_replace($onlybodyParam, '', $searchParams['actionURL']);
$this->session->set('searchParams', $searchParams);
}
+3 -6
View File
@@ -946,6 +946,7 @@ class story extends control
$this->view->type = $type;
$this->view->allStories = $allStories;
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->actionURL = $this->config->product->search;
$this->display();
}
@@ -964,8 +965,7 @@ class story extends control
$stories = $this->story->getLinkedStories($linkedStories);
$story = $this->story->getById($storyID);
$output = "<ul class='list-unstyled'>";
$output .= html::a($this->createLink('story', 'linkStory', "storyID=$storyID&type=$type&stories={$story->$type}", '', true), $this->lang->story->linkStory, '', "class='iframe' data-width='85%'");
$output = '';
foreach($stories as $storyId => $storyTitle)
{
$output .= '<li>';
@@ -973,7 +973,6 @@ class story extends control
$output .= html::a("javascript:deleteLinkedStory($storyID, \"$type\", $storyId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
$output .= '</ul>';
die($output);
}
@@ -992,8 +991,7 @@ class story extends control
$stories = $this->story->deleteLinkedStory($storyID, $type, $deleteStory);
$story = $this->story->getById($storyID);
$output = "<ul class='list-unstyled'>";
$output .= html::a($this->createLink('story', 'linkStory', "storyID=$storyID&type=$type&stories={$story->$type}", '', true), $this->lang->story->linkStory, '', "class='iframe' data-width='85%'");
$output = "";
foreach($stories as $storyId => $storyTitle)
{
$output .= '<li>';
@@ -1001,7 +999,6 @@ class story extends control
$output .= html::a("javascript:deleteLinkedStory($storyID, \"$type\", $storyId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
$output .= '</ul>';
die($output);
}
+1 -1
View File
@@ -1,3 +1,3 @@
.col-side .chosen-container .chosen-drop {width: 216px!important}
.col-side .chosen-container {width: 218px!important}
#linkStoriesBox > .list-unstyled > li ,#childStoriesBox > .list-unstyled > li {margin-left:-56px}
#linkStoriesBox > li ,#childStoriesBox > li {margin-left:-56px}
+5 -5
View File
@@ -171,9 +171,9 @@
</tr>
<tr class='text-top'>
<th><?php echo $lang->story->linkStories;?></th>
<td id='linkStoriesBox'>
<ul class='list-unstyled'>
<td>
<?php echo html::a($this->createLink('story', 'linkStory', "storyID=$story->id&type=linkStories&stories=$story->linkStories", '', true), $lang->story->linkStory, '', "data-toggle='modal' data-type='iframe' data-width='85%'");?>
<ul class='list-unstyled' id='linkStoriesBox'>
<?php
$linkStories = explode(',', $story->linkStories);
foreach($linkStories as $linkStoryID)
@@ -192,9 +192,9 @@
</tr>
<tr class='text-top'>
<th><?php echo $lang->story->childStories;?></th>
<td id='childStoriesBox'>
<ul class='list-unstyled'>
<?php echo html::a($this->createLink('story', 'linkStory', "storyID=$story->id&type=childStories&stories=$story->childStories", '', true), $lang->story->linkStory, '', "class='iframe' data-width='85%'");?>
<td>
<?php echo html::a($this->createLink('story', 'linkStory', "storyID=$story->id&type=childStories&stories=$story->childStories", '', true), $lang->story->linkStory, '', "data-toggle='modal' data-type='iframe' data-width='85%'");?>
<ul class='list-unstyled' id='childStoriesBox'>
<?php
$childStories = explode(',', $story->childStories);
foreach($childStories as $childStoryID)
+2 -6
View File
@@ -683,8 +683,7 @@ class testcase extends control
$cases = $this->testcase->getLinkedCases($linkedCases);
/* Build linkCase list. */
$output = "<ul class='list-unstyled'>";
$output .= html::a($this->createLink('testcase', 'linkCases', "caseID=$caseID&cases=$case->linkCase", '', true), $this->lang->testcase->linkCases, '', "class='iframe' data-width='85%'");
$output = '';
foreach($cases as $caseId => $caseTitle)
{
$output .= '<li>';
@@ -692,7 +691,6 @@ class testcase extends control
$output .= html::a("javascript:deleteLinkedCase($caseID, $caseId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
$output .= '</ul>';
die($output);
}
@@ -712,8 +710,7 @@ class testcase extends control
$cases = $this->testcase->deleteLinkedCase($caseID, $deleteCase);
/* Build linkCase list. */
$output = "<ul class='list-unstyled'>";
$output .= html::a($this->createLink('testcase', 'linkCases', "caseID=$caseID&cases=$cases", '', true), $this->lang->testcase->linkCases, '', "class='iframe' data-width='85%'");
$output = '';
foreach($cases as $caseId => $caseTitle)
{
$output .= '<li>';
@@ -721,7 +718,6 @@ class testcase extends control
$output .= html::a("javascript:deleteLinkedCase($caseID, $caseId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
$output .= '</ul>';
die($output);
}
+1 -1
View File
@@ -2,4 +2,4 @@
.col-side .chosen-container {width: 218px!important}
.table-form > tbody > tr > td .btn.addbutton {display:block; margin:1px 0px; width:40px; padding:1px 6px;}
.table-form > tbody > tr > td .btn.delbutton {display:block; margin:1px 0px; width:40px; padding:1px 6px;}
#linkCaseBox > .list-unstyled > li {margin-left:-56px}
#linkCaseBox li {margin-left:-56px}
+2 -2
View File
@@ -142,9 +142,9 @@
</tr>
<tr class='text-top'>
<th><?php echo $lang->testcase->linkCase;?></th>
<td id='linkCaseBox'>
<ul class='list-unstyled'>
<td>
<?php echo html::a($this->createLink('testcase', 'linkCases', "caseID=$case->id&case=$case->linkCase", '', true), $lang->testcase->linkCases, '', "data-type='iframe' data-toggle='modal' data-width='85%'");?>
<ul class='list-unstyled' id='linkCaseBox'>
<?php
if(isset($case->linkCaseTitles))
{