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

Autocomplete Value always undefind

Hallo I will use the autocomplete to Pick data vom a json string. but always the value in the Textbox after Click is "undifind".

Html.EJ()
        .Autocomplete("Antwort")
        .Datasource(d => d.URL(Url.Action("Lookup", "Data"))
        .Adaptor(AdaptorType.UrlAdaptor))
        .Query("ej.Query()")
        .AutocompleteFields(field => field.Key("DataRecord.Id").Text("DataRecord.DisplayName"))
        .Width("300")
        .FilterType(FilterOperatorType.Contains)
        .WatermarkText("CRM Daten")
        .MultiColumnSettings(obj => obj.Enable(true)
                .Columns(obj1 =>
                {
                    obj1.Field("Columns.Name").HeaderText("Entität").Add();
                    obj1.Field("LogicalName").HeaderText("LogischerName").Add();
                })
                .ShowHeader(true)
                )
        .MinCharacter(3)
        .ShowPopupButton(true)
        .MultiSelectMode(MultiSelectModeTypes.None)
        .Render();

Result From Controller:
[
  {
    "DisplayName": "Kundenobjekt",
    "LogicalName": "xxz_standort",
    "Columns": {
      "Objektart": "",
      "Name": "Anmietung Dachstandort Musterhausen - Adlerstraße. 34-36",
      "Ort": "",
      "PLZ": "",
      "Straße 1": ""
    },
    "DataRecord": {
      "Id": "1aef2105-a58c-e711-80eb-3863bb352d80",
      "LogicalName": "xxz_standort",
      "DisplayName": "Anmietung Dachstandort Musterhausen - Adlerstraße. 34-36",
      "RecordLink": "https://xxz.crm4.dynamics.com/main.aspx?etn=xxz_standort&pagetype=entityrecord&id=1aef2105-a58c-e711-80eb-3863bb352d80"
    }
  },
]

a Secend Question
is it Possible the Key set to a string like "DataRecord.LogicalName + ':' + DataRecord.Id"

1 Reply

AP Arun Palaniyandi Syncfusion Team September 6, 2017 11:23 AM UTC

Hi Stephan Thiel,    
    
A support incident to track the status of this defect has been created under your account. Please log on to our support website to check for further updates. 
 
Please let us know if you have any queries. 
 
Regards, 
Arun P. 


Loader.
Up arrow icon