Workday definition for Calls

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tothewine
    Active Community Member
    • Jan 2018
    • 373

    Workday definition for Calls

    I would likes some option to prevent users from scheduling calls on saturday or sunday.
  • tanya
    Senior Member
    • Jun 2014
    • 4308

    #2
    hello,
    workflow triggers actions after record saved, so in workflow you can only reschedule the call, to the one of next working day.
    If you want to prevent creation, you can create a beforeSave hook and throws error, if date start or date end is the weekend

    Comment

    • tothewine
      Active Community Member
      • Jan 2018
      • 373

      #3
      Is there a way to do client form validation from the server hook? For example what kind of error should be thrown in order to make the client highlight wrong fields in the creation form? If not implemented I would like to suggest that as a feature request. For now I think I will probably reschedule from a workflow.

      Comment

      • tanya
        Senior Member
        • Jun 2014
        • 4308

        #4
        Yes, if you set view for these date fields (dateStart and dateEnd), you can add own validation

        Comment

        • tothewine
          Active Community Member
          • Jan 2018
          • 373

          #5
          Ok. I will try that too.

          Now I want also to customize/extend popup notifications for calls but popups are not a specific entity...
          What is the correct path for setting custom call notification popups view?
          custom/Espo/Custom/Resources/metadata/clientDefs/YourEntityType.json
          Last edited by tothewine; 01-15-2019, 04:26 PM.

          Comment

          • tanya
            Senior Member
            • Jun 2014
            • 4308

            #6
            original https://github.com/espocrm/espocrm/b...fications.json
            custom custom/Espo/Custom/Resources/metadata/app/popupNotifications.json

            Comment

            • tothewine
              Active Community Member
              • Jan 2018
              • 373

              #7
              Thanks I will use that

              Comment

              • tothewine
                Active Community Member
                • Jan 2018
                • 373

                #8
                I created custom/Espo/Custom/Resources/metadata/app/popupNotifications.json now I copy the existing "crm:views/meeting/popup-notification" from "\client\modules\crm\src\views\meeting\popup-notification.js" to "/client/custom/src/views/popup-notification.js". Is the path for the custom view correct?

                More importantly I am not sure what the Espo.Define line should be for the extended custom popup notification.

                This is the current one:
                Espo.define('crm:views/meeting/popup-notification', 'views/popup-notification', function (Dep) {

                What do I put in there?
                Last edited by tothewine; 01-17-2019, 08:16 PM.

                Comment

                Working...