cronapp-framework-js 2.8.28 → 2.8.29
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/components/crn-cron-grid.components.json +24 -34
- package/components/crn-vertical-container.components.json +3 -3
- package/components/templates/grid-vertical.template.html +2 -2
- package/components/templates/textinputbutton.template.html +11 -9
- package/css/modalTemplate.css +6 -1
- package/css/themes/custom/material/custom-material.css +0 -4
- package/dist/components/templates/grid-vertical.template.html +1 -1
- package/dist/components/templates/textinputbutton.template.html +1 -1
- package/dist/css/modalTemplate.css +1 -1
- package/dist/css/themes/custom/material/custom-material.css +1 -1
- package/dist/img/barcode.png +0 -0
- package/dist/img/cronGrid.png +0 -0
- package/dist/img/cronRichEditor.png +0 -0
- package/dist/img/cronapp-logo-login.png +0 -0
- package/dist/img/logo.png +0 -0
- package/dist/img/placehold-100x100.png +0 -0
- package/dist/img/placehold-900x500.png +0 -0
- package/dist/img/qrcode.png +0 -0
- package/dist/img/selectFile.png +0 -0
- package/dist/img/switch.png +0 -0
- package/dist/js/app.js +1 -1
- package/dist/js/controllers.js +1 -1
- package/dist/js/directives.js +1 -1
- package/js/app.js +18 -2
- package/js/controllers.js +2 -15
- package/js/directives.js +14 -5
- package/package.json +1 -1
package/js/app.js
CHANGED
|
@@ -212,7 +212,7 @@ var app = (function() {
|
|
|
212
212
|
$scope.UploadService = UploadService;
|
|
213
213
|
$scope.$state = $state;
|
|
214
214
|
|
|
215
|
-
app.registerEventsCronapi($scope, $translate);
|
|
215
|
+
app.registerEventsCronapi($scope, $translate, $location);
|
|
216
216
|
|
|
217
217
|
$("form").kendoValidator({
|
|
218
218
|
errorTemplate: '<span class="k-widget k-tooltip-validation k-x-invalid-msg-block">#=message#</span>',
|
|
@@ -365,7 +365,23 @@ app.bindScope = function($scope, obj) {
|
|
|
365
365
|
return newObj;
|
|
366
366
|
};
|
|
367
367
|
|
|
368
|
-
app.registerEventsCronapi = function($scope, $translate) {
|
|
368
|
+
app.registerEventsCronapi = function($scope, $translate, $location) {
|
|
369
|
+
|
|
370
|
+
let $stateParams = $scope.params || {};
|
|
371
|
+
let queryStringParams = $location && $location.search() || {};
|
|
372
|
+
$scope.params = {};
|
|
373
|
+
|
|
374
|
+
let makeCopy = (from, to) => {
|
|
375
|
+
for (let key in from) {
|
|
376
|
+
if (from.hasOwnProperty(key)) {
|
|
377
|
+
to[key] = from[key];
|
|
378
|
+
}
|
|
379
|
+
}
|
|
380
|
+
};
|
|
381
|
+
makeCopy($stateParams, $scope.params);
|
|
382
|
+
makeCopy(queryStringParams, $scope.params);
|
|
383
|
+
|
|
384
|
+
|
|
369
385
|
for (var x in app.userEvents)
|
|
370
386
|
$scope[x] = app.userEvents[x].bind($scope);
|
|
371
387
|
|
package/js/controllers.js
CHANGED
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
$scope.$http = $http;
|
|
82
82
|
$scope.params = $stateParams;
|
|
83
83
|
$scope.$state = $state;
|
|
84
|
-
app.registerEventsCronapi($scope, $translate);
|
|
84
|
+
app.registerEventsCronapi($scope, $translate, $location);
|
|
85
85
|
|
|
86
86
|
$rootScope.http = $http;
|
|
87
87
|
$rootScope.Notification = Notification;
|
|
@@ -91,12 +91,6 @@
|
|
|
91
91
|
ReportService.openReport(reportName, params, config);
|
|
92
92
|
};
|
|
93
93
|
|
|
94
|
-
var queryStringParams = $location.search();
|
|
95
|
-
for (var key in queryStringParams) {
|
|
96
|
-
if (queryStringParams.hasOwnProperty(key)) {
|
|
97
|
-
$scope.params[key] = queryStringParams[key];
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
94
|
$scope.redirectToLogin = function() {
|
|
101
95
|
$scope.cronapi.social.ssoLogin();
|
|
102
96
|
};
|
|
@@ -250,7 +244,7 @@
|
|
|
250
244
|
$scope.$http = $http;
|
|
251
245
|
$scope.params = $stateParams;
|
|
252
246
|
$scope.$state = $state;
|
|
253
|
-
app.registerEventsCronapi($scope, $translate);
|
|
247
|
+
app.registerEventsCronapi($scope, $translate, $location);
|
|
254
248
|
|
|
255
249
|
$rootScope.http = $http;
|
|
256
250
|
$rootScope.Notification = Notification;
|
|
@@ -260,13 +254,6 @@
|
|
|
260
254
|
ReportService.openReport(reportName, params, config);
|
|
261
255
|
};
|
|
262
256
|
|
|
263
|
-
var queryStringParams = $location.search();
|
|
264
|
-
for (var key in queryStringParams) {
|
|
265
|
-
if (queryStringParams.hasOwnProperty(key)) {
|
|
266
|
-
$scope.params[key] = queryStringParams[key];
|
|
267
|
-
}
|
|
268
|
-
}
|
|
269
|
-
|
|
270
257
|
$scope.message = {};
|
|
271
258
|
|
|
272
259
|
$scope.selecionado = {
|
package/js/directives.js
CHANGED
|
@@ -3517,6 +3517,7 @@
|
|
|
3517
3517
|
}
|
|
3518
3518
|
},
|
|
3519
3519
|
link: async function (scope, element, attrs, ngModelCtrl) {
|
|
3520
|
+
await cronapi.internal.skipIterationLoop();
|
|
3520
3521
|
var modelGetter = $parse(attrs['ngModel']);
|
|
3521
3522
|
var modelSetter = modelGetter.assign;
|
|
3522
3523
|
var select = {};
|
|
@@ -4710,14 +4711,22 @@
|
|
|
4710
4711
|
return {
|
|
4711
4712
|
restrict: 'A',
|
|
4712
4713
|
require: 'ngModel',
|
|
4713
|
-
link: function(scope, element, attrs, ngModelCtrl) {
|
|
4714
|
+
link: async function(scope, element, attrs, ngModelCtrl) {
|
|
4714
4715
|
if (attrs.ngInitialValue) {
|
|
4715
4716
|
var modelGetter = $parse(attrs['ngModel']);
|
|
4716
4717
|
var modelSetter = modelGetter.assign;
|
|
4717
4718
|
var evaluated;
|
|
4718
4719
|
|
|
4719
4720
|
try {
|
|
4720
|
-
|
|
4721
|
+
if(attrs.ngInitialValue.indexOf("cronapi.client('js.") != -1){//cronapi caller?
|
|
4722
|
+
let shortVersion = attrs.ngInitialValue.replace("cronapi.client('js.", 'blockly.js.');
|
|
4723
|
+
let blocklyPackage = shortVersion.split("').names")[0];
|
|
4724
|
+
blocklyPackage = blocklyPackage.split("').attr()")[0];
|
|
4725
|
+
let blocklyParams = shortVersion.split('.run')[1];
|
|
4726
|
+
evaluated = await scope.$eval(blocklyPackage + blocklyParams);
|
|
4727
|
+
} else {
|
|
4728
|
+
evaluated = scope.$eval(attrs.ngInitialValue);
|
|
4729
|
+
}
|
|
4721
4730
|
} catch (e) {
|
|
4722
4731
|
evaluated = attrs.ngInitialValue;
|
|
4723
4732
|
}
|
|
@@ -4777,7 +4786,7 @@
|
|
|
4777
4786
|
viewValue = null;
|
|
4778
4787
|
el.prop('indeterminate', true);
|
|
4779
4788
|
}
|
|
4780
|
-
ctrl.$setViewValue(viewValue);
|
|
4789
|
+
setTimeout(() => ctrl.$setViewValue(viewValue));
|
|
4781
4790
|
};
|
|
4782
4791
|
} else if (attrs.crnAllowNullValues == 'false') {
|
|
4783
4792
|
ctrl.$render = function () {
|
|
@@ -4787,7 +4796,7 @@
|
|
|
4787
4796
|
viewValue = false;
|
|
4788
4797
|
}
|
|
4789
4798
|
if (viewValue === falseValue) {
|
|
4790
|
-
let modelForEval = `${el.attr('ng-model')}=${
|
|
4799
|
+
let modelForEval = `${el.attr('ng-model')}=${attrs.ngFalseValue}`;
|
|
4791
4800
|
scope.$eval(modelForEval);
|
|
4792
4801
|
}
|
|
4793
4802
|
el.data('checked', viewValue);
|
|
@@ -4804,7 +4813,7 @@
|
|
|
4804
4813
|
viewValue = falseValue;
|
|
4805
4814
|
break;
|
|
4806
4815
|
}
|
|
4807
|
-
ctrl.$setViewValue(viewValue);
|
|
4816
|
+
setTimeout(() => ctrl.$setViewValue(viewValue));
|
|
4808
4817
|
};
|
|
4809
4818
|
}
|
|
4810
4819
|
el.bind('click', function () {
|