We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Cell dropdown displaying model value!!

Thread ID:





150852 Jan 21,2020 10:10 PM UTC Jan 24,2020 04:02 AM UTC JavaScript - EJ 2 0
Tags: Grid
Humanjo Daro
Asked On January 24, 2020 04:02 AM UTC

I have a grid bound to a local list of JS objects.
One of the grid cells is defined to be a dropDown list which is bound to another local list of JS object. The object is mapped to this C# class:

class Tax
int id {set;get;}
string name{set;get;} routerlogin
When the grid is displayed and not in edit mode, i expect it to show the tax value as a string representing the name of the tax (ex: Local, Export ...), but i am getting the id of the tax displayed instade.
Here is how i define the dropdown: whatsapp web

List ctries = CrescendoPMS.Models.Country.Get(); // This is for showing purpose only, in reality, the controller is getting the values from the model class
var dropDown = new Syncfusion.EJ2.DropDowns.DropDownList()
DataSource = ctries,
Query = "new ej.data.Query()",
Fields = new Syncfusion.EJ2.DropDowns.DropDownListFieldSettings { Value = "id", Text = "name" },

and in the grid i have this:
col.Field(nameof(CrescendoPMS_BL.Models.invoice_line.tax_id)).EditType("dropdownedit").Edit(new { @params = dropDown }).HeaderText("Tax").Add();


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon