Plugin Directory

Changeset 3176193


Ignore:
Timestamp:
10/26/2024 09:03:14 PM (17 months ago)
Author:
loncar
Message:

New version 3.12.4

Location:
easy-appointments/trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • easy-appointments/trunk/js/admin.prod.js

    r3148231 r3176193  
    494494
    495495            var $btn = jQuery(e.currentTarget);
     496
     497            var id = $btn.data('id');
     498
    496499            var $li = $btn.closest('li');
    497500            var name = _.unescape('' + $li.data('name'));
    498             var element = this.fields.findWhere({label:name});
     501            var element = !!id ? this.fields.findWhere({id: id}) : this.fields.findWhere({ label:name });
    499502
    500503            this.fields.remove(element);
  • easy-appointments/trunk/js/frontend-bootstrap.js

    r3059359 r3176193  
    444444                next_element.append('<option value="">-</option>');
    445445
     446                var option_count = 0;
     447
    446448                // options
    447449                jQuery.each(response, function (index, element) {
     
    469471
    470472                    next_element.append($option);
     473
     474                    option_count++;
    471475                });
    472476
     
    477481
    478482                plugin.scrollToElement(next_element.parent());
     483
     484                // if there is only one option auto select it
     485                if (ea_settings['auto_select_option'] === '1' && option_count === 1) {
     486                    next_element
     487                        .children()
     488                        .last()
     489                        .prop('selected', true)
     490                        .trigger('change');
     491                }
    479492            }, 'json');
    480493
  • easy-appointments/trunk/main.php

    r3172490 r3176193  
    55 * Plugin URI: https://easy-appointments.com/
    66 * Description: Simple and easy to use management system for Appointments and Bookings
    7  * Version: 3.12.3
     7 * Version: 3.12.4
    88 * Requires PHP: 5.3
    99 * Author: Nikola Loncar
     
    2222 * Currently plugin version.
    2323 */
    24 define( 'EASY_APPOINTMENTS_VERSION', '3.12.3' );
     24define( 'EASY_APPOINTMENTS_VERSION', '3.12.4' );
    2525
    2626// path for source files
  • easy-appointments/trunk/readme.txt

    r3172490 r3176193  
    66Tested up to: 6.6
    77Requires PHP: 5.3
    8 Stable tag: 3.12.3
     8Stable tag: 3.12.4
    99License: GPLv2
    1010License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    214214== Changelog ==
    215215
     216= 3.12.4 (2024-10-26)
     217* Fixed issue with custom form fields that in some cases could not be deleted
     218* Added new option for auto selection location/service/worker if there is only one option available (shortcode param `auto_select_option="1"`)
     219
    216220= 3.12.3 (2024-10-20)
    217221* Fixed bug with Vacation page not loading (due to plan permalinks settings)
  • easy-appointments/trunk/src/fields/tablecolumns.php

    r3007458 r3176193  
    141141            'cal_auto_select',
    142142            'auto_select_slot',
     143            'auto_select_option',
    143144            'cancel.scroll',
    144145            'captcha.site-key',
  • easy-appointments/trunk/src/frontend.php

    r3100056 r3176193  
    485485            'block_days'           => null,
    486486            'block_days_tooltip'   => '',
    487             'select_placeholder'   => '-'
     487            'select_placeholder'   => '-',
     488            'auto_select_option'   => '0'
    488489        ), $atts);
    489490
     
    526527        $settings['cal_auto_select']        = $code_params['cal_auto_select'];
    527528        $settings['auto_select_slot']       = $code_params['auto_select_slot'];
     529        $settings['auto_select_option']     = $code_params['auto_select_option'];
    528530        $settings['block_days']             = $code_params['block_days'] !== null ? explode(',', $code_params['block_days']) : null;
    529531        $settings['block_days_tooltip']     = $code_params['block_days_tooltip'];
  • easy-appointments/trunk/src/templates/admin.tpl.php

    r3148231 r3176193  
    915915        </select>
    916916    </p>
    917     <p><a href="#" class="deletion item-delete">Delete</a> | <a href="#" class="item-save">Apply</a></p>
     917    <p><a href="#" class="deletion item-delete" data-id="<%=item.id%>">Delete</a> | <a href="#" class="item-save">Apply</a></p>
    918918</div>
    919919</script>
Note: See TracChangeset for help on using the changeset viewer.