From eafbcb1915a056f7bd291f7d40a25e9b4aeed7ef Mon Sep 17 00:00:00 2001 From: Juan Ferrer Toribio Date: Tue, 29 Nov 2016 10:14:31 +0100 Subject: [PATCH 1/6] Estilos CSS - Bordes, fuente --- @salix/app/src/app.js | 3 ++ @salix/app/src/styles/border.scss | 45 ++++++++++++++++++++ @salix/app/src/styles/colors.scss | 5 +-- @salix/app/src/styles/font-style.scss | 10 +++++ @salix/app/src/styles/misc.scss | 7 +++ @salix/crud/src/client/addresses/index.html | 8 ++-- @salix/crud/src/client/addresses/index.js | 35 ++++++--------- @salix/crud/src/client/basic-data/index.html | 2 +- dev.sh | 1 - 9 files changed, 86 insertions(+), 30 deletions(-) create mode 100644 @salix/app/src/styles/border.scss create mode 100644 @salix/app/src/styles/font-style.scss create mode 100644 @salix/app/src/styles/misc.scss diff --git a/@salix/app/src/app.js b/@salix/app/src/app.js index 55ca62470e..bf5992122b 100644 --- a/@salix/app/src/app.js +++ b/@salix/app/src/app.js @@ -7,5 +7,8 @@ import padding from './styles/layout.css' import margin from './styles/margin.scss' import layout from './styles/padding.scss' import background from './styles/background.scss' +import border from './styles/border.scss' +import fontStyle from './styles/font-style.scss' +import misc from './styles/misc.scss' bootstrap(); diff --git a/@salix/app/src/styles/border.scss b/@salix/app/src/styles/border.scss new file mode 100644 index 0000000000..2afa4fd8a0 --- /dev/null +++ b/@salix/app/src/styles/border.scss @@ -0,0 +1,45 @@ +@import "colors"; + +$border-color: #AAA; +$border-thin: 1px; +$border-thick: 2px; + +html [border-none], .border-none { + border: 0; +} + +/* Solid border */ + +html [border-solid], .border-solid { + border: $border-thin solid $border-color; +} +html [border-solid-top], .border-solid-top { + border-top: $border-thin solid $border-color; +} +html [border-solid-left], .border-solid-left { + border-left: $border-thin solid $border-color; +} +html [border-solid-right], .border-solid-right { + border-right: $border-thin solid $border-color; +} +html [border-solid-bottom], .border-solid-bottom { + border-bottom: $border-thin solid $border-color; +} + +/* Dashed border */ + +html [border-dashed], .border-dashed { + border: $border-thin dashed $border-color; +} +html [border-dashed-top], .border-dashed-top { + border-top: $border-thin dashed $border-color; +} +html [border-dashed-left], .border-dashed-left { + border-left: $border-thin dashed $border-color; +} +html [border-dashed-right], .border-dashed-right { + border-right: $border-thin dashed $border-color; +} +html [border-dashed-bottom], .border-dashed-bottom { + border-bottom: $border-thin dashed $border-color; +} diff --git a/@salix/app/src/styles/colors.scss b/@salix/app/src/styles/colors.scss index 734adf05f4..87226d7360 100644 --- a/@salix/app/src/styles/colors.scss +++ b/@salix/app/src/styles/colors.scss @@ -1,8 +1,7 @@ $color-green: rgb(139,195,74); $color-orange: rgb(255,171,64); -$color-dark-grey: #424242; -$color-light-grey: #e6e6e6; $color-white: white; $color-dark: #3c393b; - +$color-dark-grey: #424242; +$color-light-grey: #e6e6e6; \ No newline at end of file diff --git a/@salix/app/src/styles/font-style.scss b/@salix/app/src/styles/font-style.scss new file mode 100644 index 0000000000..59755abf4f --- /dev/null +++ b/@salix/app/src/styles/font-style.scss @@ -0,0 +1,10 @@ +@import "colors"; + +$font-color: $color-dark-grey; + +body { + color: $font-color; +} +html [uppercase], .uppercase { + text-transform: uppercase; +} \ No newline at end of file diff --git a/@salix/app/src/styles/misc.scss b/@salix/app/src/styles/misc.scss new file mode 100644 index 0000000000..cecf042daf --- /dev/null +++ b/@salix/app/src/styles/misc.scss @@ -0,0 +1,7 @@ +@import "padding"; + +.form { + height: 100%; + box-sizing: border-box; + padding: $pad-large; +} \ No newline at end of file diff --git a/@salix/crud/src/client/addresses/index.html b/@salix/crud/src/client/addresses/index.html index c936878b9e..65069c6c03 100644 --- a/@salix/crud/src/client/addresses/index.html +++ b/@salix/crud/src/client/addresses/index.html @@ -1,17 +1,17 @@ - +

