Announcement

Collapse
No announcement yet.

No fields emailAddress and phoneNumber in Basis-type entity

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

  • No fields emailAddress and phoneNumber in Basis-type entity

    entity PERSONEN (people) - type person
    ​entity KONTAKTE - type basis (all kinds of calls, meetings, emails, letter-post ...) with relationships to FIRMEN (companies) and PERSONEN (people)
    there is a n:1 relationship between KONTAKTE and PERSONEN (I've also tried n:n)
    I want to show eMail-address and phone-numers of a linked PERSONEN to KONAKTE in the KONTAKTE-side-Panel - but there are no fields emailaddress and phonenumer for layout (and also I can't print it out.

    I know, that neither emailaddress nor phonenumer are fields of the tables PERSONEN, they are "outsourced" to own tables.
    There is no possibility to make own relationships to these tables.
    How can I "go" from KONTAKTE to emailaddress (and phonenumer) from PERSONEN?

    Christoph

  • #2
    solution (found latenight anywhere in forum);
    • add fields in custom/Espo/custom/Resources/metadata/entityDefs/<your entity>.json
      • the easy-way to copy code is:
      • create (temporary) a new entity with type person - for example people
      • in custom/Espo/custom/Resources/metadata/entityDefs/people.json you'll find both fields-code
    • administration rebuild system
    • if emailAdress and/or phoneNumbers are linked fields in reallity from another entity (it's not possible to build this fields as linked-fields), add formular to fill these fields with the content of the linked field in your entity like:
    if (<linked-entity>.emailAdress != null) {
    <entity>.emailAddress = <linked-entity>emailAddress;
    };
    Christoph
    Last edited by ctheuring; 12-02-2023, 02:49 PM.

    Comment

    Working...
    X