Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Polish

Serwis MessageService pozwala na wyświetlanie animowanych komunikatów dla użytkownika formularza. Posiada następujące funkcje:

  • show - pokazuje podstawową wiadomość w formie animowanego dymka u góry ekranu, treść i tło są szare.
    • Parametry funkcji

      NazwaTyp

      Wartość domyślna

      Opis
      msgString'Info'Treść wiadomości
      conf (od 3.1.18)Object{}Konfiguracja okna wiadomości.

          - hideAfter (Typ Number)

              Czas (w milisekundach) po jakim ma zniknąć wiadomość (domyślnie: 3000).
        Czas ten musi być liczba dodatnią. Jeżeli podana zostanie wartość 0 to parametr przyjmie wartość domyślną.


    • Rezultat funkcji: brak

 

  • showSuccess - pokazuje wiadomość  w formie animowanego dymka u góry ekranu informującą o sukcesie, treść i tło są zielone.
    • Parametry funkcji

      NazwaTyp

      Wartość domyślna

      Opis
      msgString'Ok'Treść wiadomości
      conf (od 3.1.18)Object{}Konfiguracja okna wiadomości.

          - hideAfter (Typ Number)

              Czas (w milisekundach) po jakim ma zniknąć wiadomość (domyślnie: 3000).
        Czas ten musi być liczba dodatnią. Jeżeli podana zostanie wartość 0 to parametr przyjmie wartość domyślną.


    • Rezultat funkcji: brak

 

  • showFailure - pokazuje wiadomość  w formie animowanego dymka u góry ekranu informującą o sukcesie, treść i tło są czerwone.
    • Parametry funkcji

      NazwaTyp

      Wartość domyślna

      Opis
      titleString'Error'Treść wiadomości
      conf (od 3.1.18)Object{}Konfiguracja okna wiadomości.

          - hideAfter (Typ Number)

              Czas (w milisekundach) po jakim ma zniknąć wiadomość (domyślnie: 3000).
        Czas ten musi być liczba dodatnią. Jeżeli podana zostanie wartość 0 to parametr przyjmie wartość domyślną.

    • Rezultat funkcji: brak



     

  • showConfirm - wyświetla okno z wiadomością umożliwiające wybranie opcji Tak lub Nie.

    • Parametry funkcji

      NazwaTyp

      Wartość domyślna

      Opis
      configObject{ }

      Konfiguracja okna wiadomości. Obiekt posiada następujące właściwości:

          - title (Typ String)

              Tytuł okna (domyślnie: '')

          - message (Typ String)

              Treść wiadomości (domyślnie: '')

          - scope (Typ Object)

              Scope dla opcjonalnych funkcji wykonywanych po kliknięciu przycisku określonych we właściwościach yes i no (domyślnie: window)

          - yes (Typ Function)

              Opcjonalna funkcja wykonywana po kliknięciu przycisku Tak (domyślnie: null)

          - yesScope (Typ Object)

               Scope dla opcjonalnej funkcji wykonywanej po kliknięciu przycisku określonej we właściwości yes (domyślnie: wartość podana we właściwości scope)

          - yesParams (Typ Object[])

              Tablica określająca parametry przekazywane do funkcji określonej we właściwości yes (domyślnie: [])

          - yesText (Typ String)

              Treść przycisku zatwierdzającego (domyślnie: 'Tak')

          - no (Typ Function)

              Opcjonalna funkcja wykonywana po kliknięciu przycisku Nie (domyślnie: null)

          - noScope (Typ Object)

               Scope dla opcjonalnej funkcji wykonywanej po kliknięciu przycisku określonej we właściwości no (domyślnie: wartość podana we właściwości scope)

          - noParams (Typ Object[])

              Tablica określająca parametry przekazywane do funkcji określonej we właściwości no (domyślnie: [])

          - noText (Typ String)

              Treść przycisku anulującego (domyślnie: 'Nie')

          - messageType (Typ String)

              Typ wyświetlanego komunikatu (domyślnie: 'QUESTION'). Możliwe opcje to: QUESTION, INFO, ERROR, WARNING, SUCCESS


    • Rezultat funkcji: brak

 

 

  • showAlert - wyświetla okno z wiadomością (od 3.2.162). Na wersji mobilnej zaleca się używanie tej funkcji zamiast alert().
    • Parametry funkcji

      NazwaTyp

      Wartość domyślna

      Opis
      titleString''Tytuł okna
      contentString''Treść wiadomości


    • Rezultat funkcji: brak
English

MessageService allows to display animated messages for the form user. It has the following functions:

  • show- shows the basic message in the form of an animated speech bubble at the top of the screen, the content and background are gray.
    • Function parameters:

      Name

      Type

      Default value

      Description

      msg

      String

      'Info'

      Message content

      conf(from 3.1.18)

      Object

      {}

      Message window configuration.

          - hideAfter(Number Type)

             The time (in milliseconds) at which the message should disappear (default: 3000).
       This time must be a positive number. If the value 0 is given, the parameter will take the default value.

    • Function result: null

 

  • showSuccess- shows a message in the form of an animated speech bubble at the top of the screen informing about success, content and background are green.
    • Function parameters:

       

      Name

      Type

      Default value

      Description

      msg

      String

      'Ok'

      Message content

      conf (from 3.1.18)

      Object

      {}

      Message window configuration.

          - hideAfter (Number Type)

             The time (in milliseconds) at which the message should disappear (default: 3000).
       This time must be a positive number. If the value 0 is given, the parameter will take the default value.

 

    • Function result: null

 

  • showFailure- shows a message in the form of an animated speech bubble at the top of the screen informing about success, content and background are red.
    • Function parameters:

      Name

      Type

      Default value

      Description

      msg

      String

      'Error'

      Message content

      conf (from 3.1.18)

      Object

      {}

      Message window configuration.

          - hideAfter (Number Type)

             The time (in milliseconds) at which the message should disappear (default: 3000).
       This time must be a positive number. If the value 0 is given, the parameter will take the default value.

    • Function result: null

 

  • showConfirm - displays a message window that allows to select Yes or No.
    • Function parameters:

      Name

      Type

      Default value

      Description

      config

      Object

      { }

      Configuration of the message window. The object has the following properties:

          - title(String Type)

              Window title (by default: '')

          - message(String Type)

              Message content (by default: '')

          - scope(Object Type)

              Scope for optional functions performed after clicking the button specified in the yes and no properties (by default: window)

          - yes(Function Type)

              Optional function performed after clicking the Yes button (by default: null)

          - yesScope(Object Type)

               Scope for the optional function performed after clicking the button specified in the yes property (by default: the value given in the property scope)

          - yesParams(Object Type[])

              An array specifying the parameters passed to the function specified in the property yes (by default: [])

          - no(Function Type)

              Optional function performed after clicking No button (by default: null)

          - noScope(Object Type)

               Scope for the optional function performed after clicking the button specified in the no property (by default: the value given in the property scope)

          - noParams(Object Type[])

              An array specifying the parameters passed to the function specified in the property no (by default: [])

    • Function result: null

 

  • showAlert - displays a message window (from 3.2.162). On the mobile version it is recommended to use this function instead of alert().
    • Function parameters:

       

      NameType

      Default value

      Description
      titleString''Window title
      contentString''Message content
    • Function result: null