Sha256: 55511dfca12ba0bfe0b412bb454b24442945b459dd1908c8daf63b4aa34e923b

Contents?: true

Size: 776 Bytes

Versions: 30

Compression:

Stored size: 776 Bytes

Contents

# -*- encoding : utf-8 -*-

class AddNotificationEventCard < Card::Migration::Core
  def up
    ensure_card "Notification template", codename: "notification_template",
                type_id: Card::CardtypeID
    ensure_trait "*message", "message", default: { type_id: Card::PhraseID }
    ensure_trait "*disappear", "disappear", default: { type_id: Card::ToggleID }
    ensure_trait "*contextual class", "contextual_class",
                 default: { type_id: Card::PointerID },
                 input: "radio",
                 options: %w(success info warning danger)

    [:create, :update, :delete].each do |action|
      update ["on_#{action}".to_sym, :right, :help],
             content: "Configure events to be executed when card id #{action}d"
    end


  end
end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
card-1.96.2 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.96.1 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.96.0 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.95.3 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.95.2 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.95.1 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.95.0 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.94.1 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.94.0 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.13 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.12 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.11 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.10 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.9 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.8 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.7 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.6 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.5 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.4 db/migrate_core_cards/20170314175313_add_notification_event_card.rb
card-1.93.3 db/migrate_core_cards/20170314175313_add_notification_event_card.rb