promethee 2.0.1 → 2.0.2
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 +4 -4
- data/UPGRADING +4 -4
- data/app/views/promethee/components/table/_edit.inspect.html.erb +18 -18
- data/lib/promethee/rails/version.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2fe4616403b3cb90eabe63970ede14b99291932c00ef08029953c7f0144f2850
|
4
|
+
data.tar.gz: 90094a3691ace6bd8c5e68385a7ac16812cc5c08444edf209e506612896daa9c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 54c0b10dda4b63f6ae60dae11693b6e85f5ae6b10988b871198c340281f09ccb9a95f0d5aa3d288af6d1b6860a053501bba7c9d5471d4c59c189ee067cb29dd0
|
7
|
+
data.tar.gz: bb5019bf8e33a52429482c451dde3e3dee723605a88aeaf6610e1235d9f90a4a4a29e5cca207d0e6e391b04aeaaa57d51006ac3c3151993b994e3b5ca9ccf5f8
|
data/UPGRADING
CHANGED
@@ -1,10 +1,10 @@
|
|
1
|
-
|
2
|
-
# NOTE FOR UPGRADING
|
3
|
-
|
1
|
+
###################################
|
2
|
+
# NOTE FOR UPGRADING FROM 1.x.x #
|
3
|
+
###################################
|
4
4
|
|
5
5
|
Prométhée 2.0 brings:
|
6
6
|
- [BREAKING CHANGE] New structure for table component. A rake task is available to update them in your master models. Localization has to be manual.
|
7
7
|
- [TOOL TO FIX ISSUE] A rake task to clean your localization models.
|
8
8
|
|
9
9
|
For more details, check the documentation:
|
10
|
-
https://github.com/lespoupeesrusses/promethee/tree/
|
10
|
+
https://github.com/lespoupeesrusses/promethee/tree/master/doc
|
@@ -1,20 +1,20 @@
|
|
1
1
|
<script type="text/ng-template" id="promethee/components/table/edit/inspect">
|
2
|
-
<div ng-controller="TableInspectController"
|
2
|
+
<div ng-controller="TableInspectController">
|
3
3
|
<div class="form-group">
|
4
4
|
<label class="label-control">Columns</label><br/>
|
5
5
|
<div class="btn btn-default btn-light btn-sm"
|
6
6
|
ng-click="addColumn()">
|
7
7
|
Add column
|
8
8
|
</div><br/><br/>
|
9
|
-
<div ui-sortable ng-model="
|
10
|
-
<div ng-repeat="colUid in
|
9
|
+
<div ui-sortable ng-model="promethee.inspected.attributes.cols">
|
10
|
+
<div ng-repeat="colUid in promethee.inspected.attributes.cols">
|
11
11
|
<div class="form-group row align-items-center">
|
12
12
|
<div class="col-1" style="line-height: 38px">
|
13
13
|
<i class="fas fa-bars"></i>
|
14
14
|
</div>
|
15
15
|
<div class="col-9">
|
16
16
|
<input type="text"
|
17
|
-
ng-model="
|
17
|
+
ng-model="promethee.inspected.attributes.cols_data[colUid].searchable_text"
|
18
18
|
class="form-control" />
|
19
19
|
</div>
|
20
20
|
<div class="col-2">
|
@@ -34,7 +34,7 @@
|
|
34
34
|
ng-click="addRow()">
|
35
35
|
Add row
|
36
36
|
</div><br/><br/>
|
37
|
-
<div ng-repeat="rowUid in
|
37
|
+
<div ng-repeat="rowUid in promethee.inspected.attributes.rows track by $index">
|
38
38
|
<span class="small">
|
39
39
|
<b>Row {{$index+1}}</b>
|
40
40
|
<a class="btn btn-default btn-light btn-sm float-right"
|
@@ -42,24 +42,24 @@
|
|
42
42
|
<%= icon('fa', 'close') %>
|
43
43
|
</a>
|
44
44
|
</span><br/>
|
45
|
-
<div ng-repeat="colUid in
|
45
|
+
<div ng-repeat="colUid in promethee.inspected.attributes.cols">
|
46
46
|
<span class="small">
|
47
|
-
{{
|
47
|
+
{{promethee.inspected.attributes.cols_data[colUid].searchable_text}}
|
48
48
|
</span>
|
49
49
|
<br/>
|
50
50
|
<input type="text"
|
51
|
-
ng-model="
|
51
|
+
ng-model="promethee.inspected.attributes.rows_data[rowUid][colUid].searchable_text"
|
52
52
|
class="form-control" />
|
53
53
|
</div>
|
54
54
|
<hr/>
|
55
55
|
</div>
|
56
56
|
</div>
|
57
|
-
<div class="form-group" ng-show="
|
57
|
+
<div class="form-group" ng-show="promethee.inspected.attributes.rows.length > 1">
|
58
58
|
<label class="label-control">Drag the rows below to reorder them:</label>
|
59
59
|
<ul ui-sortable
|
60
|
-
ng-model="
|
60
|
+
ng-model="promethee.inspected.attributes.rows"
|
61
61
|
class="list-unstyled">
|
62
|
-
<li ng-repeat="_ in
|
62
|
+
<li ng-repeat="_ in promethee.inspected.attributes.rows track by $index">
|
63
63
|
<%= icon('fa', 'bars') %> Row {{$index + 1}}
|
64
64
|
</li>
|
65
65
|
</ul>
|
@@ -71,23 +71,23 @@
|
|
71
71
|
promethee.controller('TableInspectController', ['$scope', 'uidService', function($scope, uidService) {
|
72
72
|
$scope.addColumn = function () {
|
73
73
|
var uid = uidService.generate();
|
74
|
-
|
75
|
-
|
74
|
+
this.promethee.inspected.attributes.cols.push(uid);
|
75
|
+
this.promethee.inspected.attributes.cols_data[uid] = { searchable_text: 'New column' };
|
76
76
|
}
|
77
77
|
|
78
78
|
$scope.addRow = function () {
|
79
79
|
var uid = uidService.generate();
|
80
|
-
|
80
|
+
this.promethee.inspected.attributes.rows.push(uid);
|
81
81
|
|
82
|
-
console.log(
|
82
|
+
console.log(this.promethee.inspected.attributes);
|
83
83
|
}
|
84
84
|
|
85
85
|
$scope.removeItem = function (uid, arrayKey) {
|
86
86
|
var dataKey = arrayKey + '_data';
|
87
|
-
var index =
|
87
|
+
var index = this.promethee.inspected.attributes[arrayKey].indexOf(uid);
|
88
88
|
if (index !== -1) {
|
89
|
-
|
90
|
-
delete
|
89
|
+
this.promethee.inspected.attributes[arrayKey].splice(index, 1);
|
90
|
+
delete this.promethee.inspected.attributes[dataKey][uid];
|
91
91
|
}
|
92
92
|
}
|
93
93
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: promethee
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sébastien Gaya
|
@@ -447,17 +447,17 @@ homepage: https://github.com/lespoupeesrusses/promethee
|
|
447
447
|
licenses:
|
448
448
|
- MIT
|
449
449
|
metadata: {}
|
450
|
-
post_install_message:
|
451
|
-
|
452
|
-
# NOTE FOR UPGRADING
|
453
|
-
|
450
|
+
post_install_message: |
|
451
|
+
###################################
|
452
|
+
# NOTE FOR UPGRADING FROM 1.x.x #
|
453
|
+
###################################
|
454
454
|
|
455
455
|
Prométhée 2.0 brings:
|
456
456
|
- [BREAKING CHANGE] New structure for table component. A rake task is available to update them in your master models. Localization has to be manual.
|
457
457
|
- [TOOL TO FIX ISSUE] A rake task to clean your localization models.
|
458
458
|
|
459
459
|
For more details, check the documentation:
|
460
|
-
https://github.com/lespoupeesrusses/promethee/tree/
|
460
|
+
https://github.com/lespoupeesrusses/promethee/tree/master/doc
|
461
461
|
rdoc_options: []
|
462
462
|
require_paths:
|
463
463
|
- lib
|