Changeset 4064


Ignore:
Timestamp:
Oct 19, 2009, 11:27:29 PM (11 years ago)
Author:
LucMorizur
Message:

[Event Cats] Continue add entry modification ability

Location:
extensions/event_cats
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • extensions/event_cats/admin/evntcats_admin.php

    r4058 r4064  
    115115               l10n('ec_tab_autoid_entries'),
    116116               $my_base_url.'&tab=autolog_entries');
    117 $tabsheet->add('autolog_new',
    118                l10n('ec_tab_autoid_new'),
     117$tabsheet->add('autolog_new', l10n(($ec_exist_entries) ?
     118                'ec_tab_autoid_new2' : 'ec_tab_autoid_new1'),
    119119               $my_base_url.'&tab=autolog_new');
    120120$tabsheet->add('duplication',
  • extensions/event_cats/admin/template/autolog_new.js

    r4058 r4064  
    1212var ec_flag2                    = false;
    1313var ec_dont_check               = false;
     14var ec_is_creation              = false;
    1415var ec_err                      = '';
    1516var ec_selected_action          = '';
     
    2627var ec_selected_old_entry       = '-1';
    2728var ec_selected_old_code        = '-1';
     29var ec_selected_old_code2       = '-1';
    2830var ec_selected_old_user        = '-1';
     31var ec_selected_old_user2       = '-1';
    2932var ec_selected_AP              = '-1';
    3033var ec_selected_cat             = '-1';
     
    4649  var t = new Array();
    4750  var r = /,/g;
    48   document.getElementById('ec_act2_id').value = ec_id;
    49   t = document.getElementById('ec_in_up_entry_list_id').options[
    50    document.getElementById('ec_in_up_entry_list_id').selectedIndex
    51   ].label.split(r);
     51  if (ec_id == '-1') ec_init(); else {
     52    document.getElementById('ec_act2_id').value = ec_id;
     53    t = document.getElementById('ec_in_up_entry_list_id').options[
     54     document.getElementById('ec_in_up_entry_list_id').selectedIndex
     55    ].label.split(r);
    5256// t[0] : user_id ; t[1] : action ; t[2] : arg1 ; t[3] : arg2 ; t[4] : forced
    53   if (ec_check_exist_value('ec_in_up_usr_list_id', t[0])) {
    54     ec_selected_user = 'ec_sel_user_old';
    55     ec_selected_old_user = t[0];
    56     if (t[2] != '' && t[1].lastIndexOf('ec_ok') != -1) i++;
    57     if (t[3] != '') { i++; i++; }
    58     switch (i) {
    59       case 0: // Home
    60         ec_selected_action = 'ec_input_action_home';
    61       break;
    62       case 1: // Category
    63         ec_selected_action = 'ec_input_action_cat';
    64         ec_selected_cat = t[2];
    65       break;
    66       case 2: // Additionnal Page
    67         ec_selected_action = 'ec_input_action_add_p';
     57    if (ec_check_exist_value('ec_in_up_usr_list_id', t[0])) {
     58      ec_selected_user = 'ec_sel_user_old';
     59      ec_selected_old_user = t[0];
     60      if (t[2] != '' && t[1].lastIndexOf('ec_ok') != -1) i++;
     61      if (t[3] != '') { i++; i++; }
     62      switch (i) {
     63        case 0: // Home
     64          ec_selected_action = 'ec_input_action_home';
     65        break;
     66        case 1: // Category
     67          ec_selected_action = 'ec_input_action_cat';
     68          ec_selected_cat = (ec_check_exist_value('ec_in_up_cats_id', t[2])) ?
     69           t[2] : '-1';
     70        break;
     71        case 2: // Additionnal Page
     72          ec_selected_action = 'ec_input_action_add_p';
     73          ec_selected_cat = (ec_check_exist_value('ec_in_up_aps_id', t[3])) ?
     74           t[3] : '-1';
     75        break;
     76        case 3: // Image
     77          ec_selected_action = 'ec_input_action_img';
     78          ec_selected_cat = (ec_check_exist_value('ec_in_up_cats_id', t[2])) ?
     79           t[2] : '-1';
     80          ec_selected_img = t[3];
     81        break;
     82      }
     83      document.getElementById('ec_in_up_forced_id').checked =
     84       (t[4] == 'true') ? 'checked' : '';
     85      ec_mark_action(ec_selected_action);
     86    }
     87    else {
     88      ec_selected_user = 'ec_sel_user_none';
     89      document.getElementById('ec_in_up_forced_id').checked = '';
     90      if (ec_check_exist_value('ec_in_up_aps_id', t[3])) {
    6891        ec_selected_AP = t[3];
    69       break;
    70       case 3: // Image
    71         ec_selected_action = 'ec_input_action_img';
    72         ec_selected_cat = t[2];
    73         ec_selected_img = t[3];
    74       break;
    75     }
    76     document.getElementById('ec_in_up_forced_id').checked =
    77      (t[4] == 'true') ? 'checked' : '';
    78     ec_mark_action(ec_selected_action);
    79   }
    80   else {
    81     ec_selected_user = 'ec_sel_user_none';
    82     document.getElementById('ec_in_up_forced_id').checked = '';
    83     if (ec_check_exist_value('ec_in_up_aps_id', t[3])) {
    84       ec_selected_AP = t[3];
    85       ec_mark_action('ec_input_action_add_p');
    86     }
    87     else {
    88       ec_mark_action('ec_input_action_refused');
     92        ec_mark_action('ec_input_action_add_p');
     93      }
     94      else {
     95        ec_mark_action('ec_input_action_refused');
     96      }
    8997    }
    9098  }
     
    97105  ) {
    98106    var t1 = '';
    99     ec_selected_code = ec_id;
     107    if (ec_id == 'ec_sel_code_old' && ec_selected_old_code == '-1') {
     108      ec_selected_code = 'ec_sel_code_new';
     109      ec_selected_old_code = ec_selected_old_code2;
     110    }
     111    else ec_selected_code = ec_id;
    100112    document.getElementById(ec_selected_code).checked = 'checked';
    101113    switch (ec_selected_code) {
     
    131143
    132144function ec_mark_user(ec_id) {
    133   if (ec_flag1 ||
     145  if (
     146   !ec_is_creation &&
     147   document.getElementById('ec_in_up_entry_list_id').value == '-1'
     148  ) {
     149    alert(ec_JS_message['ec_act_entry_miss']);
     150    return false;
     151  }
     152  else if (ec_flag1 ||
    134153   !(document.getElementById('ec_sel_user_old').disabled == 'disabled' ||
    135154   document.getElementById('ec_sel_user_old').disabled == true)
    136155  ) {
    137     ec_selected_user = ec_id;
     156    if (ec_id == 'ec_sel_user_old' && ec_selected_old_user == '-1') {
     157      ec_selected_user =
     158       (ec_is_creation) ? 'ec_sel_user_new' : 'ec_sel_user_none';
     159      ec_selected_old_user = ec_selected_old_user2;
     160    }
     161    else ec_selected_user = ec_id;
    138162    document.getElementById(ec_selected_user).checked = 'checked';
    139163    switch (ec_selected_user) {
    140164      case 'ec_sel_user_none': // None
    141165        ec_selected_action =
    142          (ec_ap_ok && (ec_selected_action != 'ec_input_action_home')) ?
    143          'ec_input_action_add_p' : 'ec_input_action_home';
     166         (ec_ap_ok && (ec_selected_action != 'ec_input_action_refused')) ?
     167         'ec_input_action_add_p' : 'ec_input_action_refused';
    144168        document.getElementById('ec_in_up_usr_txt_id').value = '';
    145169        document.getElementById('ec_in_up_psd_txt_id').value = '';
     
    147171      break;
    148172      case 'ec_sel_user_new': // New user
     173        if (ec_selected_action == 'ec_input_action_refused')
     174         ec_selected_action = 'ec_input_action_home';
    149175        document.getElementById('ec_in_up_usr_txt_id').value =
    150176         ec_new_user_text;
     
    154180      break;
    155181      case 'ec_sel_user_old': // "Old" user
     182        if (ec_selected_action == 'ec_input_action_refused')
     183         ec_selected_action = 'ec_input_action_home';
    156184        document.getElementById('ec_in_up_usr_txt_id').value = '';
    157185        document.getElementById('ec_in_up_psd_txt_id').value = '';
     
    167195    }
    168196  }
     197  return true;
    169198}
    170199
    171200function ec_mark_action(ec_id) {
    172   ec_selected_action = ec_id;
    173   if (ec_selected_action != '') {
    174     document.getElementById(ec_selected_action).checked = 'checked';
    175     switch (ec_selected_action) {
    176       case 'ec_input_action_add_p': // Additional Page
    177         document.getElementById('ec_in_up_aps_id').value = ec_selected_AP;
    178         document.getElementById('ec_in_up_cats_id').value = '-1';
    179         document.getElementById('ec_in_up_imgs_id').value = '';
    180         document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
    181       break;
    182       case 'ec_input_action_cat': // Category
    183         document.getElementById('ec_in_up_aps_id').value = '-1';
    184         document.getElementById('ec_in_up_cats_id').value = ec_selected_cat;
    185         document.getElementById('ec_in_up_imgs_id').value = '';
    186         ec_selected_user = (ec_selected_user == 'ec_sel_user_none') ?
    187          'ec_sel_user_old' : ec_selected_user;
    188         document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
    189       break;
    190       case 'ec_input_action_img': // Image
    191         document.getElementById('ec_in_up_aps_id').value = '-1';
    192         document.getElementById('ec_in_up_cats_id').value = ec_selected_cat;
    193         document.getElementById('ec_in_up_imgs_id').value = ec_selected_img;
    194         ec_selected_user = (ec_selected_user == 'ec_sel_user_none') ?
    195          'ec_sel_user_old' : ec_selected_user;
    196         ec_check_img_text();
    197       break;
    198       case 'ec_input_action_home': // Home
    199         document.getElementById('ec_in_up_aps_id').value = '-1';
    200         document.getElementById('ec_in_up_cats_id').value = '-1';
    201         document.getElementById('ec_in_up_imgs_id').value = '';
    202         document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
    203       break;
    204       case 'ec_input_action_refused': // Access denied
    205         document.getElementById('ec_in_up_aps_id').value = '-1';
    206         document.getElementById('ec_in_up_cats_id').value = '-1';
    207         document.getElementById('ec_in_up_imgs_id').value = '';
    208         ec_selected_user = 'ec_sel_user_none';
    209         document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
    210       break;
    211     }
    212     if (ec_avoid_infinite_loop) {
    213       ec_avoid_infinite_loop = false;
    214       ec_mark_user(ec_selected_user);
    215       ec_avoid_infinite_loop = true;
    216     }
    217     ec_mark_forced();
    218   }
     201  if (
     202   !ec_is_creation &&
     203   document.getElementById('ec_in_up_entry_list_id').value == '-1'
     204  ) {
     205    alert(ec_JS_message['ec_act_entry_miss']);
     206    return false;
     207  }
     208  else {
     209    ec_selected_action = ec_id;
     210    if (ec_selected_action != '') {
     211      document.getElementById(ec_selected_action).checked = 'checked';
     212      switch (ec_selected_action) {
     213        case 'ec_input_action_add_p': // Additional Page
     214          document.getElementById('ec_in_up_aps_id').value = ec_selected_AP;
     215          document.getElementById('ec_in_up_cats_id').value = '-1';
     216          document.getElementById('ec_in_up_imgs_id').value = '';
     217          document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
     218        break;
     219        case 'ec_input_action_cat': // Category
     220          document.getElementById('ec_in_up_aps_id').value = '-1';
     221          document.getElementById('ec_in_up_cats_id').value = ec_selected_cat;
     222          document.getElementById('ec_in_up_imgs_id').value = '';
     223          ec_selected_user = (ec_selected_user == 'ec_sel_user_none') ?
     224           'ec_sel_user_old' : ec_selected_user;
     225          document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
     226        break;
     227        case 'ec_input_action_img': // Image
     228          document.getElementById('ec_in_up_aps_id').value = '-1';
     229          document.getElementById('ec_in_up_cats_id').value = ec_selected_cat;
     230          document.getElementById('ec_in_up_imgs_id').value = ec_selected_img;
     231          ec_selected_user = (ec_selected_user == 'ec_sel_user_none') ?
     232           'ec_sel_user_old' : ec_selected_user;
     233          ec_check_img_text();
     234        break;
     235        case 'ec_input_action_home': // Home
     236          document.getElementById('ec_in_up_aps_id').value = '-1';
     237          document.getElementById('ec_in_up_cats_id').value = '-1';
     238          document.getElementById('ec_in_up_imgs_id').value = '';
     239          document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
     240          ec_selected_user = (ec_selected_user == 'ec_sel_user_none') ?
     241           'ec_sel_user_old' : ec_selected_user;
     242        break;
     243        case 'ec_input_action_refused': // Access denied
     244          document.getElementById('ec_in_up_aps_id').value = '-1';
     245          document.getElementById('ec_in_up_cats_id').value = '-1';
     246          document.getElementById('ec_in_up_imgs_id').value = '';
     247          ec_selected_user = 'ec_sel_user_none';
     248          document.getElementById('ec_in_up_imgs_warn').innerHTML = '';
     249        break;
     250      }
     251      if (ec_avoid_infinite_loop) {
     252        ec_avoid_infinite_loop = false;
     253        ec_mark_user(ec_selected_user);
     254        ec_avoid_infinite_loop = true;
     255      }
     256      ec_mark_forced();
     257    }
     258  }
     259  return true;
    219260}
    220261
     
    436477}
    437478
     479function ec_change_user_list(ec_id) {
     480  ec_selected_old_user2 = ec_selected_old_user;
     481  ec_selected_old_user = ec_id;
     482  ec_mark_user('ec_sel_user_old');
     483}
     484
    438485function ec_change_code_list(ec_id) {
     486  ec_selected_old_code2 = ec_selected_old_code;
    439487  ec_selected_old_code = ec_id;
    440488  ec_mark_code('ec_sel_code_old');
     
    454502function ec_init() {
    455503  var d = document;
    456   ec_err               = '';
    457   ec_selected_user     = 'ec_sel_user_old';
    458   ec_selected_code     = 'ec_sel_code_new';
    459   ec_selected_old_user = '-1';
    460   ec_selected_old_code = '-1';
    461   ec_selected_AP       = '-1';
    462   ec_selected_cat      = '-1';
    463   ec_selected_action   = '';
    464   ec_selected_img      = '';
    465   ec_new_code_text     = '';
    466   ec_new_user_text     = '';
    467   ec_new_psd_text      = '';
    468   ec_old_new_psd_text  = '';
    469   ec_test_reg          = '';
     504  ec_err                = '';
     505  ec_selected_action    = '';
     506  ec_selected_img       = '';
     507  ec_new_code_text      = '';
     508  ec_new_user_text      = '';
     509  ec_new_psd_text       = '';
     510  ec_old_new_psd_text   = '';
     511  ec_test_reg           = '';
     512  ec_selected_old_user  = '-1';
     513  ec_selected_old_code  = '-1';
     514  ec_selected_old_code2 = '-1';
     515  ec_selected_AP        = '-1';
     516  ec_selected_cat       = '-1';
     517  ec_selected_old_user2 = '-1';
     518  ec_selected_user      = 'ec_sel_user_old';
     519  ec_selected_code      = 'ec_sel_code_new';
    470520  d.getElementById('ec_style_forced_id').innerHTML        =
    471521   ec_up_code_lbl_forced_txt;
  • extensions/event_cats/admin/template/autolog_new.tpl

    r4058 r4064  
    2828        <a href = "#ec_top" name = "ec_top" title = "{'ec_top_title'|@translate}">
    2929      {/if}
    30       <label for = "ec_page_type_create" onclick = "ec_mark_type('create');">
     30      <label for = "ec_page_type_create" onclick = "ec_mark_type('create');" {if $ec_is_creation} style = "text-decoration:underline;" {/if}>
    3131        <input type = "radio" id = "ec_page_type_create" onclick = "ec_mark_type('create');" {if $ec_is_creation} checked = "checked" {/if} />
    3232        {'ec_new_entry_title'|@translate}
    3333      </label>
    3434      {if $ec_hidden_when_no_code == ''}
    35         <a href = "#ec_top" name = "ec_top" title = "{'ec_top_title'|@translate}">&nbsp;/&nbsp;
     35        <a href = "#ec_top" name = "ec_top" title = "{'ec_top_title'|@translate}">&nbsp;&#149;&#149;&nbsp;
    3636      {/if}
    3737      </a>
    38       <label for = "ec_page_type_modify" onclick = "ec_mark_type('modify_entry_ask');" {$ec_hidden_when_no_code}>
     38      <label for = "ec_page_type_modify" onclick = "ec_mark_type('modify_entry_ask');"
     39       {$ec_hidden_when_no_code} {if !$ec_is_creation} style = "text-decoration:underline;" {/if}
     40      >
    3941        <input type = "radio" id = "ec_page_type_modify" onclick = "ec_mark_type('modify_entry_ask');" {if !$ec_is_creation} checked = "checked" {/if} />
    4042        {'ec_modify_entry_title'|@translate}
     
    107109              {'ec_up_code_lbl_code_old'|@translate}
    108110            </label>
    109             <select name = "ec_in_up_code_list" id = "ec_in_up_code_list_id" onclick = "ec_mark_code('ec_sel_code_old');"
     111            <select name = "ec_in_up_code_list" id = "ec_in_up_code_list_id"
    110112             onchange = "ec_change_code_list(this.value);" {$ec_hidden_when_no_code}
    111113            >
     
    123125            {* <!-- Entry choice --> *}
    124126            <select name = "ec_in_up_entry_list" id = "ec_in_up_entry_list_id" onchange = "ec_mark_entry(this.value);">
    125               <option label = "" value = "-1">------------</option>
     127              <option value = "-1" label = "">------------</option>
    126128              {foreach from=$ec_lists.ec_table item=ec_val}
    127129                <option value = "{$ec_val.id}" label = "{$ec_val.user_id},{$ec_val.action},{$ec_val.arg1},{$ec_val.arg2},{$ec_val.forced}">
     
    143145          <li>
    144146            {* <!-- None --> *}
    145             <label onclick = "ec_mark_user('ec_sel_user_none');">
     147            <label onclick = "return ec_mark_user('ec_sel_user_none');">
    146148              <input type = "radio" name = "ec_sel_user" value = "none" id = "ec_sel_user_none"
    147                onclick = "ec_mark_user('ec_sel_user_none');"
     149               onclick = "return ec_mark_user('ec_sel_user_none');"
    148150              />
    149151              {'ec_up_code_lbl_user_none'|@translate}
     
    154156        <li>
    155157          {* <!-- New user (to create) --> *}
    156           <label for = "ec_in_up_usr_txt_id" onclick = "ec_mark_user('ec_sel_user_new');" {$ec_hidden_when_no_user} >
     158          <label for = "ec_in_up_usr_txt_id" onclick = "return ec_mark_user('ec_sel_user_new');" {$ec_hidden_when_no_user} >
    157159            <input type = "radio" name = "ec_sel_user" for = "ec_in_up_usr_txt_id" value = "new"
    158              id = "ec_sel_user_new" onclick = "ec_mark_user('ec_sel_user_new');" {$ec_hidden_when_no_user}
     160             id = "ec_sel_user_new" onclick = "return ec_mark_user('ec_sel_user_new');" {$ec_hidden_when_no_user}
    159161            />
    160162            {'ec_up_code_lbl_user_new'|@translate}
     
    167169            <label class = "ec_block">{'ec_new_user_name'|@translate}<br>
    168170              <input type = "text" name = "ec_in_up_usr_txt" id = "ec_in_up_usr_txt_id" maxlength = "32"
    169                size = "20" onclick = "ec_mark_user('ec_sel_user_new');" onblur = "ec_new_user_text = this.value;"
     171               size = "20" onclick = "return ec_mark_user('ec_sel_user_new');" onblur = "ec_new_user_text = this.value;"
    170172              />
    171173            </label>
    172174            <label class = "ec_block">{'ec_new_user_pswd'|@translate}<br>
    173175              <input type = "text" name = "ec_in_up_psd_txt" id = "ec_in_up_psd_txt_id" maxlength = "32"
    174                size = "20" onclick = "ec_mark_user('ec_sel_user_new');" onblur = "ec_new_psd_text = this.value; ec_check_pwd_text();"
     176               size = "20" onclick = "return ec_mark_user('ec_sel_user_new');" onblur = "ec_new_psd_text = this.value; ec_check_pwd_text();"
    175177              />
    176178            </label>
     
    184186        <li>
    185187          {* <!-- Known user --> *}
    186           <label for = "ec_in_up_usr_list_id" onclick = "ec_mark_user('ec_sel_user_old');" {$ec_hidden_when_no_user} >
     188          <label for = "ec_in_up_usr_list_id" onclick = "return ec_mark_user('ec_sel_user_old');" {$ec_hidden_when_no_user} >
    187189            <input type = "radio" name = "ec_sel_user" for = "ec_in_up_usr_list_id" {$ec_hidden_when_no_user}
    188              value = "old" id = "ec_sel_user_old" onclick = "ec_mark_user('ec_sel_user_old');"
     190             value = "old" id = "ec_sel_user_old" onclick = "return ec_mark_user('ec_sel_user_old');"
    189191            />
    190192            {'ec_up_code_lbl_user_old'|@translate}
    191193          </label>
    192           <select name = "ec_in_up_usr_list" id = "ec_in_up_usr_list_id" onclick = "ec_mark_user('ec_sel_user_old');"
    193            onchange = "ec_selected_old_user = this.value;" {$ec_hidden_when_no_user}
     194          <select name = "ec_in_up_usr_list" id = "ec_in_up_usr_list_id"
     195           onchange = "ec_change_user_list(this.value);" {$ec_hidden_when_no_user}
    194196          >
    195197            <option label = "------------" value = "-1" {$ec_hidden_when_no_user} >------------</option>
     
    214216       
    215217        {* <!-- Additionnal Page, provided the plugin is activated and at least one Add. P. is available --> *}
    216         <label class = "ec_block" for = "ec_in_up_aps_id" onclick = "ec_mark_action('ec_input_action_add_p');"
    217          {if !$ec_ap_ok or count($ec_lists.add_pages) == 0} style = "display:none;"{/if}
     218        <label class = "ec_block" for = "ec_in_up_aps_id" onclick = "return ec_mark_action('ec_input_action_add_p');"
     219         {if !$ec_ap_ok or count($ec_lists.add_pages) == 0} style = "display:none;" {/if}
    218220        >
    219221          <input type = "radio" name = "ec_input_action" value = "add_p" id = "ec_input_action_add_p" for = "ec_in_up_aps_id"
    220            onclick = "ec_mark_action('ec_input_action_add_p');"
     222           onclick = "return ec_mark_action('ec_input_action_add_p');"
    221223          />
    222224          {'ec_up_code_lbl_aps'|@translate}<br>
    223225          <select class = "categoryList" name = "ec_in_up_aps" size="30" id = "ec_in_up_aps_id"
    224            onclick = "ec_mark_action('ec_input_action_add_p');" onchange = "ec_selected_AP = this.value;"
     226           onclick = "return ec_mark_action('ec_input_action_add_p');" onchange = "ec_selected_AP = this.value;"
    225227          >
    226228            <option label = "------------" value = "-1" style = "display:none;">------------</option>
     
    230232       
    231233        {* <!-- Category --> *}
    232         <label class = "ec_block" for = "ec_in_up_cats_id" onclick = "ec_mark_action('ec_input_action_cat');">
     234        <label class = "ec_block" for = "ec_in_up_cats_id" onclick = "return ec_mark_action('ec_input_action_cat');">
    233235          <input type = "radio" name = "ec_input_action" value = "cat" id = "ec_input_action_cat" for = "ec_in_up_cats_id"
    234            onclick = "ec_mark_action('ec_input_action_cat');"
     236           onclick = "return ec_mark_action('ec_input_action_cat');"
    235237          />
    236238          {'ec_up_code_lbl_cats'|@translate}<br>
    237239          <select class = "categoryList" name = "ec_in_up_cat" size = "30" id = "ec_in_up_cats_id"
    238            onclick = "ec_mark_action('ec_input_action_cat');" onchange = "ec_selected_cat = this.value;"
     240           onclick = "return ec_mark_action('ec_input_action_cat');" onchange = "ec_selected_cat = this.value;"
    239241          >
    240242            <option label = "------------" value = "-1" style = "display:none;">------------</option>
     
    244246       
    245247        {* <!-- Image --> *}
    246         <label class = "ec_block" for = "ec_in_up_imgs_id" onclick = "ec_mark_action('ec_input_action_img');">
     248        <label class = "ec_block" for = "ec_in_up_imgs_id" onclick = "return ec_mark_action('ec_input_action_img');">
    247249          <input type = "radio" name = "ec_input_action" value = "img" id = "ec_input_action_img" for = "ec_in_up_imgs_id"
    248            onclick = "ec_mark_action('ec_input_action_img');"
     250           onclick = "return ec_mark_action('ec_input_action_img');"
    249251          />
    250252          {'ec_up_code_lbl_img'|@translate}<br>
    251253          <input type = "text" name = "ec_in_up_img" id = "ec_in_up_imgs_id" maxlength = "6"
    252            size = "10" onblur = "ec_selected_img = this.value; ec_check_img_text();" onfocus = "ec_mark_action('ec_input_action_img');"
     254           size = "10" onblur = "ec_selected_img = this.value; ec_check_img_text();" onfocus = "return ec_mark_action('ec_input_action_img');"
    253255          /><br>
    254           <span id = "ec_in_up_imgs_warn">&nbsp;</span>
     256          <span id = "ec_in_up_imgs_warn"></span>
    255257        </label>
    256258       
    257259        {* <!-- Index page --> *}
    258         <label class = "ec_block" onclick = "ec_mark_action('ec_input_action_home');">
     260        <label class = "ec_block" onclick = "return ec_mark_action('ec_input_action_home');">
    259261          <input type = "radio" name = "ec_input_action" value = "home" id = "ec_input_action_home"
    260            onclick = "ec_mark_action('ec_input_action_home');"
     262           onclick = "return ec_mark_action('ec_input_action_home');"
    261263          />
    262264          {'ec_up_code_lbl_home'|@translate}
     
    265267        {* <!-- Access denied page (only when modifying an entry) --> *}
    266268        {if !$ec_is_creation}
    267           <label class = "ec_block" onclick = "ec_mark_action('ec_input_action_refused');">
     269          <label class = "ec_block" onclick = "return ec_mark_action('ec_input_action_refused');">
    268270            <input type = "radio" name = "ec_input_action" value = "refused" id = "ec_input_action_refused"
    269              onclick = "ec_mark_action('ec_input_action_refused');"
     271             onclick = "return ec_mark_action('ec_input_action_refused');"
    270272            />
    271273            {'ec_up_code_lbl_refused'|@translate}
     
    284286<script type = "text/javascript" src = "{$RACINE_URL}{$EVNTCATS_PATH}admin/template/autolog_new.js"></script>
    285287<script type = "text/javascript"><!--
     288  ec_is_creation                         = {if $ec_is_creation}true{else}false{/if};
    286289  ec_up_code_lbl_forced_txt              = "{'ec_up_code_lbl_forced'|@translate}";
    287290  ec_JS_message['ec_gen_user_act_miss']  = "{'ec_gen_user_act_miss'|@translate|@escape:javascript}";
     
    289292  ec_JS_message['ec_act_img_miss']       = "{'ec_act_img_miss'|@translate|@escape:javascript}";
    290293  ec_JS_message['ec_new_pwd_gen']        = "{'ec_new_pwd_gen'|@translate|@escape:javascript}";
     294  ec_JS_message['ec_act_entry_miss']     = "{'ec_act_entry_miss'|@translate|@escape:javascript}";
    291295  ec_JS_message['ec_up_code_lbl_home']   = "{'ec_up_code_lbl_home'|@translate}";
    292296  ec_JS_message['ec_submit_code_miss']   = "{'ec_submit_code_miss'|@translate}";
  • extensions/event_cats/language/fr_FR/plugin.lang.php

    r4058 r4064  
    1010// Upper banner
    1111$lang['ec_tab_autoid_entries']    = 'Entrées autolog';
    12 $lang['ec_tab_autoid_new']        = 'Nouvelle entrée autolog';
     12$lang['ec_tab_autoid_new1']       = 'Création autolog';
     13$lang['ec_tab_autoid_new2']       = 'Création/modification autolog';
    1314$lang['ec_tab_config']            = 'Configuration générale';
    1415$lang['ec_tab_duplication']       = 'Duplication';
     
    4344$lang['ec_new_entry']             = 'Code';
    4445$lang['ec_up_code_lbl_code_new']  = 'Nouveau code :';
    45 $lang['ec_sel_entry']             = 'Entrée sélectionnée :';
     46$lang['ec_sel_entry']             = 'Entrée sélectionnée';
    4647$lang['ec_new_entry_button']      = 'Générer un code automatiquement';
    4748$lang['ec_gen_code_nb_pre']       = 'de';
     
    6162$lang['ec_up_code_lbl_aps']       = 'Additional Page';
    6263$lang['ec_up_code_lbl_cats']      = 'Catégorie';
    63 $lang['ec_up_code_lbl_img']       = 'Image';
     64$lang['ec_up_code_lbl_img']       = 'Id. image';
    6465$lang['ec_up_code_lbl_home']      = 'Accueil';
    6566$lang['ec_up_code_lbl_refused']   = 'Accès refusé';
     
    7778$lang['ec_submit_user_miss']      = 'Vous devez fournir un utilisateur.';
    7879$lang['ec_submit_action_miss']    = 'Vous devez proposer une page à afficher.';
     80$lang['ec_act_entry_miss']        = 'Sélectionnez d\'abord une entrée à modifier.';
    7981
    8082// In PHP files
Note: See TracChangeset for help on using the changeset viewer.