supportcenter 0.1.6 → 0.1.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/README.rdoc +11 -1
  3. data/app/assets/javascripts/supportcenter/support_ticket_positions.js +2 -0
  4. data/app/assets/stylesheets/supportcenter/application.css +8 -0
  5. data/app/assets/stylesheets/supportcenter/support_ticket_positions.css +4 -0
  6. data/app/controllers/supportcenter/application_controller.rb +4 -1
  7. data/app/controllers/supportcenter/support_ticket_positions_controller.rb +6 -0
  8. data/app/controllers/supportcenter/support_tickets_controller.rb +50 -3
  9. data/app/helpers/supportcenter/application_helper.rb +14 -0
  10. data/app/helpers/supportcenter/support_ticket_positions_helper.rb +4 -0
  11. data/app/models/supportcenter/email.rb +4 -0
  12. data/app/models/supportcenter/support_ticket.rb +2 -0
  13. data/app/models/supportcenter/support_ticket_position.rb +6 -0
  14. data/app/views/layouts/supportcenter/applications.html.erb +38 -0
  15. data/app/views/supportcenter/support_tickets/_form.html.erb +0 -0
  16. data/app/views/supportcenter/support_tickets/index.html.erb +1 -0
  17. data/app/views/supportcenter/support_tickets/new.html.erb +0 -0
  18. data/app/views/supportcenter/support_tickets/show.html.erb +36 -0
  19. data/config/environment.rb +2 -0
  20. data/config/routes.rb +4 -2
  21. data/db/migrate/{20150922215753_create_supportcenter_support_tickets.rb → 20150922215753_create_support_tickets.rb} +1 -1
  22. data/db/migrate/20150923102302_create_support_ticket_positions.rb +10 -0
  23. data/db/migrate/20150923105748_add_user_id_to_support_ticket_position.rb +5 -0
  24. data/db/migrate/20150923122239_add_closed_to_support_tickets.rb +5 -0
  25. data/db/migrate/20150923130700_add_date_closed_to_support_tickets.rb +5 -0
  26. data/db/migrate/20150923141132_create_emails.rb +12 -0
  27. data/db/migrate/20150923155417_change_content_of_support_tickets.rb +5 -0
  28. data/db/migrate/20150923155649_change_email.rb +5 -0
  29. data/db/migrate/20150924112427_add_email_id_to_emails.rb +5 -0
  30. data/lib/generators/supportcenter/install_generator.rb +36 -0
  31. data/lib/generators/supportcenter/templates/20150922215753_create_support_tickets.rb +12 -0
  32. data/lib/generators/supportcenter/templates/20150923102302_create_support_ticket_positions.rb +10 -0
  33. data/lib/generators/supportcenter/templates/20150923105748_add_user_id_to_support_ticket_position.rb +5 -0
  34. data/lib/generators/supportcenter/templates/20150923122239_add_closed_to_support_tickets.rb +5 -0
  35. data/lib/generators/supportcenter/templates/20150923130700_add_date_closed_to_support_tickets.rb +5 -0
  36. data/lib/generators/supportcenter/templates/20150923141132_create_emails.rb +12 -0
  37. data/lib/generators/supportcenter/templates/20150923155417_change_content_of_support_tickets.rb +5 -0
  38. data/lib/generators/supportcenter/templates/20150923155649_change_email.rb +5 -0
  39. data/lib/generators/supportcenter/templates/20150924112427_add_email_id_to_emails.rb +5 -0
  40. data/lib/supportcenter.rb +1 -1
  41. data/lib/supportcenter/engine.rb +1 -1
  42. data/lib/supportcenter/version.rb +1 -1
  43. data/test/controllers/supportcenter/support_ticket_positions_controller_test.rb +9 -0
  44. data/test/fixtures/supportcenter/mails.yml +13 -0
  45. data/test/fixtures/supportcenter/support_ticket_positions.yml +9 -0
  46. data/test/helpers/supportcenter/support_ticket_positions_helper_test.rb +6 -0
  47. data/test/models/supportcenter/mail_test.rb +9 -0
  48. data/test/models/supportcenter/support_ticket_position_test.rb +9 -0
  49. metadata +73 -5
  50. data/app/views/layouts/supportcenter/application.html.erb +0 -14
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ebc073ba9e5b52b472463c8573a2ac3ff9ed8666
4
- data.tar.gz: 528b76cb8e6c6e1d3100db7fb149e4cc92cc71b1
3
+ metadata.gz: 6c9134b58c2fd30582ef2dcf41b55447d49f7ad3
4
+ data.tar.gz: 72558cad789c28d8e84fbf04d228a743e43b5a65
5
5
  SHA512:
6
- metadata.gz: 84ab68aa77fc0c5b8d6c2b8392c2b2bc1db08544487a086a12923c36678bd715e5538c84f6c1b8dd7c61bf9ff40b98ef1b58f8c9803e2aad52c17db667dcacd4
7
- data.tar.gz: 04640078365ee8c7fb3346dd9627a98c9793ee4b887da948858f353b7812621353ea263f25be7bcece45f73d832bbd8fc3baf849efa492466119679fedc17465
6
+ metadata.gz: 62f4081e98791d1600716ec965dae26a51bcce5f9328293940ae7c2c1cbf5a78878c6bda4eac0c0eb5aee20a072db27fd8430c5303d99db3379ca855e6e36525
7
+ data.tar.gz: 9e7038dc81edd1fedab079cce331956d5b60e9c7707d1a46a0fca1e2e9e0f2e7253d7a0ed03e03a40ba5da671c60c98adcd5b933744010b54b9f41a68050c24e
@@ -1,5 +1,15 @@
1
1
  Installation :
2
2
 
3
+ #Gemfile
3
4
  gem supportcenter
4
5
 
5
- rake supportcenter:install:migrations
6
+
7
+ #Console
8
+ rails g supportcenter:install
9
+
10
+
11
+
12
+ #clockwork file
13
+ every(2.minutes, 'check_mail'){
14
+ Supportcenter::SupportTicketsController.receive_mail if module_exists?
15
+ }
@@ -0,0 +1,2 @@
1
+ // Place all the behaviors and hooks related to the matching controller here.
2
+ // All this logic will automatically be available in application.js.
@@ -11,3 +11,11 @@
11
11
  *= require_self
12
12
  *= require_tree .
13
13
  */
14
+ .supportcenter-answer-box{
15
+ width:80%;
16
+ margin-left:10%;
17
+ height:150px;
18
+ }
19
+ #new_support_ticket_position label{
20
+ text-align: center
21
+ }
@@ -0,0 +1,4 @@
1
+ /*
2
+ Place all the styles related to the matching controller here.
3
+ They will automatically be included in application.css.
4
+ */
@@ -1,4 +1,7 @@
1
+
1
2
  module Supportcenter
2
- class ApplicationController < ActionController::Base
3
+ class ApplicationController < ApplicationController
4
+ include Rails.application.routes.url_helpers
5
+ layout "application"
3
6
  end
4
7
  end
@@ -0,0 +1,6 @@
1
+ require_dependency "supportcenter/application_controller"
2
+
3
+ module Supportcenter
4
+ class SupportTicketPositionsController < ApplicationController
5
+ end
6
+ end
@@ -1,9 +1,56 @@
1
- require_dependency "supportcenter/application_controller"
2
-
1
+ require 'mail'
3
2
  module Supportcenter
4
3
  class SupportTicketsController < ApplicationController
4
+ helper_method :receive_mail
5
5
  def index
