ng-easycommerce 0.0.498 → 0.0.499
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/bundles/ng-easycommerce.umd.js +33 -10
- package/bundles/ng-easycommerce.umd.js.map +1 -1
- package/bundles/ng-easycommerce.umd.min.js +1 -1
- package/bundles/ng-easycommerce.umd.min.js.map +1 -1
- package/esm2015/lib/ec-component/account-ec/account-ec.component.js +2 -2
- package/esm2015/lib/ec-component/account-ec/order-ec/order-ec.component.js +2 -2
- package/esm2015/lib/ec-component/account-ec/orders-list-ec/orders-list-ec.component.js +2 -2
- package/esm2015/lib/ec-component/blocks-ec/block-banner-full-ec/block-banner-full-ec.component.js +2 -2
- package/esm2015/lib/ec-component/cart-ec/cart-ec.component.js +29 -7
- package/esm5/lib/ec-component/account-ec/account-ec.component.js +2 -2
- package/esm5/lib/ec-component/account-ec/order-ec/order-ec.component.js +2 -2
- package/esm5/lib/ec-component/account-ec/orders-list-ec/orders-list-ec.component.js +2 -2
- package/esm5/lib/ec-component/blocks-ec/block-banner-full-ec/block-banner-full-ec.component.js +2 -2
- package/esm5/lib/ec-component/cart-ec/cart-ec.component.js +30 -7
- package/fesm2015/ng-easycommerce.js +32 -10
- package/fesm2015/ng-easycommerce.js.map +1 -1
- package/fesm5/ng-easycommerce.js +33 -10
- package/fesm5/ng-easycommerce.js.map +1 -1
- package/lib/ec-component/cart-ec/cart-ec.component.d.ts +1 -1
- package/ng-easycommerce.metadata.json +1 -1
- package/package.json +1 -1
|
@@ -6026,7 +6026,7 @@
|
|
|
6026
6026
|
AccountEcComponent = __decorate$F([
|
|
6027
6027
|
core.Component({
|
|
6028
6028
|
selector: 'app-account-ec',
|
|
6029
|
-
template: "<section class=\"perfil mt-5\" id=\"accountEcComponent\">\n <div class=\"container row w-100 mx-auto py-md-3\">\n <div class=\"col-12 py-3\">\n <div class=\"row w-100 mx-auto border-bottom justify-content-between align-items-center py-3\">\n <h3 class=\"text-black w-auto\">MIS
|
|
6029
|
+
template: "<section class=\"perfil mt-5\" id=\"accountEcComponent\">\n <div class=\"container row w-100 mx-auto py-md-3\">\n <div class=\"col-12 py-3\">\n <div class=\"row w-100 mx-auto border-bottom justify-content-between align-items-center py-3\">\n <h3 class=\"text-black w-auto\">MIS PEDIDOS2232323232</h3>\n <button class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto\" (click)=\"logout()\">CERRAR SESI\u00D3N</button>\n </div>\n <app-orders-ec></app-orders-ec>\n </div>\n </div>\n</section>\n",
|
|
6030
6030
|
styles: [".font-size-10{font-size:10px!important}"]
|
|
6031
6031
|
})
|
|
6032
6032
|
], AccountEcComponent);
|
|
@@ -6321,7 +6321,7 @@
|
|
|
6321
6321
|
BlockBannerFullEcComponent = __decorate$H([
|
|
6322
6322
|
core.Component({
|
|
6323
6323
|
selector: 'app-block-banner-full-ec',
|
|
6324
|
-
template: "<section [ngClass]=\"trimClassBlock(meta.code) + ' container-fluid px-0'\" *ngIf=\"banners.length\"\n [style.background-color]=\"meta.styles?.backgroundColor\"\n [style.background-image]=\"meta.styles?.backgroundImage ? 'url(' + consts.mediaUrl() + meta.styles?.backgroundImage +')' : 'inherit'\">\n\n\n <!-- si es formato fijo -->\n <ng-container *ngIf=\"banners.length == 1;else carrousel \">\n\n <div class=\"row justify-content-center\">\n <!-- banner sin boton -->\n <a *ngIf=\"!banners[0].styles?.button?.text; else fullwithButton\" href=\"{{banners[0].url}}\">\n <div class=\"item col-12\">\n <img class=\"img-fluid\" [src]=\"consts.mediaBannerUrl() + getImage(banners[0])\" alt=\"\">\n <div class=\"position-absolute w-100 h-100 start-0 top-0\">\n <h2 *ngIf=\"banners[0].title\" [class]=\"'item-title-full px-2 item-position-vertical-' + (banners[0].styles?.description?.position)\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#fff' \">\n {{banners[0].title}}\n </h2>\n <p *ngIf=\"banners[0].subtitle\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#000' \"\n [class]=\"'px-4 item-subtitle-full item-position-vertical-' + (banners[0].styles?.description?.position)\">\n {{banners[0].subtitle}}\n </p>\n </div>\n </div>\n </a>\n\n <!-- banner fijo con boton -->\n <ng-template #fullwithButton>\n <div class=\"item col-12\">\n <img class=\"img-fluid\" [src]=\"consts.mediaBannerUrl() + getImage(banners[0])\" alt=\"\">\n <div class=\"position-absolute w-100 h-100 start-0 top-0\">\n <h2 *ngIf=\"banners[0].title\" [class]=\"'item-title-full px-2 item-position-vertical-' + (banners[0].styles?.description?.position)\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#000' \">\n {{banners[0].title}}\n </h2>\n <p *ngIf=\"banners[0].subtitle\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#000' \"\n [class]=\"'px-4 item-subtitle-full item-position-vertical-' + (banners[0].styles?.description?.position)\">\n {{banners[0].subtitle}}\n </p>\n <div [class]=\"'item-position-vertical-' + (banners[0].styles?.button?.position)\">\n <a *ngIf=\"banners[0].styles?.button?.text\" href=\"{{banners[0].url}}\"\n [class]=\"'item-button-full btn btn-light '\">\n {{banners[0].styles.button.text}}\n </a>\n </div>\n </div>\n </div>\n\n </ng-template>\n </div>\n </ng-container>\n\n\n <!-- si es carrousel -->\n <ng-template #carrousel>\n\n <owl-carousel-o [options]=\"options\">\n <ng-template carouselSlide *ngFor=\"let banner of banners\" [id]=\"banner.id\">\n\n <!-- banner sin boton -->\n <div class=\"item\" *ngIf=\"!banner.styles?.button?.text; else carrouselwithButton\">\n <a *ngIf=\"banner.url; else onlyImage\" href=\"{{banner.url}}\">\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </a>\n <ng-template #onlyImage>\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </ng-template>\n </div>\n\n <!-- banner con boton -->\n <ng-template #carrouselwithButton>\n <div class=\"item\">\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n <div class=\"position-absolute w-100 h-100 start-0 top-0\">\n <h2 *ngIf=\"banner.title\"\n [class]=\"'item-title-full px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\n [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \">\n {{banner.title}}\n </h2>\n <p *ngIf=\"banner.subtitle\"\n [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\n [class]=\"'px-4 item-subtitle-full item-position-vertical-' + (banner.styles?.description?.position)\">\n {{banner.subtitle}}\n </p>\n <div [class]=\"'item-position-vertical-' + (banner.styles?.button?.position)\">\n <a *ngIf=\"banner.styles?.button?.text\" href=\"{{banner.url}}\"\n [class]=\"'item-button-full btn btn-light'\">\n {{banner.styles.button.text}}\n </a>\n </div>\n </div>\n <!-- <a *ngIf=\"!banner.url && (formUrl(banner) != '/')\" [routerLink]=\"formUrl(banner)\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a>\n <a *ngIf=\"banner.url\" href=\"{{banner.url}}\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a> -->\n </div>\n </ng-template>\n\n\n <!-- <div class=\"item\">\n <a *ngIf=\"banner.url; else onlyImage\" href=\"{{banner.url}}\">\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </a>\n <ng-template #onlyImage>\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </ng-template>\n <div class=\"carousel-caption d-block\">\n <a *ngIf=\"!banner.url && (formUrl(banner) != '/')\" [routerLink]=\"formUrl(banner)\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a>\n <a *ngIf=\"banner.url\" href=\"{{banner.url}}\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a>\n </div>\n </div> -->\n </ng-template>\n </owl-carousel-o>\n </ng-template>\n</section
|
|
6324
|
+
template: "<section [ngClass]=\"trimClassBlock(meta.code) + ' container-fluid px-0'\" *ngIf=\"banners.length\"\n [style.background-color]=\"meta.styles?.backgroundColor\"\n [style.background-image]=\"meta.styles?.backgroundImage ? 'url(' + consts.mediaUrl() + meta.styles?.backgroundImage +')' : 'inherit'\">\n\n\n <!-- si es formato fijo -->\n <ng-container *ngIf=\"banners.length == 1;else carrousel \">\n\n <div class=\"row justify-content-center\">\n <!-- banner sin boton -->\n <a *ngIf=\"!banners[0].styles?.button?.text; else fullwithButton\" href=\"{{banners[0].url}}\">\n <div class=\"item col-12\">\n <img class=\"img-fluid\" [src]=\"consts.mediaBannerUrl() + getImage(banners[0])\" alt=\"\">\n <div class=\"position-absolute w-100 h-100 start-0 top-0\">\n <h2 *ngIf=\"banners[0].title\" [class]=\"'item-title-full px-2 item-position-vertical-' + (banners[0].styles?.description?.position)\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#fff' \">\n {{banners[0].title}}\n </h2>\n <p *ngIf=\"banners[0].subtitle\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#000' \"\n [class]=\"'px-4 item-subtitle-full item-position-vertical-' + (banners[0].styles?.description?.position)\">\n {{banners[0].subtitle}}\n </p>\n </div>\n </div>\n </a>\n\n <!-- banner fijo con boton -->\n <ng-template #fullwithButton>\n <div class=\"item col-12\">\n <img class=\"img-fluid\" [src]=\"consts.mediaBannerUrl() + getImage(banners[0])\" alt=\"\">\n <div class=\"position-absolute w-100 h-100 start-0 top-0\">\n <h2 *ngIf=\"banners[0].title\" [class]=\"'item-title-full px-2 item-position-vertical-' + (banners[0].styles?.description?.position)\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#000' \">\n {{banners[0].title}}\n </h2>\n <p *ngIf=\"banners[0].subtitle\"\n [style.color]=\"(banners[0].styles?.description?.color) ? banners[0].styles?.description?.color : '#000' \"\n [class]=\"'px-4 item-subtitle-full item-position-vertical-' + (banners[0].styles?.description?.position)\">\n {{banners[0].subtitle}}\n </p>\n <div [class]=\"'item-position-vertical-' + (banners[0].styles?.button?.position)\">\n <a *ngIf=\"banners[0].styles?.button?.text\" href=\"{{banners[0].url}}\"\n [class]=\"'item-button-full btn btn-light '\">\n {{banners[0].styles.button.text}}\n </a>\n </div>\n </div>\n </div>\n\n </ng-template>\n </div>\n </ng-container>\n\n\n <!-- si es carrousel -->\n <ng-template #carrousel>\n\n <owl-carousel-o [options]=\"options\">\n <ng-template carouselSlide *ngFor=\"let banner of banners\" [id]=\"banner.id\">\n\n <!-- banner sin boton -->\n <div class=\"item\" *ngIf=\"!banner.styles?.button?.text; else carrouselwithButton\">\n <a *ngIf=\"banner.url; else onlyImage\" href=\"{{banner.url}}\">\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </a>\n <ng-template #onlyImage>\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </ng-template>\n </div>\n\n <!-- banner con boton -->\n <ng-template #carrouselwithButton>\n <div class=\"item\">\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n <div class=\"position-absolute w-100 h-100 start-0 top-0\">\n <h2 *ngIf=\"banner.title\"\n [class]=\"'item-title-full px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\n [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \">\n {{banner.title}}\n </h2>\n <p *ngIf=\"banner.subtitle\"\n [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\n [class]=\"'px-4 item-subtitle-full item-position-vertical-' + (banner.styles?.description?.position)\">\n {{banner.subtitle}}\n </p>\n <div [class]=\"'item-position-vertical-' + (banner.styles?.button?.position)\">\n <a *ngIf=\"banner.styles?.button?.text\" href=\"{{banner.url}}\"\n [class]=\"'item-button-full btn btn-light'\">\n {{banner.styles.button.text}}\n </a>\n </div>\n </div>\n <!-- <a *ngIf=\"!banner.url && (formUrl(banner) != '/')\" [routerLink]=\"formUrl(banner)\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a>\n <a *ngIf=\"banner.url\" href=\"{{banner.url}}\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a> -->\n </div>\n </ng-template>\n\n\n <!-- <div class=\"item\">\n <a *ngIf=\"banner.url; else onlyImage\" href=\"{{banner.url}}\">\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </a>\n <ng-template #onlyImage>\n <img [src]=\"consts.mediaBannerUrl() + getImage(banner)\" alt=\"\">\n </ng-template>\n <div class=\"carousel-caption d-block\">\n <a *ngIf=\"!banner.url && (formUrl(banner) != '/')\" [routerLink]=\"formUrl(banner)\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a>\n <a *ngIf=\"banner.url\" href=\"{{banner.url}}\"\n class=\"btn btn-outline-light rounded-0 py-3 px-4 btn-conoce btn-caption-banner\">\n Conocé Mas</a>\n </div>\n </div> -->\n </ng-template>\n </owl-carousel-o>\n </ng-template>\n</section>\n",
|
|
6325
6325
|
styles: [".owl-theme .owl-nav{background:0 0!important}.item{position:relative}.item-title{top:30%}.item-title-full{top:50%}.item-subtitle-full{top:60%}.item-subtitle{top:40%}.item-button{top:60%}.item-button.item-position-vertical-center{left:50%;transform:translate(-50%)}.item-button.item-position-vertical-left{left:10%}.item-button.item-position-vertical-right{right:5%;transform:translate(-50%)}.item-button-full{top:70%}.item-button-full.item-position-vertical-center{left:50%;transform:translate(-50%)}.item-button-full.item-position-vertical-left{left:10%}.item-button-full.item-position-vertical-right{right:5%;transform:translate(-50%)}.item-position-vertical-left{text-align:left}.item-position-vertical-center{text-align:center}.item-position-vertical-right{text-align:right}h2.item-title-full::after{content:none}"]
|
|
6326
6326
|
})
|
|
6327
6327
|
], BlockBannerFullEcComponent);
|
|
@@ -6997,7 +6997,6 @@
|
|
|
6997
6997
|
_this.isLoggedIn = false;
|
|
6998
6998
|
_this.mediaUrl = '';
|
|
6999
6999
|
_this.promotions = [];
|
|
7000
|
-
_this.addressBook = [];
|
|
7001
7000
|
_this.toDecimal = function (amount) { return _this.consts.toDecimal(amount); };
|
|
7002
7001
|
_this.actualizarCantidad = function (item, cantidad, stock) {
|
|
7003
7002
|
cantidad > 0 && cantidad <= stock ? _this.cartService.updateItemQuantity(item, cantidad) : _this.toastrService.show('out-of-stock-actually');
|
|
@@ -7031,9 +7030,18 @@
|
|
|
7031
7030
|
path += variant.options.length ? "?variant=true" : "";
|
|
7032
7031
|
this.router.navigateByUrl(path);
|
|
7033
7032
|
};
|
|
7033
|
+
CartEcComponent.prototype.formatDate = function (date) {
|
|
7034
|
+
var d = new Date(date), month = '' + (d.getMonth() + 1), day = '' + d.getDate(), year = d.getFullYear();
|
|
7035
|
+
if (month.length < 2)
|
|
7036
|
+
month = '0' + month;
|
|
7037
|
+
if (day.length < 2)
|
|
7038
|
+
day = '0' + day;
|
|
7039
|
+
return [year, month, day].join('-');
|
|
7040
|
+
};
|
|
7034
7041
|
CartEcComponent.prototype.cargaModal = function (item) {
|
|
7035
7042
|
return __awaiter$8(this, void 0, void 0, function () {
|
|
7036
7043
|
var sedes, id, this_, allID, bodyTable;
|
|
7044
|
+
var _this = this;
|
|
7037
7045
|
return __generator$8(this, function (_a) {
|
|
7038
7046
|
switch (_a.label) {
|
|
7039
7047
|
case 0: return [4 /*yield*/, this.cartService.getAddressBook()];
|
|
@@ -7057,9 +7065,11 @@
|
|
|
7057
7065
|
var cell3 = row.insertCell(2);
|
|
7058
7066
|
var cell4 = row.insertCell(3);
|
|
7059
7067
|
var cell5 = row.insertCell(4);
|
|
7068
|
+
var cell6 = row.insertCell(5);
|
|
7069
|
+
var date = new Date(Date.parse(lot['date_deliver']));
|
|
7060
7070
|
cell1.innerHTML = '<input id="id' + id + '" style="border: 0;" value="' + lot.id + '" disabled>';
|
|
7061
7071
|
cell2.innerHTML = '<input type="number" id="quantity' + id + '" value= "' + lot.quantity + '"class="form-control w-50" max="' + lot.quantity + '">';
|
|
7062
|
-
cell3.innerHTML = '<input type="
|
|
7072
|
+
cell3.innerHTML = '<input type="date" value="' + _this.formatDate(date) + '" id="deliveryDate' + id + '" class="form-control w-75">';
|
|
7063
7073
|
var opciones = "";
|
|
7064
7074
|
sedes.forEach(function (sede) {
|
|
7065
7075
|
if (sede.id == lot.shipping_address_id) {
|
|
@@ -7070,7 +7080,12 @@
|
|
|
7070
7080
|
}
|
|
7071
7081
|
});
|
|
7072
7082
|
cell4.innerHTML = '<select id="shippingAddress' + id + '" class="form-control w-75">' + opciones + '</select>';
|
|
7073
|
-
cell5.innerHTML = '<
|
|
7083
|
+
cell5.innerHTML = '<input type="button" class="btn btn-primary btnSeguir" type="button" data-bs-toggle="collapse" data-bs-target="#collapseExample' + id + '" aria-expanded="false" aria-controls="collapseExample' + id + '" value="Ver"></input>';
|
|
7084
|
+
cell6.innerHTML = '<div class="col-1 flex-grow-0 text-right btnBorrar d-none d-md-block d-none d-md-block"><button value="' + lot.id + '" class="btn" id="botonBorrar"><img src="./assets/maquetado/img/ic-borrar.svg" alt=""> </button></div>';
|
|
7085
|
+
var row2 = bodyTable.insertRow(bodyTable.rows.length);
|
|
7086
|
+
var fila2 = row2.insertCell(0);
|
|
7087
|
+
fila2.colSpan = 6;
|
|
7088
|
+
fila2.innerHTML = '<div class="collapse" id="collapseExample' + id + '"><input id="notes' + id + '" class="form-control" value="' + lot.notes + '" placeholder="Ingrese un comentario en caso de que sea necesario." type="text"/></div>';
|
|
7074
7089
|
id = id + 1;
|
|
7075
7090
|
allID.push(lot['id']);
|
|
7076
7091
|
});
|
|
@@ -7092,13 +7107,19 @@
|
|
|
7092
7107
|
var cell3 = row.insertCell(2);
|
|
7093
7108
|
var cell4 = row.insertCell(3);
|
|
7094
7109
|
var cell5 = row.insertCell(4);
|
|
7110
|
+
var cell6 = row.insertCell(5);
|
|
7095
7111
|
cell1.innerHTML = '<input id="id' + id + '" style="border: 0;" value="Pendt." disabled>';
|
|
7096
7112
|
cell2.innerHTML = '<input type="number" id="quantity' + id + '" value= "' + (item['quantity'] - cantidadActual) + '"class="form-control w-50" max="' + (item['quantity'] - cantidadActual) + '">';
|
|
7097
7113
|
cell3.innerHTML = '<input type="date" id="deliveryDate' + id + '" class="form-control w-75">';
|
|
7098
7114
|
var opciones = "";
|
|
7099
7115
|
sedes.forEach(function (sede) { opciones += '<option value="' + sede.id + '">' + sede.city + ' - ' + sede.street + '</option>'; });
|
|
7100
7116
|
cell4.innerHTML = '<select id="shippingAddress' + id + '" class="form-control w-75">' + opciones + '</select>';
|
|
7101
|
-
cell5.innerHTML = '<
|
|
7117
|
+
cell5.innerHTML = '<input type="button" class="btn btn-primary btnSeguir" type="button" data-bs-toggle="collapse" data-bs-target="#collapseExample' + id + '" aria-expanded="false" aria-controls="collapseExample' + id + '" value="Ver"></input>';
|
|
7118
|
+
cell6.innerHTML = '<div class="col-1 flex-grow-0 text-right btnBorrar d-none d-md-block d-none d-md-block"><button class="btn" id="botonBorrar"><img src="./assets/maquetado/img/ic-borrar.svg" alt=""> </butt></div>';
|
|
7119
|
+
var row2 = bodyTable.insertRow(bodyTable.rows.length);
|
|
7120
|
+
var fila2 = row2.insertCell(0);
|
|
7121
|
+
fila2.colSpan = 6;
|
|
7122
|
+
fila2.innerHTML = '<div class="collapse" id="collapseExample' + id + '"><input id="notes' + id + '" class="form-control" placeholder="Ingrese un comentario en caso de que sea necesario." type="text"/></div>';
|
|
7102
7123
|
id = id + 1;
|
|
7103
7124
|
}
|
|
7104
7125
|
else {
|
|
@@ -7120,15 +7141,16 @@
|
|
|
7120
7141
|
var quantity = parseInt(document.getElementById("quantity" + index).value);
|
|
7121
7142
|
var deliveryDate = document.getElementById("deliveryDate" + index).value;
|
|
7122
7143
|
var shippingAddress = $("#shippingAddress" + index).val();
|
|
7144
|
+
var notes = $("#notes" + index).val();
|
|
7123
7145
|
var shippingAddressName = $('#shippingAddress' + index + ' option:selected').text();
|
|
7124
7146
|
}
|
|
7125
7147
|
if (lotID == 'Pendt.') {
|
|
7126
7148
|
// console.log('nuevo');
|
|
7127
|
-
this_.cartService.addToLot(item.product, 0, item.variant_id, 0, item.item_id, quantity, item.product.price, item.quantity,
|
|
7149
|
+
this_.cartService.addToLot(item.product, 0, item.variant_id, 0, item.item_id, quantity, item.product.price, item.quantity, item.discount, item.product.price * quantity, 'new', deliveryDate, notes, parseInt(shippingAddress), shippingAddressName, 'newlot');
|
|
7128
7150
|
}
|
|
7129
7151
|
else if (lotID != '') {
|
|
7130
7152
|
// console.log('editar');
|
|
7131
|
-
this_.cartService.addToLot(item.product, 0, item.variant_id, parseInt(lotID), item.item_id, quantity, item.product.price, item.quantity,
|
|
7153
|
+
this_.cartService.addToLot(item.product, 0, item.variant_id, parseInt(lotID), item.item_id, quantity, item.product.price, item.quantity, item.discount, item.product.price * quantity, 'edited', deliveryDate, notes, parseInt(shippingAddress), shippingAddressName, 'editlot');
|
|
7132
7154
|
}
|
|
7133
7155
|
}
|
|
7134
7156
|
allID.forEach(function (element) {
|
|
@@ -7140,6 +7162,7 @@
|
|
|
7140
7162
|
};
|
|
7141
7163
|
$(document).on('click', '#botonBorrar', function (event) {
|
|
7142
7164
|
event.preventDefault();
|
|
7165
|
+
// console.log(this);
|
|
7143
7166
|
$(this).closest('tr').remove();
|
|
7144
7167
|
});
|
|
7145
7168
|
return [2 /*return*/];
|
|
@@ -11988,7 +12011,7 @@
|
|
|
11988
12011
|
OrdersEcComponent = __decorate$1j([
|
|
11989
12012
|
core.Component({
|
|
11990
12013
|
selector: 'app-orders-ec',
|
|
11991
|
-
template: "<div class=\"container-fluid\" id=\"ordersEcComponent\">\n <section id=\"orders\" class=\"w-100\" *ngIf=\"!loading; else loadingView\">\n <div *ngIf=\"orders && orders.length; else noOrders\">\n <div class=\"row mb-1 border-bottom\">\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'number' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('number')\">{{ 'order' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'paymentState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('paymentState')\">{{ 'payment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'method' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('method')\">{{ 'shipment-method' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12 \">\n <p\n [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'methodState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('methodState')\">\n {{ 'shipment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'date' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('date')\">{{ 'date' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'total' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('total')\">{{ 'total' | translate }}:</p>\n </div>\n </div>\n <div class=\"row item border-bottom py-2\" *ngFor=\"let order of orders\">\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold\">\n {{ order.number }}\n </h5>\n <ng-container *ngIf=\"showImage\">\n <ng-container *ngIf=\"order.items[0].product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth\" [src]=\"mediaUrl + order.items[0].product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"order.items[0].product.picturesdefault\" class=\"smc maxwidth\"\n [src]=\"mediaUrl + order.items[0].product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </ng-container>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\" *ngIf=\"order.payments && order.payments.length > 0\">\n {{ order.payments[0].state | translate | titlecase }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n\n <p class=\"price\">\n {{ order.shipments[0].method.name }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ order.shipments[0].state | translate | titlecase }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <!-- <button class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</button> -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\" class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</a>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold text-nowrap\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </h5>\n <button class=\"btn px-0 w-100 btdetalle\" (click)=\"goToOrder(order)\">{{\n 'see-order' | translate }}</button>\n </div>\n </div>\n </div>\n </section>\n</div>\n\n<ng-template #noOrders>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #errorView>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h4>{{ 'orders-error' | translate }}</h4>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>\n",
|
|
12014
|
+
template: "<div class=\"container-fluid\" id=\"ordersEcComponent\">\n <section id=\"orders\" class=\"w-100\" *ngIf=\"!loading; else loadingView\">\n <div *ngIf=\"orders && orders.length; else noOrders\">\n <div class=\"row mb-1 border-bottom\">\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'number' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('number')\">{{ 'order' | translate }}aaa:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'paymentState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('paymentState')\">{{ 'payment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'method' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('method')\">{{ 'shipment-method' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12 \">\n <p\n [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'methodState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('methodState')\">\n {{ 'shipment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'date' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('date')\">{{ 'date' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'total' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('total')\">{{ 'total' | translate }}:</p>\n </div>\n </div>\n <div class=\"row item border-bottom py-2\" *ngFor=\"let order of orders\">\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold\">\n {{ order.number }}\n </h5>\n <ng-container *ngIf=\"showImage\">\n <ng-container *ngIf=\"order.items[0].product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth\" [src]=\"mediaUrl + order.items[0].product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"order.items[0].product.picturesdefault\" class=\"smc maxwidth\"\n [src]=\"mediaUrl + order.items[0].product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </ng-container>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\" *ngIf=\"order.payments && order.payments.length > 0\">\n {{ order.payments[0].state | translate | titlecase }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n\n <p class=\"price\">\n {{ order.shipments[0].method.name }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ order.shipments[0].state | translate | titlecase }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <!-- <button class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</button> -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\" class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</a>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold text-nowrap\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </h5>\n <button class=\"btn px-0 w-100 btdetalle\" (click)=\"goToOrder(order)\">{{\n 'see-order' | translate }}</button>\n </div>\n </div>\n </div>\n </section>\n</div>\n\n<ng-template #noOrders>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #errorView>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h4>{{ 'orders-error' | translate }}</h4>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>\n",
|
|
11992
12015
|
styles: ["#ordersEcComponent .btn.btdetalle{background-color:#000;color:#fff;border-color:#000;border-width:1px;border-radius:10px;padding:10px 0}#ordersEcComponent .btn.btdetalle:hover{background-color:#fff;color:#000;border-color:#000}.asc.dropdown-toggle::after{transform:rotate(180deg)}.applied.dropdown-toggle::after{color:#198754}"]
|
|
11993
12016
|
})
|
|
11994
12017
|
], OrdersEcComponent);
|
|
@@ -12118,7 +12141,7 @@
|
|
|
12118
12141
|
OrderEcComponent = __decorate$1k([
|
|
12119
12142
|
core.Component({
|
|
12120
12143
|
selector: 'app-order-ec',
|
|
12121
|
-
template: "<main class=\"py-5\" id=\"orderEcComponent\">\n <div class=\"container\">\n <div class=\"wrap\" *ngIf=\"!loading; else loadingView\">\n <div *ngIf=\"order; else noOrder\">\n\n <div class=\"row justify-content-between \">\n <div class=\"col-sm-auto col-12 font-brandon\">\n <h4 class=\"tit1 fw-bold\">{{ ('order' | translate) + ': ' + order.number }}</h4>\n </div>\n <ng-container *ngIf=\"order?.invoice\">\n <div class=\"col-sm col-12 font-brandon\">\n <a target=\"_blank\" [href]=\"consts.getUrlBase().slice(0, -1) + order.invoice\"\n class=\"btn btn-link btn-invoice\">\n <i class=\"fas fa-file-download me-1\"></i>\n {{ 'download' | translate }} {{ 'invoices' | translate | titlecase }}\n </a>\n </div>\n </ng-container>\n <a (click)=\"volver()\" class=\"col-auto text-end\">\n <button class=\"btn btvolver bg-gray text-white\">{{ 'back-to-orders' | translate }}</button>\n </a>\n </div>\n\n <section id=\"orders\">\n <div class=\"row pt-2\">\n <div class=\"col-md-2 col-12\">\n <p class=\"st\">{{ 'payment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'payment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0]?.method?.name | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].method.name }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\" class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</a>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'date' | translate }}:</p>\n <p class=\"\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'total' | translate }}:</p>\n <h5 class=\"fw-bold\">\n {{ (order.totals.total) | ecCurrencySymbol}}\n\n </h5>\n </div>\n </div>\n </section>\n\n <div class=\"container py-3 border-top border-bottom\">\n <div *ngIf=\"order.items.length; else noProducts\" class=\"row\">\n <div class=\"col-2 font-sm font-brandon d-none d-md-block\">\n {{ 'product' | translate | uppercase }}\n </div>\n <div class=\"col-4 font-sm font-brandon d-none d-md-block\">\n {{ 'description' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-center font-sm font-brandon d-none d-md-block\">\n {{ 'unit-price' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-center font-sm font-brandon d-none d-md-block\">\n {{ 'quantity' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-end font-sm font-brandon d-none d-md-block\">\n {{ 'total' | translate | uppercase }}\n </div>\n </div>\n <ng-container *ngFor=\"let item of order.items\">\n <div class=\"row cart-items\">\n <div class=\"col-5 col-md-2 py-2\">\n <ng-container *ngIf=\"item.product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth img-fluid rounded-custom \" [src]=\"consts.mediaUrl() + item.product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"item.product.picturesdefault\" class=\"smc maxwidth img-fluid rounded-custom\"\n [src]=\"consts.mediaUrl() + item.product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </div>\n <div\n class=\"col-md-4 col-7 flex-column flex-md-row justify-content-start d-flex align-items-center\">\n <p class=\"font-brandon d-flex w-100 mb-0\">\n {{ item.product.name }} (Cod:{{ item.product.variants[0].code }})\n </p>\n <div class=\"container d-md-none\">\n <div class=\"row\">\n <div class=\"col-4\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-4 font-xl\">\n <p class=\"text-center w-100 m-0\"> {{ (item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) | ecCurrencySymbol}}</p>\n </div>\n <div class=\"col-4 font-xl\">\n <p class=\"text-center w-100 m-0\"> {{ ((item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) * item.quantity) | ecCurrencySymbol}}</p>\n </div>\n </div>\n </div>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\">\n <p class=\"text-center w-100 m-0\">\n {{ (item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) | ecCurrencySymbol}}\n </p>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\">\n <p class=\"text-end w-100 m-0\">\n {{ ((item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) * item.quantity) | ecCurrencySymbol}}</p>\n </div>\n </div>\n </ng-container>\n </div>\n\n <div class=\"container\">\n <div class=\"row\">\n <div class=\"col-12 col-md-6\"></div>\n <div class=\"col-12 col-md-6\">\n <div class=\"row py-4\">\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'total-products' | translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.items) | ecCurrencySymbol }}\n </div>\n\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'shipment' | translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.shipping || '0') | ecCurrencySymbol }}\n </div>\n\n <div *ngIf=\"order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'discount' | translate }}</div>\n <div *ngIf=\"order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom text-end text-end\">\n {{ (order.totals.promotion) | ecCurrencySymbol }}</div>\n\n <div *ngIf=\"order.totals.taxes && order.totals.taxes != 0 \" class=\"col-6 font-brandon font-md text-gray border-bottom \">\n {{ 'taxes' | translate }}</div>\n <div *ngIf=\"order.totals.taxes && order.totals.taxes != 0\" class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.taxes) | ecCurrencySymbol }}</div>\n\n <div class=\"col-6 font-brandon font-md\">{{ 'total' | translate | uppercase }}</div>\n <div class=\"col-6 font-brandon font-md text-end\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n</main>\n\n<ng-template #noOrder>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>\n",
|
|
12144
|
+
template: "<main class=\"py-5\" id=\"orderEcComponent\">\n <div class=\"container\">\n <div class=\"wrap\" *ngIf=\"!loading; else loadingView\">\n <div *ngIf=\"order; else noOrder\">\n\n <div class=\"row justify-content-between \">\n <div class=\"col-sm-auto col-12 font-brandon\">\n <h4 class=\"tit1 fw-bold\">{{ ('order' | translate) + ': ' + order.number }}</h4>\n </div>\n <ng-container *ngIf=\"order?.invoice\">\n <div class=\"col-sm col-12 font-brandon\">\n <a target=\"_blank\" [href]=\"consts.getUrlBase().slice(0, -1) + order.invoice\"\n class=\"btn btn-link btn-invoice\">\n <i class=\"fas fa-file-download me-1\"></i>\n {{ 'download' | translate }} {{ 'invoices' | translate | titlecase }}\n </a>\n </div>\n </ng-container>\n <a (click)=\"volver()\" class=\"col-auto text-end\">\n <button class=\"btn btvolver bg-gray text-white\">{{ 'back-to-orders' | translate }}</button>\n </a>\n </div>\n\n <section id=\"orders\">\n <div class=\"row pt-2\">\n <div class=\"col-md-2 col-12\">\n <p class=\"st\">{{ 'payment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'payment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0]?.method?.name | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].method.name }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\" class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</a>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'date' | translate }}:</p>\n <p class=\"\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'total' | translate }}:</p>\n <h5 class=\"fw-bold\">\n {{ (order.totals.total) | ecCurrencySymbol}}\n\n </h5>\n </div>\n </div>\n </section>\n\n <div class=\"container py-3 border-top border-bottom\">\n <div *ngIf=\"order.items.length; else noProducts\" class=\"row\">\n <div class=\"col-2 font-sm font-brandon d-none d-md-block\">\n {{ 'product' | translate | uppercase }}\n </div>\n <div class=\"col-4 font-sm font-brandon d-none d-md-block\">\n {{ 'description' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-center font-sm font-brandon d-none d-md-block\">\n {{ 'unit-price' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-center font-sm font-brandon d-none d-md-block\">\n {{ 'quantity' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-end font-sm font-brandon d-none d-md-block\">\n {{ 'total' | translate | uppercase }}\n </div>\n </div>\n <ng-container *ngFor=\"let item of order.items\">\n <div class=\"row cart-items\">\n <div class=\"col-5 col-md-2 py-2\">\n <ng-container *ngIf=\"item.product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth img-fluid rounded-custom \" [src]=\"consts.mediaUrl() + item.product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"item.product.picturesdefault\" class=\"smc maxwidth img-fluid rounded-custom\"\n [src]=\"consts.mediaUrl() + item.product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </div>\n <div\n class=\"col-md-4 col-7 flex-column flex-md-row justify-content-start d-flex align-items-center\">\n <p class=\"font-brandon d-flex w-100 mb-0\">\n {{ item.product.name }} (Cod:{{ item.product.variants[0].code }})\n </p>\n <div class=\"container d-md-none\">\n <div class=\"row\">\n <div class=\"col-4\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-4 font-xl\">\n <p class=\"text-center w-100 m-0\"> {{ (item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) | ecCurrencySymbol}}</p>\n </div>\n <div class=\"col-4 font-xl\">\n <p class=\"text-center w-100 m-0\"> {{ ((item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) * item.quantity) | ecCurrencySymbol}}</p>\n </div>\n </div>\n </div>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\">\n <p class=\"text-center w-100 m-0\">\n {{ (item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) | ecCurrencySymbol}}\n </p>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\">\n <p class=\"text-end w-100 m-0\">\n {{ ((item.product.variants[0].saleprice ? item.product.variants[0].saleprice : item.product.variants[0].price) * item.quantity) | ecCurrencySymbol}}</p>\n </div>\n </div>\n </ng-container>\n </div>\n\n <div class=\"container\">\n <div class=\"row\">\n <div class=\"col-12 col-md-6\"></div>\n <div class=\"col-12 col-md-6\">\n <div class=\"row py-4\">\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'total-products' | translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.items) | ecCurrencySymbol }}\n </div>\n\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'shipment' | translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n <!-- {{ (order.totals.shipping || '0') | ecCurrencySymbol }} -->\n Pendiente de cotizar\n </div>\n\n <div *ngIf=\"order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'discount' | translate }}</div>\n <div *ngIf=\"order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom text-end text-end\">\n {{ (order.totals.promotion) | ecCurrencySymbol }}</div>\n\n <div *ngIf=\"order.totals.taxes && order.totals.taxes != 0 \" class=\"col-6 font-brandon font-md text-gray border-bottom \">\n {{ 'taxes' | translate }}</div>\n <div *ngIf=\"order.totals.taxes && order.totals.taxes != 0\" class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.taxes) | ecCurrencySymbol }}</div>\n\n <div class=\"col-6 font-brandon font-md\">{{ 'total' | translate | uppercase }}</div>\n <div class=\"col-6 font-brandon font-md text-end\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n</main>\n\n<ng-template #noOrder>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>\n",
|
|
12122
12145
|
styles: [".maxwidth{max-width:100px}"]
|
|
12123
12146
|
})
|
|
12124
12147
|
], OrderEcComponent);
|