EasyUI Forum
May 02, 2024, 02:59:04 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: Propertgrid and multilines textarea  (Read 13253 times)
Fabrice
Jr. Member
**
Posts: 62


View Profile
« on: September 09, 2015, 04:50:09 AM »

How can i display a multilines textarea on a propertygrid?
I want also that when editing the enter key don't leave the field but make a newline
Logged
jarry
Administrator
Hero Member
*****
Posts: 2262


View Profile Email
« Reply #1 on: September 09, 2015, 07:02:39 AM »

Please set the 'textbox' editor with 'multiline' property set to true.
Code:
{"name":"Address","value":"","group":"ID Settings","editor":{
"type":"textbox",
"options":{
"multiline":true,
"height":50
}
}},
Logged
Fabrice
Jr. Member
**
Posts: 62


View Profile
« Reply #2 on: September 14, 2015, 01:39:36 AM »

I would like a multilines textarea in the propertygrid, not only in the editor.
I have extended the textarea type to show multilines when editing and to catch <enter> key to go to the line when pressed. It's works fine but when i validate the field, the text entered appears in only one row in the property grid.

Logged
Fabrice
Jr. Member
**
Posts: 62


View Profile
« Reply #3 on: September 17, 2015, 12:39:56 AM »

Any idea?
Logged
jarry
Administrator
Hero Member
*****
Posts: 2262


View Profile Email
« Reply #4 on: September 17, 2015, 01:37:19 AM »

Please define a formatter function on the value column to display your value with multiple lines.
Logged
Fabrice
Jr. Member
**
Posts: 62


View Profile
« Reply #5 on: September 17, 2015, 06:36:47 AM »

That's perfect.

As i want the same thing in a datagrid, i have added :
Code:
.datagrid-cell {
    height: auto;
}

in my css, is-it the best solution?
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!