@fluxhub/fluxhub-lib 1.0.307 → 1.0.310

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.
@@ -37,7 +37,7 @@ import { DomSanitizer } from '@angular/platform-browser';
37
37
  import { NgControl, NG_VALUE_ACCESSOR, FormsModule } from '@angular/forms';
38
38
  import { MatDialogRef, MatDialog, DateAdapter, MAT_DATE_FORMATS, MatAutocompleteModule, MatButtonModule, MatButtonToggleModule, MatPaginatorModule, MatCardModule, MatCheckboxModule, MatChipsModule, MatDatepickerModule, MatGridListModule, MatIconModule, MatInputModule, MatListModule, MatMenuModule, MatProgressBarModule, MatProgressSpinnerModule, MatRadioModule, MatSelectModule, MatSidenavModule, MatSliderModule, MatSortModule, MatSlideToggleModule, MatSnackBarModule, MatTableModule, MatTabsModule, MatToolbarModule, MatTooltipModule, MatFormFieldModule, MatExpansionModule, MatStepperModule, MatDialogModule, MatNativeDateModule } from '@angular/material';
39
39
  import { ActivatedRoute, Router } from '@angular/router';
40
- import { Injectable, Component, Directive, Pipe, Inject, PLATFORM_ID, Input, forwardRef, Output, EventEmitter, ViewChild, ViewContainerRef, ElementRef, Optional, HostListener, defineInjectable, inject, NgModule } from '@angular/core';
40
+ import { Injectable, Component, Directive, Inject, PLATFORM_ID, Pipe, Input, forwardRef, Output, EventEmitter, ViewChild, ViewContainerRef, ElementRef, Optional, HostListener, defineInjectable, inject, NgModule } from '@angular/core';
41
41
  import { Http } from '@angular/http';
42
42
  import { SlimLoadingBarService } from 'ng2-slim-loading-bar';
43
43
  import { ToastrService } from 'ngx-toastr';
@@ -8359,7 +8359,7 @@ var moment = momentNs;
8359
8359
  /** @type {?} */
8360
8360
  var MOMENT_DATE_FORMATS = {
8361
8361
  parse: {
8362
- dateInput: 'D/MM/YYYY'
8362
+ dateInput: 'DD/MM/YYYY'
8363
8363
  },
8364
8364
  display: {
8365
8365
  dateInput: 'DD/MM/YYYY',
@@ -8550,6 +8550,17 @@ var MomentDateAdapter = /** @class */ (function (_super) {
8550
8550
  * @return {?}
8551
8551
  */
8552
8552
  function (value, parseFormat) {
8553
+ if (value != null) {
8554
+ /** @type {?} */
8555
+ var arr = value.split('/');
8556
+ if (arr.length == 3) {
8557
+ if (arr[1].length == 1)
8558
+ arr[1] = "0" + arr[1];
8559
+ if (arr[0].length == 1)
8560
+ arr[0] = "0" + arr[0];
8561
+ value = arr[0] + "/" + arr[1] + "/" + arr[2];
8562
+ }
8563
+ }
8553
8564
  /** @type {?} */
8554
8565
  var m = moment(value, parseFormat, true);
8555
8566
  if (!m.isValid()) {
@@ -8771,10 +8782,16 @@ var FHDatePickerComponent = /** @class */ (function (_super) {
8771
8782
  /** @type {?} */
8772
8783
  var arr = s.split('/');
8773
8784
  if (arr.length == 3) {
8785
+ if (arr[1].length == 1)
8786
+ arr[1] = "0" + arr[1];
8787
+ if (arr[0].length == 1)
8788
+ arr[0] = "0" + arr[0];
8774
8789
  if (parseInt(arr[2]) < 3000 && parseInt(arr[0]) > 0 && parseInt(arr[0]) <= 31 && parseInt(arr[1]) > 0 && parseInt(arr[1]) <= 12) {
8790
+ console.log('arr ', arr);
8775
8791
  /** @type {?} */
8776
8792
  var dtp = new MomentDateAdapter();
8777
8793
  this.date_sel = dtp.createDate(parseInt(arr[2]), parseInt(arr[1]) - 1, parseInt(arr[0]));
8794
+ console.log('dare s', this.date_sel);
8778
8795
  }
8779
8796
  else
8780
8797
  console.log('data non valida! ', arr);