Okay
  Public Ticket #1680755
WPdataTables
Closed

Comments

  • Mark chaskelson started the conversation

    Is there a way to import post types into the table? 

    For example, import products from a woo-commerce category?

    Then assign custom table headers?

    I would like to create a table called "screens". Then import all the products in the screen category. Set the custom headers and input data for each product table entry (size, resolution, type of mount).

    Optional. If the answer is yes. I would love it if it removed product entries on the table if the product was deleted.

  • [deleted] replied

    Hi Mark,

    It is possible to create wpDataTable from post types with MySQL query. Also we have query generator that will create wpDataTable from WordPress database:

    "Please note: this tool is not an ultimate query generator. It simply constructs a suggestion of a query. We are constantly working to improve it, but SQL is such a complicated and flexible language that full automation for constructing queries is next to impossible. Consequently, the more complicated the query, the higher is the probability that it will not return exactly what you need. So, you will often need to play around with the resulting query."

    Also it is possible to create custom headers for column names. I am not sure for the part of removing product entries if product is deleted. Probably something like this would be possible with WHERE condition in the query but I am not sure because I don't know how WooCommerce table in the database looks like.

    You can try our sandbox site: Front-end & Back-end - you can find a fully functional version there to try out all plugin features.