Results 1 to 5 of 5

Thread: Tagfield: edit record value with tagfield

  1. #1
    Sencha Premium User
    Join Date
    Jul 2014
    Posts
    269
    Answers
    15

    Default Answered: Tagfield: edit record value with tagfield

    Hi!

    I want to edit a record.
    For this purpose I use a form that loads a record from a grid row.
    This form consists of several fields, including combobox and tagfield.

    When I intend to edit a value sent by the server, in a combobox, I do as follows (I am not sure if it is the correct way to do this):

    I use a combobox like when I want add a new record, since I will need the combobox list items to edit the value sent by the server.

    The parameter sent by the server is inserted into the 'name' config (value is displayed in the combobox when the form is loaded)

    Code:
    //seems to work
    xtype:'combobox',
    name:'valuetoedit', //value == Alabama
    fieldLabel:'Choose State',    
    store: states,    
    queryMode:'local',    
    displayField:'name',    
    valueField:'abbr',
    
    It seems to work in the combobox, but when I intend to do the same at tagfield does not work: the value is not displayed in tagfield when the form is loaded, and I get this TypeError:

    Code:
    TypeError: val is undefined
    if(val.isModel){
    this error happens when I add tagfield config name:'valuetoedit',

    Code:
    xtype:'tagfield',
    name:'valuetoedit', //value == Alabama
    fieldLabel:'Choose State',    
    store: states,    
    queryMode:'local',    
    displayField:'name',    
    valueField:'abbr',
    
    How do I edit a value in a tagfield?

    Thanks in advance.

  2. Looks like there's a bug in play:
    http://www.sencha.com/forum/showthread.php?289852

  3. #2
    Sencha User
    Join Date
    Feb 2013
    Location
    California
    Posts
    11,985
    Answers
    506

    Default

    Looks like there's a bug in play:
    http://www.sencha.com/forum/showthread.php?289852

  4. #3
    Sencha Premium User
    Join Date
    Jul 2014
    Posts
    269
    Answers
    15

    Default

    Thanks Gary.

  5. #4
    Sencha Premium User
    Join Date
    Mar 2011
    Posts
    287
    Answers
    35

  6. #5
    Sencha Premium User
    Join Date
    Jul 2014
    Posts
    269
    Answers
    15

    Default

    Thanks chamacs.

    Quote Originally Posted by chamacs View Post

Similar Threads

  1. [CLOSED] Tagfield bugs
    By jonw in forum Ext 5: Bugs
    Replies: 6
    Last Post: 29 Sep 2015, 8:22 AM
  2. [FIXED] Tagfield remove bug
    By kszmetena in forum Ext 5: Bugs
    Replies: 2
    Last Post: 23 Mar 2015, 7:29 AM
  3. [FIXED] tagfield bind value
    By vbueb in forum Ext 5: Bugs
    Replies: 5
    Last Post: 14 Sep 2014, 7:51 AM
  4. tagfield + treestore
    By tomasz.mysliwiec in forum Ext 5: Q&A
    Replies: 1
    Last Post: 9 Sep 2014, 9:42 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •