removing choice for show instance if in shows tab.

This commit is contained in:
Naomi Aro 2013-08-29 18:52:40 -04:00
parent 0f0958ee6b
commit 5a8957273f
2 changed files with 27 additions and 8 deletions

View file

@ -31,12 +31,14 @@
</dd>
<?php endforeach;?>
<dt>
<dd id="his_choose_instance">
<div>
<label for="<?php echo $name;?>"><?php echo _("Choose Show Instance") ?></label>
</dt>
<dd>
</div>
<div>
<select id="his_instance_select"><option value="0"><?php echo "----------" ?><option></select>
<button class="btn" type="button" id="his_instance_retrieve"><?php echo _("Find") ?></button>
</div>
</dd>
<?php foreach ($form->getSubForm('his_item_template') as $index=>$el): ?>

View file

@ -57,7 +57,8 @@ var AIRTIME = (function(AIRTIME) {
oTableAgg,
oTableItem,
oTableShow;
oTableShow,
inShowsTab = false;
function getSelectedLogItems() {
var items = Object.keys(selectedLogItems);
@ -424,6 +425,9 @@ var AIRTIME = (function(AIRTIME) {
},
navigate: function() {
delete fnServerData.instance;
},
always: function() {
inShowsTab = false;
}
},
{
@ -433,14 +437,21 @@ var AIRTIME = (function(AIRTIME) {
},
navigate: function() {
delete fnServerData.instance;
},
always: function() {
inShowsTab = false;
}
},
{
initialized: false,
initialize: function() {
showSummaryList();
},
navigate: function() {
},
always: function() {
inShowsTab = true;
showSummaryList();
}
}
@ -478,6 +489,10 @@ var AIRTIME = (function(AIRTIME) {
function makeHistoryDialog(html) {
$hisDialogEl = $(html);
if (inShowsTab) {
$hisDialogEl.find("#his_choose_instance").remove();
}
$hisDialogEl.dialog({
title: $.i18n._("Edit History Record"),
modal: false,
@ -649,6 +664,8 @@ var AIRTIME = (function(AIRTIME) {
else {
tab.navigate();
}
tab.always();
}
});