6
- @support_tickets = SupportTickets.all
6
+ @support_tickets = SupportTicket.all
7
+ end
8
+
9
+ def show
10
+ @support_ticket = SupportTicket.where(code:params[:code]).first
11
+ @support_ticket_position = SupportTicketPosition.new
12
+ if !@support_ticket.user.blank? && current_user.role_id != 1
13
+ if current_user != @support_ticket.user
14
+ redirect_to main_app.news_path
15
+ end
16
+ else
17
+ #redirect_to "users/sign_in" , alert: 'This is not your Ticket'
18
+ end
19
+ end
20
+
21
+ def new
22
+ @support_ticket = SupportTicket.new
23
+ end
24
+
25
+ def create
26
+
27
+ end
28
+
29
+ def create_ticket_position
30
+ support_ticket = SupportTicket.find_by_code(params[:code])
31
+ if (support_ticket.user == current_user || current_user.role_id == 1 ) && !params["support_ticket_position"][:content].blank? && support_ticket.closed == false
32
+ support_ticket.update_attributes(closed:false,date_closed:nil)
33
+ SupportTicketPosition.create(content:params["support_ticket_position"][:content],user_id:current_user.id,support_ticket_id:support_ticket.id)
34
+ end
35
+
36
+ redirect_to "/supportcenter/#{params[:code]}"
37
+ end
38
+ def self.receive_mail
39
+ #Supportcenter::SupportTicketsController.receive_mail()
40
+ Mail.defaults do
41
+ retriever_method :pop3, :address => "pop.gmail.com",
42
+ :port => 995,
43
+ :user_name => 'mailongasshitemailaccatgm@gmail.com',
44
+ :password => 'xxx',
45
+ :enable_ssl => true
46
+ end
47
+ @mail = Mail.find(:what => :first,count:1000000, :order => :asc)
48
+ @mail.each do |mail|
49
+ if Email.where(email_id:mail.message_id).first.blank?
50
+ Email.create(sender:mail.from[0],email_id:mail.message_id ,send_date:mail.date.to_s,subject:mail.subject,body:((mail.text_part || mail.html_part || mail).body.decoded))
51
+ else
52
+ end
53
+ end
7
54
  end
8
55
  end
9
56
  end
@@ -1,4 +1,18 @@
1
1
  module Supportcenter
2
2
  module ApplicationHelper
3
+ def receive_mail
4
+ Mail.defaults do
5
+ retriever_method :pop3, :address => "pop.gmail.com",
6
+ :port => 995,
7
+ :user_name => 'info@4s-lan.com',
8
+ :password => '4sea15?4sea15',
9
+ :enable_ssl => true
10
+ end
11
+ @mail = Mail.all
12
+ @mail.each do |mail|
13
+ puts (mail.text_part || mail.html_part || mail).body.decoded
14
+ Email.create(sender:mail.from.addresses ,send_date:mail.date.to_s,subject:mail.subject,body:((mail.text_part || mail.html_part || mail).body.decoded))
15
+ end
16
+ end
3
17
  end
4
18
  end
@@ -0,0 +1,4 @@
1
+ module Supportcenter
2
+ module SupportTicketPositionsHelper
3
+ end
4
+ end
@@ -0,0 +1,4 @@
1
+ module Supportcenter
2
+ class Email < ActiveRecord::Base
3
+ end
4
+ end
@@ -1,4 +1,6 @@
1
1
  module Supportcenter
2
2
  class SupportTicket < ActiveRecord::Base
3
+ has_many :support_ticket_positions
4
+ belongs_to :user
3
5
  end
4
6
  end
@@ -0,0 +1,6 @@
1
+ module Supportcenter
2
+ class SupportTicketPosition < ActiveRecord::Base
3
+ belongs_to :support_ticket
4
+ belongs_to :user
5
+ end
6
+ end
@@ -0,0 +1,38 @@
1
+ <head>
2
+ <title>
3
+ <%= "4s LAN | #{@active_lanparty.name}" if @active_lanparty %>
4
+ <%= "4s LAN" unless @active_lanparty %>
5
+ </title>
6
+ <link rel="image_src" href="/assets/logo.png" />
7
+ <%= analytics_init if Rails.env.production? %>
8
+ <link rel="apple-touch-icon-precomposed" sizes="57x57" href="/assets/ios57.jpg" />
9
+ <link rel="apple-touch-icon-precomposed" sizes="72x72" href="/assets/ios72.jpg" />
10
+ <link rel="apple-touch-icon-precomposed" sizes="114x114" href="/assets/ios114.jpg" />
11
+ <link rel="apple-touch-icon-precomposed" sizes="144x144" href="/assets/ios144.jpg" />
12
+
13
+ <!--[if lt IE 9]>
14
+ <script src="http://html5shim.googlecode.com/svn/trunk/html5.js" type="text/javascript"></script>
15
+ <![endif]-->
16
+ <script type="text/javascript">
17
+ var global_address ='<%= "http://#{request.host}" %>';
18
+ <% if current_user %>
19
+ var current_user = '<%= current_user.username %>';
20
+ <% else %>
21
+ var current_user = 'guest';
22
+ <% end %>
23
+ </script>
24
+ <%= javascript_include_tag "application" %>
25
+ <%= stylesheet_link_tag "supportcenter/application", :media => "all" %>
26
+ <%= stylesheet_link_tag "application", :media => "all" %>
27
+ <%= stylesheet_link_tag 'jquery-ui-1.8.20.custom.css', :rel => 'text/css' %>
28
+ <%= csrf_meta_tags %>
29
+ <meta http-equiv="content-type" content="text/html; charset=utf-8" />
30
+ <meta content='width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0' name='viewport' />
31
+ <meta name="HandheldFriendly" content="true" />
32
+ <meta name="description" content="Eine 200 man Lanparty in Elsdorf und Umgebung: Elsdorf, Köln, Aachen, Düren, Jülich, Neuss, Düsseldorf, Geilenkirchen. Veranstaltet vom Netproject e.V. aus Geilenkirchen" />
33
+ <meta name="keywords" content="lanparty, lan, games, turniere, Elsdorf, Köln, Aachen, Düren, Jülich, Neuss, Geilenkirchen, Verein, Netproject, Gemeinnützig, 200 man" />
34
+ <meta http-equiv="Content-Language" content="de">
35
+ </head>
36
+
37
+
38
+ <%= yield %>
@@ -0,0 +1 @@
1
+ <%= @support_tickets.first.user %>
@@ -0,0 +1,36 @@
1
+ <table class="table">
2
+ <thead>
3
+ <th></th>
4
+ <th>Content</th>
5
+ <th></th>
6
+ </thead>
7
+ <tbody>
8
+ <tr>
9
+ <td><%=@support_ticket.user.username if current_user == @support_ticket.user%></td>
10
+ <td><%=@support_ticket.content%></td>
11
+ <td><%=@support_ticket.user.username if current_user != @support_ticket.user%></td>
12
+ </tr>
13
+ <% @support_ticket.support_ticket_positions.each do |support_ticket_position| %>
14
+ <tr>
15
+ <td><%=support_ticket_position.user.username if current_user == support_ticket_position.user%></td>
16
+ <td><%=support_ticket_position.content%></td>
17
+ <td><%=support_ticket_position.user.username if current_user != support_ticket_position.user%></td>
18
+ </tr>
19
+ <% end%>
20
+ </tbody>
21
+ </table>
22
+ <div class="input-group">
23
+ <% if @support_ticket.closed == false%>
24
+ <%= simple_form_for @support_ticket_position,html: {method: :post },url:"/supportcenter/#{params[:code]}" do |f| %>
25
+ <%= f.error_notification %>
26
+
27
+ <div class="form-inputs">
28
+ <%= f.input :content ,input_html: { class: "supportcenter-answer-box" }, label: "Message"%>
29
+ </div>
30
+
31
+ <div class="form-actions">
32
+ <%= f.button :submit ,value: "Submit ", :class => "btn btn-primary"%>
33
+ </div>
34
+ <% end %>
35
+ <% end %>
36
+ </div>
@@ -0,0 +1,2 @@
1
+ Encoding.default_external = Encoding::UTF_8
2
+ Encoding.default_internal = Encoding::UTF_8
@@ -1,3 +1,5 @@
1
- Supportcenter::Engine.routes.draw do
2
- root :to => "support_tickets#index"
1
+ Rails.application.routes.draw do
2
+ get "supportcenter/" => "Supportcenter/support_tickets#index"
3
+ get 'supportcenter/:code' => "Supportcenter/support_tickets#show", :as => :show
4
+ post 'supportcenter/:code' => "Supportcenter/support_tickets#create_ticket_position", :as => :show, :method => :post
3
5
  end
