EasyUI Forum
December 21, 2025, 10:49:49 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: [SOLVED]Table inside datagrid cell  (Read 6733 times)
jega
Full Member
***
Posts: 232


View Profile
« on: February 24, 2022, 05:38:37 AM »

Hi.

Trying to put a formatted table inside a cell in datagrid.

<th data-options="field:'timestamps',width:'300px',formatter:formatTimestamps">Kopiering</th>

    function formatTimestamps(val,row){
      var res = '<table>'+val+'</table>'
      return res;
   }

But there is some border. See attachment

How can i put it without these borders

« Last Edit: February 28, 2022, 06:28:26 AM by jega » Logged
jarry
Administrator
Hero Member
*****
Posts: 2305


View Profile Email
« Reply #1 on: February 27, 2022, 11:28:38 PM »

Assign a class to the <table> and then define the <td> element with no border.
Code:
var res = '<table class="mt">'+val+'</table>'
return res;
Code:
<style type="text/css">
    .mt td{
        border:0;
    }
</style>
Logged
jega
Full Member
***
Posts: 232


View Profile
« Reply #2 on: February 28, 2022, 06:28:02 AM »

Arh. Yes, of course.

Thanks Jarry
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!