From cb9e2284eb71e49daab48b8e324d348e5334adec Mon Sep 17 00:00:00 2001 From: Gerard Date: Fri, 15 Feb 2019 17:30:22 +0100 Subject: [PATCH] styles, imports of titles and traductions added --- front/core/directives/uvc.html | 14 ++++++++------ front/core/directives/uvc.js | 7 ++++++- front/core/directives/uvc.scss | 11 +++++++++++ modules/item/front/index/index.html | 2 +- modules/item/front/index/locale/es.yml | 1 + 5 files changed, 27 insertions(+), 8 deletions(-) create mode 100644 front/core/directives/uvc.scss create mode 100644 modules/item/front/index/locale/es.yml diff --git a/front/core/directives/uvc.html b/front/core/directives/uvc.html index be96cb35e..f7b559cd9 100644 --- a/front/core/directives/uvc.html +++ b/front/core/directives/uvc.html @@ -1,5 +1,5 @@
-
+
- - + + + +
diff --git a/front/core/directives/uvc.js b/front/core/directives/uvc.js index d880162ee..cce9e9ee5 100644 --- a/front/core/directives/uvc.js +++ b/front/core/directives/uvc.js @@ -1,5 +1,6 @@ import ngModule from '../module'; import template from './uvc.html'; +import './uvc.scss'; directive.$inject = ['$http', '$compile', 'vnApp', '$translate']; export function directive($http, $compile, vnApp, $translate) { @@ -7,12 +8,16 @@ export function directive($http, $compile, vnApp, $translate) { let allHeaders = $element[0].querySelectorAll(`vn-th[field], vn-th[th-id]`); let headerList = Array.from(allHeaders); let ids = []; + let titles = {}; headerList.forEach(header => { - ids.push(header.getAttribute('th-id') || header.getAttribute('field')); + let id = header.getAttribute('th-id') || header.getAttribute('field'); + ids.push(id); + titles[id] = header.innerText || id; }); $scope.fields = ids; + $scope.titles = titles; return headerList; } diff --git a/front/core/directives/uvc.scss b/front/core/directives/uvc.scss new file mode 100644 index 000000000..5221b8bdd --- /dev/null +++ b/front/core/directives/uvc.scss @@ -0,0 +1,11 @@ +vn-table vn-dialog[vn-id="uvc"]{ + & > div { + min-width: 18em; + align-items: center; + + } + + vn-button[label="Save"] { + margin: 0 auto; + } +} \ No newline at end of file diff --git a/modules/item/front/index/index.html b/modules/item/front/index/index.html index 8480dd842..48ca536ec 100644 --- a/modules/item/front/index/index.html +++ b/modules/item/front/index/index.html @@ -61,7 +61,7 @@ {{::item.intrastat}} {{::item.origin}} {{::item.userNickname}} - {{::item.density}} + {{::item.density}} {{::item.taxClass}}