Note entity in Sandbox

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Enju
    Senior Member
    • Apr 2018
    • 128

    Note entity in Sandbox

    Hello,
    is possible to test formula for Note entity in Sandbox?
  • Jakub Grufik
    Senior Member
    • Aug 2022
    • 361

    #2
    Hello what do you mean by "Note entity" I do not see the type of entity "Note"

    Comment


    • rabii
      rabii commented
      Editing a comment
      Note is represented in the system as stream / post.

    • Jakub Grufik
      Jakub Grufik commented
      Editing a comment
      aha, thanks for the clarification
  • rabii
    Active Community Member
    • Jun 2016
    • 1250

    #3
    Originally posted by Enju
    Hello,
    is possible to test formula for Note entity in Sandbox?
    No not possible.
    Rabii
    Web Dev

    Comment

    • Kharg
      Senior Member
      • Jun 2021
      • 410

      #4
      You actually have 2 options

      (not recommend)
      Create a new file in Custom\Resources\metadata\scopes

      Note.json
      PHP Code:
      {
      "object": true
      }
      then rebuild and will you have the note entity selectable in the formula sandbox.

      Or just use the browser inspect element to change the data-value of another entity to "Note".

      Comment

      • yuri
        Member
        • Mar 2014
        • 8453

        #5
        I don't remember any place in Espo that allows applying a formula script to an existing note entity. Maybe you don't need it? You can utilize record\ functions.
        If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.

        Comment

        • item
          Active Community Member
          • Mar 2017
          • 1476

          #6
          Hello,
          Note entity is very usefull for us for send Sms.
          Just a idea .. very simple

          PHP Code:
          if ( $entity->isNew() && substr($entity->get('post'), 0, 4) == '#Sms' )
                  {
                      $parentEntity = $this->em->getRDBRepository($entity->get('parentType'))
                              ->where([
                                  'id' => $entity->get('parentId'),
                              ])
                              ->findOne();
                      $toNumber = $parentEntity->get('phoneNumber');
                      $sms = $this->createSms($this->user, $entity->get('post'), $toNumber);
                      $this->smsSender->send($sms);
          
                  }
          If you could give the project a star on GitHub. EspoCrm believe our work truly deserves more recognition. Thanks.​

          Comment

          Working...