Changeset 7972


Ignore:
Timestamp:
Dec 2, 2010, 3:25:28 PM (10 years ago)
Author:
LucMorizur
Message:

Bullets implementation

Location:
extensions/event_cats/admin/template
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/event_cats/admin/template/autolog_new.js

    r7942 r7972  
    8181}
    8282
     83function ec_mark_reduced_fieldsets() { /*
     84  if (de('ec_sel_code_new').checked == 'checked') {
     85  }
     86  else {
     87  } */
     88}
     89
    8390function ec_mark_entry(ec_id) {
    8491  var i = 0;
     
    139146  }
    140147  ec_chk_nover_cat = true;
     148  ec_mark_reduced_fieldsets();
    141149}
    142150
    143151function ec_mark_code(ec_id) {
     152  var t3 = d.ec_new_code.ec_in_up_code_list_id;
     153  var t2 = '';
    144154  if (ec_id == '-1') {
    145155    de('ec_sel_code_old').checked = 'checked';
     
    164174           (ec_selected_old_group) ? 'checked' : '';
    165175          de('ec_act2_id').value                    = '-1';
     176          t2 = ' <em>(' + de('ec_in_up_comment_id').value + ')</em>';
     177          t2 = (t2 == ' ()') ? '' : t2
     178          de('first_fieldset_value_id').innerHTML = ec_new_code_text + t2;
    166179        break;
    167180        case 'ec_sel_code_old':
     
    178191          ec_selected_old_user               =
    179192           ec_lists['user_id'][ec_selected_old_code];
     193          t2 =
     194            ' <em>(' +
     195            ec_lists['comment'][t3.options[t3.selectedIndex].value] +
     196            ')</em>'
     197          ;
     198          t2 = (t2 == ' ()') ? '' : t2
     199          de('first_fieldset_value_id').innerHTML =
     200            ec_lists['code'][t3.options[t3.selectedIndex].value] + t2;
    180201          ec_flag1 = true;
    181202          ec_mark_user('ec_sel_user_old');
     
    194215    }
    195216  }
    196   de('first_fieldset_value_id').innerHTML = de('ec_in_up_code_id').value;
    197   if (de('ec_in_up_comment_id').value == '')
    198    de('first_fieldset_comment_id').innerHTML = '';
    199   else
    200    de('first_fieldset_comment_id').innerHTML =
    201     ' (' + de('ec_in_up_comment_id').value + ')';
     217  ec_mark_reduced_fieldsets();
    202218}
    203219
     
    215231      de('ec_in_up_usr_list_id').selectedIndex = '-1';
    216232      d.ec_new_code.ec_in_up_entry_list.focus();
     233      ec_mark_reduced_fieldsets();
    217234      return false;
    218235    }
     
    266283    }
    267284  }
     285  ec_mark_reduced_fieldsets();
    268286  return true;
    269287}
     
    284302      de('ec_in_up_imgs_id').value = '';
    285303      d.ec_new_code.ec_in_up_entry_list.focus();
     304      ec_mark_reduced_fieldsets();
    286305      return false;
    287306    }
     
    359378    }
    360379  }
     380  ec_mark_reduced_fieldsets();
    361381  return true;
    362382}
     
    373393
    374394function ec_rnd(ec_min, ec_max) {
    375   return Math.floor(ec_min + (ec_max - ec_min + 1) * Math.random() );
     395  return Math.floor(ec_min + (ec_max - ec_min + 1) * Math.random());
    376396}
    377397
     
    10041024    );
    10051025    ec_check_validity_on();
    1006     jQuery('#reduced_first_fieldset_bullet_id').click(function(){
     1026    jQuery('#reduced_first_fieldset_legend_id').click(function(){
    10071027      ec_toggle_fieldset(
    10081028        '#reduced_first_fieldset_id', '#maximized_first_fieldset_id'
    10091029      );
    10101030    });
    1011     jQuery('#maximized_first_fieldset_bullet_id').click(function(){
     1031    jQuery('#maximized_first_fieldset_legend_id').click(function(){
    10121032      ec_toggle_fieldset(
    10131033        '#reduced_first_fieldset_id', '#maximized_first_fieldset_id'
     
    10341054      'padding-left'   : jQuery('fieldset').css('padding-left'),
    10351055      'padding-right'  : jQuery('fieldset').css('padding-right'),
    1036       'padding-top'    : jQuery('fieldset').css('padding-top'),
    1037       'padding-bottom' : jQuery('fieldset').css('padding-bottom'),
    10381056      'margin-left'    : jQuery('fieldset').css('margin-left'),
    10391057      'margin-right'   : jQuery('fieldset').css('margin-right'),
     
    10441062      'padding-left', jQuery('legend').css('padding-left')
    10451063    );
    1046     jQuery('.reduced_fieldsets_legend').css(
    1047       'padding-left', jQuery('fieldset').css('border-left-width')
    1048     );
     1064    jQuery('.reduced_fieldsets_legend').css({
     1065      'padding-left'   : jQuery('fieldset').css('border-left-width'),
     1066      'padding-top'    : jQuery('fieldset').css('border-top-width'),
     1067      'letter-spacing' : jQuery('legend').css('letter-spacing'),
     1068    });
    10491069  });
    10501070  return false;
  • extensions/event_cats/admin/template/autolog_new.tpl

    r7942 r7972  
    66{include file = 'include/datepicker.inc.tpl'}
    77
    8 {* <!-- Remove a strange unwanted line at the bottom of the screen --> *}
     8{* <!-- Specific CSS --> *}
    99{html_head} {literal}
    1010  <link rel = "stylesheet" type = "text/css" href = "{$RACINE_URL}themes/default/js/ui/theme/ui.datepicker.css">
    11   <style type = "text/css"> #ui-datepicker-div { display:none; } </style>
     11  <style type = "text/css">
     12    #ui-datepicker-div {
     13      display:none;
     14    }
     15    .reduced_fieldsets {
     16      margin:0;
     17      padding:0;
     18    }
     19    .fieldsets_legend {
     20      cursor:pointer;
     21    }
     22  </style>
    1223{/literal} {/html_head}
    1324
     
    7485  {* <!-- [ [ [New] / [existing] code] / [Existing entry] ] selection --> *}
    7586  <div id = "reduced_first_fieldset_id" class = "reduced_fieldsets" style = "display:none;">
    76     <img id = "reduced_first_fieldset_bullet_id" class = "plus_bullets" alt = "" title = "" src = "{$EVNTCATS_URLS.ROOT}icon/plus.png">
    77     <span style = "font-weight:bold;" id = "first_fieldset_legend_id1" class = "reduced_fieldsets_legend"
    78      >{if $ec_is_creation}{'Code'|@translate}{else}{'Selected entry'|@translate}{/if}</span>&nbsp;:
     87    <span style = "font-weight:bold;" class = "reduced_fieldsets_legend fieldsets_legend" id = "reduced_first_fieldset_legend_id"
     88     ><img class = "plus_bullets" alt = "" title = "" src = "{$EVNTCATS_URLS.ROOT}icon/plus.png"
     89     >&nbsp;<span id = "first_fieldset_legend_id1"
     90     >{if $ec_is_creation}{'Code'|@translate}{else}{'Selected entry'|@translate}{/if}</span>&nbsp;: </span>
    7991    <span id = "first_fieldset_value_id"></span>
    80     <span id = "first_fieldset_comment_id"></span>
    8192  </div>
    8293  <fieldset id = "maximized_first_fieldset_id">
    83     <legend style = "font-weight:bold;">
    84       <img id = "maximized_first_fieldset_bullet_id" class = "minus_bullets" alt = "" title = "" src = "{$EVNTCATS_URLS.ROOT}icon/minus.png">
     94    <legend style = "font-weight:bold;" class = "fieldsets_legend" id = "maximized_first_fieldset_legend_id">
     95      <img class = "minus_bullets" alt = "" title = "" src = "{$EVNTCATS_URLS.ROOT}icon/minus.png">
    8596      <script type = "text/javascript">d.write(de('first_fieldset_legend_id1').innerHTML);</script>
    8697    </legend>
Note: See TracChangeset for help on using the changeset viewer.