incline 0.2.14 → 0.2.15

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: bf040c758d3c9d16281ecb31a9717d2567946617
4
- data.tar.gz: 36e956d34e0835257aff3e0196519fe23d53d74c
3
+ metadata.gz: 189ee598dbe80457cd734f19b0555be60b13343a
4
+ data.tar.gz: 9cab9fd2b99b2f94380dc2aa522bf23a26c7f344
5
5
  SHA512:
6
- metadata.gz: 0ba2d1dace409afd8b3b06ddf65310219b09e0812e249379172a0da2bf9c6ad49400defa5e3833c2469d454540b40c8f88dcde3430e9a621014bbbae2d46d5a9
7
- data.tar.gz: 5bc80a718d8ac2a97ade503a98eb927bd346da0319da7c2636e6a5b20b51858fa59f0ae9f84348190cf51403c6888a9fba142d52cb3cdea757086ca64f0752ba
6
+ metadata.gz: 3851133292c0eb1efe0173b2327216086716ec44d1ed432f2a8eae7081094ad738e8cc374c63f537115361856e64a60a9941e243265b003cfff60286a5cdf015
7
+ data.tar.gz: a7855cf854c8b667d909837c0e38a0376dca630ba7ae918a2703c9bdc8c114af7edbaff0c3e732e8bb2e0b5c00d181f649dc718e094a753bedbdf4f47faaf275
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- incline (0.2.14)
4
+ incline (0.2.15)
5
5
  ansi (~> 1.5.0)
6
6
  bcrypt
7
7
  bootstrap-sass
@@ -58,7 +58,7 @@ GEM
58
58
  tzinfo (~> 1.1)
59
59
  ansi (1.5.0)
60
60
  arel (6.0.4)
61
- autoprefixer-rails (7.1.4)
61
+ autoprefixer-rails (7.1.4.1)
62
62
  execjs
63
63
  bcrypt (3.1.11)
64
64
  bootstrap-sass (3.3.7)
