EasyUI Forum
May 14, 2024, 08:47:40 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: Disable editing  (Read 6570 times)
rezzonico
Full Member
***
Posts: 183


View Profile
« on: July 17, 2015, 04:34:03 AM »

Hi all,

I have a datagrid similar to the following example:
http://www.jeasyui.com/tutorial/datagrid/datagrid15_demo.html

As you can try in the demo, the user can edit the column "Unit Cost".
Since the column "Unit Cost" is calculated, I don't want that this column is editable by the user.
How is it possible ?

Any help is appreciated.
Miche
« Last Edit: July 17, 2015, 05:35:28 AM by rezzonico » Logged
eagleeye
Newbie
*
Posts: 19


View Profile Email
« Reply #1 on: July 17, 2015, 07:52:20 AM »

Use data-options

readonly:true and
disabled:true

Code:
 <th field= "fecha_fin_real"   
 fixed="true"
width="115" 
align="center" 
editor="{
type:'datetimebox',
options:{disabled:true,editable:false,readonly:true,currentText:'Hoy',closeText:'Cerrar',okText:'Aceptar',showSeconds:false}}" >
Fecha RealTer
</th>
Logged
rezzonico
Full Member
***
Posts: 183


View Profile
« Reply #2 on: July 18, 2015, 07:04:00 AM »

Thanks a lot !

Regards
Miche
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!