As previously announced via banners and our newsletters, support is no longer available through this platform.

For easier navigation, you can still click on "Submit a Ticket" here, choose the appropriate category, and you'll be redirected to the correct support channel for your plugin.

You can still access your previous tickets and browse public tickets, but please note that responding to tickets is no longer possible.

Paid customers: Please log in to your store account for support.

Pre-purchase questions: Use the support widget in the bottom-right corner of our websites:
https://wpamelia.com
https://wpdatatables.com
https://wpreportbuilder.com

Okay
  Public Ticket #1042753
Date Range Filter Options
Closed

Comments

  •  2
    kbosworth started the conversation

    In the date range drop down, the user has the ability to sort 5 years in the past and 5 years in the future. I would like to limit the drop down to show on the current and future years and eliminate the past years. Could you explain how this is done?

  •  1,896
    Miloš replied

    Hi kbosworth,
    Thank you for your purchase.

    Unfortunately that request is out of the box of our plugin and it will require some code customization.

    I can give you some guide where to look so maybe you can find the solution.
    In file ../wpdatatables/assets/js/wpdatatables/wpdatatables.js around line 606 you will find this code

     * Apply pickadate
     */
    var dateFormat = tableDescription.datepickFormat.replace(/y/g, 'yy').replace(/Y/g, 'yyyy').replace(/M/g, 'mmm');
    var datePickerInit = function (selector, additional_params, state) {
        if( $('#wdtDatePickContainer').length == 0 ){
            $('<div id="wdtDatePickContainer" class="wpDataTables"></div>').appendTo('body');
        }
        var input = $(selector).pickadate({
            format: dateFormat,
            formatSubmit: dateFormat,
            selectYears: 5,
            selectMonths: true,
            container: '#wdtDatePickContainer',
            onClose: additional_params,
            firstDay: 1
        });
        var picker = input.pickadate('picker');
        if (state == 'opened') {
            picker.open();
        }
    }

    the "selectYears : 5" gives the select box 5 years in past and 5 years in the future. 
    So I hope this can help.
    If you can not find the solution we can offer you our paid customization service.

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    Try our FREE mapping plugin! MapSVG - easy Google maps, interactive SVG maps and floor plans, choropleth maps and much more - https://wordpress.org/plugins/mapsvg-lite-interactive-vector-maps/

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables