Announcement

Collapse
No announcement yet.

How to add duration field to new entity

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to add duration field to new entity

    Hi,

    I want to add duration field to new entity.

    Eg: For case i need to add duration field. How can I add it ??
    Cheers!
    Nishan.

  • #2
    Hi,

    I found a way to sort this. Please let me know if im wrong.

    Path - client/custom/src/views/fields/Case.json

    Code:
    "duration": {
                "type": "duration",
                "start": "dateStart",
                "end": "dateEnd",
                "options": [300, 600, 900, 1800, 2700, 3600, 7200],
                "default": 300,
                "notStorable": true,
                "select": "TIMESTAMPDIFF(SECOND, call.date_start, call.date_end)",
                "orderBy": "duration {direction}"
    }
    and rebuild. Now its appear in field and layout. Please check and let me know if im wrong.
    Cheers!
    Nishan.

    Comment


    • #3
      Hello,

      Change 'call' to 'case'.

      "select": "TIMESTAMPDIFF(SECOND, `case`.date_start, `case`.date_end)"

      Comment


      • #4
        Originally posted by yurikuzn View Post
        Hello,

        Change 'call' to 'case'.

        "select": "TIMESTAMPDIFF(SECOND, `case`.date_start, `case`.date_end)"
        Hi Yuri, Thank you so much.
        Cheers!
        Nishan.

        Comment


        • #5
          Here is the previous post for the same with better explanation

          Cheers!
          Nishan.

          Comment

          Working...
          X