Changeset 25280 for trunk/admin/themes


Ignore:
Timestamp:
Nov 1, 2013, 11:28:36 AM (11 years ago)
Author:
mistic100
Message:

initialization issue in add_album.inc.tpl if there is no albums

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/themes/default/template/include/add_album.inc.tpl

    r23952 r25280  
    11{footer_script}{literal}
    22jQuery(document).ready(function(){
     3  var $albumSelect = jQuery("#albumSelect");
     4 
    35  jQuery(".addAlbumOpen").colorbox({
    46    inline: true,
     
    810     
    911      jQuery("#category_parent").html('<option value="0">------------</option>')
    10         .append(jQuery("#albumSelect").html())
    11         .val(jQuery("#albumSelect").val());
     12        .append($albumSelect.html())
     13        .val($albumSelect.val() || 0);
    1214    }
    1315  });
     
    4850              .text(newAlbum_name);
    4951             
    50           jQuery("#albumSelect").find("option").removeAttr('selected');
     52          $albumSelect.find("option").removeAttr('selected');
    5153         
    5254          if (parent_id==0) {
    53             jQuery("#albumSelect").prepend(new_option);
     55            $albumSelect.prepend(new_option);
    5456          }
    5557          else {
    56             jQuery("#albumSelect").find("option[value="+ parent_id +"]").after(new_option);
     58            $albumSelect.find("option[value="+ parent_id +"]").after(new_option);
    5759          }
    5860
Note: See TracChangeset for help on using the changeset viewer.