tramway-event 1.9.28 → 1.9.29

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6722dde4b829b38429a1403e26b967326d932d3ae37a1f4c2e8858f6fe0784cc
4
- data.tar.gz: 0e6c0d0cf2989d4ac14daa4c5236160f72af1d10de0f78048021a8f157ddc16d
3
+ metadata.gz: cf3d72e709059acfcae7a33f0f01f792f211d8a951b7a772c8df3b7c7190fc0c
4
+ data.tar.gz: b40bd14865ecbf88c689580ca69586a0e990f353198ab98066464c16f012d919
5
5
  SHA512:
6
- metadata.gz: a4366960890115f07f118f7da6ea51ddc9bb4acb58c8ee5df5ded6f6d4e000437771d4a8d317a5b935a376ef1384734cbf370310ae73f1618a4045624f7fc79b
7
- data.tar.gz: 8593dd349e943ccfd494e1195e8cf43391149cadaa71e11730b8b35bce56f7fa8df0d8973f597d68d5068b8d0fd12af11c827633ab4ceada98bd6fd108b280fe
6
+ metadata.gz: e7c806800292b230ed68e1381a3e60c5a2deadf0143d57c07a98bd7dcc926301ed52ed703ae54d8e29e541d089d6fc3cef19fc6e2f2b8ea6716eb5449df56b6a
7
+ data.tar.gz: 012bf2e429ac2a7b0637906c589b973e69aeb172fb191e91289cefc6f3fae63875f2fc6f64ad9a3e52d5ea6581c70e7fa944cc81bcbf7e54d3e97f9be7d6c434
@@ -75,7 +75,7 @@ class Tramway::Event::EventDecorator < ::Tramway::Core::ApplicationDecorator
75
75
 
76
76
  def events_link
77
77
  event_link = Tramway::Event::Engine.routes.url_helpers.event_path object
78
- event_url = ['http://molodoy.online', event_link].join
78
+ event_url = [configus.host, event_link].join
79
79
  content_tag(:pre) do
80
80
  id = "event#{object.id}"
81
81
  concat link_to event_url, event_url, id: id
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class Tramway::Event::ParticipantXlsxDecorator < Tramway::Export::Xlsx::ApplicationDecorator
3
+ class Tramway::Event::ParticipantXlsDecorator < Tramway::Export::Xls::ApplicationDecorator
4
4
  class << self
5
5
  def columns
6
6
  %i[full_name email phone organization event].map do |attribute|
@@ -9,23 +9,31 @@ class Tramway::Event::ParticipantXlsxDecorator < Tramway::Export::Xlsx::Applicat
9
9
  end
10
10
 
11
11
  def filename
12
- 'participants.xlsx'
12
+ 'participants.xls'
13
13
  end
14
14
  end
15
15
 
16
16
  def full_name
17
+ return unless object.values
18
+
17
19
  "#{object.values['Фамилия'] || object.values['Фамилия ']} #{object.values['Имя'] || object.values['Имя ']}"
18
20
  end
19
21
 
20
22
  def email
23
+ return unless object.values
24
+
21
25
  object.values['Email']
22
26
  end
23
27
 
24
28
  def phone
29
+ return unless object.values
30
+
25
31
  object.values['Телефон']
26
32
  end
27
33
 
28
34
  def organization
35
+ return unless object.values
36
+
29
37
  object.values['Место работы/ Учебное заведение']
30
38
  end
31
39
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class Tramway::Event::EventForm < ::Tramway::Core::ApplicationForm
3
+ class Admin::Tramway::Event::EventForm < ::Tramway::Core::ApplicationForm
4
4
  properties :title, :description, :begin_date, :end_date, :photo, :status,
5
5
  :request_collecting_begin_date, :request_collecting_end_date, :short_description
6
6
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class Tramway::Event::PartakingForm < ::Tramway::Core::ApplicationForm
3
+ class Admin::Tramway::Event::PartakingForm < ::Tramway::Core::ApplicationForm
4
4
  properties :part_id, :part_type, :person_id, :position
