tryton-sao 6.0.60 → 6.0.62
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/dist/tryton-sao.css +11 -5
- package/dist/tryton-sao.js +32 -6
- package/dist/tryton-sao.min.css +11 -5
- package/dist/tryton-sao.min.js +2 -2
- package/package.json +1 -1
- package/src/common.js +6 -1
- package/src/model.js +11 -0
- package/src/sao.js +10 -4
- package/src/sao.less +1 -1
- package/src/theme.less +6 -2
- package/src/view/tree.js +5 -1
package/CHANGELOG
CHANGED
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
|
|
2
|
+
Version 6.0.62 - 2025-07-01
|
|
3
|
+
---------------------------
|
|
4
|
+
* Bug fixes (see mercurial logs for details)
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Version 6.0.61 - 2025-06-04
|
|
8
|
+
---------------------------
|
|
9
|
+
* Bug fixes (see mercurial logs for details)
|
|
10
|
+
|
|
11
|
+
|
|
2
12
|
Version 6.0.60 - 2025-05-15
|
|
3
13
|
---------------------------
|
|
4
14
|
* Bug fixes (see mercurial logs for details)
|
package/dist/tryton-sao.css
CHANGED
|
@@ -8774,6 +8774,11 @@ html[theme="default"] .radio input[type="radio"]:focus,
|
|
|
8774
8774
|
html[theme="default"] .radio-inline input[type="radio"]:focus {
|
|
8775
8775
|
outline: none;
|
|
8776
8776
|
}
|
|
8777
|
+
html[theme="default"] input[type="radio"]:focus:after,
|
|
8778
|
+
html[theme="default"] .radio input[type="radio"]:focus:after,
|
|
8779
|
+
html[theme="default"] .radio-inline input[type="radio"]:focus:after {
|
|
8780
|
+
border-color: #71bdc1 !important;
|
|
8781
|
+
}
|
|
8777
8782
|
html[theme="default"] input[type="radio"]:before,
|
|
8778
8783
|
html[theme="default"] .radio input[type="radio"]:before,
|
|
8779
8784
|
html[theme="default"] .radio-inline input[type="radio"]:before,
|
|
@@ -8863,10 +8868,10 @@ html[theme="default"] .checkbox input[type="checkbox"]:focus,
|
|
|
8863
8868
|
html[theme="default"] .checkbox-inline input[type="checkbox"]:focus {
|
|
8864
8869
|
outline: none;
|
|
8865
8870
|
}
|
|
8866
|
-
html[theme="default"] input[type="checkbox"]:focus:
|
|
8867
|
-
html[theme="default"] .checkbox input[type="checkbox"]:focus:
|
|
8868
|
-
html[theme="default"] .checkbox-inline input[type="checkbox"]:focus:
|
|
8869
|
-
border-color: #
|
|
8871
|
+
html[theme="default"] input[type="checkbox"]:focus:after,
|
|
8872
|
+
html[theme="default"] .checkbox input[type="checkbox"]:focus:after,
|
|
8873
|
+
html[theme="default"] .checkbox-inline input[type="checkbox"]:focus:after {
|
|
8874
|
+
border-color: #71bdc1 !important;
|
|
8870
8875
|
}
|
|
8871
8876
|
html[theme="default"] input[type="checkbox"]:before,
|
|
8872
8877
|
html[theme="default"] .checkbox input[type="checkbox"]:before,
|
|
@@ -9185,7 +9190,8 @@ html[theme="default"] .carousel-caption h6 {
|
|
|
9185
9190
|
float: none;
|
|
9186
9191
|
}
|
|
9187
9192
|
}
|
|
9188
|
-
.btn-primary .icon
|
|
9193
|
+
.btn-primary .icon,
|
|
9194
|
+
.bg-primary .icon {
|
|
9189
9195
|
filter: brightness(0) invert(1);
|
|
9190
9196
|
}
|
|
9191
9197
|
.panel-heading a {
|
package/dist/tryton-sao.js
CHANGED
|
@@ -1066,20 +1066,26 @@ var Sao = {};
|
|
|
1066
1066
|
shortcut: 'alt+shift+tab',
|
|
1067
1067
|
label: Sao.i18n.gettext('Previous tab'),
|
|
1068
1068
|
callback: function() {
|
|
1069
|
-
|
|
1069
|
+
if (!jQuery('body').children('.modal').length) {
|
|
1070
|
+
Sao.Tab.previous_tab();
|
|
1071
|
+
}
|
|
1070
1072
|
},
|
|
1071
1073
|
}, {
|
|
1072
1074
|
shortcut: 'alt+tab',
|
|
1073
1075
|
label: Sao.i18n.gettext('Next tab'),
|
|
1074
1076
|
callback: function() {
|
|
1075
|
-
|
|
1077
|
+
if (!jQuery('body').children('.modal').length) {
|
|
1078
|
+
Sao.Tab.next_tab();
|
|
1079
|
+
}
|
|
1076
1080
|
},
|
|
1077
1081
|
}, {
|
|
1078
1082
|
shortcut: 'ctrl+k',
|
|
1079
1083
|
label: Sao.i18n.gettext('Global search'),
|
|
1080
1084
|
callback: function() {
|
|
1081
|
-
jQuery('
|
|
1082
|
-
|
|
1085
|
+
if (!jQuery('body').children('.modal').length) {
|
|
1086
|
+
jQuery('#main_navbar:hidden').collapse('show');
|
|
1087
|
+
jQuery('#global-search-entry').focus();
|
|
1088
|
+
}
|
|
1083
1089
|
},
|
|
1084
1090
|
}, {
|
|
1085
1091
|
shortcut: 'f1',
|
|
@@ -4932,8 +4938,13 @@ var Sao = {};
|
|
|
4932
4938
|
}
|
|
4933
4939
|
let { format } = new Intl.NumberFormat(
|
|
4934
4940
|
Sao.i18n.BC47(Sao.i18n.getlang()));
|
|
4941
|
+
// use 10000 because some language (ex: es) add thousand
|
|
4942
|
+
// separator only after 9999
|
|
4943
|
+
let [, thousandSeparator] = /^10(.)?000/.exec(format(10000));
|
|
4935
4944
|
let [, decimalSign] = /^0(.)1$/.exec(format(0.1));
|
|
4936
|
-
return Number(string
|
|
4945
|
+
return Number(string
|
|
4946
|
+
.replace(new RegExp(thousandSeparator, 'g'), '')
|
|
4947
|
+
.replace(decimalSign, '.'));
|
|
4937
4948
|
}
|
|
4938
4949
|
var convert_selection = function() {
|
|
4939
4950
|
if (typeof value == 'string') {
|
|
@@ -9100,12 +9111,23 @@ var Sao = {};
|
|
|
9100
9111
|
},
|
|
9101
9112
|
apply_factor: function(record, value, factor) {
|
|
9102
9113
|
if (value !== null) {
|
|
9114
|
+
// The default precision is the one used by value (before
|
|
9115
|
+
// applying the factor), per the ecmascript specification
|
|
9116
|
+
// it's the shortest representation of said value.
|
|
9117
|
+
// Once the factor is applied the number might become even
|
|
9118
|
+
// more inexact thus we should rely on the initial
|
|
9119
|
+
// precision + the effect factor will have
|
|
9120
|
+
// https://tc39.es/ecma262/multipage/ecmascript-data-types-and-values.html#sec-numeric-types-number-tostring
|
|
9121
|
+
let default_precision = (value.toString().split('.')[1] || '').length;
|
|
9122
|
+
default_precision += Math.ceil(Math.log10(factor));
|
|
9103
9123
|
value /= factor;
|
|
9104
9124
|
var digits = this.digits(record);
|
|
9105
9125
|
if (digits) {
|
|
9106
9126
|
// Round to avoid float precision error
|
|
9107
9127
|
// after the division by factor
|
|
9108
9128
|
value = value.toFixed(digits[1]);
|
|
9129
|
+
} else {
|
|
9130
|
+
value = value.toFixed(default_precision);
|
|
9109
9131
|
}
|
|
9110
9132
|
value = this.convert(value);
|
|
9111
9133
|
}
|
|
@@ -21042,12 +21064,13 @@ function eval_pyson(value){
|
|
|
21042
21064
|
current_record = this.tree.screen.current_record;
|
|
21043
21065
|
this.tree.select_records(current_record, this.record);
|
|
21044
21066
|
} else {
|
|
21067
|
+
let selected = this.is_selected();
|
|
21045
21068
|
if (!(event_.ctrlKey || event_.metaKey) ||
|
|
21046
21069
|
this.tree.selection_mode ==
|
|
21047
21070
|
Sao.common.SELECTION_SINGLE) {
|
|
21048
21071
|
this.tree.select_records(null, null);
|
|
21049
21072
|
}
|
|
21050
|
-
this.set_selection(!
|
|
21073
|
+
this.set_selection(!selected);
|
|
21051
21074
|
}
|
|
21052
21075
|
this.selection_changed();
|
|
21053
21076
|
if (current_record) {
|
|
@@ -21078,6 +21101,9 @@ function eval_pyson(value){
|
|
|
21078
21101
|
},
|
|
21079
21102
|
selection_changed: function() {
|
|
21080
21103
|
var is_selected = this.is_selected();
|
|
21104
|
+
if (this.tree.selection_mode == Sao.common.SELECTION_SINGLE) {
|
|
21105
|
+
this.tree.select_records(null, null);
|
|
21106
|
+
}
|
|
21081
21107
|
this.set_selection(is_selected);
|
|
21082
21108
|
if (is_selected) {
|
|
21083
21109
|
this.tree.select_changed(this.record);
|
package/dist/tryton-sao.min.css
CHANGED
|
@@ -8774,6 +8774,11 @@ html[theme="default"] .radio input[type="radio"]:focus,
|
|
|
8774
8774
|
html[theme="default"] .radio-inline input[type="radio"]:focus {
|
|
8775
8775
|
outline: none;
|
|
8776
8776
|
}
|
|
8777
|
+
html[theme="default"] input[type="radio"]:focus:after,
|
|
8778
|
+
html[theme="default"] .radio input[type="radio"]:focus:after,
|
|
8779
|
+
html[theme="default"] .radio-inline input[type="radio"]:focus:after {
|
|
8780
|
+
border-color: #71bdc1 !important;
|
|
8781
|
+
}
|
|
8777
8782
|
html[theme="default"] input[type="radio"]:before,
|
|
8778
8783
|
html[theme="default"] .radio input[type="radio"]:before,
|
|
8779
8784
|
html[theme="default"] .radio-inline input[type="radio"]:before,
|
|
@@ -8863,10 +8868,10 @@ html[theme="default"] .checkbox input[type="checkbox"]:focus,
|
|
|
8863
8868
|
html[theme="default"] .checkbox-inline input[type="checkbox"]:focus {
|
|
8864
8869
|
outline: none;
|
|
8865
8870
|
}
|
|
8866
|
-
html[theme="default"] input[type="checkbox"]:focus:
|
|
8867
|
-
html[theme="default"] .checkbox input[type="checkbox"]:focus:
|
|
8868
|
-
html[theme="default"] .checkbox-inline input[type="checkbox"]:focus:
|
|
8869
|
-
border-color: #
|
|
8871
|
+
html[theme="default"] input[type="checkbox"]:focus:after,
|
|
8872
|
+
html[theme="default"] .checkbox input[type="checkbox"]:focus:after,
|
|
8873
|
+
html[theme="default"] .checkbox-inline input[type="checkbox"]:focus:after {
|
|
8874
|
+
border-color: #71bdc1 !important;
|
|
8870
8875
|
}
|
|
8871
8876
|
html[theme="default"] input[type="checkbox"]:before,
|
|
8872
8877
|
html[theme="default"] .checkbox input[type="checkbox"]:before,
|
|
@@ -9185,7 +9190,8 @@ html[theme="default"] .carousel-caption h6 {
|
|
|
9185
9190
|
float: none;
|
|
9186
9191
|
}
|
|
9187
9192
|
}
|
|
9188
|
-
.btn-primary .icon
|
|
9193
|
+
.btn-primary .icon,
|
|
9194
|
+
.bg-primary .icon {
|
|
9189
9195
|
filter: brightness(0) invert(1);
|
|
9190
9196
|
}
|
|
9191
9197
|
.panel-heading a {
|