Announcement

Collapse
No announcement yet.

Do not display certain items in target lists

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

  • Do not display certain items in target lists

    How do I get the following areas hidden? See the pictures in the appendix, the areas marked in red. They shouldn't be displayed. It's about the target lists. For contacts, companies and so on, I can hide this in sidebar details. How do I do this here?

  • #2
    Hello. For Target List You need:
    1. Create the file /custom/Espo/Custom/Resources/metadata/scopes/TargetList.json with code as follows:
    Code:
    {"layouts": true}
    2. Administration -> Clear cache
    3. Refresh a webpage
    4. Administration -> Layout Manager -> Target List ->:
    - Bottom panels -> set dynamic conditions for the subpanels to hide them or just remove them from the layout
    - Side Panels (detail) -> set dynamic conditions for the Opted Out field to hide it or just remove it from the layout
    - Side Panel Field -> set dynamic conditions for the Assigned user field to hide it or just remove it from the layout

    Read more about the dynamic conditions https://docs.espocrm.com/administration/dynamic-logic/

    Cange menu or hide it on the Campaigns list view requires more complex code customization.

    Comment


    • #3

      Hello Maximus,

      great, thank you, it worked. Is there maybe a solution for picture 1? The hiding of mass emails, email templates, tracking URLs?

      Regards

      Comment


      • #4
        Hi. Unfortunately, I don't know how to hide it.
        telecastg could you help here, please?

        Comment


        • #5
          Hello Maximus and RSGRG I have not made this modification in our system but this is how I would do it:

          1) Create file custom/Espo/Custom/Resources/metadata/clientDefs/Campaign.json to modify the original clientDefs eliminating the dropdown elements
          Code:
          {
              "menu": {
                  "list": {
                      "buttons": [                 
                          {
                              "label": "Target Lists",
                              "link": "#TargetList",
                              "acl": "read",
                              "style": "default",
                              "aclScope": "TargetList"
                         }
                      ]
                  }
              }
          }
          2) Clear cache and rebuild

          Comment


          • #6
            Hello Maximus and telecastg,
            unfortunately that didn't work. The Campaign.json file already existed in the path custom/Espo/Custom/Resources/metadata/clientDefs/. And the following code was already in the file:
            Code:
            {
            "kanbanViewMode": false,
            "iconClass": "fas fa-chart-line"
            }
            I took this code out and replaced it with the code from @telegast. Unfortunately, the entries are still displayed to me. I also tried to replace the two characters: [ ] with this one { }. But that didn't help either.

            Comment


            • #7
              Here's how I did this:
              Click image for larger version  Name:	Campaign modification.JPG Views:	0 Size:	32.0 KB ID:	73713
              custom/Custom/Espo/Resources/metadata/clientDefs/Campaign.json
              Code:
              {
                  "menu": {
                      "list": {
                          "buttons": [
                              {
                                  "label": "Target Lists",
                                  "link": "#TargetList",
                                  "acl": "read",
                                  "style": "default",
                                  "aclScope": "TargetList"
                              }
                          ],
                          "dropdown": [
                          ]
                      }
                  },
                  "boolFilterList": ["onlyMy"],
                  "iconClass": "fas fa-chart-line"
              }
              Administration > Rebuild

              Reload page
              Attached Files

              Comment


              • #8
                Hello @telecastg,

                with this code it worked now. Super thank you.

                Comment


                • telecastg
                  telecastg commented
                  Editing a comment
                  You're very welcome

              • #9
                telecastg, thank you!

                Comment


                • telecastg
                  telecastg commented
                  Editing a comment
                  Always glad to help a fellow participant that helps many others Maximus
              Working...
              X