spree_mini_contact 0.1.2 → 0.1.3

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.
@@ -13,7 +13,7 @@ class ContactsController < Spree::BaseController
13
13
  respond_to do |format|
14
14
  if @contact.valid? && @contact.save
15
15
  ContactMailer.message_email(@contact).deliver
16
- format.html { redirect_to(contact_path, :notice => t("message_sent")) }
16
+ format.html { redirect_to(contact_path, :notice => t("mini_contact.message_sent")) }
17
17
  else
18
18
  format.html { render :action => "new" }
19
19
  end
@@ -1,7 +1,7 @@
1
1
  module Admin::ContactsHelper
2
2
 
3
3
  def link_to_view(resource)
4
- link_to_with_icon('view', t('view'), object_url(resource))
4
+ link_to_with_icon('view', t('mini_contact.view'), object_url(resource))
5
5
  end
6
6
 
7
7
  end
@@ -3,7 +3,7 @@ class ContactMailer < ActionMailer::Base
3
3
  def message_email(message)
4
4
  opts = {}
5
5
  opts[:to] = message.email
6
- opts[:subject] = "#{t('message_from')} #{Spree::Config[:site_name]}"
6
+ opts[:subject] = "#{t('mini_contact.message_from')} #{Spree::Config[:site_name]}"
7
7
  @message = message
8
8
  mail(opts)
9
9
  end
@@ -1,12 +1,12 @@
1
- <h1><%= t("contacts")%></h1>
1
+ <h1><%= t("mini_contact.contacts")%></h1>
2
2
 
3
3
  <table class="index">
4
4
  <tr>
5
5
  <%= hook :admin_contact_index_headers do %>
6
- <th><%= t("name") %></th>
7
- <th><%= t("email") %></th>
8
- <th><%= t("phone") %></th>
9
- <th><%= t("subject") %></th>
6
+ <th><%= t("mini_contact.name") %></th>
7
+ <th><%= t("mini_contact.email") %></th>
8
+ <th><%= t("mini_contact.phone") %></th>
9
+ <th><%= t("mini_contact.subject") %></th>
10
10
  <% end %>
11
11
  <th>
12
12
  <%= hook :admin_contact_index_header_actions %>
@@ -31,4 +31,4 @@
31
31
  </td>
32
32
  </tr>
33
33
  <% end %>
34
- </table>
34
+ </table>
@@ -1,40 +1,40 @@
1
- <h1><%= "#{t('contacts')} #{t('from')} #{@contact.name}" %></h1>
1
+ <h1><%= "#{t('mini_contact.contacts')} #{t('mini_contact.from')} #{@contact.name}" %></h1>
2
2
 
3
3
  <%= render :partial => 'admin/shared/contact_tabs', :locals => {:current => "Contact Details"} %>
4
4
 
5
5
  <%= hook :admin_contact_show do %>
6
- <div class="adr">
7
- <h4><%= t("name") %></h4>
8
- <p>
9
- <%= @contact.name %><br />
10
- </p>
11
- </div>
6
+ <div class="adr">
7
+ <h4><%= t("mini_contact.name") %></h4>
8
+ <p>
9
+ <%= @contact.name %><br />
10
+ </p>
11
+ </div>
12
12
 
13
- <div class="adr">
14
- <h4><%= t("email") %></h4>
15
- <p>
16
- <%= @contact.email %><br />
17
- </p>
18
- </div>
13
+ <div class="adr">
14
+ <h4><%= t("mini_contact.email") %></h4>
15
+ <p>
16
+ <%= @contact.email %><br />
17
+ </p>
18
+ </div>
19
19
 
20
- <div class="adr">
21
- <h4><%= t("phone") %></h4>
22
- <p>
23
- <%= @contact.phone %><br />
24
- </p>
25
- </div>
20
+ <div class="adr">
21
+ <h4><%= t("mini_contact.phone") %></h4>
22
+ <p>
23
+ <%= @contact.phone %><br />
24
+ </p>
25
+ </div>
26
26
 
27
- <div class="adr">
28
- <h4><%= t("subject") %></h4>
29
- <p>
30
- <%= @contact.subject %><br />
31
- </p>
32
- </div>
27
+ <div class="adr">
28
+ <h4><%= t("mini_contact.subject") %></h4>
29
+ <p>
30
+ <%= @contact.subject %><br />
31
+ </p>
32
+ </div>
33
33
 
34
- <div class="adr">
35
- <h4><%= t("message") %></h4>
36
- <p>
37
- <%= @contact.message %>
38
- </p>
39
- </div>
34
+ <div class="adr">
35
+ <h4><%= t("mini_contact.message") %></h4>
36
+ <p>
37
+ <%= @contact.message %>
38
+ </p>
39
+ </div>
40
40
  <% end %>
@@ -1,12 +1,12 @@
1
1
  <% content_for :sidebar do %>
2
2
  <ul class="sidebar">
3
- <%= hook :admin_contact_tabs do %>
4
- <li<%== ' class="active"' if current == 'Contact List' %>>
5
- <%= link_to t("contact_list"), collection_url() %>
6
- </li>
7
- <li<%== ' class="active"' if current == 'Contact Details' %>>
8
- <%= link_to t("contact_details"), object_url(@contact) %>
9
- </li>
10
- <% end %>
3
+ <%= hook :admin_contact_tabs do %>
4
+ <li<%== ' class="active"' if current == 'Contact List' %>>
5
+ <%= link_to t("mini_contact.contact_list"), collection_url() %>
6
+ </li>
7
+ <li<%== ' class="active"' if current == 'Contact Details' %>>
8
+ <%= link_to t("mini_contact.contact_details"), object_url(@contact) %>
9
+ </li>
10
+ <% end %>
11
11
  </ul>
12
12
  <% end %>
@@ -1,11 +1,11 @@
1
- <%= t('contact_email_greeting') %>
1
+ <%= t('mini_contact.greeting') %>
2
2
 
3
- <%= t('name') %>: <%= @message.name %>
4
- <%= t('email') %>: <%= @message.email %>
5
- <%= t('phone') %>: <%= @message.phone %>
6
- <%= t('subject') %>: <%= @message.subject %>
3
+ <%= t('mini_contact.name') %>: <%= @message.name %>
4
+ <%= t('mini_contact.email') %>: <%= @message.email %>
5
+ <%= t('mini_contact.phone') %>: <%= @message.phone %>
6
+ <%= t('mini_contact.subject') %>: <%= @message.subject %>
7
7
 
8
8
  <%= @message.message %>
9
9
 
10
- <%= t('contact_email_footer') %>
11
- <%= Spree::Config[:site_name] %>
10
+ <%= t('mini_contact.footer') %>
11
+ <%= Spree::Config[:site_name] %>
@@ -1,31 +1,13 @@
1
- <% @body_id = 'contact' %>
2
- <div id="contact-us">
3
- <%= hook :contact do %>
4
- <%= render "shared/error_messages", :target => @contact %>
5
- <%= form_for(@contact) do |f| %>
6
- <%= hook :contact_inside_form do %>
7
- <div class="field">
8
- <%= f.label :name, t("name") %><br />
9
- <%= f.text_field :name %>
10
- </div>
11
- <div class="field">
12
- <%= f.label :email, t("email") %><br />
13
- <%= f.text_field :email %>
14
- </div>
15
- <div class="field">
16
- <%= f.label :phone, t("phone") %><br />
17
- <%= f.text_field :phone %>
18
- </div>
19
- <div class="field">
20
- <%= f.label :subject, t("subject") %><br />
21
- <%= f.text_field :subject %>
22
- </div>
23
- <div class="field">
24
- <%= f.label :message, t("message") %><br />
25
- <%= f.text_area :message %>
26
- </div>
27
- <div class="action"><%= f.submit t("send_message"), :class => "button primary" %></div>
28
- <% end %>
29
- <% end %>
30
- <% end %>
31
- </div>
1
+ <%= form_for(@contact) do |f| %>
2
+ <%= f.label :name, t("mini_contact.name") %>
3
+ <%= f.text_field :name %>
4
+ <%= f.label :email, t("mini_contact.email") %>
5
+ <%= f.text_field :email %>
6
+ <%= f.label :phone, t("mini_contact.phone") %>
7
+ <%= f.text_field :phone %>
8
+ <%= f.label :subject, t("mini_contact.subject") %>
9
+ <%= f.text_field :subject %>
10
+ <%= f.label :message, t("mini_contact.message") %>
11
+ <%= f.text_area :message %>
12
+ <%= f.submit t("mini_contact.send_message"), :class => "button primary" %>
13
+ <% end %>
@@ -1,22 +1,24 @@
1
1
  en:
2
- contacts: Contacts
3
- contact: Contact us
4
- name: Name
5
- email: Email
6
- sent: Sent
7
- view: View
8
- message: Message
9
- order_number: Order number
10
- optionnal: optional
11
- name: Name
12
- email: Email
13
- phone: Phone
14
- subject: Subject
15
- contact_details: Contact details
16
- contact_list: Contacts list
17
2
  send_message: Send message
18
- message_sent: Thank You - Your email has been sent!
19
- from: from
20
- message_from: Message from
21
- contact_email_greeting: Thank you for your enquiry. Our staff will get back to you shortly. Please see your submission below.
22
- contact_email_footer: Regards,
3
+ mini_contact:
4
+ contacts: Contacts
5
+ contact: Contact us
6
+ name: Name
7
+ email: Email
8
+ sent: Sent
9
+ view: View
10
+ message: Message
11
+ order_number: Order number
12
+ optionnal: optional
13
+ name: Name
14
+ email: Email
15
+ phone: Phone
16
+ subject: Subject
17
+ contact_details: Contact details
18
+ contact_list: Contacts list
19
+ send_message: Send message
20
+ message_sent: Thank You - Your email has been sent!
21
+ from: from
22
+ message_from: Message from
23
+ greeting: Thank you for your enquiry. Our staff will get back to you shortly. Please see your submission below.
24
+ footer: Regards,
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spree_mini_contact
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,19 +9,19 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2011-11-05 00:00:00.000000000Z
12
+ date: 2011-11-06 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: spree_core
16
- requirement: &15666560 !ruby/object:Gem::Requirement
16
+ requirement: &5834380 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
20
20
  - !ruby/object:Gem::Version
21
- version: 0.40.0
21
+ version: '0.60'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *15666560
24
+ version_requirements: *5834380
25
25
  description: ! ' Basically the easiest way to implement a contact form.
26
26
 
27
27
  '