asv-hlps 1.3.15 → 1.3.17

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.
@@ -0,0 +1,31 @@
1
+ import { AuthTag } from "../auth/AuthTag";
2
+ import { Address } from "./Address";
3
+ import { Gender } from "./Gender";
4
+ import { Ste } from "./Ste";
5
+ import { UserGrp } from "./UserGrp";
6
+ import { UserRole } from "./UserRole";
7
+ import { UserTitr } from "./UserTitr";
8
+ export interface UserBase extends Address {
9
+ id: number;
10
+ codeCompta?: string | number;
11
+ firstname: string;
12
+ lastname: string;
13
+ username?: string;
14
+ birthday?: Date | string;
15
+ password?: string;
16
+ ip?: string;
17
+ isActive: boolean;
18
+ isValided?: boolean;
19
+ disabled?: boolean;
20
+ isBadPayer?: boolean;
21
+ foto?: string;
22
+ clp?: string;
23
+ gender?: Gender;
24
+ titr?: UserTitr;
25
+ grp?: UserGrp;
26
+ tags?: AuthTag[];
27
+ role?: UserRole;
28
+ roles?: UserRole[];
29
+ ste?: Ste;
30
+ fullname?: string;
31
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -5,6 +5,7 @@ import { Leave } from "./Leave";
5
5
  import { Ste } from "./Ste";
6
6
  import { SteGrp } from "./SteGrp";
7
7
  import { User } from "./User";
8
+ import { UserBase } from "./UserBase";
8
9
  import { UserCredit } from "./UserCredit";
9
10
  import { UserGrp } from "./UserGrp";
10
11
  import { UserNotarial } from "./UserNotatial";
@@ -13,4 +14,4 @@ import { UserOnline } from "./UserOnline";
13
14
  import { UserRole } from "./UserRole";
14
15
  import { UserTitr } from "./UserTitr";
15
16
  import { Zone } from "./Zone";
16
- export { UserNotarial, Address, DutyPhcie, Gender, Leave, Ste, SteGrp, User, UserCredit, UserGrp, UserNote, UserOnline, UserRole, UserTitr, Zone, };
17
+ export { Address, DutyPhcie, Gender, Leave, Ste, SteGrp, User, UserCredit, UserGrp, UserNotarial, UserNote, UserOnline, UserRole, UserTitr, UserBase, Zone, };
package/lib/cjs/utils.js CHANGED
@@ -623,7 +623,7 @@ const monthStringName = (date, format = "MMM", options) => {
623
623
  return (0, dayjs_1.default)(date).locale("fr").format(format);
624
624
  };
625
625
  exports.monthStringName = monthStringName;
626
- const dateFormatter = (date, format, separator = "-") => {
626
+ const dateFormatter = (date, format, separator = "/") => {
627
627
  switch (format) {
628
628
  case "y":
629
629
  return (0, dayjs_1.default)(date).format("YYYY");
@@ -642,7 +642,8 @@ const dateFormatter = (date, format, separator = "-") => {
642
642
  case "mfr-long":
643
643
  return (0, dayjs_1.default)(date).locale("fr").format("MMMM");
644
644
  default:
645
- return (0, dayjs_1.default)(date).format(`YYYY${separator}MM${separator}DD`);
645
+ return (0, dayjs_1.default)(date).format(`DD${separator}MM${separator}YYYY`);
646
+ // return dayjs(date).format(`YYYY${separator}MM${separator}DD`);
646
647
  }
647
648
  };
648
649
  exports.dateFormatter = dateFormatter;
@@ -0,0 +1,31 @@
1
+ import { AuthTag } from "../auth/AuthTag";
2
+ import { Address } from "./Address";
3
+ import { Gender } from "./Gender";
4
+ import { Ste } from "./Ste";
5
+ import { UserGrp } from "./UserGrp";
6
+ import { UserRole } from "./UserRole";
7
+ import { UserTitr } from "./UserTitr";
8
+ export interface UserBase extends Address {
9
+ id: number;
10
+ codeCompta?: string | number;
11
+ firstname: string;
12
+ lastname: string;
13
+ username?: string;
14
+ birthday?: Date | string;
15
+ password?: string;
16
+ ip?: string;
17
+ isActive: boolean;
18
+ isValided?: boolean;
19
+ disabled?: boolean;
20
+ isBadPayer?: boolean;
21
+ foto?: string;
22
+ clp?: string;
23
+ gender?: Gender;
24
+ titr?: UserTitr;
25
+ grp?: UserGrp;
26
+ tags?: AuthTag[];
27
+ role?: UserRole;
28
+ roles?: UserRole[];
29
+ ste?: Ste;
30
+ fullname?: string;
31
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -5,6 +5,7 @@ import { Leave } from "./Leave";
5
5
  import { Ste } from "./Ste";
6
6
  import { SteGrp } from "./SteGrp";
7
7
  import { User } from "./User";
8
+ import { UserBase } from "./UserBase";
8
9
  import { UserCredit } from "./UserCredit";
9
10
  import { UserGrp } from "./UserGrp";
10
11
  import { UserNotarial } from "./UserNotatial";
@@ -13,4 +14,4 @@ import { UserOnline } from "./UserOnline";
13
14
  import { UserRole } from "./UserRole";
14
15
  import { UserTitr } from "./UserTitr";
15
16
  import { Zone } from "./Zone";
16
- export { UserNotarial, Address, DutyPhcie, Gender, Leave, Ste, SteGrp, User, UserCredit, UserGrp, UserNote, UserOnline, UserRole, UserTitr, Zone, };
17
+ export { Address, DutyPhcie, Gender, Leave, Ste, SteGrp, User, UserCredit, UserGrp, UserNotarial, UserNote, UserOnline, UserRole, UserTitr, UserBase, Zone, };
package/lib/esm/utils.js CHANGED
@@ -542,7 +542,7 @@ export const monthStringName = (date, format = "MMM", options) => {
542
542
  }
543
543
  return dayjs(date).locale("fr").format(format);
544
544
  };
545
- export const dateFormatter = (date, format, separator = "-") => {
545
+ export const dateFormatter = (date, format, separator = "/") => {
546
546
  switch (format) {
547
547
  case "y":
548
548
  return dayjs(date).format("YYYY");
@@ -561,7 +561,8 @@ export const dateFormatter = (date, format, separator = "-") => {
561
561
  case "mfr-long":
562
562
  return dayjs(date).locale("fr").format("MMMM");
563
563
  default:
564
- return dayjs(date).format(`YYYY${separator}MM${separator}DD`);
564
+ return dayjs(date).format(`DD${separator}MM${separator}YYYY`);
565
+ // return dayjs(date).format(`YYYY${separator}MM${separator}DD`);
565
566
  }
566
567
  };
567
568
  export const countryIsoToFlag = (code) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "asv-hlps",
3
- "version": "1.3.15",
3
+ "version": "1.3.17",
4
4
  "description": "helpers",
5
5
  "main": "./lib/cjs/index.js",
6
6
  "module": "./lib/esm/index.js",