Addresses

- + Default Consignee Enabled - + - + diff --git a/@salix/crud/src/client/addresses/index.js b/@salix/crud/src/client/addresses/index.js index 97e7825286..307209ab7f 100644 --- a/@salix/crud/src/client/addresses/index.js +++ b/@salix/crud/src/client/addresses/index.js @@ -6,27 +6,20 @@ export const COMPONENT = { template: template, controller: function ($http) { - this.addresses = [{ - consignee: 'Consignee 1', - street: 'Street', - city: 'City', - postcode: '46600', - province: 'Province', - country: 'Country', - phone: 'XX-XXX-XX-XX', - mobile: 'XX-6XX-XX-XX', - enabled: true - },{ - consignee: 'Consignee 2', - street: 'Street', - city: 'City', - postcode: '46600', - province: 'Province', - country: 'Country', - phone: 'XX-XXX-XX-XX', - mobile: 'XX-6XX-XX-XX', - enabled: false - }]; + this.addresses = []; + + for (var i = 1; i <= 4; i++) + this.addresses.push ({ + consignee: 'Consignee '+ i, + street: 'Street', + city: 'City', + postcode: '46600', + province: 'Province', + country: 'Country', + phone: '+XX XXX XX XX XX', + mobile: '+XX 6XX XX XX XX', + enabled: i % 2 == 0 + }); }, }; module.component(NAME, COMPONENT); diff --git a/@salix/crud/src/client/basic-data/index.html b/@salix/crud/src/client/basic-data/index.html index 5eafbea407..c6c910a534 100644 --- a/@salix/crud/src/client/basic-data/index.html +++ b/@salix/crud/src/client/basic-data/index.html @@ -1,5 +1,5 @@
- +

Datos básicos

