EasyUI
Home
Demo
Tutorial
Documentation
Download
Extension
Contact
Forum
EasyUI Forum
May 20, 2024, 05:41:21 PM
Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News
:
Home
Help
Search
Login
Register
EasyUI Forum
>
General Category
>
EasyUI for jQuery
>
datagrid + formatter + appendRow
Pages: [
1
]
« previous
next »
Print
Author
Topic: datagrid + formatter + appendRow (Read 3612 times)
rezzonico
Full Member
Posts: 184
datagrid + formatter + appendRow
«
on:
May 19, 2018, 12:30:09 AM »
Hi all,
I have a datagrid with a combobox field (with valueField and textField).
In the comobox field (vehicle) I use a formatter.
The formatter convert the value received from the server to a string, example:
1 -> car
2 -> airplane
The problem is when I use "appendRow" (but I don't go in edit mode).
$('#dg').datagrid('appendRow', {
vehicle: 1
}
In this case the formatter is not executed and in the field vehicle i see "1" and not the string "car".
When I use "appendRow" is it possible to add "valueField and textField" of the combobox or to trigger the formatter ?
Thanks
Miche
«
Last Edit: May 19, 2018, 06:07:54 AM by rezzonico
»
Logged
stworthy
Administrator
Hero Member
Posts: 3581
Re: datagrid + formatter + appendRow
«
Reply #1 on:
May 19, 2018, 09:41:48 PM »
The 'formatter' function does execute when calling 'appendRow' method.
Logged
rezzonico
Full Member
Posts: 184
Re: datagrid + formatter + appendRow
«
Reply #2 on:
May 22, 2018, 02:18:55 AM »
It was my error !
Thanks
Miche
Logged
Pages: [
1
]
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General Category
-----------------------------
=> News
=> General Discussion
=> EasyUI for jQuery
=> EasyUI for Angular
=> EasyUI for Vue
=> EasyUI for React
=> Bug Report
Loading...