@@ -1,6 +1,6 @@
1
1
  class CreateSupportcenterSupportTickets < ActiveRecord::Migration
2
2
  def change
3
- create_table :supportcenter_support_tickets do |t|
3
+ create_table :support_tickets do |t|
4
4
  t.string :email
5
5
  t.string :code
6
6
  t.text :content
@@ -0,0 +1,10 @@
1
+ class CreateSupportcenterSupportTicketPositions < ActiveRecord::Migration
2
+ def change
3
+ create_table :support_ticket_positions do |t|
4
+ t.integer :support_ticket_id
5
+ t.text :content
6
+
7
+ t.timestamps
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,5 @@
1
+ class AddUserIdToSupportTicketPosition < ActiveRecord::Migration
2
+ def change
3
+ add_column :support_ticket_positions, :user_id, :integer
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddClosedToSupportTickets < ActiveRecord::Migration
2
+ def change
3
+ add_column :support_tickets, :closed, :boolean, default: false
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddDateClosedToSupportcenterSupportTickets < ActiveRecord::Migration
2
+ def change
3
+ add_column :support_tickets, :date_closed, :datetime
4
+ end
5
+ end
@@ -0,0 +1,12 @@
1
+ class CreateSupportcenterEmails < ActiveRecord::Migration
2
+ def change
3
+ create_table :emails do |t|
4
+ t.string :sender
5
+ t.string :subject
6
+ t.string :body
7
+ t.datetime :send_date
8
+
9
+ t.timestamps
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,5 @@
1
+ class ChangeContentOfSupportTickets < ActiveRecord::Migration
2
+ def change
3
+ change_column :support_ticket_positions, :content, :text
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class ChangeEmail < ActiveRecord::Migration
2
+ def change
3
+ change_column :emails, :body , :text
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddEmailIdToSupportcenterEmails < ActiveRecord::Migration
2
+ def change
3
+ add_column :emails, :email_id, :string
4
+ end
5
+ end
@@ -0,0 +1,36 @@
1
+ module Supportcenter
2
+ module Generators
3
+ class InstallGenerator < Rails::Generators::Base
4
+ source_root File.expand_path("../templates", __FILE__)
5
+ include Rails::Generators::Migration
6
+ desc "Shiiiiet"
7
+ class_option :orm
8
+
9
+ def setup_routes
10
+ route "mount Supportcenter::Engine => '/supportcenter'"
11
+ end
12
+
13
+ def self.next_migration_number(path)
14
+ unless @prev_migration_nr
15
+ @prev_migration_nr = Time.now.utc.strftime("%Y%m%d%H%M%S").to_i
16
+ else
17
+ @prev_migration_nr += 1
18
+ end
19
+ @prev_migration_nr.to_s
20
+ end
21
+
22
+ def copy_migrations
23
+ migration_template "20150922215753_create_support_tickets.rb", "db/migrate/create_support_tickets.rb"
24
+ migration_template "20150923102302_create_support_ticket_positions.rb", "db/migrate/create_support_ticket_positions.rb"
25
+ migration_template "20150923105748_add_user_id_to_support_ticket_position.rb", "db/migrate/add_user_id_to_support_ticket_position.rb"
26
+ migration_template "20150923122239_add_closed_to_support_tickets.rb", "db/migrate/add_closed_to_support_tickets.rb"
27
+ migration_template "20150923130700_add_date_closed_to_support_tickets.rb", "db/migrate/add_date_closed_to_support_tickets.rb"
28
+ migration_template "20150923141132_create_emails.rb", "db/migrate/create_emails.rb"
29
+ migration_template "20150923155417_change_content_of_support_tickets.rb", "db/migrate/change_content_of_support_tickets.rb"
30
+ migration_template "20150923155649_change_email.rb", "db/migrate/change_email.rb"
31
+ migration_template "20150924112427_add_email_id_to_emails.rb", "db/migrate/add_email_id_to_emails.rb"
32
+ end
33
+
34
+ end
35
+ end
36
+ end
@@ -0,0 +1,12 @@
1
+ class CreateSupportTickets < ActiveRecord::Migration
2
+ def change
3
+ create_table :support_tickets do |t|
4
+ t.string :email
5
+ t.string :code
6
+ t.text :content
7
+ t.integer :user_id
8
+
9
+ t.timestamps
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,10 @@
1
+ class CreateSupportTicketPositions < ActiveRecord::Migration
2
+ def change
3
+ create_table :support_ticket_positions do |t|
4
+ t.integer :support_ticket_id
5
+ t.text :content
6
+
7
+ t.timestamps
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,5 @@
1
+ class AddUserIdToSupportTicketPosition < ActiveRecord::Migration
2
+ def change
3
+ add_column :support_ticket_positions, :user_id, :integer
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddClosedToSupportTickets < ActiveRecord::Migration
2
+ def change
3
+ add_column :support_tickets, :closed, :boolean, default: false
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddDateClosedToSupportTickets < ActiveRecord::Migration
2
+ def change
3
+ add_column :support_tickets, :date_closed, :datetime
4
+ end
5
+ end
@@ -0,0 +1,12 @@
1
+ class CreateEmails < ActiveRecord::Migration
2
+ def change
3
+ create_table :emails do |t|
4
+ t.string :sender
5
+ t.string :subject
6
+ t.string :body
7
+ t.datetime :send_date
8
+
9
+ t.timestamps
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,5 @@
1
+ class ChangeContentOfSupportTickets < ActiveRecord::Migration
2
+ def change
3
+ change_column :support_ticket_positions, :content, :text
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class ChangeEmail < ActiveRecord::Migration
2
+ def change
3
+ change_column :emails, :body , :text
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddEmailIdToEmails < ActiveRecord::Migration
2
+ def change
3
+ add_column :emails, :email_id, :string
4
+ end
5
+ end
@@ -1,4 +1,4 @@
1
1
  require "supportcenter/engine"
2
-
3
2
  module Supportcenter
3
+ ActionView::Base.send :include, ApplicationHelper
4
4
  end
@@ -1,5 +1,5 @@
1
1
  module Supportcenter
2
2
  class Engine < ::Rails::Engine
3
- isolate_namespace Supportcenter
3
+ config.autoload_paths += Dir["#{config.root}/lib/**/"]
4
4
  end
5
5
  end
@@ -1,3 +1,3 @@
1
1
  module Supportcenter
2
- VERSION = "0.1.6"
2
+ VERSION = "0.1.7"
3
3
  end
@@ -0,0 +1,9 @@
1
+ require 'test_helper'
2
+
3
+ module Supportcenter
4
+ class SupportTicketPositionsControllerTest < ActionController::TestCase
5
+ # test "the truth" do
6
+ # assert true
7
+ # end
8
+ end
9
+ end
@@ -0,0 +1,13 @@
1
+ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2
+
3
+ one:
4
+ sender: MyString
5
+ subject: MyString
6
+ body: MyString
7
+ send_date: 2015-09-23 16:11:32
8
+
9
+ two:
10
+ sender: MyString
11
+ subject: MyString
12
+ body: MyString
13
+ send_date: 2015-09-23 16:11:32
@@ -0,0 +1,9 @@
1
+ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2
+
3
+ one:
4
+ support_ticket_id: 1
5
+ content: MyText
6
+
7
+ two:
8
+ support_ticket_id: 1
9
+ content: MyText
@@ -0,0 +1,6 @@
1
+ require 'test_helper'
2
+
3
+ module Supportcenter
4
+ class SupportTicketPositionsHelperTest < ActionView::TestCase
5
+ end
6
+ end
@@ -0,0 +1,9 @@
1
+ require 'test_helper'
2
+
3
+ module Supportcenter
4
+ class MailTest < ActiveSupport::TestCase
5
+ # test "the truth" do
6
+ # assert true
7
+ # end
8
+ end
9
+ end
@@ -0,0 +1,9 @@
1
+ require 'test_helper'
2
+
3
+ module Supportcenter
4
+ class SupportTicketPositionTest < ActiveSupport::TestCase
5
+ # test "the truth" do
6
+ # assert true
7
+ # end
8
+ end
9
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: supportcenter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Samer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-09-22 00:00:00.000000000 Z
11
+ date: 2015-09-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -24,6 +24,34 @@ dependencies:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: carrierwave
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: mailman
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
27
55
  - !ruby/object:Gem::Dependency
