Solution For Customizing DataTable Search Field

17 Views Asked by At

I want to Customize Jquery DataTable Search text field and put an icon inside the text field The Jquery Datatable Provide Some Features To Customize its built-in Fields How to Resolve This Help me Any One Please Is there any other Solution Without Customizing ?? Is DataTable Providing Feature of TextField Customization With Icons??

here is my dataTable Code

 $('#FamilyMembersTable').DataTable({
        "searching": true,
        "processing": true,
        "serverSide": false,
        //"searchDelay": 10000,
        "destroy": true,
        "ScrollX": true,
        "order": [[0, "desc"]],
        "ajax": {
            url: "/Home/GetFamilyMembers",
            data: function(data) {
                data.IsChildAccount = false;
                data.PatientId = $('#hdn_PatientIdForFamilyMemberInsertion').val();
            },
            type: 'POST',
        },
       columns": [
             {
                 "data": "DateOfBirth",
                 render: function (data) {
                     return moment(data).format('MMM DD, YYYY');
                 }

             },

             {
                 "data": "Gender"

             },
              {
                  "data": "Email",

              },
               
                },
        ],

        "columnDefs": [
            { "className": "text-left", "targets": [0,1,3, 5] },
            { "className": "text-center", "targets": [2,6] }
        ],
       
        },

        "language": {
            "lengthMenu": '<select class="custom-select custom-select-sm form-control form-control-sm mr-2">' +
                '<option value="10">10</option>' +
                '<option value="25">25</option>' +
                '<option value="50">50</option>' +
                '<option value="100">100</option></select>Show on page',
            "search": ""

        }
        
    });
0

There are 0 best solutions below