diff --git a/dev.sh b/dev.sh index 6c789897de..87123d9fe8 100755 --- a/dev.sh +++ b/dev.sh @@ -13,7 +13,6 @@ case "$1" in $0 stop echo "################################ Starting services" forever start forever.json - forever list "$nginxBin" -c "$nginxConf" -p "$nginxPrefix" cd @salix && gulp ;; From b8df169eebb7f822b430e2def0cfafa73f8b66cc Mon Sep 17 00:00:00 2001 From: Juan Ferrer Toribio Date: Tue, 29 Nov 2016 13:00:15 +0100 Subject: [PATCH 2/6] Consignatarios acabado --- @salix/core/src/buttonicon/buttonicon.bt.html | 3 - @salix/core/src/buttonicon/buttonicon.bt.js | 23 ------- @salix/core/src/buttonicon/buttonicon.mt.html | 4 -- @salix/core/src/buttonicon/buttonicon.mt.js | 23 ------- @salix/core/src/check/check.mt.html | 4 +- @salix/core/src/check/check.mt.js | 3 - @salix/core/src/combo/combo.js | 17 +++-- @salix/core/src/combo/combo.mt.js | 2 - @salix/core/src/core.js | 63 +++++++++---------- @salix/core/src/date-picker/date-picker.js | 17 +++-- .../core/src/date-picker/date-picker.mt.html | 2 +- @salix/core/src/date-picker/date-picker.mt.js | 5 +- .../icon-button.js} | 8 +-- .../core/src/icon-button/icon-button.mt.html | 3 + @salix/core/src/icon-button/icon-button.mt.js | 15 +++++ @salix/core/src/radio/radio.mt.html | 4 +- @salix/core/src/radio/radio.mt.js | 2 - @salix/core/src/resolveDefaultComponents.js | 3 - @salix/crud/src/client/addresses/index.html | 22 ++++--- @salix/crud/src/client/addresses/index.js | 25 +++++--- 20 files changed, 102 insertions(+), 146 deletions(-) delete mode 100644 @salix/core/src/buttonicon/buttonicon.bt.html delete mode 100644 @salix/core/src/buttonicon/buttonicon.bt.js delete mode 100644 @salix/core/src/buttonicon/buttonicon.mt.html delete mode 100644 @salix/core/src/buttonicon/buttonicon.mt.js rename @salix/core/src/{buttonicon/buttonicon.js => icon-button/icon-button.js} (76%) create mode 100644 @salix/core/src/icon-button/icon-button.mt.html create mode 100644 @salix/core/src/icon-button/icon-button.mt.js diff --git a/@salix/core/src/buttonicon/buttonicon.bt.html b/@salix/core/src/buttonicon/buttonicon.bt.html deleted file mode 100644 index 8dbb625128..0000000000 --- a/@salix/core/src/buttonicon/buttonicon.bt.html +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/@salix/core/src/buttonicon/buttonicon.bt.js b/@salix/core/src/buttonicon/buttonicon.bt.js deleted file mode 100644 index 02b0d72b6d..0000000000 --- a/@salix/core/src/buttonicon/buttonicon.bt.js +++ /dev/null @@ -1,23 +0,0 @@ -import {module as _module} from '../module'; -import * as util from '../util'; -import * as constant from '../constants'; -import template from './buttonicon.bt.html'; - -const _NAME = 'buttonicon'; -const DEFAULT_CLASS = 'mdl-button mdl-js-button mdl-button--icon'; - -export const NAME = util.getFactoryName(_NAME + constant.MATERIAL_DESIGN_FRAMEWORK); - -export function factory() { - return { - template: template, - default: { - className: DEFAULT_CLASS, - enabled: 'true', - typeName: 'button', - image:'', - } - } -} - -_module.factory(NAME, factory); diff --git a/@salix/core/src/buttonicon/buttonicon.mt.html b/@salix/core/src/buttonicon/buttonicon.mt.html deleted file mode 100644 index 7814cfde7c..0000000000 --- a/@salix/core/src/buttonicon/buttonicon.mt.html +++ /dev/null @@ -1,4 +0,0 @@ - - diff --git a/@salix/core/src/buttonicon/buttonicon.mt.js b/@salix/core/src/buttonicon/buttonicon.mt.js deleted file mode 100644 index 5d951a217f..0000000000 --- a/@salix/core/src/buttonicon/buttonicon.mt.js +++ /dev/null @@ -1,23 +0,0 @@ -import {module as _module} from '../module'; -import * as util from '../util'; -import * as constant from '../constants'; -import template from './buttonicon.mt.html'; - -const _NAME = 'buttonicon'; -const DEFAULT_CLASS = 'mdl-button mdl-js-button mdl-button--icon'; - -export const NAME = util.getFactoryName(_NAME + constant.MATERIAL_DESIGN_FRAMEWORK); - -export function factory() { - return { - template: template, - default: { - className: DEFAULT_CLASS, - enabled: 'true', - typeName: 'button', - image:'', - } - } -} - -_module.factory(NAME, factory); diff --git a/@salix/core/src/check/check.mt.html b/@salix/core/src/check/check.mt.html index a4616186ea..671daf1624 100644 --- a/@salix/core/src/check/check.mt.html +++ b/@salix/core/src/check/check.mt.html @@ -1,4 +1,4 @@ -
- + - -
{{i.consignee}}
-
{{i.street}}
-
{{i.city}}, {{i.province}}
-
{{i.phone}}, {{i.mobile}}
+ + +
{{i.consignee}}
+
{{i.street}}
+
{{i.city}}, {{i.province}}
+
{{i.phone}}, {{i.mobile}}
+
+ + + +
- +
\ No newline at end of file diff --git a/@salix/crud/src/client/addresses/index.js b/@salix/crud/src/client/addresses/index.js index 307209ab7f..83cee40fd4 100644 --- a/@salix/crud/src/client/addresses/index.js +++ b/@salix/crud/src/client/addresses/index.js @@ -6,19 +6,24 @@ export const COMPONENT = { template: template, controller: function ($http) { +/* $http.get('/client/api/Addresses', this.model).then ( + (json) => { this.addresses = json.data; }, + (json) => console.error (json.data.error.message) + ); +*/ this.addresses = []; - + for (var i = 1; i <= 4; i++) this.addresses.push ({ - consignee: 'Consignee '+ i, - street: 'Street', - city: 'City', - postcode: '46600', - province: 'Province', - country: 'Country', - phone: '+XX XXX XX XX XX', - mobile: '+XX 6XX XX XX XX', - enabled: i % 2 == 0 + "consignee": "Consignee", + "street": "Street", + "city": "City", + "postcode": "46600", + "province": "Province", + "country": "Country", + "phone": "+XX XXX XX XX XX", + "mobile": "+XX 6XX XX XX XX", + "enabled": true }); }, }; From ced1e8669a7956c2d09c69d35a72a80f92f40640 Mon Sep 17 00:00:00 2001 From: Juan Ferrer Toribio Date: Tue, 29 Nov 2016 13:13:17 +0100 Subject: [PATCH 3/6] Uppercase --- @salix/crud/src/client/basic-data/index.html | 68 ++++++++++---------- 1 file changed, 35 insertions(+), 33 deletions(-) diff --git a/@salix/crud/src/client/basic-data/index.html b/@salix/crud/src/client/basic-data/index.html index c6c910a534..646e175dd2 100644 --- a/@salix/crud/src/client/basic-data/index.html +++ b/@salix/crud/src/client/basic-data/index.html @@ -1,41 +1,43 @@ - +

Datos básicos

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
\ No newline at end of file From 7e1b4d6c7efaa3f7657b4b6785b4f0c6fab2f412 Mon Sep 17 00:00:00 2001 From: "SAMBA\\vfalco" Date: Tue, 29 Nov 2016 13:22:19 +0100 Subject: [PATCH 4/6] Client access web --- @salix/crud/src/client/client.js | 3 +++ @salix/crud/src/client/routes.js | 5 +++++ @salix/crud/src/client/web-access/index.html | 14 ++++++++++++++ .../webclient => client/web-access}/index.js | 2 +- @salix/crud/src/crud.js | 3 --- @salix/crud/src/customer/routes.js | 1 - @salix/crud/src/customer/webclient/index.html | 14 -------------- 7 files changed, 23 insertions(+), 19 deletions(-) create mode 100644 @salix/crud/src/client/web-access/index.html rename @salix/crud/src/{customer/webclient => client/web-access}/index.js (63%) delete mode 100644 @salix/crud/src/customer/webclient/index.html diff --git a/@salix/crud/src/client/client.js b/@salix/crud/src/client/client.js index b4e35cc0e8..a5fea374e3 100644 --- a/@salix/crud/src/client/client.js +++ b/@salix/crud/src/client/client.js @@ -4,3 +4,6 @@ export {NAME as CLIENT_BASIC_DATA_INDEX, COMPONENT as CLIENT_BASIC_DATA_INDEX_COMPONENT} from './basic-data/index'; export {NAME as CLIENT_ADDRESSES, COMPONENT as CLIENT_ADDRESSES_COMPONENT} from './addresses/index'; +export {NAME as CLIENT_WEB_ACCESS, + COMPONENT as CLIENT_WEB_ACCESS_COMPONENT} from './web-access/index'; + diff --git a/@salix/crud/src/client/routes.js b/@salix/crud/src/client/routes.js index c339a9d607..702ffae93a 100644 --- a/@salix/crud/src/client/routes.js +++ b/@salix/crud/src/client/routes.js @@ -15,6 +15,11 @@ state: 'client.addresses', template: '', module: 'crud' +},{ + url: '/web-access', + state: 'client.webaccess', + template: '', + module: 'crud' }] diff --git a/@salix/crud/src/client/web-access/index.html b/@salix/crud/src/client/web-access/index.html new file mode 100644 index 0000000000..1382668756 --- /dev/null +++ b/@salix/crud/src/client/web-access/index.html @@ -0,0 +1,14 @@ + + +

