wordjelly-auth 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (103) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/images/ai_lab.jpg +0 -0
  3. data/app/assets/images/lab.jpg +0 -0
  4. data/app/assets/images/placeholder.png +0 -0
  5. data/app/assets/javascripts/auth/application.js +1 -2
  6. data/app/assets/javascripts/auth/auth_dependencies.js +25 -4
  7. data/app/assets/javascripts/auth/auth_modals_and_navbar.js +9 -6
  8. data/app/assets/stylesheets/auth/auth_default_css.scss +4 -4
  9. data/app/assets/stylesheets/auth/overrides.scss +12 -1
  10. data/app/controllers/auth/concerns/devise_concern.rb +7 -9
  11. data/app/controllers/auth/concerns/shopping/product_controller_concern.rb +41 -3
  12. data/app/controllers/auth/concerns/token_concern.rb +1 -1
  13. data/app/controllers/auth/concerns/work/instruction_controller_concern.rb +109 -0
  14. data/app/controllers/auth/shopping/shopping_controller.rb +0 -1
  15. data/app/controllers/auth/work/bullets_controller.rb +18 -0
  16. data/app/controllers/auth/work/instructions_controller.rb +16 -0
  17. data/app/controllers/auth/work/work_controller.rb +46 -0
  18. data/app/helpers/auth/work/bullets/bullets_helper.rb +25 -0
  19. data/app/helpers/auth/work/instructions/instructions_helper.rb +25 -0
  20. data/app/models/auth/concerns/chief_model_concern.rb +20 -0
  21. data/app/models/auth/concerns/notification_concern.rb +6 -0
  22. data/app/models/auth/concerns/owner_concern.rb +1 -2
  23. data/app/models/auth/concerns/shopping/product_concern.rb +9 -0
  24. data/app/models/auth/concerns/work/good_concern.rb +37 -0
  25. data/app/models/auth/concerns/work/inform_concern.rb +31 -0
  26. data/app/models/auth/image.rb +3 -0
  27. data/app/models/auth/work/VICTORY SPEECH: +12 -30
  28. data/app/models/auth/work/actor.rb +4 -0
  29. data/app/models/auth/work/bullet.rb +8 -0
  30. data/app/models/auth/work/cycle.rb +1 -1
  31. data/app/models/auth/work/information.rb +20 -0
  32. data/app/models/auth/work/instruction.rb +26 -0
  33. data/app/models/auth/work/link.rb +6 -0
  34. data/app/models/auth/work/minute.rb +151 -5
  35. data/app/models/auth/work/parameter.rb +9 -0
  36. data/app/models/auth/work/variable.rb +4 -0
  37. data/app/views/auth/modals/_oauth_and_submit.html.erb +2 -4
  38. data/app/views/auth/modals/_sign_in_inputs.html.erb +6 -4
  39. data/app/views/auth/modals/_sign_up_inputs.html.erb +1 -0
  40. data/app/views/auth/search/_search_bar.html.erb +8 -11
  41. data/app/views/auth/shopping/cart_items/_form.html.erb +2 -1
  42. data/app/views/auth/shopping/products/index.html.erb +6 -47
  43. data/app/views/auth/shopping/products/index/_show.html.erb +19 -0
  44. data/app/views/auth/shopping/products/show.html.erb +4 -11
  45. data/app/views/auth/shopping/products/show/_action_links.html.erb +2 -0
  46. data/app/views/auth/shopping/products/show/_content.html.erb +22 -0
  47. data/app/views/auth/shopping/products/show/_summary.html.erb +20 -0
  48. data/app/views/auth/work/bullets/_form.html.erb +10 -0
  49. data/app/views/auth/work/bullets/_show.html.erb +12 -0
  50. data/app/views/auth/work/bullets/edit.html.erb +1 -0
  51. data/app/{models/auth/concerns/work/schedule_concern.rb → views/auth/work/bullets/new.html.erb} +0 -0
  52. data/app/views/auth/work/instructions/_form.html.erb +16 -0
  53. data/app/views/auth/work/instructions/_show.html.erb +21 -0
  54. data/app/views/auth/work/instructions/edit.html.erb +1 -0
  55. data/app/views/layouts/auth/application.html.erb +0 -1
  56. data/app/views/layouts/auth/navbar/_navbar.html.erb +31 -31
  57. data/app/views/layouts/auth/navbar/_personalization.html.erb +2 -0
  58. data/config/initializers/devise.rb +0 -1
  59. data/config/initializers/omniauth.rb +5 -4
  60. data/lib/assets/javascripts/main.js +17 -6
  61. data/lib/assets/javascripts/you_need_to_sign_in.js.erb +9 -7
  62. data/lib/auth/engine.rb +19 -1
  63. data/lib/auth/rails/routes.rb +80 -29
  64. data/lib/auth/version.rb +1 -1
  65. data/spec/dummy/app/assets/images/ai_lab.jpg +0 -0
  66. data/spec/dummy/app/assets/images/lab.jpg +0 -0
  67. data/spec/dummy/app/assets/javascripts/application.js +1 -0
  68. data/spec/dummy/app/assets/time_hashes.json +1 -1
  69. data/spec/dummy/app/models/noti.rb +1 -1
  70. data/spec/dummy/app/models/shopping/product.rb +3 -1
  71. data/spec/dummy/app/views/home/index.html.erb +71 -5
  72. data/spec/dummy/app/views/layouts/application.html.erb +2 -0
  73. data/spec/dummy/config/application.rb +6 -0
  74. data/spec/dummy/config/initializers/preinitializer.rb +2 -2
  75. data/spec/dummy/db/products.json +136 -0
  76. data/spec/dummy/db/seeds.rb +80 -2
  77. data/spec/models/auth/work/minute_spec.rb +141 -3
  78. data/spec/requests/shopping/product_request_spec.rb +213 -0
  79. metadata +43 -45
  80. data/app/assets/javascripts/auth/admin_create_users.js +0 -2
  81. data/app/assets/javascripts/auth/assemblies.js +0 -2
  82. data/app/assets/javascripts/auth/clients.js +0 -2
  83. data/app/assets/javascripts/auth/images.js +0 -5
  84. data/app/assets/javascripts/auth/search.js +0 -2
  85. data/app/assets/stylesheets/auth/admin_create_users.css +0 -4
  86. data/app/assets/stylesheets/auth/assemblies.css +0 -4
  87. data/app/assets/stylesheets/auth/images.css +0 -4
  88. data/app/assets/stylesheets/auth/search.css +0 -4
  89. data/app/assets/stylesheets/auth/shopping/discounts.css +0 -4
  90. data/spec/dummy/app/assets/javascripts/activity.js +0 -2
  91. data/spec/dummy/app/assets/javascripts/home.js +0 -2
  92. data/spec/dummy/app/assets/javascripts/pollymer.min.js +0 -170
  93. data/spec/dummy/app/assets/javascripts/tests.js +0 -2
  94. data/spec/dummy/app/assets/javascripts/topics.js +0 -2
  95. data/spec/dummy/app/assets/javascripts/worms.js +0 -2
  96. data/spec/dummy/app/assets/stylesheets/activity.css +0 -4
  97. data/spec/dummy/app/assets/stylesheets/home.css +0 -4
  98. data/spec/dummy/app/assets/stylesheets/scaffolds.scss +0 -73
  99. data/spec/dummy/app/assets/stylesheets/tests.css +0 -4
  100. data/spec/dummy/app/assets/stylesheets/topics.css +0 -4
  101. data/spec/dummy/app/assets/stylesheets/worms.scss +0 -3
  102. data/spec/dummy/log/development.log +0 -21
  103. data/spec/dummy/log/test.log +0 -2821
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a2a54d41ad7d6f3f3178df55eb30fea897c200a3
4
- data.tar.gz: e7803ae5f41826ddb8ee7c8ec6af8091f76990e2
3
+ metadata.gz: 6800b6f5d5bb2dd7dd0758db368ea6f3506b7a29
4
+ data.tar.gz: 7464b108289680f202303bdef638b5548d0abf88
5
5
  SHA512:
