Announcement

Collapse
No announcement yet.

Entity - Multiple Assigned users

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

  • Entity - Multiple Assigned users

    I found this in the forum https://github.com/espocrm/documenta...igned-users.md

    It worked great however the newly created field "assignedUsers" is not visible in multiple areas to be selected from such as "Layout Manager" for Entity "Lead", under any of the sections such as List, Detail, Mass Update, Etc. in either the Enabled or Disabled Columns to choose from.

    How can I get this to show properly in the list of available fields to choose from?
    Last edited by khopper; 10-15-2018, 03:54 PM. Reason: Multiple

  • #2
    Hi,

    You can find this field in metadata entityDefs in custom dir and remove parameters layoutDetailDisabled, layoutMassUpdateDisabled.

    On List and Filters it should be already available.

    Comment


    • #3
      I changed the file /custom/Espo/Custom/Resources/metadata/entityDefs/Lead.json
      And it had no effect, "assignedUsers" is still not available even after clearing cache and Rebuilding the Backend.

      Before:
      Code:
          "fields": {
              "assignedUsers": {
                  "type": "linkMultiple",
                  "layoutDetailDisabled": true,
                  "layoutMassUpdateDisabled": true,
                  "importDisabled": true,
                  "noLoad": true,
                  "isCustom": true
              }
      After:
      Code:
          "fields": {
              "assignedUsers": {
                  "type": "linkMultiple",
                  "importDisabled": true,
                  "noLoad": true,
                  "isCustom": true
              }

      Comment


      • #4
        I've got Assigned Users field available in every layout on the latest EspoCRM version.

        Comment


        • #5
          The version I was testing on is 5.4.0 - would the cause an issue? (I see it was implemented in 5.2.0 per the link)
          This is what I see when selecting fields in layout manager.
          Attached Files
          Last edited by khopper; 10-15-2018, 07:25 PM.

          Comment


          • #6
            did you clear the cache in Administration?

            Comment


            • khopper
              khopper commented
              Editing a comment
              Yes I have, that was mentioned in post # 3.

          • #7
            I can't reproduce it as well. Tested on 5.4.3 and on 5.2.3
            Is your json valid after modification?

            Comment


            • #8
              Does this Code look Valid for the json file?

              Code:
              "fields": { "assignedUsers": { "type": "linkMultiple", "layoutDetailDisabled": true, "layoutMassUpdateDisabled": true, "importDisabled": true, "noLoad": true, "isCustom": true }
              After:
              Code:
              "fields": { "assignedUsers": { "type": "linkMultiple", "importDisabled": true, "noLoad": true, "isCustom": true }

              Comment


              • #9
                this is full content of my file custom/Espo/Custom/Resources/metadata/entityDefs/Lead.php
                Code:
                {
                    "fields": {
                        "assignedUsers": {
                            "type": "linkMultiple",
                            "layoutDetailDisabled": false,
                            "layoutListDisabled": false,
                            "layoutMassUpdateDisabled": false,
                            "importDisabled": false,
                            "noLoad": false,
                            "isCustom": true
                        }
                    },
                    "links": {
                        "assignedUsers": {
                            "type": "hasMany",
                            "relationName": "leadUser",
                            "foreign": "assignedLeads",
                            "entity": "User",
                            "audited": false,
                            "isCustom": true
                        }
                    }
                }
                and it works.

                "layoutDetailDisabled": false, is the same as lack of this string.

                DIdn't you modify core code?

                And check in data/cache/application/metadata.php, whether your updates applied.

                Comment


                • #10
                  My mistake - I was looking for the wrong field name, I apologize for the confusion.
                  By default it was named "Users", not "Assigned Users".
                  Thank you for your patience and assistance!

                  Comment

                  Working...
                  X