Announcement

Collapse
No announcement yet.

How to clear the "assigned to" relation by default

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

  • How to clear the "assigned to" relation by default

    Is there a way to clear the assigned-to field by default?

    My customer doesn't want the user that creates the record to be assigned by default.

    I tried using workflows, but with no success.

    Thanks!

  • #2
    Hello
    You can configure 'Do not fill Assigned User if not required' In User Preferences.
    or set in worflow action Update Entity and set in formula
    Code:
    assignedUserId=null;
    assignedUserName='';

    Comment


    • #3
      Cool,

      Is there a way to use a formula to assign to the current user? (I want to do this in case of a certain status)

      Comment


      • #5
        Thanks for your help, I found that, and used:

        assignedUserId=env\userAttribute('id');
        assignedUserName=env\userAttribute('name');

        or

        assignedUserId=env\userAttribute('UserId');
        assignedUserName=env\userAttribute('UserName');


        But with no success yet.

        Is the syntax correct?

        What a powerful option!!

        Comment


        • #6
          first one works for me
          check the condition

          Comment


          • #7
            Works indeed... Thanks Tanya!

            Comment


            • #8
              Yes you can set in worflow action Update Entity and set in formula.

              Comment


              • #9
                How do you set "Do not fill Assigned User if not required" for every user by default?

                Comment


                • #10
                  Adding

                  Code:
                  "default": true
                  to

                  Code:
                  application\Espo\Resources\metadata\entityDefs\Preferences.json
                  used to work, but it no longer does:

                  Code:
                  "doNotFillAssignedUserIfNotRequired": {
                      "type": "bool"
                      "default": true
                  },

                  Comment


                  • #11
                    Hello

                    You did right thing, but in not upgrade safe way. Also you lost comma. But it will work only for new users

                    Comment


                    • #12
                      Originally posted by tanya View Post
                      Hello

                      You did right thing, but in not upgrade safe way. Also you lost comma. But it will work only for new users
                      So is there not a way to do it with a setting for every user by default? Do I have to use a workflow?

                      Comment


                      • #13
                        It set this field by default. But, for active users, preferences were created with old default value. An administrator can change preferences for each user. For new ones this preference will be set in True
                        Workflows are triggered after save (notifications could be created), Formula is triggered before save. But needs to check the order of auto-fill functionality and formula: what runs the last

                        Comment

                        Working...
                        X