Acceso Web

+
+ + + + + + + + + +
\ No newline at end of file diff --git a/@salix/crud/src/customer/webclient/index.js b/@salix/crud/src/client/web-access/index.js similarity index 63% rename from @salix/crud/src/customer/webclient/index.js rename to @salix/crud/src/client/web-access/index.js index b9207f05e2..1660ec601f 100644 --- a/@salix/crud/src/customer/webclient/index.js +++ b/@salix/crud/src/client/web-access/index.js @@ -1,7 +1,7 @@ import template from './index.html'; import {module} from '../../module'; -export const NAME = 'customerWebClient'; +export const NAME = 'vnClientWebAccess'; export const COMPONENT = { template: template }; diff --git a/@salix/crud/src/crud.js b/@salix/crud/src/crud.js index 62666d119d..e7c0c61593 100644 --- a/@salix/crud/src/crud.js +++ b/@salix/crud/src/crud.js @@ -14,9 +14,6 @@ export {NAME as CUSTOMER_DESCRIPTOR, export {NAME as CUSTOMER_ACTIONS, COMPONENT as CUSTOMER_ACTIONS_COMPONENT} from './customer/edit/actions'; -export {NAME as CUSTOMER_WEB_CLIENT_INDEX, - COMPONENT as CUSTOMER_WEB_CLIENT_INDEX_COMPONENT} from './customer/webclient'; - export {NAME as NAVIGATION_INDEX, COMPONENT as NAVIGATION_INDEX_COMPONENT} from './navigation/index'; export {NAME as NAVIGATION_ITEM, diff --git a/@salix/crud/src/customer/routes.js b/@salix/crud/src/customer/routes.js index a2ada44a6c..9eed639dfa 100644 --- a/@salix/crud/src/customer/routes.js +++ b/@salix/crud/src/customer/routes.js @@ -34,5 +34,4 @@ description: '', image: '' } - ] diff --git a/@salix/crud/src/customer/webclient/index.html b/@salix/crud/src/customer/webclient/index.html deleted file mode 100644 index e065cd47be..0000000000 --- a/@salix/crud/src/customer/webclient/index.html +++ /dev/null @@ -1,14 +0,0 @@ - - -

CLIENTE_acceso web

-
- - - - - - - - - -
\ No newline at end of file From ce34c4c15101b5f16ba0c88620b9af1b740ae689 Mon Sep 17 00:00:00 2001 From: "SAMBA\\vfalco" Date: Tue, 29 Nov 2016 14:50:10 +0100 Subject: [PATCH 5/6] model access-web --- @salix/crud/src/client/web-access/index.html | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/@salix/crud/src/client/web-access/index.html b/@salix/crud/src/client/web-access/index.html index 1382668756..f0a1d0b8eb 100644 --- a/@salix/crud/src/client/web-access/index.html +++ b/@salix/crud/src/client/web-access/index.html @@ -1,14 +1,16 @@ - +
+

Acceso Web

