No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    QTable format date and number

    Framework
    2
    3
    2013
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • P
      Pedro last edited by

      I need to format table columns values like ths :

      data_entrada -> “dd-mm-yyyy”
      valor_entrada -> 12.345,66

      I didn’t find a working example of that.
      Somebody can ahow me an example of how to achieve this ?

      Tks

      1 Reply Last reply Reply Quote 0
      • P
        Pedro last edited by

        I had success formatting the date width the excelent Quasar Date Utils
        format: val => date.formatDate(val, ‘DD-MM-YYYY’) (*)

        the number, I’m not sure if it’s the best way of doing it, but it works
        format: val => parseFloat(val).toLocaleString(‘pt-br’, { minimumFractionDigits: 2, maximumFractionDigits: 2 })

        • needs to import
          import { date } from ‘quasar’

        I solved my problem but leave this post for anybody who has the same problem

        Tks

        metalsadman 1 Reply Last reply Reply Quote 0
        • metalsadman
          metalsadman @Pedro last edited by

          @Pedro good solving it on your own, docs is a gold mine, just need some diligent reading :). thanks for sharing.

          1 Reply Last reply Reply Quote 0
          • First post
            Last post