Nested editing with new table for each entry

Nested editing with new table for each entry

MarekAdamMarekAdam Posts: 30Questions: 9Answers: 1

Link to test case: https://editor.datatables.net/examples/datatables/nested.html
Description of problem: Is there posibility to make table like in nested editing but with every main entry another data in nested table? I want to add 1-4 entries in each with two cols, select and number (1-20 so can be select to).

Answers

  • allanallan Posts: 62,448Questions: 1Answers: 10,251 Site admin

    I'm afraid I don't quite understand what you are asking for - sorry. Do you mean you want multiple datatable field types? If so, then yes that is quite possible. I've got a feeling it is something else though - could you illustrate it perhaps?

    Thanks,
    Allan

  • MarekAdamMarekAdam Posts: 30Questions: 9Answers: 1

    Yes, i want datatable field but with another data in every main row entry. Every main entry has own datatable field. I think that best would be to add where parametr to php query with reference to data datatables field.

    T1 - Main Table
    id_T1 | name | text | datetime

    T2 - datatable field
    id_T2 | id_T1 | id_T3 (select field, multiple) | b2 (int)

    T3 - select to datatable field
    id_T3 | name

    It is posible? Is there any Server script example of nested editing?

  • allanallan Posts: 62,448Questions: 1Answers: 10,251 Site admin

    I'm really sorry, I'm just not quite understanding what you are looking for. Is it something a bit more like this example?

    Allan

  • MarekAdamMarekAdam Posts: 30Questions: 9Answers: 1

    Yes but closer example will be:
    https://editor.datatables.net/examples/datatables/nested.html (but with multiple Cities/locations - multiple: true,)

    OR
    https://editor.datatables.net/examples/datatables/mJoin.html (but with 2 cols in Permissions table)

    I have tried to correct each of these examples and none of them want to work this way. Both examples have a database structure that makes this impossible

  • allanallan Posts: 62,448Questions: 1Answers: 10,251 Site admin

    https://editor.datatables.net/examples/datatables/mJoin.html (but with 2 cols in Permissions table)

    That shouldn't be a problem - you can have as many columns in the datatable field as you like. As long as the data you want to show for each row is in the data that is loaded you can display it, like in this example.

    If that isn't working for you, can you give me a link to your page so I can take a look at see what is going wrong? You can PM it to me by clicking my user name above and then "Send message" if you don't want to make it public.

    Thanks,
    Allan

  • MarekAdamMarekAdam Posts: 30Questions: 9Answers: 1

    If you say so, I'll do one more try. If I can't do it, I'll send you the code.

  • allanallan Posts: 62,448Questions: 1Answers: 10,251 Site admin

    Yes, if it doesn't work, send me the code, screenshots and any error messages please (or a link to the page would be even better).

    Allan

Sign In or Register to comment.