28
56
  name: sqlite3
29
57
  requirement: !ruby/object:Gem::Requirement
@@ -49,22 +77,51 @@ files:
49
77
  - README.rdoc
50
78
  - Rakefile
51
79
  - app/assets/javascripts/supportcenter/application.js
80
+ - app/assets/javascripts/supportcenter/support_ticket_positions.js
52
81
  - app/assets/javascripts/supportcenter/support_tickets.js
53
82
  - app/assets/stylesheets/supportcenter/application.css
83
+ - app/assets/stylesheets/supportcenter/support_ticket_positions.css
54
84
  - app/assets/stylesheets/supportcenter/support_tickets.css
55
85
  - app/controllers/supportcenter/application_controller.rb
86
+ - app/controllers/supportcenter/support_ticket_positions_controller.rb
56
87
  - app/controllers/supportcenter/support_tickets_controller.rb
57
88
  - app/helpers/supportcenter/application_helper.rb
89
+ - app/helpers/supportcenter/support_ticket_positions_helper.rb
58
90
  - app/helpers/supportcenter/support_tickets_helper.rb
91
+ - app/models/supportcenter/email.rb
59
92
  - app/models/supportcenter/support_ticket.rb
60
- - app/views/layouts/supportcenter/application.html.erb
93
+ - app/models/supportcenter/support_ticket_position.rb
94
+ - app/views/layouts/supportcenter/applications.html.erb
95
+ - app/views/supportcenter/support_tickets/_form.html.erb
61
96
  - app/views/supportcenter/support_tickets/index.html.erb
97
+ - app/views/supportcenter/support_tickets/new.html.erb
98
+ - app/views/supportcenter/support_tickets/show.html.erb
99
+ - config/environment.rb
62
100
  - config/routes.rb
63
- - db/migrate/20150922215753_create_supportcenter_support_tickets.rb
101
+ - db/migrate/20150922215753_create_support_tickets.rb
102
+ - db/migrate/20150923102302_create_support_ticket_positions.rb
103
+ - db/migrate/20150923105748_add_user_id_to_support_ticket_position.rb
104
+ - db/migrate/20150923122239_add_closed_to_support_tickets.rb
105
+ - db/migrate/20150923130700_add_date_closed_to_support_tickets.rb
106
+ - db/migrate/20150923141132_create_emails.rb
107
+ - db/migrate/20150923155417_change_content_of_support_tickets.rb
108
+ - db/migrate/20150923155649_change_email.rb
109
+ - db/migrate/20150924112427_add_email_id_to_emails.rb
110
+ - lib/generators/supportcenter/install_generator.rb
111
+ - lib/generators/supportcenter/templates/20150922215753_create_support_tickets.rb
112
+ - lib/generators/supportcenter/templates/20150923102302_create_support_ticket_positions.rb
113
+ - lib/generators/supportcenter/templates/20150923105748_add_user_id_to_support_ticket_position.rb
114
+ - lib/generators/supportcenter/templates/20150923122239_add_closed_to_support_tickets.rb
115
+ - lib/generators/supportcenter/templates/20150923130700_add_date_closed_to_support_tickets.rb
116
+ - lib/generators/supportcenter/templates/20150923141132_create_emails.rb
117
+ - lib/generators/supportcenter/templates/20150923155417_change_content_of_support_tickets.rb
118
+ - lib/generators/supportcenter/templates/20150923155649_change_email.rb
119
+ - lib/generators/supportcenter/templates/20150924112427_add_email_id_to_emails.rb
64
120
  - lib/supportcenter.rb
