Quantcast
Channel: Editor — DataTables forums
Viewing all articles
Browse latest Browse all 3744

Duplicate button cannot create new records from existing record

$
0
0

I have added the button Duplicate as below. It can copy the fields from the selected row and pop up for editing. But when click on button 'Create from existing'. It has no new record update. Did I miss anything?

            {
                extend: 'selected',
                text: 'Duplicate',
                action: function (e, dt, node, config) {
                    // Start in edit mode, and then change to create
                    editor
                        .edit(table.rows({ selected: true }).indexes(), {
                            title: 'Duplicate record',
                            buttons: 'Create from existing'
                        })
                        .mode('create');
                }
            },

Viewing all articles
Browse latest Browse all 3744