OBJECT Page 1070 MS - PayPal Standard Setup
{
  OBJECT-PROPERTIES
  {
    Date=;
    Time=;
    Version List=;
  }
  PROPERTIES
  {
    CaptionML=ENU=PayPal Payments Standard Setup;
    InsertAllowed=No;
    SourceTable=Table1070;
    DataCaptionExpr=Description;
    PageType=Card;
    OnOpenPage=VAR
                 MSPayPalStandardMgt@1000 : Codeunit 1070;
               BEGIN
                 MSPayPalStandardMgt.GetTemplate(MSPayPalStandardTemplate);
                 MSPayPalStandardTemplate.RefreshLogoIfNeeded;
               END;

    OnQueryClosePage=BEGIN
                       IF NOT Enabled THEN
                         IF NOT CONFIRM(STRSUBSTNO(EnableServiceQst,CurrPage.CAPTION),TRUE) THEN
                           EXIT(FALSE);
                     END;

    OnAfterGetCurrRecord=BEGIN
                           TargetURL := GetTargetURL;
                         END;

    ActionList=ACTIONS
    {
      { 10      ;    ;ActionContainer;
                      ActionContainerType=NewDocumentItems }
      { 11      ;1   ;Action    ;
                      Name=SetupTemplate;
                      CaptionML=ENU=Setup Template;
                      ToolTipML=ENU=Opens Template Setup for all PayPal accounts.;
                      ApplicationArea=#Basic,#Suite;
                      RunObject=Page 1071;
                      RunPageOnRec=No;
                      PromotedIsBig=Yes;
                      Image=Setup;
                      PromotedCategory=Process }
      { 14      ;1   ;Action    ;
                      Name=ActivityLog;
                      CaptionML=ENU=Activity Log;
                      ToolTipML=ENU=Log listing events for this PayPal account.;
                      ApplicationArea=#Basic,#Suite;
                      Image=Log;
                      OnAction=VAR
                                 MSPayPalStandardTemplate@1000 : Record 1071;
                                 ActivityLog@1002 : Record 710;
                                 MSPayPalStandardMgt@1001 : Codeunit 1070;
                               BEGIN
                                 MSPayPalStandardMgt.GetTemplate(MSPayPalStandardTemplate);
                                 ActivityLog.ShowEntries(MSPayPalStandardTemplate);
                               END;
                                }
    }
  }
  CONTROLS
  {
    { 1   ;0   ;Container ;
                ContainerType=ContentArea }

    { 2   ;1   ;Group     ;
                CaptionML=ENU=General;
                GroupType=Group }

    { 13  ;2   ;Group     ;
                GroupType=Group }

    { 8   ;3   ;Field     ;
                ToolTipML=ENU=Specifies the name of the PayPal account.;
                ApplicationArea=#Basic,#Suite;
                SourceExpr=Name }

    { 7   ;3   ;Field     ;
                ToolTipML=ENU=Specifies description for what this PayPal account is being used for.;
                ApplicationArea=#Basic,#Suite;
                SourceExpr=Description }

    { 3   ;3   ;Field     ;
                ToolTipML=ENU=Specifies the email or the Merchant account ID of the PayPal account;
                ApplicationArea=#Basic,#Suite;
                SourceExpr="Account ID";
                ShowMandatory=TRUE }

    { 4   ;3   ;Field     ;
                ToolTipML=ENU=Specifies if the payment service is enabled.;
                ApplicationArea=#Basic,#Suite;
                SourceExpr=Enabled }

    { 5   ;3   ;Field     ;
                ToolTipML=ENU=Specifies if this PayPal account should be included on all of the Documents by default.;
                ApplicationArea=#Basic,#Suite;
                SourceExpr="Always Include on Documents" }

    { 9   ;2   ;Field     ;
                Name=Logo;
                CaptionML=ENU=Logo;
                ToolTipML=ENU=Specifies Logo that should be included for this account on all invoices.;
                ApplicationArea=#Basic,#Suite;
                SourceExpr=MSPayPalStandardTemplate.Logo }

    { 12  ;2   ;Field     ;
                Name=TargetURL;
                CaptionML=ENU=Target URL;
                ToolTipML=ENU=Specifies the target URL that will be opened when the customer chooses the link on the invoice.;
                ApplicationArea=#Basic,#Suite;
                SourceExpr=TargetURL;
                Importance=Additional;
                MultiLine=Yes;
                OnValidate=VAR
                             MSPayPalStandardMgt@1000 : Codeunit 1070;
                           BEGIN
                             MSPayPalStandardMgt.ValidateChangeTargetURL;
                             SetTargetURL(TargetURL);
                           END;
                            }

    { 6   ;2   ;Field     ;
                ToolTipML=ENU=Specifies PayPal terms of service.;
                ApplicationArea=#Basic,#Suite;
                SourceExpr="Terms of Service";
                Editable=TermsOfServiceEditable;
                OnDrillDown=BEGIN
                              HYPERLINK("Terms of Service");
                            END;

                OnAssistEdit=BEGIN
                               TermsOfServiceEditable := NOT TermsOfServiceEditable;
                             END;
                              }

  }
  CODE
  {
    VAR
      MSPayPalStandardTemplate@1002 : Record 1071;
      TargetURL@1001 : Text;
      TermsOfServiceEditable@1003 : Boolean;
      EnableServiceQst@1004 : TextConst '@@@="%1 = pagecaption (OCR Service Setup)";ENU=The %1 is not enabled. Are you sure you want to exit?';

    BEGIN
    END.
  }
}

