ish_manager 0.1.8.32 → 0.1.8.33

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
  SHA1:
3
- metadata.gz: a1df70026a3d6cd74f73cd3e8515e540e56e55db
4
- data.tar.gz: 30add02fca20290c47fc4a3d4c423a540ab7b024
3
+ metadata.gz: 6632b14e4f481e7ff53f96df5614fef857f9a7d3
4
+ data.tar.gz: 55e69a6d9dd528ddb53c0f95dbb1cf1b11ac5087
5
5
  SHA512:
6
- metadata.gz: fc349a69f9bca8f46970e0bd3812ca9e8c25af017c0a01d468a193e735dda96c381257f29d80698489b48403de5606b984b89ea9d01e2274f3d7d3113db5e5a9
7
- data.tar.gz: a990070bacee2bf77d4d74747408eb83147da9d865af6b81b33a78f341b34a4389faac41a4c814fb8af1aa007a3fea3f5b9bfea061fe2bdba9042c601102cbca
6
+ metadata.gz: 676d24598fe531e4a5c696c01a248ff032ea02e35924526a63192adbeffc5de99506130d74d42b10cfb56ad96e8bfb490c6f26c319018511b91fa11f2f07fce3
7
+ data.tar.gz: 0d4b9b341ce4c2b4f9df4687ed31264cc5ef932e8cd43861ec5eaaaf53b3d8a4bee015fbef41da639e5870bb859392c53f7c293fb49ac1758b925ef7417232d5
@@ -42,7 +42,12 @@ class IshManager::CitiesController < IshManager::ApplicationController
42
42
  @city = City.find( params[:id] )
43
43
  authorize! :update, @city
44
44
  @city.update_attributes params[:city].permit!
45
+ if params[:photo]
46
+ photo = Photo.new :photo => params[:photo]
47
+ @city.profile_photo = photo
48
+ end
45
49
  if @city.save
50
+ ::IshModels::CacheKey.one.update_attributes( :cities => Time.now )
46
51
  flash[:notice] = 'Success'
47
52
  redirect_to edit_city_path @city.id
48
53
  else
@@ -1,11 +1,15 @@
1
1
 
2
2
  .manager-cities--form
3
- = form_for @city do |f|
3
+ = form_for @city, :html => { :multipart => true } do |f|
4
4
  .row
5
- .small-6.columns
5
+ .col-sm-6
6
6
  .field
7
7
  %label= t('cities.name')
8
8
  = f.text_field :name
9
+ .field
10
+ %label CityName
11
+ = f.text_field :cityname
12
+ .col-sm-6
9
13
  .field
10
14
  = image_flag 'en'
11
15
  %label= t('cities.name_en')
@@ -18,36 +22,30 @@
18
22
  = image_flag 'pt'
19
23
  %label= t('cities.name')
20
24
  = f.text_field :name_pt
25
+ .col-sm-6
21
26
  .field
22
- %label CityName
23
- = f.text_field :cityname
24
- .small-6.columns
25
- .field
26
- %label Feature?
27
27
  = f.check_box :is_feature
28
+ = f.label :is_feature
28
29
  .field
29
30
  = f.label :n_features
30
31
  = f.number_field :n_features
31
-
32
+ .change-profile-pic
33
+ %label Change profile pic
34
+ = file_field_tag :photo
35
+ - begin
36
+ = image_tag @city.profile_photo.photo.url(:thumb)
37
+ - rescue
38
+ .col-sm-6
32
39
  .field
33
40
  = f.label :description
34
- = f.text_area :description, :class => [ :tinymce ]
35
-
36
- .field
37
- %label Calendar
38
- = f.text_area :calendar_frame
41
+ = f.text_area :description, :class => [ :tinymce ]
39
42
  .field
40
43
  %label coords
41
- = f.text_field :x
42
- = f.text_field :y
43
-
44
- -# Only if editing
45
- - unless @city.updated_at.blank?
46
- .change-profile-pic
47
- %h2 Change profile pic
48
- - begin
49
- = image_tag @city.profile_photo.photo.url(:thumb)
50
- - rescue
51
-
44
+ .row
45
+ .col-xs-6
46
+ = f.text_field :x
47
+ .col-xs-6
48
+ = f.text_field :y
49
+ .col-xs-12
52
50
  .actions
53
51
  = f.submit
@@ -25,7 +25,7 @@
25
25
  %br
26
26
  = f.label :link_path
27
27
  = f.text_field :link_path
28
- %br
28
+ -# %br
29
29
  = f.label :photo
30
30
  = f.file_field :photo
31
31
  .large-6.columns
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ish_manager
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.8.32
4
+ version: 0.1.8.33
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-05 00:00:00.000000000 Z
11
+ date: 2017-08-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails