Okay
  Public Ticket #2693828
Mobile view on desktop - for custom tables or pages
Closed

Comments

  •  1
    Piotr Kowalski started the conversation

    I have general idea about using "tablet width" to achive row collapse on desktop. Problem is this setting is appilled to every table no mater number of columns it have - 4 or 14.

    There must be the way to override tablet width on "onload" event and  distinguish it for different tables or pages. Set 1024px for one table or page and 1300px for another. 


  •  471
    Isidora replied

    Hi Piotr,

    Thank you for your purchase
    Sorry for the delay in our responses, has been national holidays in our country for the last few days.

    Yes now it is on global settings and it is applied on all tables. We have in plan to implement it on each table on Customize tab in table settings in the future.

    Until that you can use this hook in functions.php of your theme or child theme.

    // $tableDescriptionObj std class/object thatcontain all table description
    // tableId string that contain table id
    // wpdtObj WPDataTable object 
    function updateTableDescription( $tableDescriptionObj, $tableId ,$wpdtObj)   {
            // condition for table that have id 1
         if( $tableId == 1 ){
            // set tabletWidth on 1000 you will insert value for your needs
                $tableDescriptionObj->tabletWidth = '1000';
            // for mobileWidth you will use like this
            // we set 300 you will set for your needs
                $tableDescriptionObj->mobileWidth = '300';
            }
        return $tableDescriptionObj;
    }
    add_filter('wpdatatables_filter_table_description','updateTableDescription', 10, 3);


    Kind Regards, 

    Isidora Markovic

    wpDataTables: FAQFacebookTwitterFront-end and back-end demoDocs

    Amelia: FAQFacebookTwitter |  Amelia demo sites | Docs

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

    Powerful FiltersGravity Forms Integration for wpDataTablesFormidable Forms Integration for wpDataTables

  •  1
    Piotr Kowalski replied

    Nice! Thank you very much :) 

  •  471
    Isidora replied

    Hi Piotr,

    You are welcome.

    If you have any other issues or questions please open a new ticket, and we help you out.

    I’d like to ask you a favor. Would you mind taking a few minutes to write a review for us, please on this link

    Our free version is the only place where we can have a proof for our hard work; your comments are beneficial for others to know what to expect when they’re looking for our plugin.

    Thank you in advance. It means a lot to us, and I am looking forward to reading your comment.

    Best regards.

    Kind Regards, 

    Isidora Markovic

    wpDataTables: FAQFacebookTwitterFront-end and back-end demoDocs

    Amelia: FAQFacebookTwitter |  Amelia demo sites | Docs

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

    Powerful FiltersGravity Forms Integration for wpDataTablesFormidable Forms Integration for wpDataTables