6
- metadata.gz: f69dfd6330848ec5d2a1e45726c67f1c75798874bc30d8dc0375aeade08f2d4fe8bca798d29fbfc1da42a57df900b3dfce58abdb790d13de952fb56ce1c4422c
7
- data.tar.gz: 43f0a5e0fa134f891dc62cb6d14bb4a37727c9ac9e9dc79da6c17a6920b6c23ba779da6057423c2ed5e90b9d24b243eda5aa89148959b2572212d87aadcde7b6
6
+ metadata.gz: f8ccbf7391d5dca9478525082f1a97639197a5063c1945dea9a9fe881b7548f5730440c7f1cc6f8c576631de886173ae85a87d4d683c0fe1cb7944cdee5e7fa2
7
+ data.tar.gz: 856e34b359782a0331bde87c54853431e5d45e3386458a41bc2f280374282c3065ec5dc6f2289f827d6e0f14de9657b463a419301ce4409bd1547dc07c187150
Binary file
@@ -16,5 +16,4 @@
16
16
  //= require underscore
17
17
  //= require turbolinks
18
18
  //= require application.js
19
- //= require modernizr.custom.63321.js
20
- //= require data.js
19
+
@@ -4,11 +4,32 @@
4
4
  //= require jquery_ujs
5
5
  //= require underscore
