Results 1 to 2 of 2

Thread: DataView Items + Ext.util.Format.ellipsis (any way to do this?)

  1. #1
    Sencha Premium Member
    Join Date
    Jul 2012
    Posts
    114
    Answers
    5
    Vote Rating
    7
      0  

    Question DataView Items + Ext.util.Format.ellipsis (any way to do this?)

    Is there any way to use Ext.util.Format.ellipsis inline within a DataView template in order to truncate long strings coming in from my store? I need the full string as well as the truncated version, but I don't necessarily want to put the truncated string into my store (if there is a way around it).

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    39,553
    Answers
    3931
    Vote Rating
    1272
      1  

    Default

    You can do something like this in your template:

    Code:
    {[Ext.util.Format.ellipsis(values.foo, 50)]}
    Mitchell Simoens @LikelyMitch
    Sencha Inc, Senior Software Engineer
    ________________
    Learn BBCode and use it! Checkout the CODE tag!

    Check out my GitHub, lots of nice things for Ext JS and Sencha Touch
    https://github.com/mitchellsimoens

Posting Permissions

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