@@ -33,12 +33,15 @@
33
33
  data: function (row, type, set, meta) {
34
34
  if (type === 'display') {
35
35
  var ret = '<div class="text-right">';
36
+ var p_start = row.DT_Path.indexOf('?');
37
+ var item_path = p_start >= 0 ? row.DT_Path.substr(0, p_start) : row.DT_Path;
38
+ var item_params = p_start >= 0 ? row.DT_Path.substr(p_start) : '';
36
39
 
37
40
  // the show icon.
38
41
  ret += '<a href="javascript:inlineForm(\'' + row.DT_Path + '\')" title="Details" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-zoom-in"></i></a>';
39
42
 
40
43
  // the edit icon.
41
- ret += '<a href="javascript:inlineForm(\'' + row.DT_Path + '/edit\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
44
+ ret += '<a href="javascript:inlineForm(\'' + item_path + '/edit' + item_params + '\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
42
45
 
43
46
  // the delete icon.
44
47
  ret += '<a href="javascript:inlineAction(\'' + row.DT_Path + '\',\'delete\')" title="Remove" class="btn btn-danger btn-xs" data-confirm="Are you sure you want to remove this access group?"><i class="glyphicon glyphicon-trash"></i></a>';
@@ -64,12 +64,15 @@
64
64
  data: function (row, type, set, meta) {
65
65
  if (type === 'display') {
66
66
  var ret = '<div class="text-right">';
67
+ var p_start = row.DT_Path.indexOf('?');
68
+ var item_path = p_start >= 0 ? row.DT_Path.substr(0, p_start) : row.DT_Path;
69
+ var item_params = p_start >= 0 ? row.DT_Path.substr(p_start) : '';
67
70
 
68
- // the show icon.
69
- ret += '<a href="javascript:inlineForm(\'' + row.DT_Path + '\')" title="Details" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-zoom-in"></i></a>';
71
+ // the show icon.
72
+ ret += '<a href="javascript:inlineForm(\'' + row.DT_Path + '\')" title="Details" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-zoom-in"></i></a>';
70
73
 
71
- // the edit icon.
72
- ret += '<a href="javascript:inlineForm(\'' + row.DT_Path + '/edit\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
74
+ // the edit icon.
75
+ ret += '<a href="javascript:inlineForm(\'' + item_path + '/edit' + item_params + '\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
73
76
 
74
77
  ret += '</div>';
75
78
  return ret;
@@ -49,28 +49,31 @@
49
49
  {
50
50
  var ret = '<div class="text-right">';
51
51
  var drop = row.show_disable || row.show_enable || row.show_promote || row.show_demote || row.show_delete;
52
+ var p_start = row.DT_Path.indexOf('?');
53
+ var item_path = p_start >= 0 ? row.DT_Path.substr(0, p_start) : row.DT_Path;
54
+ var item_params = p_start >= 0 ? row.DT_Path.substr(p_start) : '';
52
55
 
53
56
  ret += '<a href="javascript:inlineForm(\'' + row.DT_Path + '\')" title="Details" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-zoom-in"></i></a>';
54
57
 
55
58
  if (drop) {
56
59
  ret += '&nbsp;<div class="btn-group">';
57
60
  if (row.show_edit) {
58
- ret += '<a href="javascript:inlineForm(\'' + row.DT_Path + '/edit\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
61
+ ret += '<a href="javascript:inlineForm(\'' + item_path + '/edit' + item_params + '\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
59
62
  } else {
60
63
  ret += '<a href="javascript:void(0)" title="Options" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-star"></i></a>';
61
64
  }
62
65
  ret += '<button type="button" class="btn btn-default btn-xs dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"><span class="caret"></span><span class="sr-only">Toggle Dropdown</span></button><ul class="dropdown-menu">'
63
66
 
64
67
  if (row.show_promote) {
65
- ret += '<li><a href="javascript:inlineAction(\'' + row.DT_Path + '/promote\',\'patch\')" title="Promote to administrator">Promote</a></li>';
68
+ ret += '<li><a href="javascript:inlineAction(\'' + item_path + '/promote' + item_params + '\',\'patch\')" title="Promote to administrator">Promote</a></li>';
66
69
  } else if (row.show_demote) {
67
- ret += '<li><a href="javascript:inlineAction(\'' + row.DT_Path + '/demote\',\'patch\')" title="Demote from administrator">Demote</a></li>';
70
+ ret += '<li><a href="javascript:inlineAction(\'' + item_path + '/demote' + item_params + '\',\'patch\')" title="Demote from administrator">Demote</a></li>';
68
71
  }
69
72
 
70
73
  if (row.show_disable) {
71
- ret += '<li><a href="javascript:inlineForm(\'' + row.DT_Path + '/disable\')" title="Disable">Disable</a></li>';
74
+ ret += '<li><a href="javascript:inlineForm(\'' + item_path + '/disable' + item_params + '\')" title="Disable">Disable</a></li>';
72
75
  } else if (row.show_enable) {
73
- ret += '<li><a href="javascript:inlineAction(\'' + row.DT_Path + '/enable\',\'patch\')" title="Enable">Enable</a></li>';
76
+ ret += '<li><a href="javascript:inlineAction(\'' + item_path + '/enable' + item_params + '\',\'patch\')" title="Enable">Enable</a></li>';
74
77
  }
75
78
 
76
79
  if (row.show_delete) {
@@ -80,7 +83,7 @@
80
83
  ret += '</ul></div>';
81
84
  } else {
82
85
  if (row.show_edit) {
83
- ret += '&nbsp;<a href="javascript:inlineForm(\'' + row.DT_Path + '/edit\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
86
+ ret += '&nbsp;<a href="javascript:inlineForm(\'' + item_path + '/edit' + item_params + '\')" title="Edit" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-pencil"></i></a>';
84
87
  }
85
88
  }
86
89
 
@@ -1,3 +1,3 @@
1
1
  module Incline
2
- VERSION = "0.2.14"
2
+ VERSION = "0.2.15"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: incline
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.14
4
+ version: 0.2.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Beau Barker