Announcement

Collapse
No announcement yet.

Hidden Link

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

  • Hidden Link

    tanya I have a problem with a related link which is hidden in the "detail" layout between two entities and this is its metdata/entityDefs/Account.json

    "contact": {
    "type": "link"
    },
    how can I show the hidden link. I added a text between the <a></a> tags and its run successfully, but how can I make it dynamic?

  • #2
    Hello
    It depends on how do you hide this field.
    Could you explain better?

    Comment


    • DevMostafa
      DevMostafa commented
      Editing a comment
      This is my entityDefs file
      \www\espocrm\custom\Espo\Custom\Resources\metadata \entityDefs

      {
      "fields": {
      "name": {
      "type": "personName"
      },
      "salutationName": {
      "type": "enum",
      "options": [
      "",
      "Mr.",
      "Mrs.",
      "Ms.",
      "Dr."
      ]
      },
      "firstName": {
      "type": "varchar",
      "maxLength": 100,
      "default": ""
      },
      "lastName": {
      "type": "varchar",
      "maxLength": 100,
      "required": true,
      "default": ""
      },
      "description": {
      "type": "text"
      },
      "emailAddress": {
      "type": "email"
      },
      "phoneNumber": {
      "type": "phone",
      "typeList": [
      "Mobile",
      "Office",
      "Home",
      "Fax",
      "Other"
      ],
      "defaultType": "Mobile"
      },
      "address": {
      "type": "address"
      },
      "addressStreet": {
      "type": "text",
      "maxLength": 255,
      "dbType": "varchar"
      },
      "addressCity": {
      "type": "varchar"
      },
      "addressState": {
      "type": "varchar"
      },
      "addressCountry": {
      "type": "varchar"
      },
      "addressPostalCode": {
      "type": "varchar"
      },
      "createdAt": {
      "type": "datetime",
      "readOnly": true
      },
      "modifiedAt": {
      "type": "datetime",
      "readOnly": true
      },
      "createdBy": {
      "type": "link",
      "readOnly": true,
      "view": "views/fields/user"
      },
      "modifiedBy": {
      "type": "link",
      "readOnly": true,
      "view": "views/fields/user"
      },
      "assignedUser": {
      "type": "link",
      "required": false,
      "view": "views/fields/assigned-user"
      },
      "teams": {
      "type": "linkMultiple",
      "view": "views/fields/teams"
      },
      "bAccountManagerId": {
      "type": "int",
      "required": false,
      "audited": true,
      "disableFormatting": false,
      "isCustom": true
      },
      "bCustomerAccountId": {
      "type": "varchar",
      "required": false,
      "trim": true,
      "audited": false,
      "isCustom": true
      },
      "contact": {
      "type": "link"
      },
      "account": {
      "type": "link"
      },
      "bClientTypeId": {
      "type": "int",
      "required": false,
      "audited": true,
      "disableFormatting": false,
      "isCustom": true
      },
      "segment": {
      "type": "link"
      },
      "cashTransfers": {
      "type": "linkMultiple",
      "layoutDetailDisabled": false,
      "layoutListDisabled": true,
      "layoutMassUpdateDisabled": false,
      "noLoad": false,
      "importDisabled": false,
      "isCustom": true
      },
      "arabicName": {
      "type": "varchar",
      "required": false,
      "trim": true,
      "audited": true,
      "isCustom": true
      }
      },
      "links": {
      "createdBy": {
      "type": "belongsTo",
      "entity": "User"
      },
      "modifiedBy": {
      "type": "belongsTo",
      "entity": "User"
      },
      "assignedUser": {
      "type": "belongsTo",
      "entity": "User"
      },
      "teams": {
      "type": "hasMany",
      "entity": "Team",
      "relationName": "EntityTeam",
      "layoutRelationshipsDisabled": true
      },
      "contact": {
      "type": "belongsTo",
      "foreign": "brokerageAccounts",
      "entity": "Contact",
      "isCustom": true
      },
      "account": {
      "type": "belongsTo",
      "foreign": "brokerageAccounts",
      "entity": "Account",
      "isCustom": true
      },
      "segment": {
      "type": "belongsTo",
      "foreign": "brokerageAccounts",
      "entity": "Segment",
      "isCustom": true
      },
      "cashTransfers": {
      "type": "hasMany",
      "foreign": "brokerageAccount",
      "entity": "CashTransfers",
      "isCustom": true
      }
      },
      "collection": {
      "sortBy": "createdAt",
      "asc": false,
      "textFilterFields": [
      "name",
      "lastName",
      "bCustomerAccountId",
      "arabicName"
      ]
      },
      "indexes": {
      "firstName": {
      "columns": [
      "firstName",
      "deleted"
      ]
      },
      "name": {
      "columns": [
      "firstName",
      "lastName"
      ]
      },
      "assignedUser": {
      "columns": [
      "assignedUserId",
      "deleted"
      ]
      }
      }
      }


      The contact link only has the hidden property and I didn't know. This file is auto-generated from EspoCRM after defining the entity fields

  • #3
    contact field has default link view, so it hasn't be hidden. Did you add this field on the layout?

    Comment


    • DevMostafa
      DevMostafa commented
      Editing a comment
      Yes, I added it in the details and list view

  • #4
    Could be this field hidden with Dynamic Logic of some field?

    Comment


    • DevMostafa
      DevMostafa commented
      Editing a comment
      NO, I checked my custom/entity and client/custom files and didn't find any dynamic logic to make this field hidden.

    • tanya
      tanya commented
      Editing a comment
      you need to look for here custom/Espo/Custom/Resources/metadata/clientDefs/Account.json

    • DevMostafa
      DevMostafa commented
      Editing a comment
      I had this code & think there's no fault

      {
      "controller": "custom:controllers/Account",
      "views": {
      "detail": "custom:views/Account/detail"
      },

      "recordViews": {

      "detail": "custom:views/Account/record/detail"

      }



      }

  • #5
    attach custom:views/Account/detail and custom:views/Account/record/detail

    Comment


    • #6
      this is the Account client files
      Attached Files

      Comment


      • #7
        This is what I'm talking to you about
        Attached Files

        Comment


        • #8
          Show me brokerage account view... seems you don't set the field 'Name'

          Comment


          • DevMostafa
            DevMostafa commented
            Editing a comment
            It's existed already, but thanks tanya for your help.
            I've managed a workaround to solve it.
        Working...
        X