- + - + - + -
\ No newline at end of file + +
\ No newline at end of file From 6cddd841c0648efab1eee1df10e5e0918949e99d Mon Sep 17 00:00:00 2001 From: Javi Gallego Date: Tue, 29 Nov 2016 14:50:40 +0100 Subject: [PATCH 6/6] fiscal-data --- @salix/crud/src/client/client.js | 2 + @salix/crud/src/client/fiscal-data/index.html | 64 +++++++++++++++++++ @salix/crud/src/client/fiscal-data/index.js | 16 +++++ @salix/crud/src/client/index/index.js | 2 +- @salix/crud/src/client/routes.js | 7 +- @salix/crud/src/crud.js | 2 +- 6 files changed, 90 insertions(+), 3 deletions(-) create mode 100644 @salix/crud/src/client/fiscal-data/index.html create mode 100644 @salix/crud/src/client/fiscal-data/index.js diff --git a/@salix/crud/src/client/client.js b/@salix/crud/src/client/client.js index b4e35cc0e8..f095b54dfb 100644 --- a/@salix/crud/src/client/client.js +++ b/@salix/crud/src/client/client.js @@ -4,3 +4,5 @@ export {NAME as CLIENT_BASIC_DATA_INDEX, COMPONENT as CLIENT_BASIC_DATA_INDEX_COMPONENT} from './basic-data/index'; export {NAME as CLIENT_ADDRESSES, COMPONENT as CLIENT_ADDRESSES_COMPONENT} from './addresses/index'; +export {NAME as CLIENT_FISCAL_DATA_INDEX, + COMPONENT as CLIENT_FISCAL_DATA_INDEX_COMPONENT} from './fiscal-data/index'; diff --git a/@salix/crud/src/client/fiscal-data/index.html b/@salix/crud/src/client/fiscal-data/index.html new file mode 100644 index 0000000000..bbcef42777 --- /dev/null +++ b/@salix/crud/src/client/fiscal-data/index.html @@ -0,0 +1,64 @@ +
+ + + +

Datos fiscales y de facturación

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ +
Información de facturación
+
+ + + + + + + + + + + +
+ + +
DOCUMENTACION
+
+
+ + + + + + + + + + +
+
\ No newline at end of file diff --git a/@salix/crud/src/client/fiscal-data/index.js b/@salix/crud/src/client/fiscal-data/index.js new file mode 100644 index 0000000000..d46d8d7cc6 --- /dev/null +++ b/@salix/crud/src/client/fiscal-data/index.js @@ -0,0 +1,16 @@ +import template from './index.html'; +import {module} from '../../module'; + +export const NAME = 'vnClientFiscalData'; +export const COMPONENT = { + template: template, + controller: function($http) { + this.submit = function() { + $http.post('/client/api/Clients', this.model).then( + json => console.log(json.statusText), + json => console.error(json.data.error.message) + ); + }; + } +}; +module.component(NAME, COMPONENT); diff --git a/@salix/crud/src/client/index/index.js b/@salix/crud/src/client/index/index.js index ea82f2e913..de37b03bf9 100644 --- a/@salix/crud/src/client/index/index.js +++ b/@salix/crud/src/client/index/index.js @@ -9,7 +9,7 @@ export const COMPONENT = { controller: function() { this.items = [ {text: "Datos básicos", image: "person", href: "#/client/basic-data"}, - {text: "Datos facturación", image: "assignment", href: "#/client/invoicing-data"}, + {text: "Datos facturación", image: "assignment", href: "#/client/fiscal-data"}, {text: "Acceso web", image: "language", href: "#/client/web-access"}, {text: "Consignatarios", image: "local_shipping", href: "#/client/addresses"}, {text: "Notas", image: "insert_drive_file", href: "#/client/notes"} diff --git a/@salix/crud/src/client/routes.js b/@salix/crud/src/client/routes.js index c339a9d607..f2068eee04 100644 --- a/@salix/crud/src/client/routes.js +++ b/@salix/crud/src/client/routes.js @@ -4,7 +4,7 @@ template: '', module: 'crud', description: '', - image: '', + image: '' },{ url: '/basic-data', state: 'client.basicdata', @@ -15,6 +15,11 @@ state: 'client.addresses', template: '', module: 'crud' +},{ + url: '/fiscal-data', + state: 'client.fiscaldata', + template: '', + module: 'crud' }] diff --git a/@salix/crud/src/crud.js b/@salix/crud/src/crud.js index 62666d119d..6fc5af1999 100644 --- a/@salix/crud/src/crud.js +++ b/@salix/crud/src/crud.js @@ -1,5 +1,5 @@ export * from './module'; -export * from './client/client' +export * from './client/client'; export {NAME as CUSTOMER_INDEX, COMPONENT as CUSTOMER_INDEX_COMPONENT} from './customer/index';