5
5
  associations :person, :part
6
6
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  require 'securerandom'
4
4
 
5
- class Tramway::Event::ParticipantForm < ::Tramway::Core::ApplicationForm
5
+ class Admin::Tramway::Event::ParticipantForm < ::Tramway::Core::ApplicationForm
6
6
  properties :participation_state_event, :comment
7
7
  association :event
8
8
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class Tramway::Event::ParticipantFormFieldForm < ::Tramway::Core::ExtendedApplicationForm
3
+ class Admin::Tramway::Event::ParticipantFormFieldForm < ::Tramway::Core::ExtendedApplicationForm
4
4
  properties :title, :description, :field_type, :options, :position, :list_field
5
5
  association :event
6
6
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class Tramway::Event::PersonForm < ::Tramway::Core::ApplicationForm
3
+ class Admin::Tramway::Event::PersonForm < ::Tramway::Core::ApplicationForm
4
4
  properties :first_name, :last_name, :photo, :description
5
5
 
6
6
  def initialize(object)
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class Tramway::Event::PlaceForm < Tramway::Core::ApplicationForm
3
+ class Admin::Tramway::Event::PlaceForm < Tramway::Core::ApplicationForm
4
4
  properties :title, :description, :coordinates, :photo, :city
5
5
 
6
6
  def initialize(object)
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class Tramway::Event::SectionForm < ::Tramway::Core::ApplicationForm
3
+ class Admin::Tramway::Event::SectionForm < ::Tramway::Core::ApplicationForm
4
4
  properties :event, :title, :description, :photo, :icon, :position
5
5
  association :event
6
6
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Tramway
4
4
  module Event
5
- VERSION = '1.9.28'
5
+ VERSION = '1.9.29'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,15 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tramway-event
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.28
4
+ version: 1.9.29
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pavel Kalashnikov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-02-06 00:00:00.000000000 Z
12
- dependencies: []
11
+ date: 2020-02-17 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: configus
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
13
27
  description: Rails engine for events
14
28
  email:
15
29
  - kalashnikovisme@gmail.com
@@ -35,19 +49,19 @@ files:
35
49
  - app/decorators/tramway/event/partaking_feature_decorator.rb
36
50
  - app/decorators/tramway/event/participant_decorator.rb
37
51
  - app/decorators/tramway/event/participant_form_field_decorator.rb
38
- - app/decorators/tramway/event/participant_xlsx_decorator.rb
52
+ - app/decorators/tramway/event/participant_xls_decorator.rb
39
53
  - app/decorators/tramway/event/person_decorator.rb
40
54
  - app/decorators/tramway/event/place_decorator.rb
41
55
  - app/decorators/tramway/event/section_decorator.rb
42
56
  - app/decorators/tramway/event/section_feature_decorator.rb
43
- - app/forms/tramway/event/event_form.rb
44
- - app/forms/tramway/event/partaking_form.rb
57
+ - app/forms/admin/tramway/event/event_form.rb
58
+ - app/forms/admin/tramway/event/partaking_form.rb
59
+ - app/forms/admin/tramway/event/participant_form.rb
60
+ - app/forms/admin/tramway/event/participant_form_field_form.rb
61
+ - app/forms/admin/tramway/event/person_form.rb
62
+ - app/forms/admin/tramway/event/place_form.rb
63
+ - app/forms/admin/tramway/event/section_form.rb
45
64
  - app/forms/tramway/event/participant_extended_form_creator.rb
46
- - app/forms/tramway/event/participant_form.rb
47
- - app/forms/tramway/event/participant_form_field_form.rb
48
- - app/forms/tramway/event/person_form.rb
49
- - app/forms/tramway/event/place_form.rb
50
- - app/forms/tramway/event/section_form.rb
51
65
  - app/helpers/tramway/event/application_helper.rb
52
66
  - app/jobs/tramway/event/application_job.rb
53
67
  - app/mailers/tramway/event/application_mailer.rb