<c1-auto-complete> not displaying the display-member-paty

Posted by: sebastian73 on 19 March 2021, 2:07 am EST

    • Post Options:
    • Link

    Posted 19 March 2021, 2:07 am EST

    Hi!

    I’m using the auto complete control in an asp.net core 3.1 project, and when the page displays, it fails to show de value into the display-member-path, it shows the value in the “EnvioId” field from the model.

    The following code shows how I implemented the control in the view.

    When it displays, it shows “0”, the id default value, if a value is selected and I reload the view with data, it shows the number, but never de value stores in display member path until I manually select it.

     
    <c1-auto-complete for="EnvioId" display-member-path="Descripcion" selected-value-path="EnvioId" css-match="highlight" class="form-control" id="cboEnvios">
                                <c1-items-source source-collection="Model.Envios"></c1-items-source>
                            </c1-auto-complete>
    
    

    If I press the pulldown button or type some text it shows the data and work normally. But if the form reload, it continue to show the Id value instead of the text.

    Any suggestion how to solve it?

    Thanks in advance!

  • Posted 21 March 2021, 7:12 pm EST

    Hi,

    We are able to replicate the issue at our end and it seems a Bug. Hence, we have forwarded this to the concerned team for further investigation with the internal tracking id C1Web-28001.

    Further, the issue will not occur if the is-editable is set to false for the Control. If you would like to set the isEditable to true. Please refer to the attached sample for the workaround.

    Regards,

    Manish Gupta

    AutoCompleteFor_ArrayOfList_wrokaround.zip

  • Posted 30 March 2021, 7:14 am EST

    Hi Manish!

    Thanks for your replay.

    Unfortunately I was unable to make it work in my project, but I noticed that, if instead of sending a complex object to the control I send an object of the type SelectList, it works fine.

    Regards,

    Sebastian.

  • Posted 30 March 2021, 4:52 pm EST

    Hi,

    We are glad to know that the SelectList works for you.

    Could you please add the provided workaround before the control initialization since this workaround works on the control prototype? That is why it is required to add this workaround script at the start of the page.

    If the issue persists, please share the demo sample depicting the issue.

    Regards,

    Manish Gupta

  • Posted 7 July 2021, 6:48 pm EST

    Looks like a bug. Have you resolved it?

  • Posted 9 July 2021, 4:31 am EST

    Hi,

    This issue will be fixed in our next release 2020v2. Thank you for your patience.

    Regards,

    Manish Gupta

  • Posted 23 November 2022, 10:58 pm EST

    I am also facing the same issue. But it is not a bug issue.

  • Posted 27 November 2022, 3:24 pm EST

    Hi,

    Please use the latest version 2022v2. This issue has been verified as fixed with the latest version.

    Regards,

    Manish Gupta

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels