eventbus 0.0.20 → 0.0.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- metadata +25 -122
- data/admin/Gemfile +0 -50
- data/admin/Gemfile.lock +0 -141
- data/admin/Rakefile +0 -7
- data/admin/app/assets/images/rails.png +0 -0
- data/admin/app/assets/javascripts/application.js +0 -15
- data/admin/app/assets/javascripts/applications.js.coffee +0 -3
- data/admin/app/assets/javascripts/message_routes.js.coffee +0 -3
- data/admin/app/assets/javascripts/message_types.js.coffee +0 -3
- data/admin/app/assets/javascripts/messages.js.coffee +0 -3
- data/admin/app/assets/stylesheets/application.css +0 -13
- data/admin/app/assets/stylesheets/applications.css.scss +0 -3
- data/admin/app/assets/stylesheets/global.css.scss +0 -72
- data/admin/app/assets/stylesheets/message_routes.css.scss +0 -3
- data/admin/app/assets/stylesheets/message_types.css.scss +0 -3
- data/admin/app/assets/stylesheets/messages.css.scss +0 -30
- data/admin/app/assets/stylesheets/scaffolds.css.scss +0 -56
- data/admin/app/controllers/application_controller.rb +0 -3
- data/admin/app/controllers/applications_controller.rb +0 -83
- data/admin/app/controllers/message_routes_controller.rb +0 -85
- data/admin/app/controllers/message_types_controller.rb +0 -83
- data/admin/app/controllers/messages_controller.rb +0 -75
- data/admin/app/helpers/application_helper.rb +0 -2
- data/admin/app/helpers/applications_helper.rb +0 -2
- data/admin/app/helpers/message_routes_helper.rb +0 -2
- data/admin/app/helpers/message_types_helper.rb +0 -2
- data/admin/app/helpers/messages_helper.rb +0 -2
- data/admin/app/models/application.rb +0 -7
- data/admin/app/models/message.rb +0 -4
- data/admin/app/models/message_route.rb +0 -5
- data/admin/app/models/message_type.rb +0 -7
- data/admin/app/views/applications/_form.html.haml +0 -27
- data/admin/app/views/applications/edit.html.haml +0 -5
- data/admin/app/views/applications/index.html.haml +0 -28
- data/admin/app/views/applications/new.html.haml +0 -3
- data/admin/app/views/applications/show.html.haml +0 -16
- data/admin/app/views/layouts/application.html.haml +0 -24
- data/admin/app/views/message_routes/_form.html.haml +0 -31
- data/admin/app/views/message_routes/edit.html.haml +0 -5
- data/admin/app/views/message_routes/index.html.haml +0 -28
- data/admin/app/views/message_routes/new.html.haml +0 -3
- data/admin/app/views/message_routes/show.html.haml +0 -16
- data/admin/app/views/message_types/_form.html.haml +0 -29
- data/admin/app/views/message_types/edit.html.haml +0 -5
- data/admin/app/views/message_types/index.html.haml +0 -28
- data/admin/app/views/message_types/new.html.haml +0 -5
- data/admin/app/views/message_types/show.html.haml +0 -17
- data/admin/app/views/messages/index.html.haml +0 -48
- data/admin/app/views/messages/show.html.haml +0 -45
- data/admin/config/application.rb +0 -64
- data/admin/config/boot.rb +0 -6
- data/admin/config/database.yml +0 -29
- data/admin/config/environment.rb +0 -5
- data/admin/config/environments/development.rb +0 -37
- data/admin/config/environments/production.rb +0 -72
- data/admin/config/environments/test.rb +0 -37
- data/admin/config/initializers/backtrace_silencers.rb +0 -7
- data/admin/config/initializers/inflections.rb +0 -15
- data/admin/config/initializers/mime_types.rb +0 -5
- data/admin/config/initializers/secret_token.rb +0 -7
- data/admin/config/initializers/session_store.rb +0 -8
- data/admin/config/initializers/wrap_parameters.rb +0 -14
- data/admin/config/locales/en.yml +0 -5
- data/admin/config/routes.rb +0 -69
- data/admin/config.ru +0 -4
- data/admin/db/development.sqlite3-journal +0 -0
- data/admin/db/migrate/20120218124300_create_messages.rb +0 -16
- data/admin/db/migrate/20120219021535_create_applications.rb +0 -11
- data/admin/db/migrate/20120219021806_create_message_types.rb +0 -13
- data/admin/db/migrate/20120219021940_create_message_routes.rb +0 -13
- data/admin/db/migrate/20120411001040_add_app_id_key_msg_type_id_to_messages.rb +0 -7
- data/admin/db/migrate/20120411001823_rename_message_type_to_message_type_name_in_messages.rb +0 -5
- data/admin/db/migrate/20120413024953_add_message_guid_to_messages.rb +0 -5
- data/admin/db/migrate/20120523112257_add_match_all_errors_to_routes.rb +0 -5
- data/admin/db/schema.rb +0 -68
- data/admin/db/seeds.rb +0 -7
- data/admin/doc/README_FOR_APP +0 -2
- data/admin/public/404.html +0 -26
- data/admin/public/422.html +0 -26
- data/admin/public/500.html +0 -25
- data/admin/public/favicon.ico +0 -0
- data/admin/public/robots.txt +0 -5
- data/admin/script/rails +0 -6
- data/admin/script/railsrunner +0 -3
- data/admin/test/fixtures/applications.yml +0 -14
- data/admin/test/fixtures/message_routes.yml +0 -11
- data/admin/test/fixtures/message_types.yml +0 -17
- data/admin/test/fixtures/messages.yml +0 -45
- data/admin/test/functional/applications_controller_test.rb +0 -49
- data/admin/test/functional/message_routes_controller_test.rb +0 -49
- data/admin/test/functional/message_types_controller_test.rb +0 -49
- data/admin/test/functional/messages_controller_test.rb +0 -49
- data/admin/test/performance/browsing_test.rb +0 -12
- data/admin/test/test_helper.rb +0 -13
- data/admin/test/unit/application_test.rb +0 -7
- data/admin/test/unit/helpers/applications_helper_test.rb +0 -4
- data/admin/test/unit/helpers/message_routes_helper_test.rb +0 -4
- data/admin/test/unit/helpers/message_types_helper_test.rb +0 -4
- data/admin/test/unit/helpers/messages_helper_test.rb +0 -4
- data/admin/test/unit/message_route_test.rb +0 -7
- data/admin/test/unit/message_test.rb +0 -7
- data/admin/test/unit/message_type_test.rb +0 -7
- data/bin/eventbus_dispatcher.rb +0 -118
- data/bin/eventbus_emailer.rb +0 -41
- data/lib/eventbus/connectors/amqp.rb +0 -70
- data/lib/eventbus/connectors/bunny.rb +0 -71
- data/lib/eventbus/connectors/stomp.rb +0 -77
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
class ApplicationsController < ApplicationController
|
|
2
|
-
# GET /applications
|
|
3
|
-
# GET /applications.json
|
|
4
|
-
def index
|
|
5
|
-
@applications = Application.all
|
|
6
|
-
|
|
7
|
-
respond_to do |format|
|
|
8
|
-
format.html # index.html.erb
|
|
9
|
-
format.json { render json: @applications }
|
|
10
|
-
end
|
|
11
|
-
end
|
|
12
|
-
|
|
13
|
-
# GET /applications/1
|
|
14
|
-
# GET /applications/1.json
|
|
15
|
-
def show
|
|
16
|
-
@application = Application.find(params[:id])
|
|
17
|
-
|
|
18
|
-
respond_to do |format|
|
|
19
|
-
format.html # show.html.erb
|
|
20
|
-
format.json { render json: @application }
|
|
21
|
-
end
|
|
22
|
-
end
|
|
23
|
-
|
|
24
|
-
# GET /applications/new
|
|
25
|
-
# GET /applications/new.json
|
|
26
|
-
def new
|
|
27
|
-
@application = Application.new
|
|
28
|
-
|
|
29
|
-
respond_to do |format|
|
|
30
|
-
format.html # new.html.erb
|
|
31
|
-
format.json { render json: @application }
|
|
32
|
-
end
|
|
33
|
-
end
|
|
34
|
-
|
|
35
|
-
# GET /applications/1/edit
|
|
36
|
-
def edit
|
|
37
|
-
@application = Application.find(params[:id])
|
|
38
|
-
end
|
|
39
|
-
|
|
40
|
-
# POST /applications
|
|
41
|
-
# POST /applications.json
|
|
42
|
-
def create
|
|
43
|
-
@application = Application.new(params[:application])
|
|
44
|
-
|
|
45
|
-
respond_to do |format|
|
|
46
|
-
if @application.save
|
|
47
|
-
format.html { redirect_to @application, notice: 'Application was successfully created.' }
|
|
48
|
-
format.json { render json: @application, status: :created, location: @application }
|
|
49
|
-
else
|
|
50
|
-
format.html { render action: "new" }
|
|
51
|
-
format.json { render json: @application.errors, status: :unprocessable_entity }
|
|
52
|
-
end
|
|
53
|
-
end
|
|
54
|
-
end
|
|
55
|
-
|
|
56
|
-
# PUT /applications/1
|
|
57
|
-
# PUT /applications/1.json
|
|
58
|
-
def update
|
|
59
|
-
@application = Application.find(params[:id])
|
|
60
|
-
|
|
61
|
-
respond_to do |format|
|
|
62
|
-
if @application.update_attributes(params[:application])
|
|
63
|
-
format.html { redirect_to @application, notice: 'Application was successfully updated.' }
|
|
64
|
-
format.json { head :no_content }
|
|
65
|
-
else
|
|
66
|
-
format.html { render action: "edit" }
|
|
67
|
-
format.json { render json: @application.errors, status: :unprocessable_entity }
|
|
68
|
-
end
|
|
69
|
-
end
|
|
70
|
-
end
|
|
71
|
-
|
|
72
|
-
# DELETE /applications/1
|
|
73
|
-
# DELETE /applications/1.json
|
|
74
|
-
def destroy
|
|
75
|
-
@application = Application.find(params[:id])
|
|
76
|
-
@application.destroy
|
|
77
|
-
|
|
78
|
-
respond_to do |format|
|
|
79
|
-
format.html { redirect_to applications_url }
|
|
80
|
-
format.json { head :no_content }
|
|
81
|
-
end
|
|
82
|
-
end
|
|
83
|
-
end
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
class MessageRoutesController < ApplicationController
|
|
2
|
-
# GET /message_routes
|
|
3
|
-
# GET /message_routes.json
|
|
4
|
-
def index
|
|
5
|
-
|
|
6
|
-
@applications = Application.order(:name)
|
|
7
|
-
#@message_routes = MessageRoute.all
|
|
8
|
-
|
|
9
|
-
respond_to do |format|
|
|
10
|
-
format.html # index.html.erb
|
|
11
|
-
format.json { render json: @message_routes }
|
|
12
|
-
end
|
|
13
|
-
end
|
|
14
|
-
|
|
15
|
-
# GET /message_routes/1
|
|
16
|
-
# GET /message_routes/1.json
|
|
17
|
-
def show
|
|
18
|
-
@message_route = MessageRoute.find(params[:id])
|
|
19
|
-
|
|
20
|
-
respond_to do |format|
|
|
21
|
-
format.html # show.html.erb
|
|
22
|
-
format.json { render json: @message_route }
|
|
23
|
-
end
|
|
24
|
-
end
|
|
25
|
-
|
|
26
|
-
# GET /message_routes/new
|
|
27
|
-
# GET /message_routes/new.json
|
|
28
|
-
def new
|
|
29
|
-
@message_route = MessageRoute.new
|
|
30
|
-
|
|
31
|
-
respond_to do |format|
|
|
32
|
-
format.html # new.html.erb
|
|
33
|
-
format.json { render json: @message_route }
|
|
34
|
-
end
|
|
35
|
-
end
|
|
36
|
-
|
|
37
|
-
# GET /message_routes/1/edit
|
|
38
|
-
def edit
|
|
39
|
-
@message_route = MessageRoute.find(params[:id])
|
|
40
|
-
end
|
|
41
|
-
|
|
42
|
-
# POST /message_routes
|
|
43
|
-
# POST /message_routes.json
|
|
44
|
-
def create
|
|
45
|
-
@message_route = MessageRoute.new(params[:message_route])
|
|
46
|
-
|
|
47
|
-
respond_to do |format|
|
|
48
|
-
if @message_route.save
|
|
49
|
-
format.html { redirect_to @message_route, notice: 'Message route was successfully created.' }
|
|
50
|
-
format.json { render json: @message_route, status: :created, location: @message_route }
|
|
51
|
-
else
|
|
52
|
-
format.html { render action: "new" }
|
|
53
|
-
format.json { render json: @message_route.errors, status: :unprocessable_entity }
|
|
54
|
-
end
|
|
55
|
-
end
|
|
56
|
-
end
|
|
57
|
-
|
|
58
|
-
# PUT /message_routes/1
|
|
59
|
-
# PUT /message_routes/1.json
|
|
60
|
-
def update
|
|
61
|
-
@message_route = MessageRoute.find(params[:id])
|
|
62
|
-
|
|
63
|
-
respond_to do |format|
|
|
64
|
-
if @message_route.update_attributes(params[:message_route])
|
|
65
|
-
format.html { redirect_to @message_route, notice: 'Message route was successfully updated.' }
|
|
66
|
-
format.json { head :no_content }
|
|
67
|
-
else
|
|
68
|
-
format.html { render action: "edit" }
|
|
69
|
-
format.json { render json: @message_route.errors, status: :unprocessable_entity }
|
|
70
|
-
end
|
|
71
|
-
end
|
|
72
|
-
end
|
|
73
|
-
|
|
74
|
-
# DELETE /message_routes/1
|
|
75
|
-
# DELETE /message_routes/1.json
|
|
76
|
-
def destroy
|
|
77
|
-
@message_route = MessageRoute.find(params[:id])
|
|
78
|
-
@message_route.destroy
|
|
79
|
-
|
|
80
|
-
respond_to do |format|
|
|
81
|
-
format.html { redirect_to message_routes_url }
|
|
82
|
-
format.json { head :no_content }
|
|
83
|
-
end
|
|
84
|
-
end
|
|
85
|
-
end
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
class MessageTypesController < ApplicationController
|
|
2
|
-
# GET /message_types
|
|
3
|
-
# GET /message_types.json
|
|
4
|
-
def index
|
|
5
|
-
@message_types = MessageType.all(:order => :name )
|
|
6
|
-
|
|
7
|
-
respond_to do |format|
|
|
8
|
-
format.html # index.html.erb
|
|
9
|
-
format.json { render json: @message_types }
|
|
10
|
-
end
|
|
11
|
-
end
|
|
12
|
-
|
|
13
|
-
# GET /message_types/1
|
|
14
|
-
# GET /message_types/1.json
|
|
15
|
-
def show
|
|
16
|
-
@message_type = MessageType.find(params[:id])
|
|
17
|
-
|
|
18
|
-
respond_to do |format|
|
|
19
|
-
format.html # show.html.erb
|
|
20
|
-
format.json { render json: @message_type }
|
|
21
|
-
end
|
|
22
|
-
end
|
|
23
|
-
|
|
24
|
-
# GET /message_types/new
|
|
25
|
-
# GET /message_types/new.json
|
|
26
|
-
def new
|
|
27
|
-
@message_type = MessageType.new
|
|
28
|
-
|
|
29
|
-
respond_to do |format|
|
|
30
|
-
format.html # new.html.erb
|
|
31
|
-
format.json { render json: @message_type }
|
|
32
|
-
end
|
|
33
|
-
end
|
|
34
|
-
|
|
35
|
-
# GET /message_types/1/edit
|
|
36
|
-
def edit
|
|
37
|
-
@message_type = MessageType.find(params[:id])
|
|
38
|
-
end
|
|
39
|
-
|
|
40
|
-
# POST /message_types
|
|
41
|
-
# POST /message_types.json
|
|
42
|
-
def create
|
|
43
|
-
@message_type = MessageType.new(params[:message_type])
|
|
44
|
-
|
|
45
|
-
respond_to do |format|
|
|
46
|
-
if @message_type.save
|
|
47
|
-
format.html { redirect_to @message_type, notice: 'Message type was successfully created.' }
|
|
48
|
-
format.json { render json: @message_type, status: :created, location: @message_type }
|
|
49
|
-
else
|
|
50
|
-
format.html { render action: "new" }
|
|
51
|
-
format.json { render json: @message_type.errors, status: :unprocessable_entity }
|
|
52
|
-
end
|
|
53
|
-
end
|
|
54
|
-
end
|
|
55
|
-
|
|
56
|
-
# PUT /message_types/1
|
|
57
|
-
# PUT /message_types/1.json
|
|
58
|
-
def update
|
|
59
|
-
@message_type = MessageType.find(params[:id])
|
|
60
|
-
|
|
61
|
-
respond_to do |format|
|
|
62
|
-
if @message_type.update_attributes(params[:message_type])
|
|
63
|
-
format.html { redirect_to @message_type, notice: 'Message type was successfully updated.' }
|
|
64
|
-
format.json { head :no_content }
|
|
65
|
-
else
|
|
66
|
-
format.html { render action: "edit" }
|
|
67
|
-
format.json { render json: @message_type.errors, status: :unprocessable_entity }
|
|
68
|
-
end
|
|
69
|
-
end
|
|
70
|
-
end
|
|
71
|
-
|
|
72
|
-
# DELETE /message_types/1
|
|
73
|
-
# DELETE /message_types/1.json
|
|
74
|
-
def destroy
|
|
75
|
-
@message_type = MessageType.find(params[:id])
|
|
76
|
-
@message_type.destroy
|
|
77
|
-
|
|
78
|
-
respond_to do |format|
|
|
79
|
-
format.html { redirect_to message_types_url }
|
|
80
|
-
format.json { head :no_content }
|
|
81
|
-
end
|
|
82
|
-
end
|
|
83
|
-
end
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
require 'eventbus/message'
|
|
2
|
-
|
|
3
|
-
class MessagesController < ApplicationController
|
|
4
|
-
# GET /messages
|
|
5
|
-
# GET /messages.json
|
|
6
|
-
def index
|
|
7
|
-
conditions = {}
|
|
8
|
-
|
|
9
|
-
unless params['message'].nil?
|
|
10
|
-
|
|
11
|
-
if params['message']['is_error'] == 1
|
|
12
|
-
params['message']['is_error'] = true
|
|
13
|
-
else
|
|
14
|
-
params['message'].delete('is_error')
|
|
15
|
-
end
|
|
16
|
-
|
|
17
|
-
params['message'].each_pair do | field, filter |
|
|
18
|
-
conditions[field] = filter unless filter.nil? or filter.blank?
|
|
19
|
-
end
|
|
20
|
-
end
|
|
21
|
-
|
|
22
|
-
logger.info "*** Filtering on conditions: #{conditions}"
|
|
23
|
-
|
|
24
|
-
@messages = Message.where(conditions).limit(75).reverse_order
|
|
25
|
-
|
|
26
|
-
respond_to do |format|
|
|
27
|
-
format.html # index.html.erb
|
|
28
|
-
format.json { render json: @messages }
|
|
29
|
-
end
|
|
30
|
-
end
|
|
31
|
-
|
|
32
|
-
# GET /messages/1
|
|
33
|
-
# GET /messages/1.json
|
|
34
|
-
def show
|
|
35
|
-
@message = Message.find(params[:id])
|
|
36
|
-
|
|
37
|
-
respond_to do |format|
|
|
38
|
-
format.html # show.html.erb
|
|
39
|
-
format.json { render json: @message }
|
|
40
|
-
end
|
|
41
|
-
end
|
|
42
|
-
|
|
43
|
-
def resubmit_event
|
|
44
|
-
@message = Message.find(params[:id])
|
|
45
|
-
logger.info "Params: #{params.inspect}"
|
|
46
|
-
logger.info "Resubmit will have status: #{params[:message][:status]}"
|
|
47
|
-
resubmit_to_queue(params[:message][:status])
|
|
48
|
-
redirect_to messages_path
|
|
49
|
-
end
|
|
50
|
-
|
|
51
|
-
def send_queue
|
|
52
|
-
@message = Message.find(params[:id])
|
|
53
|
-
q = params[:message][:dispatch_to]
|
|
54
|
-
resubmit_to_queue(nil, q)
|
|
55
|
-
redirect_to messages_path
|
|
56
|
-
end
|
|
57
|
-
|
|
58
|
-
private
|
|
59
|
-
|
|
60
|
-
def resubmit_to_queue(status = nil, queue="dispatcher")
|
|
61
|
-
m = EventBus::Message.new("EVENTBUS_CORE")
|
|
62
|
-
m.load(@message.content)
|
|
63
|
-
m.status = status unless status.nil?
|
|
64
|
-
|
|
65
|
-
system_queue = queue == "dispatcher" ? true : false
|
|
66
|
-
|
|
67
|
-
m.send :queue_name => queue, :system_queue => system_queue
|
|
68
|
-
|
|
69
|
-
logger.info "Resubmitted to queue: #{queue}"
|
|
70
|
-
logger.info "Message content:"
|
|
71
|
-
logger.info m.dump
|
|
72
|
-
|
|
73
|
-
end
|
|
74
|
-
|
|
75
|
-
end
|
data/admin/app/models/message.rb
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
= form_for(@application) do |f|
|
|
2
|
-
- if @application.errors.any?
|
|
3
|
-
#error_explanation
|
|
4
|
-
%h2
|
|
5
|
-
= pluralize(@application.errors.count, "error")
|
|
6
|
-
prohibited this application from being saved:
|
|
7
|
-
|
|
8
|
-
%ul
|
|
9
|
-
- @application.errors.full_messages.each do |msg|
|
|
10
|
-
%li
|
|
11
|
-
= msg
|
|
12
|
-
|
|
13
|
-
.field
|
|
14
|
-
= f.label :name
|
|
15
|
-
%br
|
|
16
|
-
= f.text_field :name
|
|
17
|
-
.field
|
|
18
|
-
= f.label :key
|
|
19
|
-
%br
|
|
20
|
-
= f.text_field :key
|
|
21
|
-
.field
|
|
22
|
-
= f.label :description
|
|
23
|
-
%br
|
|
24
|
-
= f.text_field :description
|
|
25
|
-
|
|
26
|
-
.actions
|
|
27
|
-
= f.submit
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
%h1 Listing Applications
|
|
2
|
-
|
|
3
|
-
%table
|
|
4
|
-
%tr
|
|
5
|
-
%th Name
|
|
6
|
-
%th Key
|
|
7
|
-
%th Description
|
|
8
|
-
%th
|
|
9
|
-
%th
|
|
10
|
-
%th
|
|
11
|
-
|
|
12
|
-
= content_tag_for(:tr, @applications) do |application|
|
|
13
|
-
%td
|
|
14
|
-
= application.name
|
|
15
|
-
%td
|
|
16
|
-
= application.key
|
|
17
|
-
%td
|
|
18
|
-
= application.description
|
|
19
|
-
%td
|
|
20
|
-
= link_to 'Show', application
|
|
21
|
-
%td
|
|
22
|
-
= link_to 'Edit', edit_application_path(application)
|
|
23
|
-
%td
|
|
24
|
-
= link_to 'Destroy', application, confirm: 'Are you sure?', method: :delete
|
|
25
|
-
|
|
26
|
-
%br
|
|
27
|
-
|
|
28
|
-
= link_to 'New Application', new_application_path
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
!!!
|
|
2
|
-
%html
|
|
3
|
-
%head
|
|
4
|
-
%title EventbusPortal
|
|
5
|
-
= stylesheet_link_tag "application", :media => "all"
|
|
6
|
-
= javascript_include_tag "application"
|
|
7
|
-
= csrf_meta_tags
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
%body
|
|
11
|
-
|
|
12
|
-
%header
|
|
13
|
-
.container
|
|
14
|
-
%h1#site_name EventBus
|
|
15
|
-
%nav
|
|
16
|
-
.container
|
|
17
|
-
= link_to "Applications", applications_path
|
|
18
|
-
= link_to "Message Types", message_types_path
|
|
19
|
-
= link_to "Message Routes", message_routes_path
|
|
20
|
-
= link_to "Dispatch Log", messages_path
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
%section#content
|
|
24
|
-
= yield
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
= form_for(@message_route) do |f|
|
|
2
|
-
- if @message_route.errors.any?
|
|
3
|
-
#error_explanation
|
|
4
|
-
%h2
|
|
5
|
-
= pluralize(@message_route.errors.count, "error")
|
|
6
|
-
prohibited this message_route from being saved:
|
|
7
|
-
|
|
8
|
-
%ul
|
|
9
|
-
- @message_route.errors.full_messages.each do |msg|
|
|
10
|
-
%li
|
|
11
|
-
= msg
|
|
12
|
-
|
|
13
|
-
.field
|
|
14
|
-
= f.label :message_type_id
|
|
15
|
-
%br
|
|
16
|
-
= f.collection_select :message_type_id, MessageType.all(:order => "name asc"), :id, :name
|
|
17
|
-
.field
|
|
18
|
-
= f.label :incoming_status
|
|
19
|
-
%br
|
|
20
|
-
= f.text_field :incoming_status
|
|
21
|
-
.field
|
|
22
|
-
= f.label :match_errors
|
|
23
|
-
(Overrides incoming status)
|
|
24
|
-
%br
|
|
25
|
-
= f.check_box :match_errors
|
|
26
|
-
.field
|
|
27
|
-
= f.label :dispatch_to
|
|
28
|
-
%br
|
|
29
|
-
= f.text_field :dispatch_to
|
|
30
|
-
.actions
|
|
31
|
-
= f.submit
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
%h1 Listing Message Routes
|
|
2
|
-
|
|
3
|
-
= div_for(@applications, :style => "margin-top: 20px; border-top-style: solid; border-top-width: 4px; border-color: #999;") do |application|
|
|
4
|
-
|
|
5
|
-
%h2= application.name
|
|
6
|
-
|
|
7
|
-
= div_for(application.message_types.order(:name), :style => 'margin-left: 15px;') do |message_type|
|
|
8
|
-
|
|
9
|
-
%h2= message_type.name
|
|
10
|
-
|
|
11
|
-
%table{ :style => "margin-left: 20px;"}
|
|
12
|
-
%tr
|
|
13
|
-
%th Incoming status
|
|
14
|
-
%th Dispatch to
|
|
15
|
-
%th
|
|
16
|
-
%th
|
|
17
|
-
%th
|
|
18
|
-
|
|
19
|
-
= content_tag_for(:tr, message_type.message_routes.order(:incoming_status)) do |message_route|
|
|
20
|
-
%td= message_route.match_errors ? "*ALL ERRORS*" : message_route.incoming_status
|
|
21
|
-
%td= message_route.dispatch_to
|
|
22
|
-
%td= link_to 'Show', message_route
|
|
23
|
-
%td= link_to 'Edit', edit_message_route_path(message_route)
|
|
24
|
-
%td= link_to 'Destroy', message_route, confirm: 'Are you sure?', method: :delete
|
|
25
|
-
|
|
26
|
-
%br
|
|
27
|
-
|
|
28
|
-
= link_to 'New Message route', new_message_route_path
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
%p#notice
|
|
2
|
-
= notice
|
|
3
|
-
|
|
4
|
-
%p
|
|
5
|
-
%b Message type:
|
|
6
|
-
= @message_route.message_type.name
|
|
7
|
-
|
|
8
|
-
%p
|
|
9
|
-
%b Incoming status:
|
|
10
|
-
= @message_route.incoming_status
|
|
11
|
-
|
|
12
|
-
%p
|
|
13
|
-
%b Dispatch to:
|
|
14
|
-
= @message_route.dispatch_to
|
|
15
|
-
|
|
16
|
-
= link_to 'Edit', edit_message_route_path(@message_route)
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
= form_for(@message_type) do |f|
|
|
2
|
-
- if @message_type.errors.any?
|
|
3
|
-
#error_explanation
|
|
4
|
-
%h2
|
|
5
|
-
= pluralize(@message_type.errors.count, "error")
|
|
6
|
-
prohibited this message_type from being saved:
|
|
7
|
-
|
|
8
|
-
%ul
|
|
9
|
-
- @message_type.errors.full_messages.each do |msg|
|
|
10
|
-
%li
|
|
11
|
-
= msg
|
|
12
|
-
|
|
13
|
-
.field
|
|
14
|
-
= f.label :application_id
|
|
15
|
-
%br
|
|
16
|
-
= f.collection_select :application_id, Application.all(:order => "name asc"), :id, :name
|
|
17
|
-
|
|
18
|
-
.field
|
|
19
|
-
= f.label :name
|
|
20
|
-
%br
|
|
21
|
-
= f.text_field :name
|
|
22
|
-
|
|
23
|
-
.field
|
|
24
|
-
= f.label :description
|
|
25
|
-
%br
|
|
26
|
-
= f.text_area :description
|
|
27
|
-
|
|
28
|
-
.actions
|
|
29
|
-
= f.submit
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
%h1 Listing Message Types
|
|
2
|
-
|
|
3
|
-
%table
|
|
4
|
-
%tr
|
|
5
|
-
%th Application
|
|
6
|
-
%th Name
|
|
7
|
-
%th Description
|
|
8
|
-
%th
|
|
9
|
-
%th
|
|
10
|
-
%th
|
|
11
|
-
|
|
12
|
-
= content_tag_for(:tr, @message_types) do |message_type|
|
|
13
|
-
%td
|
|
14
|
-
= message_type.application.name
|
|
15
|
-
%td
|
|
16
|
-
= message_type.name
|
|
17
|
-
%td
|
|
18
|
-
= message_type.description
|
|
19
|
-
%td
|
|
20
|
-
= link_to 'Show', message_type
|
|
21
|
-
%td
|
|
22
|
-
= link_to 'Edit', edit_message_type_path(message_type)
|
|
23
|
-
%td
|
|
24
|
-
= link_to 'Destroy', message_type, confirm: 'Are you sure?', method: :delete
|
|
25
|
-
|
|
26
|
-
%br
|
|
27
|
-
|
|
28
|
-
= link_to 'New Message type', new_message_type_path
|