datatable printing issue

datatable printing issue

THEJASVITHEJASVI Posts: 31Questions: 9Answers: 0



above i send that pic . Y checkbox data not printing

This question has accepted answers - jump to:

Answers

  • colincolin Posts: 12,602Questions: 0Answers: 2,154
    Answer ✓

    Hi @THEJASVI ,

    The checkbox would be a custom control, something your code does, so without seeing that code, or better still, having a running example to look at, it makes it hard to recommend a solution...

    Cheers,

    Colin

  • THEJASVITHEJASVI Posts: 31Questions: 9Answers: 0
    edited May 2018
     {
                                data:   "client_status",
                                render: function ( data, type, row ) {
                                    if ( data === 'Active' ) {
                                        return '<input type="checkbox" class="editor-active" onclick="return false;" checked>';
                                    }
                                    else {
                                        return '<input type="checkbox" onclick="return false;" class="editor-active">';
                                    }
                                    return data;
                                },
                                className: "dt-body-center text-center"
                            },
    

    i M USING CODE LIKE THIS
    my question is clients status data is not printing in datatable print

  • colincolin Posts: 12,602Questions: 0Answers: 2,154

    I see. Take a look at this example here, this is displaying a 'Y' or 'N' based on the checkboxes values. I don't know off hand how to get a checkbox into the PDF, but this may do the trick for you.

    Cheers,

    Colin

  • THEJASVITHEJASVI Posts: 31Questions: 9Answers: 0

    example here link is blank please send me correct link example

  • colincolin Posts: 12,602Questions: 0Answers: 2,154
    Answer ✓

    http://live.datatables.net/kovegexo/1/edit

    Sorry, not sure what happened there

  • THEJASVITHEJASVI Posts: 31Questions: 9Answers: 0

    thank u colin it's working

This discussion has been closed.