$scope.fetchTemplates(true);
$scope.applyTemplate = function (n) {
- if (n) {\r
- if ($scope.templates[n]) {\r
+ if (n) {
+ if ($scope.templates[n]) {
$scope.print.cn_template_content = $scope.templates[n].cn_content;
$scope.print.template_content = $scope.templates[n].content;
$scope.print.template_context = $scope.templates[n].context;
- for (var s in $scope.templates[n].settings) {\r
- $scope.preview_scope.settings[s] = $scope.templates[n].settings[s];\r
+ for (var s in $scope.templates[n].settings) {
+ $scope.preview_scope.settings[s] = $scope.templates[n].settings[s];
}
- if ($scope.templates[n].toolbox_settings) {\r
+ if ($scope.templates[n].toolbox_settings) {
$scope.preview_scope.toolbox_settings = $scope.templates[n].toolbox_settings;
- $scope.create_print_label_table();\r
+ $scope.create_print_label_table();
}
egCore.hatch.setItem('cat.printlabels.default_template', n);
- $scope.save_locally();\r
- }\r
+ $scope.save_locally();
+ }
}
}