GlideNotification - クライアント
GlideNotification API は、ページコンテンツの上にメッセージを表示するメソッドを提供します。
g_notificationグローバルオブジェクトを使用してこの API にアクセスします。g_notificationオブジェクトを使用するには、リスト V3 を有効にする必要があります。
GlideNotification - show(文字列タイプ, 文字列メッセージ, 数値期間)
指定されたタイプのメッセージとして、指定された文字列をページコンテンツ上に表示します。期間タイマーが期限切れになると、メッセージは削除されます。
注:
スコープ対象のアプリケーションでこのメソッドを使用する場合は、関連付けられた名前空間
nowapi を指定する必要があります。たとえば、 nowapi.g_notification.show("info", "レコードが更新されました", 10000);| 名前 | タイプ | 説明 |
|---|---|---|
| type | 文字列 | 表示するメッセージのタイプ。 有効な値:
|
| メッセージ | 文字列 | 表示するメッセージ。 |
| duration | 番号 | オプション。メッセージを表示する時間。 単位:ミリ秒 デフォルト:5,000 |
| タイプ | 説明 |
|---|---|
| なし |
// Displays an info message at the top of the screen
g_notification.show("info", "The record has been updated", 10000);
// Displays an error message at the top of the screen in a scoped app
nowapi.g_notification.show("error", "You need to provide notes!");