ish_manager 0.1.8.102 → 0.1.8.103

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3378fc29f8e0fb2ee52a8306808e243d93364352
4
- data.tar.gz: c95dab22724af775f9a5e06541080749facae9b1
3
+ metadata.gz: af5ce863cbb49710defb92563180eafb665aee13
4
+ data.tar.gz: afab02eae36558acd5b31efbebdecf59e030c425
5
5
  SHA512:
6
- metadata.gz: fe463c485749c794462d189c319fd7a139aee2c0f4c3c64bdae1b72270a07bd42baf33546814bd13796154dcaa6b83a1c24a98e96695dd96700dfda005f630d7
7
- data.tar.gz: 44c0a8dd91a10d25623b2307cfc541ad99fc47e31234323b2fde743b3990a9fdadbdd2fd77785425dde980ff0ae86ff8c2a0cf427aee2ad003b0a83cac1030d2
6
+ metadata.gz: 8b6495aba691333fd41d30a2ab96f5ecb0037d5342f2bce249fac28095b5f09e936e19617b5b8e9906dd1eaad0ea3dc2f6b5e483211346c3330160962cb49049
7
+ data.tar.gz: 1d4d18c166f12e65bd9b74d69716e0360d846e304f41fa2061c36a29cc30bffdbd1909c695b85305874762cd725cad74e2ebce60f9b5bea8fa6e2634e40174a5
@@ -77,6 +77,7 @@ class IshManager::ReportsController < IshManager::ApplicationController
77
77
 
78
78
  def create
79
79
  @report = Report.new params[:report].permit!
80
+ @report.user_profile = current_user.profile
80
81
  authorize! :create, @report
81
82
 
82
83
  @site = Site.where( :id => params[:report][:site_id] ).first
@@ -138,7 +138,8 @@ module IshManager::ImagesHelper
138
138
  end
139
139
 
140
140
  def image_new
141
- image_tag 'icons/32x32/new.png', :alt => '[+]'
141
+ raw('<i class="fa fa-plus-square"></i>')
142
+ # image_tag 'icons/32x32/new.png', :alt => '[+]'
142
143
  end
143
144
 
144
145
  # @deprecated, should use image_3s
@@ -238,4 +239,8 @@ module IshManager::ImagesHelper
238
239
  end
239
240
  end
240
241
 
242
+ def edit_img
243
+ raw('<i class="fa fa-pencil-square"></i>')
244
+ end
245
+
241
246
  end
@@ -55,10 +55,8 @@
55
55
 
56
56
  .row
57
57
  .col-md-6
58
- / Single button
59
- %label{} Sites
60
- .btn-group{:style => "width:100%"}
61
- = select :report, :site_id, @sites_list
58
+ = f.label :site
59
+ = f.select :site_id, options_for_select(@sites_list, :selected => report.site_id || params[:site_id] )
62
60
 
63
61
 
64
62
  .col-md-6
@@ -1,10 +1,16 @@
1
1
 
2
2
  - reports = reports.page( params[:reports_page] ).per( 10 )
3
-
3
+ - if site
4
+ - new_path = new_site_report_path( site.id )
5
+ - else
6
+ - new_path = new_report_path
7
+
4
8
  .manager-reports--index
5
9
  .row
6
10
  .col-sm-12
7
- %h2 Reports (#{reports.length})
11
+ %h2
12
+ Reports (#{reports.length})
13
+ = link_to image_new, new_path
8
14
 
9
15
  = paginate reports, :param_name => :reports_page
10
16
  %ol
@@ -5,7 +5,7 @@
5
5
  Reports Index (#{@reports.length})
6
6
  - if @site
7
7
  In #{@site.domain}/#{@site.lang}
8
- = link_to '[+]', new_report_path
8
+ = link_to image_new, new_report_path
9
9
 
10
10
  = paginate @reports, :param_name => :reports_page, :views_prefix => 'ish_manager'
11
11
 
@@ -6,10 +6,10 @@
6
6
  .row
7
7
  .col-lg-6
8
8
  = f.label :domain
9
- = f.text_field :domain, :disabled => true
9
+ = f.text_field :domain, :disabled => params[:action] == 'edit' ? true : false
10
10
  .col-lg-6
11
11
  = f.label :lang
12
- = f.text_field :lang, :disabled => true
12
+ = f.text_field :lang, :disabled => params[:action] == 'edit' ? true : false
13
13
 
14
14
  .row
15
15
  .col-lg-6
@@ -1,7 +1,9 @@
1
1
 
2
2
  - per_row = 2
3
3
  .sites-index
4
- %h3 Sites
4
+ %h3
5
+ Sites
6
+ = link_to raw('<i class="fa fa-plus-square"></i>'), new_site_path
5
7
  .row
6
8
  - @site_groups.each_with_index do |sites, index|
7
9
  .col-xs-12{ :class => "col-sm-#{12/per_row}" }
@@ -10,7 +12,7 @@
10
12
  - sites.each do |site|
11
13
  %h5
12
14
  = link_to "#{site.domain}/#{site.lang}", site_path( site )
13
- = link_to '[~]', edit_site_path( site )
15
+ = link_to edit_img, edit_site_path( site )
14
16
  (R#{site.reports.count}) (G#{site.galleries.count}) (V#{site.videos.count})
15
17
  - if (index + 1 ) % per_row == 0
16
18
  .clearfix
@@ -1,2 +1,4 @@
1
1
 
2
+ %h3 New Site
3
+
2
4
  = render 'form', :site => @site, :url => sites_path
@@ -8,7 +8,7 @@
8
8
  .col-sm-6
9
9
  = render 'ish_manager/galleries/list', :galleries => @galleries
10
10
  .col-sm-6
11
- = render 'ish_manager/reports/index', :reports => @reports
11
+ = render 'ish_manager/reports/index', :reports => @reports, :site => @site
12
12
 
13
13
  .row
14
14
  .col-sm-6
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.102
4
+ version: 0.1.8.103
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-12-06 00:00:00.000000000 Z
11
+ date: 2017-12-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails