mix-rails 0.25.1 → 0.26.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/MIX_RAILS_VERSION +1 -1
- data/admix/lib/admix/version.rb +2 -2
- data/lib/mix-rails.rb +1 -2
- data/lib/mix-rails/contact-us.rb +1 -0
- data/mix-rails-addresses/lib/mix-rails-addresses/version.rb +2 -2
- data/mix-rails-albums/lib/mix-rails-albums/version.rb +2 -2
- data/mix-rails-auth/lib/mix-rails-auth/version.rb +2 -2
- data/mix-rails-contact-us/.gitignore +7 -0
- data/{mix-rails-vouchers → mix-rails-contact-us}/Gemfile +1 -1
- data/{mix-rails-message-board → mix-rails-contact-us}/MIT-LICENSE +0 -0
- data/mix-rails-contact-us/README.rdoc +3 -0
- data/{mix-rails-vouchers → mix-rails-contact-us}/Rakefile +1 -1
- data/{mix-rails-message-board/app/assets/images/message-board → mix-rails-contact-us/app/assets/images/mix-rails-contact-us}/.gitkeep +0 -0
- data/{mix-rails-message-board/app/assets/javascripts/message-board → mix-rails-contact-us/app/assets/javascripts/mix-rails-contact-us}/.gitkeep +0 -0
- data/{mix-rails-message-board/app/assets/stylesheets/message-board → mix-rails-contact-us/app/assets/stylesheets/mix-rails-contact-us}/.gitkeep +0 -0
- data/{mix-rails-message-board → mix-rails-contact-us}/app/controllers/.gitkeep +0 -0
- data/{mix-rails-message-board → mix-rails-contact-us}/app/helpers/.gitkeep +0 -0
- data/{mix-rails-message-board → mix-rails-contact-us}/app/mailers/.gitkeep +0 -0
- data/{mix-rails-message-board → mix-rails-contact-us}/app/models/.gitkeep +0 -0
- data/{mix-rails-message-board → mix-rails-contact-us}/app/views/.gitkeep +0 -0
- data/mix-rails-contact-us/config/routes.rb +2 -0
- data/mix-rails-contact-us/lib/mix-rails-contact-us.rb +4 -0
- data/mix-rails-contact-us/lib/mix-rails-contact-us/engine.rb +4 -0
- data/{mix-rails-vouchers/lib/mix-rails-vouchers → mix-rails-contact-us/lib/mix-rails-contact-us}/version.rb +4 -4
- data/{mix-rails-message-board/lib/tasks/message-board_tasks.rake → mix-rails-contact-us/lib/tasks/mix-rails-contact-us_tasks.rake} +1 -1
- data/{mix-rails-message-board/mix-rails-message-board.gemspec → mix-rails-contact-us/mix-rails-contact-us.gemspec} +5 -4
- data/{mix-rails-message-board → mix-rails-contact-us}/script/rails +1 -1
- data/mix-rails-core/lib/mix-rails-core/version.rb +2 -2
- data/mix-rails-settings/lib/mix-rails-settings/version.rb +2 -2
- data/mix-rails-songs/lib/mix-rails-songs/version.rb +2 -2
- data/mix-rails-videos/lib/mix-rails-videos/version.rb +2 -2
- data/mix-rails-wireframe/lib/mix-rails-wireframe/version.rb +2 -2
- data/mix-rails-writer/lib/mix-rails-writer/version.rb +2 -2
- data/mix-rails.gemspec +3 -4
- data/version.rb +2 -2
- metadata +54 -137
- data/lib/mix-rails/message-board.rb +0 -1
- data/lib/mix-rails/vouchers.rb +0 -1
- data/mix-rails-message-board/.gitignore +0 -7
- data/mix-rails-message-board/Gemfile +0 -17
- data/mix-rails-message-board/README.rdoc +0 -3
- data/mix-rails-message-board/Rakefile +0 -27
- data/mix-rails-message-board/app/controllers/admix/board_messages_controller.rb +0 -17
- data/mix-rails-message-board/app/controllers/admix/board_replies_controller.rb +0 -21
- data/mix-rails-message-board/app/controllers/admix/dashboard_controller.rb +0 -7
- data/mix-rails-message-board/app/controllers/board_messages_controller.rb +0 -23
- data/mix-rails-message-board/app/mailers/message_board_mailer.rb +0 -10
- data/mix-rails-message-board/app/models/board_message.rb +0 -20
- data/mix-rails-message-board/app/models/board_reply.rb +0 -27
- data/mix-rails-message-board/app/views/admix/board_messages/_form_config.haml +0 -8
- data/mix-rails-message-board/app/views/admix/board_messages/_grid_actions.haml +0 -8
- data/mix-rails-message-board/app/views/admix/board_messages/_grid_columns.haml +0 -9
- data/mix-rails-message-board/app/views/admix/board_messages/_show.html.haml +0 -16
- data/mix-rails-message-board/app/views/admix/board_messages/_table_actions.html.haml +0 -10
- data/mix-rails-message-board/app/views/admix/board_replies/_form_config.haml +0 -8
- data/mix-rails-message-board/app/views/admix/board_replies/_grid_actions.haml +0 -8
- data/mix-rails-message-board/app/views/admix/board_replies/_grid_columns.haml +0 -9
- data/mix-rails-message-board/app/views/admix/board_replies/_show.html.haml +0 -11
- data/mix-rails-message-board/app/views/admix/board_replies/_table_actions.html.haml +0 -8
- data/mix-rails-message-board/app/views/admix/dashboard/index.html.haml +0 -4
- data/mix-rails-message-board/app/views/board_messages/_board_message.html.haml +0 -21
- data/mix-rails-message-board/app/views/board_messages/index.html.haml +0 -16
- data/mix-rails-message-board/app/views/board_messages/show.html.haml +0 -9
- data/mix-rails-message-board/app/views/message_board_mailer/message_replied.text.erb +0 -7
- data/mix-rails-message-board/config/locales/message-board.pt-BR.yml +0 -52
- data/mix-rails-message-board/config/routes.rb +0 -20
- data/mix-rails-message-board/db/migrate/20130208130406_create_board_messages.rb +0 -13
- data/mix-rails-message-board/db/migrate/20130208130716_create_board_replies.rb +0 -14
- data/mix-rails-message-board/lib/mix-rails-message-board.rb +0 -4
- data/mix-rails-message-board/lib/mix-rails-message-board/engine.rb +0 -22
- data/mix-rails-message-board/lib/mix-rails-message-board/version.rb +0 -10
- data/mix-rails-vouchers/.gitignore +0 -7
- data/mix-rails-vouchers/MIT-LICENSE +0 -20
- data/mix-rails-vouchers/README.rdoc +0 -3
- data/mix-rails-vouchers/app/assets/images/mix-vouchers/.gitkeep +0 -0
- data/mix-rails-vouchers/app/assets/javascripts/mix-vouchers/.gitkeep +0 -0
- data/mix-rails-vouchers/app/assets/stylesheets/mix-vouchers/.gitkeep +0 -0
- data/mix-rails-vouchers/app/controllers/admix/vouchers_controller.rb +0 -24
- data/mix-rails-vouchers/app/controllers/vouchers_controller.rb +0 -68
- data/mix-rails-vouchers/app/helpers/.gitkeep +0 -0
- data/mix-rails-vouchers/app/mailers/.gitkeep +0 -0
- data/mix-rails-vouchers/app/mailers/voucher_mailer.rb +0 -10
- data/mix-rails-vouchers/app/models/email_validator.rb +0 -9
- data/mix-rails-vouchers/app/models/voucher.rb +0 -18
- data/mix-rails-vouchers/app/models/voucher_user.rb +0 -43
- data/mix-rails-vouchers/app/models/vouchers/contact.rb +0 -17
- data/mix-rails-vouchers/app/uploaders/vouchers/photo_uploader.rb +0 -63
- data/mix-rails-vouchers/app/views/.gitkeep +0 -0
- data/mix-rails-vouchers/app/views/admix/vouchers/_form_config.haml +0 -15
- data/mix-rails-vouchers/app/views/admix/vouchers/_show.html.haml +0 -9
- data/mix-rails-vouchers/app/views/admix/vouchers/_table_actions.html.haml +0 -9
- data/mix-rails-vouchers/app/views/admix/vouchers/print.html.haml +0 -27
- data/mix-rails-vouchers/app/views/admix/vouchers/users.html.haml +0 -31
- data/mix-rails-vouchers/app/views/voucher_mailer/send_confirmation_link.text.erb +0 -7
- data/mix-rails-vouchers/app/views/vouchers/_voucher.html.haml +0 -12
- data/mix-rails-vouchers/app/views/vouchers/_voucher_show.html.haml +0 -30
- data/mix-rails-vouchers/app/views/vouchers/confirmation.html.haml +0 -0
- data/mix-rails-vouchers/app/views/vouchers/confirmation_error.html.haml +0 -5
- data/mix-rails-vouchers/app/views/vouchers/email_sent.html.haml +0 -4
- data/mix-rails-vouchers/app/views/vouchers/index.html.haml +0 -9
- data/mix-rails-vouchers/app/views/vouchers/print.html.haml +0 -56
- data/mix-rails-vouchers/app/views/vouchers/show.html.haml +0 -3
- data/mix-rails-vouchers/config/locales/vouchers.pt-BR.yml +0 -16
- data/mix-rails-vouchers/config/routes.rb +0 -15
- data/mix-rails-vouchers/db/migrate/20130208143458_create_vouchers.rb +0 -15
- data/mix-rails-vouchers/db/migrate/20130208143613_create_voucher_users.rb +0 -13
- data/mix-rails-vouchers/lib/mix-rails-vouchers.rb +0 -4
- data/mix-rails-vouchers/lib/mix-rails-vouchers/engine.rb +0 -21
- data/mix-rails-vouchers/lib/tasks/mix-vouchers_tasks.rake +0 -4
- data/mix-rails-vouchers/mix-rails-vouchers.gemspec +0 -20
- data/mix-rails-vouchers/script/rails +0 -8
@@ -1,27 +0,0 @@
|
|
1
|
-
!!!
|
2
|
-
%html
|
3
|
-
%head
|
4
|
-
%meta{:charset => "utf-8"}
|
5
|
-
%meta{:content => "noindex, nofollow", :name => "robots"}
|
6
|
-
%title Admix
|
7
|
-
= stylesheet_link_tag "admix/application", :media => "all"
|
8
|
-
= javascript_include_tag "admix/application"
|
9
|
-
= csrf_meta_tags
|
10
|
-
%body
|
11
|
-
%h2 Lista do voucher "#{@voucher.name}"
|
12
|
-
- if @users.length > 0
|
13
|
-
%table.table
|
14
|
-
%thead
|
15
|
-
%tr
|
16
|
-
%th Nome
|
17
|
-
%th Email
|
18
|
-
%tbody
|
19
|
-
- @users.each do |user|
|
20
|
-
%tr
|
21
|
-
%td= user.name.titleize
|
22
|
-
%td= user.email.downcase
|
23
|
-
|
24
|
-
%script
|
25
|
-
window.print();
|
26
|
-
- else
|
27
|
-
%p Nenhum cliente imprimiu este voucher
|
@@ -1,31 +0,0 @@
|
|
1
|
-
%h1 Usuários do voucher "#{@voucher.name}"
|
2
|
-
|
3
|
-
- if @users.length > 0
|
4
|
-
%table.table.table-striped
|
5
|
-
%table.table
|
6
|
-
%thead
|
7
|
-
%tr
|
8
|
-
%th Nome
|
9
|
-
%th Email
|
10
|
-
%th Confirmou por email?
|
11
|
-
%th Ações
|
12
|
-
%tbody
|
13
|
-
- @users.each do |user|
|
14
|
-
%tr
|
15
|
-
%td= user.name.titleize
|
16
|
-
%td= user.email.downcase
|
17
|
-
%td= user.confirmed ? 'Sim' : 'Não'
|
18
|
-
%td
|
19
|
-
= link_to image_tag('admix/icons/delete.png'), admix_voucher_user_delete_url(id: @voucher.id, user_id: user.id), method: :delete, class: 'btn', title: 'Deletar este usuário'
|
20
|
-
- if user.confirmed
|
21
|
-
= link_to image_tag('admix/icons/printer.png'), vouchers_print_url(id: @voucher.id, user_id: user.id), class: 'btn', title: 'Imprimir voucher do usuário'
|
22
|
-
- else
|
23
|
-
%a.btn.disabled{title: 'Usuário não confirmado'}= image_tag('admix/icons/printer.png')
|
24
|
-
|
25
|
-
- else
|
26
|
-
%p Nenhum cliente requisitou este voucher
|
27
|
-
|
28
|
-
|
29
|
-
= link_to t('admix.crud.back'), collection_url, class: 'btn'
|
30
|
-
|
31
|
-
|
@@ -1,30 +0,0 @@
|
|
1
|
-
.row
|
2
|
-
.span5
|
3
|
-
= image_tag voucher.photo.url
|
4
|
-
.span10.offset1
|
5
|
-
%p.fz18.fb.white
|
6
|
-
= voucher.name
|
7
|
-
%p.p.red.fz14.fb Regras de utilização:
|
8
|
-
!= voucher.rules
|
9
|
-
%hr
|
10
|
-
%div
|
11
|
-
%h3.fb.white.p.mini Imprima seu Voucher
|
12
|
-
%p.muted.p
|
13
|
-
Para ter acesso ao voucher é necessário preencher apenas essas informações abaixo e imprimir o cupom que será gerado na tela seguinte e apresentá-lo no estabelecimento para obter o benefício.
|
14
|
-
|
15
|
-
= simple_form_for @user, url: vouchers_send_confirmation_url do |f|
|
16
|
-
%form{:action => vouchers_send_confirmation_url}
|
17
|
-
.row.p.mini
|
18
|
-
.span
|
19
|
-
= f.label :name
|
20
|
-
= f.input_field :name, class: 'span8'
|
21
|
-
%p
|
22
|
-
= f.error :name
|
23
|
-
.span.offset1
|
24
|
-
= f.label :email
|
25
|
-
= f.input_field :email, class: 'span7', type: :email
|
26
|
-
%p
|
27
|
-
= f.error :email
|
28
|
-
.ta-r
|
29
|
-
%button.no-style{:type => "submit"}
|
30
|
-
= image_tag 'btn_seguir.png'
|
File without changes
|
@@ -1,56 +0,0 @@
|
|
1
|
-
!!!
|
2
|
-
%html
|
3
|
-
%head
|
4
|
-
%meta{:charset => "utf-8"}
|
5
|
-
%meta{:content => "IE=edge,chrome=1", "http-equiv" => "X-UA-Compatible"}
|
6
|
-
%title Forro com Turista
|
7
|
-
%meta{:content => "width=device-width", :name => "viewport"}
|
8
|
-
%meta{:content => "", :name => "description"}
|
9
|
-
%meta{:content => "", :name => "keywords"}
|
10
|
-
= stylesheet_link_tag "application", :media => "all"
|
11
|
-
= javascript_include_tag "application"
|
12
|
-
= csrf_meta_tags
|
13
|
-
%link{:href => "favicon.png", :rel => "shortcut icon", :type => "image/png"}
|
14
|
-
%link{:href => "http://fonts.googleapis.com/css?family=Open+Sans:600italic,800italic,700,400", :rel => "stylesheet", :type => "text/css"}
|
15
|
-
%body.print
|
16
|
-
.row
|
17
|
-
.span16
|
18
|
-
.row.p
|
19
|
-
.span8
|
20
|
-
= image_tag 'logo_bw.png'
|
21
|
-
.span8.ta-r
|
22
|
-
.p.inverse
|
23
|
-
%h2.i Voucher de desconto
|
24
|
-
%p.i.gray.fz14.b forrocomturista.com.br
|
25
|
-
.line.big.p
|
26
|
-
%h2.i.p= @voucher.name
|
27
|
-
%p.fz14.p.b.i Regras de utilização:
|
28
|
-
%p.muted.p!= @voucher.rules
|
29
|
-
|
30
|
-
.pad-content.p.super
|
31
|
-
%table
|
32
|
-
%tbody
|
33
|
-
%tr
|
34
|
-
%td.gray.fz14
|
35
|
-
Nome:
|
36
|
-
%strong.gray= @user.name
|
37
|
-
%tr
|
38
|
-
%td.gray.fz14
|
39
|
-
Email:
|
40
|
-
%strong.gray= @user.email
|
41
|
-
%tr
|
42
|
-
%td.gray.fz14
|
43
|
-
Data de Impressão:
|
44
|
-
%strong.gray= @user.confirmation_date.strftime("%d/%m/%Y")
|
45
|
-
%tr
|
46
|
-
%td.gray.fz14
|
47
|
-
Válido até
|
48
|
-
%strong.gray= @voucher.date_to.strftime("%d/%m/%Y")
|
49
|
-
.line.big.p.super
|
50
|
-
%p.ta-c.i.fz14
|
51
|
-
Agradecemos seu interesse em nossos produtos/serviços,vamos continuar trabalhando
|
52
|
-
para que sua experiência em Natal/RN seja sempre inesquessível!
|
53
|
-
%br
|
54
|
-
%strong.fz18 www.forrocomturista.com.br
|
55
|
-
%script
|
56
|
-
window.print();
|
@@ -1,16 +0,0 @@
|
|
1
|
-
pt-BR:
|
2
|
-
vouchers:
|
3
|
-
vouchers: 'Vouchers'
|
4
|
-
voucher: 'Voucher'
|
5
|
-
mailers:
|
6
|
-
send_confirmation_link:
|
7
|
-
subject: 'Imprima seu Voucher'
|
8
|
-
fields:
|
9
|
-
name: 'Nome'
|
10
|
-
date_from: 'Válido de'
|
11
|
-
date_to: 'Válido até'
|
12
|
-
rules: 'Regras'
|
13
|
-
photo: 'Foto'
|
14
|
-
partner_photo: 'Foto do parceiro'
|
15
|
-
errors:
|
16
|
-
invalid_email: 'Email inválido'
|
@@ -1,15 +0,0 @@
|
|
1
|
-
Rails.application.routes.draw do
|
2
|
-
resources :vouchers
|
3
|
-
|
4
|
-
post 'vouchers/:id' => 'vouchers#send_confirmation', as: :vouchers_send_confirmation
|
5
|
-
match 'vouchers/:id/email-enviado' => 'vouchers#email_sent', as: :vouchers_email_sent
|
6
|
-
match 'vouchers/:id/confirm/:user_id' => 'vouchers#confirmation', as: :vouchers_confirmation
|
7
|
-
match 'vouchers/:id/imprimir/:user_id' => 'vouchers#print', as: :vouchers_print
|
8
|
-
|
9
|
-
scope Admix::namespace_path, as: :admix, module: :admix do
|
10
|
-
get 'vouchers/:id/users/print' => 'vouchers#print', as: :voucher_print
|
11
|
-
get 'vouchers/:id/users' => 'vouchers#users', as: :voucher_users
|
12
|
-
delete 'vouchers/:id/users/:user_id/delete' => 'vouchers#delete_user', as: :voucher_user_delete
|
13
|
-
resources :vouchers
|
14
|
-
end
|
15
|
-
end
|
@@ -1,15 +0,0 @@
|
|
1
|
-
class CreateVouchers < ActiveRecord::Migration
|
2
|
-
def change
|
3
|
-
create_table :vouchers do |t|
|
4
|
-
t.string :name
|
5
|
-
t.text :rules
|
6
|
-
t.date :date_from
|
7
|
-
t.date :date_to
|
8
|
-
t.string :photo
|
9
|
-
t.string :partner_photo
|
10
|
-
t.string :slug
|
11
|
-
|
12
|
-
t.timestamps
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
@@ -1,21 +0,0 @@
|
|
1
|
-
module MixRailsVouchers
|
2
|
-
class Engine < ::Rails::Engine
|
3
|
-
|
4
|
-
def navigation
|
5
|
-
if defined? Admix
|
6
|
-
|
7
|
-
Admix::Navigation::NavBar.post_menu do
|
8
|
-
Admix::Navigation::NavBar.find(:content) do |menu|
|
9
|
-
menu.submenu do |submenu|
|
10
|
-
submenu.key = :vouchers
|
11
|
-
submenu.title = I18n.t 'vouchers.vouchers'
|
12
|
-
submenu.url = 'admix_vouchers_url'
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
16
|
-
|
17
|
-
end
|
18
|
-
end
|
19
|
-
|
20
|
-
end
|
21
|
-
end
|
@@ -1,20 +0,0 @@
|
|
1
|
-
$:.push File.expand_path("../lib", __FILE__)
|
2
|
-
|
3
|
-
# Maintain your gem's version:
|
4
|
-
version = File.read(File.expand_path('../../MIX_RAILS_VERSION', __FILE__)).strip
|
5
|
-
|
6
|
-
# Describe your gem and declare its dependencies:
|
7
|
-
Gem::Specification.new do |s|
|
8
|
-
s.name = "mix-rails-vouchers"
|
9
|
-
s.version = version
|
10
|
-
s.authors = ["Rafael Garcia", "Sadjow Medeiros Leão"]
|
11
|
-
s.email = ["rafbgarcia@gmail.com", "sadjow@gmail.com"]
|
12
|
-
s.homepage = "https://github.com/mixinternet/mix-rails"
|
13
|
-
s.summary = "Vouchers module for mix-rails"
|
14
|
-
s.description = "Vouchers module for mix-rails"
|
15
|
-
|
16
|
-
s.files = Dir["{app,config,db,lib}/**/*"] + ["MIT-LICENSE", "Rakefile", "README.rdoc"]
|
17
|
-
|
18
|
-
s.add_dependency 'mail_form', '~> 1.4.0'
|
19
|
-
s.add_dependency "rails", "~> 3.2.9"
|
20
|
-
end
|
@@ -1,8 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby1.9.1
|
2
|
-
# This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
|
3
|
-
|
4
|
-
ENGINE_ROOT = File.expand_path('../..', __FILE__)
|
5
|
-
ENGINE_PATH = File.expand_path('../../lib/mix-rails-vouchers/engine', __FILE__)
|
6
|
-
|
7
|
-
require 'rails/all'
|
8
|
-
require 'rails/engine/commands'
|