tryton-sao 7.8.2 → 7.8.4
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.
- package/CHANGELOG +10 -0
- package/COPYRIGHT +2 -2
- package/dist/tryton-sao.js +13 -6
- package/package.json +1 -1
- package/src/model.js +5 -2
- package/src/sao.js +1 -1
- package/src/view/tree.js +7 -3
package/CHANGELOG
CHANGED
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
|
|
2
|
+
Version 7.8.4 - 2026-02-01
|
|
3
|
+
--------------------------
|
|
4
|
+
* Bug fixes (see mercurial logs for details)
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Version 7.8.3 - 2026-01-15
|
|
8
|
+
--------------------------
|
|
9
|
+
* Bug fixes (see mercurial logs for details)
|
|
10
|
+
|
|
11
|
+
|
|
2
12
|
Version 7.8.2 - 2026-01-02
|
|
3
13
|
--------------------------
|
|
4
14
|
* Bug fixes (see mercurial logs for details)
|
package/COPYRIGHT
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Copyright (C) 2012-2025 Nicolas Évrard.
|
|
2
|
-
Copyright (C) 2012-
|
|
2
|
+
Copyright (C) 2012-2026 Cédric Krier.
|
|
3
3
|
Copyright (C) 2012-2014 Bertrand Chenal.
|
|
4
|
-
Copyright (C) 2012-
|
|
4
|
+
Copyright (C) 2012-2026 B2CK SPRL.
|
|
5
5
|
Copyright (C) 2019 Jitbit.
|
|
6
6
|
Copyright (C) 2013 Thomas Park
|
|
7
7
|
Copyright (C) 2020-2021 Maxime Richez
|
package/dist/tryton-sao.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
/* eslint-disable no-redeclare */
|
|
5
5
|
var Sao = {
|
|
6
|
-
__version__: '7.8.
|
|
6
|
+
__version__: '7.8.4',
|
|
7
7
|
};
|
|
8
8
|
/* eslint-enable no-redeclare */
|
|
9
9
|
|
|
@@ -8270,11 +8270,14 @@ var Sao = {
|
|
|
8270
8270
|
} else {
|
|
8271
8271
|
cmp = function(a, b) { return a < b; };
|
|
8272
8272
|
}
|
|
8273
|
+
let max_id = Math.max(0, ...this.map((r) => r.id));
|
|
8273
8274
|
for (const record of this) {
|
|
8274
8275
|
if (record.get_loaded([field]) || changed || record.id < 0) {
|
|
8276
|
+
let prev_id = null;
|
|
8275
8277
|
if (prev) {
|
|
8276
8278
|
prev.load(field, false);
|
|
8277
8279
|
index = prev.field_get(field);
|
|
8280
|
+
prev_id = prev.id >= 0 ? prev.id : max_id++;
|
|
8278
8281
|
} else {
|
|
8279
8282
|
index = null;
|
|
8280
8283
|
}
|
|
@@ -8285,7 +8288,7 @@ var Sao = {
|
|
|
8285
8288
|
update = true;
|
|
8286
8289
|
} else if (prev) {
|
|
8287
8290
|
if (record.id >= 0) {
|
|
8288
|
-
update = cmp(record.id,
|
|
8291
|
+
update = cmp(record.id, prev_id);
|
|
8289
8292
|
} else if (position === 0) {
|
|
8290
8293
|
update = true;
|
|
8291
8294
|
}
|
|
@@ -8293,7 +8296,7 @@ var Sao = {
|
|
|
8293
8296
|
} else if (value === index) {
|
|
8294
8297
|
if (prev) {
|
|
8295
8298
|
if (record.id >= 0) {
|
|
8296
|
-
update = cmp(record.id,
|
|
8299
|
+
update = cmp(record.id, prev_id);
|
|
8297
8300
|
} else if (position === 0) {
|
|
8298
8301
|
update = true;
|
|
8299
8302
|
}
|
|
@@ -23578,11 +23581,14 @@ function eval_pyson(value){
|
|
|
23578
23581
|
cell.text(value);
|
|
23579
23582
|
}
|
|
23580
23583
|
};
|
|
23584
|
+
let prm = jQuery.when();
|
|
23581
23585
|
if (!record.is_loaded(this.attributes.name)) {
|
|
23582
|
-
record.load(this.attributes.name, true, false)
|
|
23583
|
-
}
|
|
23584
|
-
|
|
23586
|
+
prm = prm.then(() => record.load(this.attributes.name, true, false));
|
|
23587
|
+
}
|
|
23588
|
+
if (this.icon && (this.icon in record.model.fields)) {
|
|
23589
|
+
prm = prm.then(() => record.load(this.icon, true, false));
|
|
23585
23590
|
}
|
|
23591
|
+
prm.done(render);
|
|
23586
23592
|
return cell;
|
|
23587
23593
|
},
|
|
23588
23594
|
clicked: function(event) {
|
|
@@ -23805,6 +23811,7 @@ function eval_pyson(value){
|
|
|
23805
23811
|
view_ids.shift();
|
|
23806
23812
|
}
|
|
23807
23813
|
cell.click(event => {
|
|
23814
|
+
event.preventDefault();
|
|
23808
23815
|
event.stopPropagation();
|
|
23809
23816
|
var params = {};
|
|
23810
23817
|
params.model = this.attributes.relation;
|
package/package.json
CHANGED
package/src/model.js
CHANGED
|
@@ -513,11 +513,14 @@
|
|
|
513
513
|
} else {
|
|
514
514
|
cmp = function(a, b) { return a < b; };
|
|
515
515
|
}
|
|
516
|
+
let max_id = Math.max(0, ...this.map((r) => r.id));
|
|
516
517
|
for (const record of this) {
|
|
517
518
|
if (record.get_loaded([field]) || changed || record.id < 0) {
|
|
519
|
+
let prev_id = null;
|
|
518
520
|
if (prev) {
|
|
519
521
|
prev.load(field, false);
|
|
520
522
|
index = prev.field_get(field);
|
|
523
|
+
prev_id = prev.id >= 0 ? prev.id : max_id++;
|
|
521
524
|
} else {
|
|
522
525
|
index = null;
|
|
523
526
|
}
|
|
@@ -528,7 +531,7 @@
|
|
|
528
531
|
update = true;
|
|
529
532
|
} else if (prev) {
|
|
530
533
|
if (record.id >= 0) {
|
|
531
|
-
update = cmp(record.id,
|
|
534
|
+
update = cmp(record.id, prev_id);
|
|
532
535
|
} else if (position === 0) {
|
|
533
536
|
update = true;
|
|
534
537
|
}
|
|
@@ -536,7 +539,7 @@
|
|
|
536
539
|
} else if (value === index) {
|
|
537
540
|
if (prev) {
|
|
538
541
|
if (record.id >= 0) {
|
|
539
|
-
update = cmp(record.id,
|
|
542
|
+
update = cmp(record.id, prev_id);
|
|
540
543
|
} else if (position === 0) {
|
|
541
544
|
update = true;
|
|
542
545
|
}
|
package/src/sao.js
CHANGED
package/src/view/tree.js
CHANGED
|
@@ -2555,11 +2555,14 @@
|
|
|
2555
2555
|
cell.text(value);
|
|
2556
2556
|
}
|
|
2557
2557
|
};
|
|
2558
|
+
let prm = jQuery.when();
|
|
2558
2559
|
if (!record.is_loaded(this.attributes.name)) {
|
|
2559
|
-
record.load(this.attributes.name, true, false)
|
|
2560
|
-
}
|
|
2561
|
-
|
|
2560
|
+
prm = prm.then(() => record.load(this.attributes.name, true, false));
|
|
2561
|
+
}
|
|
2562
|
+
if (this.icon && (this.icon in record.model.fields)) {
|
|
2563
|
+
prm = prm.then(() => record.load(this.icon, true, false));
|
|
2562
2564
|
}
|
|
2565
|
+
prm.done(render);
|
|
2563
2566
|
return cell;
|
|
2564
2567
|
},
|
|
2565
2568
|
clicked: function(event) {
|
|
@@ -2782,6 +2785,7 @@
|
|
|
2782
2785
|
view_ids.shift();
|
|
2783
2786
|
}
|
|
2784
2787
|
cell.click(event => {
|
|
2788
|
+
event.preventDefault();
|
|
2785
2789
|
event.stopPropagation();
|
|
2786
2790
|
var params = {};
|
|
2787
2791
|
params.model = this.attributes.relation;
|