Quantcast
Channel: Recent Discussions — DataTables forums
Viewing all 82267 articles
Browse latest View live

highlight search field by having the focus

$
0
0

I would like that when I click on a field in the table and this field appears in the table search, this search engine will be highlighted in some way, changing the color for example

"initComplete": function (settings, json) {//Hace una busqueda haciendo click sobre el campo
                var api = this.api();
                api.$('td').not(" :nth-child(1),:nth-child(7), :nth-child(9)").click(function () {
                    $( ".input" ).css( "border", "3px solid red" );
                    api.search(this.innerHTML).draw();
                });
            },

A Easy Work Hairstyle

$
0
0

Purchase Greatest Brazilian Hair On-line
Beauty Eternally Hair virgin and remy Brazilian hair weaves and bundles can be found for you to purchase with inexpensive worth. Earlier than shopping for, select your favored hairstyle, there are straight hair,body wave weave, curly hair, loose wave, deep wave for you to decide on; And various hair size range 8, 10, 12...26, 28, 30 can be found for you. The hair weave are priced based on its quality, size, texture. Customized Brazilian hair weaves could value more and take extra time for making.

Brazilian body wave hair weave bundles are made from 100% actual Brazilian hair, can remodel any banal haircut into a glamorous lock. The Brazilian hair is thick, mushy and naturally wavy, Brazilian body wave 3bundles and lace frontal are excellent to provide you with a recent body wavy hairstyle and have been quite a popular choice among ladies.

These beautifully outlined waves offers you a extra bouncy look. It is extremely versatile and provides extra edge and quantity to your hair. Loose wave hair braid is extra trend than straight hair braid. An vital reminder is you want to purchase the high-high quality unfastened wavy Brazilian hair which is never been handled with dangerous chemicals when producing it.
3.The Elegant Gala
It's at all times an important time to gown your finest for any high-end event and what's higher than a gala?
A swept over fashion would be a superb praise to such an elegant atmosphere leaving a red carpet impression. A straightforward hairstyle swept over body wave hair is the proper look accentuating all forms of sexy for the night. A handy technique to get this look is by using virgin Brazilian body wave hair neatly combed out. This will still give quantity and body.

Why We Use Human Hair Bundles With Closure?
Ladies all the time buy human hair weavesor human hair extensionswith hair closures.In Widespread three or four bundles hair will be enough for a full head once they sew within the hair extensions to the pinnacle.But on the top of the pinnacle, you could a hair closure to cover all.So The lace closures are often bought with hair bundles.
Brighter

Pass variable from .js to .php not working

$
0
0

Here is my "table.something.js'

                    var test = datatest;
                    $.ajax({
                        url: 'php/table.something.php',
                        type: 'POST',
                        data: ({
                            test: test
                        }),
                        success: function (data) {

                        }
                    });

And here is my "table.something.php'

$idNumber = $_POST['test'];

// Build our Editor instance and process the data coming from _POST
Editor::inst( $db, 'table' )
    ->fields(
        Field::inst( 'column_id' ),
        Field::inst( 'text' ),
        Field::inst( 'registertime' ),
        Field::inst( 'changedtime' )
    )
    ->where('table.column_id', $idNumber)
    ->process( $_POST )
    ->json();

Why is not passing the variable!?
If i change to $idNumber = 1 or any other number, it work great.
Any suggestion!?
Thanks ;-)

Is it possible to load language information from remote file for DataTables.Editor?

$
0
0

There is the language.url option for DataTable itself, but I see no similar for the Editor. Does it exist? Or may be it's planned in future? It would be very nice to have translations for all editor instances in one file.

Regards.

Symfony 4 - How to use custom Datatables ajax to server

$
0
0

Hi,

I am new using Datatables and we think it's a powerfull tool for our project, but I'm lost with it's implementation.

I need a Datatable on my page and sending/receiving data to/from my symfony 4 app.

As we have complex custom authorization to check any call to server, and also to check if the user can or can not edit any sended data (and in fact, read or write over a Symfony Entity), and also check the received data format, I don't know how to configure DataTables to send/get the data to a specific Symfony Controller so we can do all this process.

In fact, I need a custom send/receive data and sorry, I don't find any page explaining the sended/received format to read/modify/delete rows.

Or may be I am wrong and all this stuff can be configured for Symfony 4.

Coul you help me? Thanks.

Excel export does not export the data in the table just the name and table headings

$
0
0

I am trying to export a table of data extracted by Java, passed back to Ajax using JSON, and populating the table with Ajax in HTML. Using a table populated with data in the HTML works fine.

Java:

    if (packSummaryList == null || packSummaryList.isEmpty()) {
        response.sendError(HttpServletResponse.SC_BAD_REQUEST, "No one joined.");
    } else {
        String json = new Gson().toJson(packSummaryList);
        response.setContentType("application/json");
        response.setCharacterEncoding("UTF-8");
        response.getWriter().write(json);
    }

Ajax:

      .done(function(responseJson1a){
            dataType: "json";
    var tablebody = "";
    try{
          for (i=0; i < responseJson1a.length; i++) {
              tablebody += "<tr><td>"+responseJson1a[i].section+"</td><td>"+responseJson1a[i].metricTotal+"</td></tr>";
          }
          $("#mytablebody").empty();
          $("#mytablebody").append(tablebody);
    }
    catch(e){
    console.log(e);
    }
})

HTML:

    <div class="col-lg-3 col-md-3 col-sm-3 col-xs-3">
        <table class="table table-hover table-bordered" id="joinedTable">
            <thead>
                 <tr>
                    <th>Section</th>
                    <th>Joined</th>
                 </tr>
            </thead>
            <tbody id="mytablebody"></tbody>
        </table>
        <div style="text-align: center;">
            <span id="ajaxGetUserServletResponse1" style="color: red;"></span>
        </div>
     </div>

Hairstyles for brief and Mid-size Hair

Translate the strings

$
0
0

Hello, I found your solution and need to translate the strings to Hebrew that RTL language, Can I translate the string without problem? I found this link 'http://legacy.datatables.net/usage/i18n' on other topic, but did not understand what to do.
If I translate the string "show X entries" I need to change between "show" and "entries" also "Showing 1 to 5 of 5 entries" need to change order.
Can I not display these strings?


Is there an issue with ckeditor5 balloon? Seems not to work with plugin.

$
0
0

Hello all,
it seems that the ckeditor 5 plugin does not work if type is ckeditorBalloon.
ckeditorClassic runs fine with the same example. But if I change to ckeditorBalloon, the editor field will not replaced with the ballooneditor. I used the cdn from ckeditor for ballon and also for classic (of course not at the same time).
Is there a way to get the balloon editor work with datatables editor?
Frank

insert into 1-1 tables

$
0
0

Hi all,

I need you help!

I have 2 tables, 1-1 relationship, for example:
table_1 (id, name, table_id_2)
table_2 (id, name)

In grid show all column from table_1, table_2 tables.

But how implement Insert into this tables? With edit no problem, hidden field table_id_2 help with it.

When try insert - get the error:
Field 'table_id_2' doesn't have a default value

If you need more details, please let me know.

Thanks in advance,
Alex

editor set value as boolean for a checkbox sends an array instead of a boolean

$
0
0

I have a backend server that is expecting a response in the form of a boolean. I've been following this example exactly as what is posted in this demo example:

https://editor.datatables.net/examples/api/checkbox.html

I have the following field on the editor:

      {
        label: "Active",
        name: "active",
        type: "checkbox",
        options: [
          { label: '', value: true }
        ]
      }

Executing the following code:

    _editor
      .edit($(this).closest('tr'), false)
      .set('active', true)
      .submit();

Send the following value to the server:

"[\r\n  1\r\n]"

Setting the field to false:

    _editor
      .edit($(this).closest('tr'), false)
      .set('active', false)
      .submit();

Send the following value to the server:

"[]"

These results aren't what I'd expect when setting a checkbox value with a boolean type. Why can't I just receive a simple "true" or "false" value? As this complicates my code on the backend.

Then I investigated what was going on:

var _editor = new $.fn.dataTable.Editor({
    ajax: {
          url: '/api/Test',
          data: function (d) {
              var id;
              switch (d.action) {
                    case "create":
                         id = 0;
                         break;
                    case "edit":
                    case "remove":
                         id = d.data[Object.keys(d.data)[0]].ID;
                         break;
              }
              console.log(d.data[id].active);   //weird results
              return JSON.stringify(d);
      },
     ....
    }
});

In the console log, I found out that if the value is true, then d.data[id].active is an array with one index, with the value true. And if the value is false, then d.data[id].active is undefined.

Is there a reason why this logic exists like that? It took me forever to find out what was going on and why my server kept blowing up. To remedy this, in the ajax code I did this:

  var retVal = false;
  if (d.data[id].active.length > 0) {
      retVal = d.data[id].active[0]
  } 
  d.data[id].active = retVal;
  return JSON.stringify(d);

Trying to get "only get rows with non-blank entries in specific column" regexp to work

$
0
0

I want to filter a column to only those that have non-blank entries. It seems like the regular expression [\s\S] should work, but it doesn't seem to. Wondering if anyone has been able to get this kind of thing to work.

doing this:
table.column( columnIndex ).search( '[\s\S]', true, false )
.draw();

since I assume datatables is just using the regexp as is with javascript, and I have successfully tested the regexp (using the AWESOME site https://regex101.com/), I am not sure what is going on. If someone else has gotten this kind of thing to work, it must be something else I am probably not doing right.

Paging disappears with buttons

Datatables is not fit in mobile screen

$
0
0

datatables grid is not filt in mobile screen. but little browser size if increase it fit.. how can we default columns fit in mobile screen. i attached 2 screen shot

old screen : 3.png
new screen : 4.png

two different editors

$
0
0

Hi
from the server I get a config that should show two different editors templates. Depending on the config another template is

displayed.function template1() {
var html = <div id="customForm1"> <fieldset class="firma"> ..... </fieldset> </div>
$("#templates").html("");
$("#templates").append(html);
editor.template('#customForm1');
}

displayed.function template2() {
var html = <div id="customForm2"> <fieldset class="name"> ..... </fieldset> </div>
$("#templates").html("");
$("#templates").append(html);
editor.template('#customForm2');
}

editor.on( 'open', function ( e, o, action) {
var firma = this.field( 'firma' );
if (firma.val().length > 0){
template1()
} else {
template2()
}

It does not work like that. Can not I assign an HTML template at runtime?
How would I have to change that to work correctly?

THANK YOU
Ciao


Table inside td

$
0
0

I had a question. Can datatables work this table :

<table>
  <thead>
    <tr>
       <th></th>
       <th>Title</th>
       <th>Title</th>
       <th>Title</th>
       <th>Title</th>
       <th>Title</th>
       <th>Title</th>
       <th></th>
       <th></th>
       <th></th>
       <th></th>
    <tr>
  </thead>
  <tbody>
    <tr>
       <td aria-expanded="false" data-toggle="collapse" data-target="#collapse1" style="cursor: pointer;"><span class="glyphicon glyphicon-chevron-right"></span><span class="glyphicon glyphicon-chevron-down"></span></td>
       <td>Stuff</td>
       <td>Stuff</td>
       <td>Stuff</td>
       <td>Stuff</td>
       <td>Stuff</td>
       <td>Stuff</td>
       <td><insert button here></td>
       <td><insert button here></td>
       <td><insert button here></td>
       <td><insert form here></td>
    <tr>
    <tr>
       <td></td>
       <td colspan="10"><insert table here></td>
    <tr>
  </tbody>

How to export a DataTable as an Excel file to be included in a Zip file ?

$
0
0

Hi all,

I am wondering what would be the best solution to export my selection from a datatable to an excel file to be included in a zip file.
For now, I have an ajax call that runs a php code to produce my zip file.
I need now to include a recall of the current selection (as an excel file).

Any idea to share ?
Thanks
Patrick

Sorting language with intl.js

$
0
0

Hello,

i looking for change local for sorting in tables. I found that best idea is intl.js. But its not working for me. Inspect show this error:
TypeError: Cannot read property 'ext' of undefined
at intl.js:72
$.fn.dataTable.ext.order.intl = function ( locales, options ) {
at intl.js:66
factory( jQuery, window, document );
at intl.js:69
(function( $, window, document ) {

I dont know what going on because its javascript from original page. Here is my code definition for order and table:

        $.fn.dataTable.ext.order.intl('fr');
        var table = $('#myTable').DataTable({
            columnDefs: [
                { orderable: true, targets: 0 },
                { orderable: true, targets: 1 },
                { orderable: true, targets: 2 },
                { orderable: false, targets: 3 },
                { orderable: false, targets: 4 }
            ],
            oLanguage: {
                oAria: {
                    "sSortAscending": "Usporiadať vzostupne",
                    "sSortDescending": "Usporiadať zostupne"
                },
                oPaginate: {
                    "sFirst": "Prvá strana",
                    "sLast": "Posledná strana",
                    "sNext": ">",
                    "sPrevious": "<"
                },
                sEmptyTable: "Žiadne zaznamenané kontakty",
                sInfo: "Zobrazené od _START_ po _END_ z celkového počtu _TOTAL_",
                sInfoEmpty: "Žiadne zaznamenané kontakty",
                sInfoFiltered: "(vyfiltrované z _MAX_ všetkých kontaktov)",
                sLengthMenu: "Zobraziť _MENU_ kontaktov na stranu",
                sLoadingRecords: "Prosím počkajte - načítavam...",
                sProcessing: "Spracúvam údaje",
                sSearch: "Vyhľadať:",
                sZeroRecords: "Žiadne zaznamenané kontakty",
            },
            dom: "<'row'<'col-sm-4'l><'col-sm-4 toolbar'><'col-sm-4'f>>" +
                "<'row'<'col-sm-12'tr>>" +
                "<'row'<'col-sm-5'i><'col-sm-7'p>>",
            aLengthMenu: [
                [10, 25, 50, 100, -1],
                [10, 25, 50, 100, "Všetky"]
            ],
            "paging": false,
            "ordering": true,
            "info": true,
            "stateSave": false,
            "searching": true
        });

Thank you for any advice.

Editor: Remove Hover and after change effect

$
0
0

When using the Editor plugin, there are some visual effects that i would like to remove:

1 - when hover on row, the row background changes to orange
2 - when changing a value, the row seems highlighted with an yellow background for a few seconds

Is it possible to remove these effects?

Limit on Multiedit?

$
0
0

Hi,
I have a data table with about 1000 records. Using MultiEdit function, I can edit 100 records at the same time, but with 200 records the server responds with Error 403 (Forbidden). I don't know the reason, maybe too much POST data? I have tried the option submit: 'changed' , but it seems this does not work on MultiEdit: it submits the whole row anyway.
Is there any idea how I would be able to multiedit all 1000 records?
Many thanks and regards,
marwi

Viewing all 82267 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>