6
6
  //= require turbolinks
7
- //= require modernizr.custom.63321.js
8
7
  //= require cloudinary
9
- //= require images
10
- //= require data.js
11
8
 
9
+
10
+
11
+ /**
12
12
  $(document).ready(function() {
13
13
  $('select').material_select();
14
- });
14
+ });
15
+ ***/
16
+
17
+ $(document).ready(function(){
18
+ $('.modal').modal();
19
+ });
20
+
21
+ $(document).ready(function(){
22
+ $('.tabs').tabs();
23
+ });
24
+
25
+ $(document).ready(function(){
26
+ $('.sidenav').sidenav();
27
+ });
28
+
29
+ $(document).ready(function(){
30
+ $('.collapsible').collapsible();
31
+ });
32
+
33
+ $(document).ready(function(){
34
+ $('.parallax').parallax();
35
+ });
@@ -20,15 +20,13 @@ payumoney.js
20
20
  ****/
21
21
 
22
22
  //= require auth/auth_dependencies.js
23
- //= require materialize-sprockets
23
+ //= require materialize
24
24
  //= require spinner.js
25
25
  //= require main.js
26
26
  //= require leanModal.js
27
27
  //= require you_need_to_sign_in.js
28
- //= require jquery.calendario.js
29
- //= require moment
30
- //= require search.js
31
28
  //= require payumoney.js
29
+ //= require search.js
32
30
 
33
31
  /////THIS CODE SHOWS HOW TO OVERRIDE ALL THE CLIENT SIDE CODE NEEDED
34
32
  /////FOR VALIDATIONS TO WORK FOR THE SIGN_IN_FORM.
@@ -45,7 +43,7 @@ SO THERE WE DONT NEED TO DO THE FOLLOWING HIDDEN-FIELD-JUGGLING ETC.
45
43
  and it juggles the action and the attributes as required, for the otp.
46
44
  ***/
47
45
  $(document).on('click','#login_submit',function(event){
48
- console.log("detected login submit click");
46
+
49
47
 
50
48
  var current_screen = $('#login_title').text();
51
49
  if(current_screen == "Sign Up"){
@@ -215,4 +213,9 @@ $(document).on('click','.additional_login_param_resend_confirmation_message',fun
215
213
  });
216
214
 
217
215
 
218
-
216
+ /***
217
+ on clicking on ORDER PRODUCT LINK, IT SUBMITS THE FORM.
218
+ ****/
219
+ $(document).on('click','.order_product_link',function(event){
220
+ $(this).closest("form").submit();
221
+ });
@@ -1,12 +1,12 @@
1
1
  /*
2
- *
3
- *= require calendar
4
- *= require calendar_modifications
2
+ * require calendar
3
+ * require calendar_modifications
5
4
  *= require auth/common-styles
6
5
  *= require auth/overrides
7
6
  */
8
7
  @import "materialize";
9
- @import "materialize/components/color";
8
+ //@import "materialize/components/color";
9
+
10
10
  $primary-color: color("blue", "lighten-2") !default;
11
11
 
12
12
  .modal { max-height: 90% !important ;}
@@ -1,6 +1,7 @@
1
1
  /***
2
2
  get rid of the ghastly yellow background color that chrome adds when autofilling forms.
3
3
  **/
4
+
4
5
  input:-webkit-autofill,
5
6
  input:-webkit-autofill:hover,
6
7
  input:-webkit-autofill:focus,
@@ -8,6 +9,7 @@ input:-webkit-autofill:active {
8
9
  transition: background-color 5000s ease-in-out 0s;
9
10
  }
10
11
 
12
+
11
13
  input[type=submit] {
12
14
  -webkit-appearance: none !important;
13
15
  }
@@ -23,4 +25,13 @@ label{
23
25
 
24
26
  .g-recaptcha{
25
27
  display:inline-block;
26
- }
28
+ }
29
+
30
+
31
+ .icon-align{
32
+ vertical-align:bottom;
33
+ }
34
+
35
+ .parallax-container {
36
+ height: 200px !important;
37
+ }
@@ -100,9 +100,7 @@ module Auth::Concerns::DeviseConcern
100
100
  if api_key.nil? || current_app_id.nil?
101
101
 
102
102
  else
103
- #puts "api key:#{api_key}"
104
- #puts "current app id: #{current_app_id}"
105
- #puts "path is: #{path}"
103
+
106
104
 
107
105
  if session[:client] = Auth::Client.find_valid_api_key_and_app_id(api_key, current_app_id)
108
106
 
@@ -136,10 +134,10 @@ module Auth::Concerns::DeviseConcern
136
134
  else
137
135
  #puts "action name is something else."
138
136
  if session[:client].nil?
139
- #puts "cient is nil so rendering nothing."
137
+ puts "cient is nil so rendering nothing."
140
138
  render :nothing => true , :status => :unauthorized
141
139
  else
142
- #puts "client is not nil"
140
+
143
141
  end
144
142
  end
145
143
  end
@@ -172,15 +170,15 @@ module Auth::Concerns::DeviseConcern
172
170
 
173
171
 
174
172
  def do_before_request
175
- #puts "came to do before request."
173
+
176
174
  clear_client_and_redirect_url
177
-
175
+
178
176
  set_client
179
-
177
+
180
178
  set_redirect_url
181
179
 
182
180
  protect_json_request
183
-
181
+
184
182
  end
185
183
 
186
184
  ##used only in render, redirect in DeviseController.class_eval
@@ -9,8 +9,10 @@ module Auth::Concerns::Shopping::ProductControllerConcern
9
9
  end
10
10
 
11
11
  def initialize_vars
12
+ puts "came to initialize vars"
12
13
  instantiate_shopping_classes
13
14
  @auth_shopping_product_params = permitted_params.fetch(:product,{})
15
+ puts "current signed in resource: #{current_signed_in_resource}"
14
16
  @auth_shopping_product = params[:id] ? @auth_shopping_product_class.find_self(params[:id],current_signed_in_resource) : @auth_shopping_product_class.new(@auth_shopping_product_params)
15
17
  end
16
18
 
@@ -19,7 +21,10 @@ module Auth::Concerns::Shopping::ProductControllerConcern
19
21
  def create
20
22
  check_for_create(@auth_shopping_product)
21
23
  @auth_shopping_product = add_owner_and_signed_in_resource(@auth_shopping_product,{:owner_is_current_resource => true})
22
-
24
+ #puts "this is the auth shopping product"
25
+ #puts @auth_shopping_product.embedded_document
26
+ #puts @auth_shopping_product.embedded_document_path
27
+ #@auth_shopping_product.send("#{@auth_shopping_product.embedded_document_path}=",@auth_shopping_product.embedded_document) if (@auth_shopping_product.embedded_document && @auth_shopping_product.embedded_document_path)
23
28
  @auth_shopping_product.save
24
29
  respond_with @auth_shopping_product
25
30
 
@@ -29,6 +34,34 @@ module Auth::Concerns::Shopping::ProductControllerConcern
29
34
  check_for_update(@auth_shopping_product)
30
35
  @auth_shopping_product = add_owner_and_signed_in_resource(@auth_shopping_product,{:owner_is_current_resource => true})
31
36
  @auth_shopping_product.assign_attributes(@auth_shopping_product_params)
37
+
38
+ ## assigns the embedded document to the provided path.
39
+ =begin
40
+ if @auth_shopping_product.embedded_document_path
41
+ curr_element = nil
42
+ total_els = @auth_shopping_product.embedded_document_path.split(".").size
43
+ @auth_shopping_product.embedded_document_path.split(".").each_with_index {|path,key|
44
+ if key == (total_els - 1)
45
+ if curr_element.nil?
46
+ @auth_shopping_product.send(path + "=",@auth_shopping_product.embedded_document)
47
+ else
48
+ curr_element.send(path + "=",@auth_shopping_product.embedded_document) if (path =~ /[a-z]+/)
49
+ curr_element.send(:[]=,path.to_i,@auth_shopping_product.embedded_document) if (path =~ /\d+/)
50
+ end
51
+ else
52
+ if curr_element.nil?
53
+ curr_element = @auth_shopping_product.send(path)
54
+ else
55
+ curr_element = curr_element.send(path) if (path =~ /[a-z]+/)
56
+ curr_element = curr_element[path.to_i] if path=~/\d+/
57
+ end
58
+ end
59
+ }
60
+ end
61
+ =end
62
+ ## prune nil elements.
63
+ ## at all levels.
64
+
32
65
  @auth_shopping_product.save
33
66
  respond_with @auth_shopping_product
34
67
 
@@ -59,10 +92,15 @@ module Auth::Concerns::Shopping::ProductControllerConcern
59
92
 
60
93
  end
61
94
 
95
+ ## so now two additional keys get added
96
+ ## one -> embedded_document_path
97
+ ## two -> embedded_document.
62
98
  def permitted_params
63
- params.permit({:product => [:name,:price]})
99
+ ## we just keep the embedded_document_path
100
+ ## i need to change the controllers back to product
101
+ ## and i need to
102
+ pr = params.permit({:product => [:name,:price]})
64
103
  end
65
104
 
66
105
  end
67
106
 
68
- ## how to handle situation where the resource_id and resource_class is
@@ -104,7 +104,7 @@ module Auth::Concerns::TokenConcern
104
104
  self.resource = @resource
105
105
  end
106
106
 
107
- puts "we have a resource as: #{@resource}"
107
+
108
108
 
109
109
  end
110
110
 
@@ -0,0 +1,109 @@
1
+ module Auth::Concerns::Work::InstructionControllerConcern
2
+
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ include Auth::Work::Instructions::InstructionsHelper
7
+ end
8
+
9
+ def initialize_vars
10
+ instantiate_work_classes
11
+ not_found("no product id provided") unless params[:product_id]
12
+
13
+ @auth_work_instruction_params = permitted_params.fetch(:instruction,{})
14
+ begin
15
+ if @auth_shopping_product = @auth_shopping_product_class.find(params[:product_id])
16
+
17
+ @auth_shopping_product = @auth_shopping_product_class.find_self(params[:product_id],current_signed_in_resource)
18
+ ## if the instruction id is provided, then it has to exist
19
+ if params[:id]
20
+ @auth_work_instruction = @auth_shopping_product.instructions.select{|c|
21
+ c.id.to_s == params[:id]
22
+ }[0]
23
+ else
24
+ @auth_work_instruction = @auth_work_instruction_class.new(@auth_work_instruction_params)
25
+ end
26
+ end
27
+ rescue Mongoid::Errors::DocumentNotFound
28
+ @auth_shopping_product = @auth_shopping_product_class.new
29
+ end
30
+
31
+ end
32
+
33
+ def get_index
34
+ index = 0
35
+ @auth_shopping_product.instructions.each do |ins|
36
+ break if ins.id.to_s == @auth_work_instruction.id.to_s
37
+ index+=1
38
+ end
39
+ index
40
+ end
41
+
42
+
43
+ def create
44
+ check_for_create(@auth_work_instruction)
45
+ @auth_shopping_product.instructions << @auth_work_instruction
46
+ @auth_shopping_product.save
47
+ respond_to do |format|
48
+ format.json do
49
+ render json: @auth_work_instruction.to_json
50
+ end
51
+ format.html do
52
+ render :partial => "show.html.erb", locals: {instruction: @auth_work_instruction, product: @auth_shopping_product}
53
+ end
54
+ end
55
+ end
56
+
57
+ def update
58
+ check_for_update(@auth_work_instruction)
59
+ @auth_work_instruction.assign_attributes(@auth_work_instruction_params)
60
+ @auth_shopping_product.instructions[get_index] = @auth_work_instruction
61
+ @auth_shopping_product.save
62
+ respond_to do |format|
63
+ format.json do
64
+ render json: @auth_work_instruction.to_json
65
+ end
66
+ format.html do
67
+ render :partial => "show.html.erb", locals: {instruction: @auth_work_instruction, product: @auth_shopping_product}
68
+ end
69
+ end
70
+ end
71
+
72
+ def index
73
+
74
+ end
75
+
76
+ def show
77
+ instantiate_work_classes
78
+ @auth_shopping_product = @auth_shopping_product_class.find(params[:product_id])
79
+ @auth_work_instruction = @auth_shopping_product.instructions.select{|c| c.id.to_s == params[:id]}[0]
80
+ end
81
+
82
+ def destroy
83
+ check_for_destroy(@auth_work_instruction)
84
+ @auth_shopping_product.delete_at(get_index)
85
+ @auth_shopping_product.save
86
+ respond_with @auth_work_instruction
87
+ end
88
+
89
+ def new
90
+
91
+ end
92
+
93
+ def edit
94
+
95
+ end
96
+
97
+ ## okay so how to port this to the pathofast side ?
98
+ ## we can just package the gem and see how it fares.
99
+ ## that's the best way
100
+ ## the only remaining major issue will be the images
101
+ ## and the only thing that has failed completely is the micro
102
+ ## let me first build the create ?
103
+
104
+ def permitted_params
105
+ pr = params.permit({:instruction => [:title,:description]}, :id, :product_id)
106
+ end
107
+
108
+ end
109
+
@@ -1,6 +1,5 @@
1
1
  class Auth::Shopping::ShoppingController < Auth::ApplicationController
2
2
 
3
-
4
3
  def instantiate_discount_class
5
4
  if @auth_shopping_discount_class = Auth.configuration.discount_class
6
5
  begin
@@ -0,0 +1,18 @@
1
+ class Auth::Work::BulletsController < Auth::ApplicationController
2
+
3
+
4
+ include Auth::Concerns::Work::BulletControllerConcern
5
+
6
+
7
+ ## only these actions need an authenticated user to be present for them to be executed.
8
+ CONDITIONS_FOR_TOKEN_AUTH = [:create,:update,:destroy,:edit,:new]
9
+
10
+ TCONDITIONS = {:only => CONDITIONS_FOR_TOKEN_AUTH}
11
+ ##this ensures api access to this controller.
12
+ include Auth::Concerns::DeviseConcern
13
+ include Auth::Concerns::TokenConcern
14
+ before_filter :do_before_request , TCONDITIONS
15
+ before_filter :initialize_vars , TCONDITIONS
16
+ before_filter :is_admin_user , :only => [:create,:update,:destroy,:edit]
17
+
18
+ end
@@ -0,0 +1,16 @@
1
+ class Auth::Work::InstructionsController < Auth::Work::WorkController
2
+
3
+ include Auth::Concerns::Work::InstructionControllerConcern
4
+
5
+ ## only these actions need an authenticated user to be present for them to be executed.
6
+ CONDITIONS_FOR_TOKEN_AUTH = [:create,:update,:destroy,:edit,:new]
7
+
8
+ TCONDITIONS = {:only => CONDITIONS_FOR_TOKEN_AUTH}
9
+ ##this ensures api access to this controller.
10
+ include Auth::Concerns::DeviseConcern
11
+ include Auth::Concerns::TokenConcern
12
+ before_filter :do_before_request , TCONDITIONS
13
+ before_filter :initialize_vars , TCONDITIONS
14
+ before_filter :is_admin_user , :only => [:create,:update,:destroy,:edit]
15
+
16
+ end
@@ -0,0 +1,46 @@
1
+ class Auth::Work::WorkController < Auth::ApplicationController
2
+ def instantiate_instruction_class
3
+ if @auth_work_instruction_class = Auth.configuration.instruction_class
4
+ begin
5
+ @auth_work_instruction_class = @auth_work_instruction_class.constantize
6
+ rescue
7
+ not_found("error instantiating class from instruction class")
8
+ end
9
+ else
10
+ not_found("instruction class not specified in configuration")
11
+ end
12
+ end
13
+
14
+ def instantiate_bullet_class
15
+ if @auth_work_bullet_class = Auth.configuration.bullet_class
16
+ begin
17
+ @auth_work_bullet_class = @auth_work_bullet_class.constantize
18
+ rescue
19
+ not_found("error instantiating class from bullet class")
20
+ end
21
+ else
22
+ not_found("bullet class not specified in configuration")
23
+ end
24
+ end
25
+
26
+ def instantiate_product_class
27
+
28
+ if @auth_shopping_product_class = Auth.configuration.product_class
29
+ begin
30
+ @auth_shopping_product_class = @auth_shopping_product_class.constantize
31
+ rescue => e
32
+ puts e.to_s
33
+ not_found("error instatiating class from product class")
34
+ end
35
+ else
36
+ not_found("product class not specified in configuration")
37
+ end
38
+
39
+ end
40
+
41
+ def instantiate_work_classes
42
+ instantiate_instruction_class
43
+ instantiate_bullet_class
44
+ instantiate_product_class
45
+ end
46
+ end