65
121
  - lib/supportcenter/engine.rb
66
122
  - lib/supportcenter/version.rb
67
123
  - lib/tasks/supportcenter_tasks.rake
124
+ - test/controllers/supportcenter/support_ticket_positions_controller_test.rb
68
125
  - test/controllers/supportcenter/support_tickets_controller_test.rb
69
126
  - test/dummy/README.rdoc
70
127
  - test/dummy/Rakefile
@@ -95,9 +152,14 @@ files:
95
152
  - test/dummy/public/500.html
96
153
  - test/dummy/public/favicon.ico
97
154
  - test/dummy/script/rails
155
+ - test/fixtures/supportcenter/mails.yml
156
+ - test/fixtures/supportcenter/support_ticket_positions.yml
98
157
  - test/fixtures/supportcenter/support_tickets.yml
158
+ - test/helpers/supportcenter/support_ticket_positions_helper_test.rb
99
159
  - test/helpers/supportcenter/support_tickets_helper_test.rb
100
160
  - test/integration/navigation_test.rb
161
+ - test/models/supportcenter/mail_test.rb
162
+ - test/models/supportcenter/support_ticket_position_test.rb
101
163
  - test/models/supportcenter/support_ticket_test.rb
102
164
  - test/supportcenter_test.rb
103
165
  - test/test_helper.rb
@@ -120,11 +182,12 @@ required_rubygems_version: !ruby/object:Gem::Requirement
120
182
  version: '0'
121
183
  requirements: []
122
184
  rubyforge_project:
123
- rubygems_version: 2.2.2
185
+ rubygems_version: 2.4.8
124
186
  signing_key:
125
187
  specification_version: 4
126
188
  summary: Summary of Supportcenter.
127
189
  test_files:
190
+ - test/controllers/supportcenter/support_ticket_positions_controller_test.rb
128
191
  - test/controllers/supportcenter/support_tickets_controller_test.rb
129
192
  - test/dummy/app/assets/javascripts/application.js
130
193
  - test/dummy/app/assets/stylesheets/application.css
@@ -155,9 +218,14 @@ test_files:
155
218
  - test/dummy/Rakefile
156
219
  - test/dummy/README.rdoc
157
220
  - test/dummy/script/rails
221
+ - test/fixtures/supportcenter/mails.yml
222
+ - test/fixtures/supportcenter/support_ticket_positions.yml
158
223
  - test/fixtures/supportcenter/support_tickets.yml
224
+ - test/helpers/supportcenter/support_ticket_positions_helper_test.rb
159
225
  - test/helpers/supportcenter/support_tickets_helper_test.rb
160
226
  - test/integration/navigation_test.rb
227
+ - test/models/supportcenter/mail_test.rb
228
+ - test/models/supportcenter/support_ticket_position_test.rb
161
229
  - test/models/supportcenter/support_ticket_test.rb
162
230
  - test/supportcenter_test.rb
163
231
  - test/test_helper.rb
@@ -1,14 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>Supportcenter</title>
5
- <%= stylesheet_link_tag "supportcenter/application", :media => "all" %>
6
- <%= javascript_include_tag "supportcenter/application" %>
7
- <%= csrf_meta_tags %>
8
- </head>
9
- <body>
10
-
11
- <%= yield %>
12
-
13
- </body>
14
- </html>