@sumaris-net/ngx-components 1.18.7 → 1.19.2

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.
Files changed (60) hide show
  1. package/bundles/sumaris-net.ngx-components.umd.js +804 -429
  2. package/bundles/sumaris-net.ngx-components.umd.js.map +1 -1
  3. package/bundles/sumaris-net.ngx-components.umd.min.js +2 -2
  4. package/bundles/sumaris-net.ngx-components.umd.min.js.map +1 -1
  5. package/doc/changelog.md +10 -0
  6. package/esm2015/public_api.js +10 -5
  7. package/esm2015/src/app/admin/admin-routing.module.js +3 -1
  8. package/esm2015/src/app/admin/admin.module.js +2 -1
  9. package/esm2015/src/app/admin/users/list/users.js +45 -7
  10. package/esm2015/src/app/core/services/base-entity-service.class.js +6 -6
  11. package/esm2015/src/app/core/services/local-settings.service.js +5 -5
  12. package/esm2015/src/app/core/services/model/referential.model.js +1 -1
  13. package/esm2015/src/app/core/services/platform.service.js +3 -4
  14. package/esm2015/src/app/shared/material/datetime/material.date.js +82 -70
  15. package/esm2015/src/app/shared/material/datetime/material.datetime.js +3 -3
  16. package/esm2015/src/app/shared/material/datetime/testing/mat-date.test.js +7 -5
  17. package/esm2015/src/app/shared/platforms.js +20 -4
  18. package/esm2015/src/app/shared/validator/validators.js +2 -2
  19. package/esm2015/src/app/social/message/message.form.js +73 -0
  20. package/esm2015/src/app/social/message/message.modal.js +96 -0
  21. package/esm2015/src/app/social/message/message.model.js +65 -0
  22. package/esm2015/src/app/social/message/message.service.js +87 -0
  23. package/esm2015/src/app/social/social.errors.js +6 -0
  24. package/esm2015/src/app/social/social.module.js +12 -15
  25. package/esm2015/src/app/social/user-event/user-event.fragments.js +27 -0
  26. package/esm2015/src/app/social/user-event/user-event.model.js +46 -0
  27. package/esm2015/src/app/social/user-event/user-event.service.js +367 -0
  28. package/esm2015/src/app/social/user-event/user-events.table.js +154 -0
  29. package/fesm2015/sumaris-net.ngx-components.js +734 -411
  30. package/fesm2015/sumaris-net.ngx-components.js.map +1 -1
  31. package/package.json +4 -3
  32. package/public_api.d.ts +9 -4
  33. package/src/app/admin/users/list/users.d.ts +10 -6
  34. package/src/app/core/services/local-settings.service.d.ts +3 -2
  35. package/src/app/core/services/model/referential.model.d.ts +7 -7
  36. package/src/app/shared/material/datetime/material.date.d.ts +6 -8
  37. package/src/app/shared/material/datetime/material.datetime.d.ts +2 -2
  38. package/src/app/shared/platforms.d.ts +1 -1
  39. package/src/app/social/message/message.form.d.ts +27 -0
  40. package/src/app/social/message/message.modal.d.ts +36 -0
  41. package/src/app/social/message/message.model.d.ts +31 -0
  42. package/src/app/social/message/message.service.d.ts +24 -0
  43. package/src/app/social/{services/errors.d.ts → social.errors.d.ts} +2 -1
  44. package/src/app/social/social.module.d.ts +0 -2
  45. package/src/app/social/{services/social.fragments.d.ts → user-event/user-event.fragments.d.ts} +1 -1
  46. package/src/app/social/{services/model → user-event}/user-event.model.d.ts +1 -1
  47. package/src/app/social/{services → user-event}/user-event.service.d.ts +4 -3
  48. package/src/app/social/{list → user-event}/user-events.table.d.ts +2 -2
  49. package/src/assets/i18n/en-US.json +23 -4
  50. package/src/assets/i18n/en.json +23 -4
  51. package/src/assets/i18n/fr.json +25 -5
  52. package/src/theme/_ionic.globals.scss +2 -1
  53. package/sumaris-net.ngx-components.metadata.json +1 -1
  54. package/esm2015/src/app/admin/services/errors.js +0 -6
  55. package/esm2015/src/app/social/list/user-events.table.js +0 -154
  56. package/esm2015/src/app/social/services/errors.js +0 -5
  57. package/esm2015/src/app/social/services/model/user-event.model.js +0 -46
  58. package/esm2015/src/app/social/services/social.fragments.js +0 -27
  59. package/esm2015/src/app/social/services/user-event.service.js +0 -367
  60. package/src/app/admin/services/errors.d.ts +0 -5
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sumaris-net/ngx-components",
3
3
  "description": "SUMARiS Angular components",
4
- "version": "1.18.7",
4
+ "version": "1.19.2",
5
5
  "author": "contact@e-is.pro",
6
6
  "license": "AGPL-3.0",
7
7
  "readmeFilename": "README.md",
@@ -26,8 +26,9 @@
26
26
  "url": "https://gitlab.ifremer.fr/sih-public/sumaris/ngx-sumaris-components/-/issues"
27
27
  },
28
28
  "engines": {
29
- "node": ">= 12.22.1",
30
- "npm": ">= 6.14.4"
29
+ "node": ">= 12.22.8",
30
+ "npm": ">= 8.3.0",
31
+ "yarn": ">= 1.22.0"
31
32
  },
32
33
  "cordova": {
33
34
  "plugins": {
package/public_api.d.ts CHANGED
@@ -156,14 +156,19 @@ export * from './src/app/core/menu/menu.module';
156
156
  export * from './src/app/core/menu/menu.service';
157
157
  export { EntityClass, EntityClasses } from './src/app/core/services/model/entity.decorators';
158
158
  export * from './src/app/social/social.module';
159
- export * from './src/app/social/services/model/user-event.model';
160
- export * from './src/app/social/services/user-event.service';
161
- export * from './src/app/social/list/user-events.table';
159
+ export * from './src/app/social/social.errors';
160
+ export * from './src/app/social/user-event/user-event.model';
161
+ export * from './src/app/social/user-event/user-event.fragments';
162
+ export * from './src/app/social/user-event/user-event.service';
163
+ export * from './src/app/social/user-event/user-events.table';
164
+ export * from './src/app/social/message/message.model';
165
+ export * from './src/app/social/message/message.service';
166
+ export * from './src/app/social/message/message.form';
167
+ export * from './src/app/social/message/message.modal';
162
168
  export * from './src/app/admin/admin.module';
163
169
  export { AdminRoutingModule } from './src/app/admin/admin-routing.module';
164
170
  export * from './src/app/admin/services/filter/person.filter';
165
171
  export * from './src/app/admin/services/validator/person.validator';
166
- export * from './src/app/admin/services/errors';
167
172
  export * from './src/app/admin/services/person.service';
168
173
  export * from './src/app/admin/users/list/users';
169
174
  export * from './src/app/shared/testing/tests.page';
@@ -10,29 +10,33 @@ import { FormFieldDefinition } from '../../../shared/form/field.model';
10
10
  import { PersonFilter } from '../../services/filter/person.filter';
11
11
  import { ConfigService } from '../../../core/services/config.service';
12
12
  import { MatExpansionPanel } from '@angular/material/expansion';
13
+ import { MessageService } from '../../../social/message/message.service';
13
14
  export declare class UsersPage extends AppTable<Person, PersonFilter> implements OnInit {
14
15
  protected accountService: AccountService;
15
16
  protected validatorService: ValidatorService;
16
17
  protected configService: ConfigService;
17
18
  protected dataService: PersonService;
19
+ protected messageService: MessageService;
18
20
  protected cd: ChangeDetectorRef;
19
- canEdit: boolean;
20
- filterForm: FormGroup;
21
- profiles: import("../../../core/services/model/person.model").UserProfileLabel[];
22
- additionalFields: FormFieldDefinition[];
23
- filterCriteriaCount: number;
21
+ readonly canEdit: boolean;
22
+ readonly canSendMessage: boolean;
23
+ readonly filterForm: FormGroup;
24
+ readonly profiles: import("../../../core/services/model/person.model").UserProfileLabel[];
24
25
  readonly statusList: readonly import("../../../core/services/model/referential.model").IStatus[];
25
26
  readonly statusById: Readonly<import("../../../shared/types").KeyValueType<import("../../../core/services/model/referential.model").IStatus>>;
27
+ additionalFields: FormFieldDefinition[];
28
+ filterCriteriaCount: number;
26
29
  set showUsernameColumn(value: boolean);
27
30
  set showUsernameExtranetColumn(value: boolean);
28
31
  useSticky: boolean;
32
+ constructor(injector: Injector, formBuilder: FormBuilder, accountService: AccountService, validatorService: ValidatorService, configService: ConfigService, dataService: PersonService, messageService: MessageService, cd: ChangeDetectorRef, environment: any);
29
33
  filterExpansionPanel: MatExpansionPanel;
30
- constructor(injector: Injector, accountService: AccountService, validatorService: ValidatorService, configService: ConfigService, dataService: PersonService, cd: ChangeDetectorRef, formBuilder: FormBuilder, environment: any);
31
34
  ngOnInit(): void;
32
35
  applyFilterAndClosePanel(event?: UIEvent): void;
33
36
  resetFilter(event?: UIEvent): void;
34
37
  protected restoreFilterOrLoad(): Promise<void>;
35
38
  clearControlValue(event: UIEvent, formControl: AbstractControl): boolean;
39
+ openComposeMessageModal(event?: Event): Promise<any>;
36
40
  referentialToString: typeof referentialToString;
37
41
  protected markForCheck(): void;
38
42
  }
@@ -7,6 +7,7 @@ import { Platform } from '@ionic/angular';
7
7
  import { FormFieldDefinition, FormFieldDefinitionMap } from '../../shared/form/field.model';
8
8
  import { Moment } from 'moment';
9
9
  import { LatLongPattern } from '../../shared/material/latlong/latlong.utils';
10
+ import { Environment } from '../../../environments/environment.class';
10
11
  import { HistoryPageReference } from './model/history.model';
11
12
  import { StartableService } from '../../shared/services/startable-service.class';
12
13
  export declare const SETTINGS_STORAGE_KEY = "settings";
@@ -22,7 +23,7 @@ export declare class LocalSettingsService extends StartableService<LocalSettings
22
23
  private translate;
23
24
  private platform;
24
25
  private storage;
25
- protected environment: any;
26
+ protected readonly environment: Environment;
26
27
  private readonly defaultSettings;
27
28
  onChange: Subject<LocalSettings>;
28
29
  private readonly _optionDefs;
@@ -34,7 +35,7 @@ export declare class LocalSettingsService extends StartableService<LocalSettings
34
35
  get mobile(): boolean;
35
36
  set mobile(value: boolean);
36
37
  get pageHistory(): HistoryPageReference[];
37
- constructor(translate: TranslateService, platform: Platform, storage: Storage, environment: any, defaultSettings: LocalSettings, defaultOptionsMap: FormFieldDefinitionMap);
38
+ constructor(translate: TranslateService, platform: Platform, storage: Storage, environment: Environment, defaultSettings: LocalSettings, defaultOptionsMap: FormFieldDefinitionMap);
38
39
  ngOnStart(): Promise<LocalSettings>;
39
40
  isUsageMode(mode: UsageMode): boolean;
40
41
  isOnFieldMode(value?: UsageMode): boolean;
@@ -9,6 +9,13 @@ export declare interface IStatus {
9
9
  }
10
10
  export declare const StatusList: Readonly<IStatus[]>;
11
11
  export declare const StatusById: Readonly<import("../../../shared/types").KeyValueType<IStatus>>;
12
+ export declare interface IReferentialRef<T extends IEntity<T, ID> = IEntity<any, any>, ID = number> extends IEntity<T, ID> {
13
+ label: string;
14
+ name: string;
15
+ levelId?: number;
16
+ statusId: number;
17
+ entityName: string;
18
+ }
12
19
  export declare abstract class BaseReferential<T extends BaseReferential<T, ID, AO>, ID = number, AO extends ReferentialAsObjectOptions = ReferentialAsObjectOptions, FO = any> extends Entity<T, ID, AO, FO> implements IReferentialRef<T, ID> {
13
20
  label: string;
14
21
  name: string;
@@ -35,13 +42,6 @@ export declare class ReferentialUtils {
35
42
  static isEmpty<T extends BaseReferential<any> | ReferentialRef>(obj: T | any): boolean;
36
43
  static equals<T extends BaseReferential<any> | ReferentialRef>(o1: T | any, o2: T | any): boolean;
37
44
  }
38
- export declare interface IReferentialRef<T extends IEntity<T, ID> = IEntity<any, any>, ID = number> extends IEntity<T, ID> {
39
- label: string;
40
- name: string;
41
- levelId?: number;
42
- statusId: number;
43
- entityName: string;
44
- }
45
45
  export interface ReferentialAsObjectOptions extends EntityAsObjectOptions {
46
46
  keepEntityName?: boolean;
47
47
  }
@@ -1,12 +1,12 @@
1
1
  import { ChangeDetectorRef, ElementRef, OnDestroy, OnInit, QueryList } from '@angular/core';
2
- import { AbstractControl, ControlValueAccessor, FormBuilder, FormControl, FormGroupDirective } from '@angular/forms';
2
+ import { ControlValueAccessor, FormBuilder, FormControl, FormGroupDirective } from '@angular/forms';
3
3
  import { TranslateService } from '@ngx-translate/core';
4
4
  import { Moment } from 'moment';
5
5
  import { Keyboard } from '@ionic-native/keyboard/ngx';
6
6
  import { InputElement } from '../../inputs';
7
7
  import { FloatLabelType } from '@angular/material/form-field';
8
8
  import { DateFilterFn, MatDatepicker, MatDatepickerInputEvent } from '@angular/material/datepicker';
9
- import { DateAdapter } from '@angular/material/core';
9
+ import { MomentDateAdapter } from '@angular/material-moment-adapter';
10
10
  export declare class MatDate implements OnInit, OnDestroy, ControlValueAccessor, InputElement {
11
11
  private dateAdapter;
12
12
  private translate;
@@ -22,11 +22,10 @@ export declare class MatDate implements OnInit, OnDestroy, ControlValueAccessor,
22
22
  private _tabindex;
23
23
  private _keyboardHideDelay;
24
24
  _readonly: boolean;
25
- dayControl: AbstractControl;
26
- displayPattern: string;
27
- dayPattern: string;
25
+ textControl: FormControl;
26
+ datePattern: string;
28
27
  locale: string;
29
- readonly dayMask: (string | RegExp)[];
28
+ readonly mask: (string | RegExp)[];
30
29
  mobile: boolean;
31
30
  formControl: FormControl;
32
31
  formControlName: string;
@@ -47,7 +46,7 @@ export declare class MatDate implements OnInit, OnDestroy, ControlValueAccessor,
47
46
  get value(): any;
48
47
  datePicker: MatDatepicker<Moment>;
49
48
  matInputs: QueryList<ElementRef>;
50
- constructor(dateAdapter: DateAdapter<Moment>, translate: TranslateService, formBuilder: FormBuilder, cd: ChangeDetectorRef, keyboard: Keyboard, formGroupDir: FormGroupDirective);
49
+ constructor(dateAdapter: MomentDateAdapter, translate: TranslateService, formBuilder: FormBuilder, cd: ChangeDetectorRef, keyboard: Keyboard, formGroupDir: FormGroupDirective);
51
50
  ngOnInit(): void;
52
51
  ngOnDestroy(): void;
53
52
  writeValue(value: any): void;
@@ -66,7 +65,6 @@ export declare class MatDate implements OnInit, OnDestroy, ControlValueAccessor,
66
65
  }): void;
67
66
  private onFormChange;
68
67
  private waitKeyboardHide;
69
- private emitChange;
70
68
  private updateTabIndex;
71
69
  private markAsTouched;
72
70
  private markAsDirty;
@@ -1,5 +1,4 @@
1
1
  import { ChangeDetectorRef, ElementRef, OnDestroy, OnInit, QueryList } from '@angular/core';
2
- import { DateAdapter } from '@angular/material/core';
3
2
  import { FloatLabelType } from '@angular/material/form-field';
4
3
  import { ControlValueAccessor, FormBuilder, FormControl, FormGroupDirective } from '@angular/forms';
5
4
  import { TranslateService } from '@ngx-translate/core';
@@ -7,6 +6,7 @@ import { Moment } from 'moment';
7
6
  import { Keyboard } from '@ionic-native/keyboard/ngx';
8
7
  import { InputElement } from '../../inputs';
9
8
  import { DateFilterFn, MatDatepicker, MatDatepickerInputEvent } from '@angular/material/datepicker';
9
+ import { MomentDateAdapter } from '@angular/material-moment-adapter';
10
10
  declare interface NgxTimePicker {
11
11
  selectedHour: {
12
12
  time: number;
@@ -59,7 +59,7 @@ export declare class MatDateTime implements OnInit, OnDestroy, ControlValueAcces
59
59
  datePicker: MatDatepicker<Moment>;
60
60
  timePicker: NgxTimePicker;
61
61
  matInputs: QueryList<ElementRef>;
62
- constructor(dateAdapter: DateAdapter<Moment>, translate: TranslateService, formBuilder: FormBuilder, cd: ChangeDetectorRef, keyboard: Keyboard, formGroupDir: FormGroupDirective);
62
+ constructor(dateAdapter: MomentDateAdapter, translate: TranslateService, formBuilder: FormBuilder, cd: ChangeDetectorRef, keyboard: Keyboard, formGroupDir: FormGroupDirective);
63
63
  ngOnInit(): void;
64
64
  ngOnDestroy(): void;
65
65
  writeValue(value: any): void;
@@ -2,7 +2,7 @@ export declare const matchMedia: (win: Window, query: string) => boolean;
2
2
  export declare const testUserAgent: (win: Window, expr: RegExp) => boolean;
3
3
  export declare const isWindows: (win?: Window) => boolean;
4
4
  export declare const isTouchUi: (win?: Window) => boolean;
5
- export declare const isMobile: (win: Window) => boolean;
6
5
  export declare const isIOS: (win: Window) => boolean;
7
6
  export declare const isAndroid: (win: Window) => boolean;
8
7
  export declare const isCordova: (win: any) => boolean;
8
+ export declare const isMobile: (win: Window) => any;
@@ -0,0 +1,27 @@
1
+ import { ChangeDetectorRef, Injector, OnInit } from '@angular/core';
2
+ import { FormBuilder } from '@angular/forms';
3
+ import { Message } from './message.model';
4
+ import { AppForm } from '../../core/form/form.class';
5
+ import { Person } from '../../core/services/model/person.model';
6
+ import { SuggestFn } from '../../shared/services/entity-service.class';
7
+ import { PersonFilter } from '../../admin/services/filter/person.filter';
8
+ export declare class MessageForm extends AppForm<Message> implements OnInit {
9
+ private formBuilder;
10
+ private readonly cd;
11
+ readonly mobile: boolean;
12
+ suggestFn: SuggestFn<Person, PersonFilter>;
13
+ subjectMinLength: number;
14
+ subjectMaxLength: number;
15
+ bodyMaxLength: number;
16
+ bodyAutoHeight: boolean;
17
+ canSelectType: boolean;
18
+ types: readonly {
19
+ id: string;
20
+ icon: string;
21
+ label: string;
22
+ }[];
23
+ constructor(injector: Injector, formBuilder: FormBuilder, cd: ChangeDetectorRef);
24
+ ngOnInit(): void;
25
+ isSamePerson(o1: Person, o2: Person): boolean;
26
+ protected markForCheck(): void;
27
+ }
@@ -0,0 +1,36 @@
1
+ import { AfterViewInit, ChangeDetectorRef, OnInit } from '@angular/core';
2
+ import { ModalController } from '@ionic/angular';
3
+ import { Message } from './message.model';
4
+ import { Person } from '../../core/services/model/person.model';
5
+ import { SuggestFn } from '../../shared/services/entity-service.class';
6
+ import { PersonFilter } from '../../admin/services/filter/person.filter';
7
+ import { LocalSettingsService } from '../../core/services/local-settings.service';
8
+ import { AccountService } from '../../core/services/account.service';
9
+ export interface MessageModalOptions {
10
+ suggestFn: SuggestFn<Person, PersonFilter>;
11
+ data?: Message;
12
+ canSelectType?: boolean;
13
+ }
14
+ export declare class MessageModal implements OnInit, AfterViewInit, MessageModalOptions {
15
+ protected settings: LocalSettingsService;
16
+ protected viewCtrl: ModalController;
17
+ protected accountService: AccountService;
18
+ protected cd: ChangeDetectorRef;
19
+ readonly mobile: boolean;
20
+ suggestFn: SuggestFn<Person, PersonFilter>;
21
+ data: Message;
22
+ canSelectType: boolean;
23
+ private form;
24
+ constructor(settings: LocalSettingsService, viewCtrl: ModalController, accountService: AccountService, cd: ChangeDetectorRef);
25
+ ngOnInit(): void;
26
+ ngAfterViewInit(): void;
27
+ cancel(event?: UIEvent): void;
28
+ doSubmit(event?: UIEvent): Promise<any>;
29
+ protected markForCheck(): void;
30
+ protected markAsLoading(opts?: {
31
+ emitEvent?: boolean;
32
+ }): void;
33
+ protected markAsLoaded(opts?: {
34
+ emitEvent?: boolean;
35
+ }): void;
36
+ }
@@ -0,0 +1,31 @@
1
+ import { Entity, EntityAsObjectOptions } from '../../core/services/model/entity.model';
2
+ import { StoreObject } from '@apollo/client/core';
3
+ import { EntityFilter } from '../../core/services/model/filter.model';
4
+ import { FilterFn } from '../../shared/services/entity-service.class';
5
+ import { Person } from '../../core/services/model/person.model';
6
+ export declare const MessageTypes: {
7
+ INBOX_MESSAGE: string;
8
+ EMAIL: string;
9
+ FEED: string;
10
+ };
11
+ export declare const MessageTypeList: readonly {
12
+ id: string;
13
+ icon: string;
14
+ label: string;
15
+ }[];
16
+ export declare class Message extends Entity<Message> {
17
+ static fromObject: (source: any, opts?: any) => Message;
18
+ type: string;
19
+ issuer: Person;
20
+ recipients: Person[];
21
+ subject: string;
22
+ body: string;
23
+ constructor();
24
+ fromObject(source: any, opts?: any): void;
25
+ asObject(opts?: EntityAsObjectOptions): StoreObject;
26
+ }
27
+ export declare class MessageFilter extends EntityFilter<MessageFilter, Message> {
28
+ static fromObject: (source: any, opts?: any) => MessageFilter;
29
+ fromObject(source: any, opts?: any): void;
30
+ protected buildFilter(): FilterFn<Message>[];
31
+ }
@@ -0,0 +1,24 @@
1
+ import { GraphqlService } from '../../core/graphql/graphql.service';
2
+ import { ToastController } from '@ionic/angular';
3
+ import { TranslateService } from '@ngx-translate/core';
4
+ import { BaseGraphqlService } from '../../core/services/base-graphql-service.class';
5
+ import { Environment } from '../../../environments/environment.class';
6
+ import { Message, MessageFilter } from './message.model';
7
+ import { ShowToastOptions } from '../../shared/toast/toasts';
8
+ export declare class MessageService extends BaseGraphqlService<Message, MessageFilter> {
9
+ protected graphql: GraphqlService;
10
+ protected translate: TranslateService;
11
+ protected toastController: ToastController;
12
+ protected environment: Environment;
13
+ constructor(graphql: GraphqlService, translate: TranslateService, toastController: ToastController, environment: Environment);
14
+ /**
15
+ * Send a message to recipient(s)
16
+ *
17
+ * @param entity
18
+ * @param opts
19
+ */
20
+ send(entity: Message, opts?: {
21
+ showToast?: boolean;
22
+ }): Promise<boolean>;
23
+ protected showToast(opts: ShowToastOptions): Promise<import("@ionic/core").OverlayEventDetail<any>>;
24
+ }
@@ -1,4 +1,5 @@
1
- export declare const ErrorCodes: {
1
+ export declare const SocialErrorCodes: {
2
2
  LOAD_USER_EVENTS_ERROR: number;
3
3
  SAVE_USER_EVENT_ERROR: number;
4
+ SEND_MESSAGE_ERROR: number;
4
5
  };
@@ -1,4 +1,2 @@
1
- import { ModuleWithProviders } from '@angular/core';
2
1
  export declare class SocialModule {
3
- static forRoot(): ModuleWithProviders<SocialModule>;
4
2
  }
@@ -1,4 +1,4 @@
1
- export declare const SocialFragments: {
1
+ export declare const UserEventFragments: {
2
2
  userEvent: import("graphql/language/ast").DocumentNode;
3
3
  lightUserEvent: import("graphql/language/ast").DocumentNode;
4
4
  };
@@ -1,5 +1,5 @@
1
1
  import { Moment } from 'moment';
2
- import { Entity, EntityAsObjectOptions, IEntity } from '../../../core/services/model/entity.model';
2
+ import { Entity, EntityAsObjectOptions, IEntity } from '../../core/services/model/entity.model';
3
3
  import { PredefinedColors } from '@ionic/core';
4
4
  export declare const UserEventTypes: {
5
5
  DEBUG_DATA: string;
@@ -1,7 +1,7 @@
1
1
  import { AccountService } from '../../core/services/account.service';
2
2
  import { GraphqlService } from '../../core/graphql/graphql.service';
3
3
  import { Observable } from 'rxjs';
4
- import { UserEvent, UserEventAction } from './model/user-event.model';
4
+ import { UserEvent, UserEventAction } from './user-event.model';
5
5
  import { SortDirection } from '@angular/material/sort';
6
6
  import { EntitiesServiceWatchOptions, EntityServiceLoadOptions, FilterFn, IEntitiesService, LoadResult, Page } from '../../shared/services/entity-service.class';
7
7
  import { ShowToastOptions } from '../../shared/toast/toasts';
@@ -10,6 +10,7 @@ import { ToastController } from '@ionic/angular';
10
10
  import { TranslateService } from '@ngx-translate/core';
11
11
  import { NetworkService } from '../../core/services/network.service';
12
12
  import { BaseGraphqlService } from '../../core/services/base-graphql-service.class';
13
+ import { Environment } from '../../../environments/environment.class';
13
14
  import { EntityFilter } from '../../core/services/model/filter.model';
14
15
  export declare class UserEventFilter extends EntityFilter<UserEventFilter, UserEvent> {
15
16
  static fromObject: (source: any, opts?: any) => UserEventFilter;
@@ -30,9 +31,9 @@ export declare class UserEventService extends BaseGraphqlService<UserEvent, User
30
31
  protected network: NetworkService;
31
32
  protected translate: TranslateService;
32
33
  protected toastController: ToastController;
33
- protected environment: any;
34
+ protected environment: Environment;
34
35
  private _userEventActions;
35
- constructor(graphql: GraphqlService, accountService: AccountService, network: NetworkService, translate: TranslateService, toastController: ToastController, environment: any);
36
+ constructor(graphql: GraphqlService, accountService: AccountService, network: NetworkService, translate: TranslateService, toastController: ToastController, environment: Environment);
36
37
  /**
37
38
  *
38
39
  * @param offset
@@ -1,8 +1,8 @@
1
1
  import { ChangeDetectorRef, Injector, OnInit } from '@angular/core';
2
2
  import { TableElement } from '@e-is/ngx-material-table';
3
- import { UserEventFilter, UserEventService } from '../services/user-event.service';
3
+ import { UserEventFilter, UserEventService } from './user-event.service';
4
4
  import { AccountService } from '../../core/services/account.service';
5
- import { UserEvent, UserEventAction } from '../services/model/user-event.model';
5
+ import { UserEvent, UserEventAction } from './user-event.model';
6
6
  import { Moment } from 'moment';
7
7
  import { AppTable } from '../../core/table/table.class';
8
8
  import { SortDirection } from '@angular/material/sort';
@@ -393,15 +393,34 @@
393
393
  "BTN_COPY_TO_LOCAL": "Copy locally",
394
394
  "INFO": {
395
395
  "COPIED_LOCALLY": "Successfully copied"
396
+ },
397
+ "TYPE_ENUM": {
398
+ "DEBUG_DATA": "Debug data",
399
+ "INBOX_MESSAGE": "Inbox message",
400
+ "FEED": "Feed"
396
401
  }
397
402
  },
398
- "EVENT_TYPE_ENUM": {
399
- "DEBUG_DATA": "Debug data",
400
- "INBOX_MESSAGE": "Inbox message"
403
+ "MESSAGE": {
404
+ "TYPE": "Message type",
405
+ "RECIPIENTS": "Recipients",
406
+ "SUBJECT": "Object",
407
+ "BODY_HELP": "Your message...",
408
+ "NEW": {
409
+ "TITLE": "New message"
410
+ },
411
+ "TYPE_ENUM": {
412
+ "INBOX_MESSAGE": "Internal message",
413
+ "EMAIL": "Email",
414
+ "FEED": "Feed"
415
+ }
401
416
  },
402
417
  "ERROR": {
403
418
  "LOAD_USER_EVENTS_ERROR": "Error while loading notifications",
404
- "SAVE_USER_EVENT_ERROR": "Error while saving user message"
419
+ "SAVE_USER_EVENT_ERROR": "Error while saving user notification",
420
+ "SEND_MESSAGE_ERROR": "Error while sending message"
421
+ },
422
+ "INFO": {
423
+ "MESSAGE_SENT": "Message <b>sent</b>"
405
424
  }
406
425
  },
407
426
  "FILE": {
@@ -393,15 +393,34 @@
393
393
  "BTN_COPY_TO_LOCAL": "Copy locally",
394
394
  "INFO": {
395
395
  "COPIED_LOCALLY": "Successfully copied"
396
+ },
397
+ "TYPE_ENUM": {
398
+ "DEBUG_DATA": "Debug data",
399
+ "INBOX_MESSAGE": "Inbox message",
400
+ "FEED": "Feed"
396
401
  }
397
402
  },
398
- "EVENT_TYPE_ENUM": {
399
- "DEBUG_DATA": "Debug data",
400
- "INBOX_MESSAGE": "Inbox message"
403
+ "MESSAGE": {
404
+ "TYPE": "Message type",
405
+ "RECIPIENTS": "Recipients",
406
+ "SUBJECT": "Object",
407
+ "BODY_HELP": "Your message...",
408
+ "NEW": {
409
+ "TITLE": "New message"
410
+ },
411
+ "TYPE_ENUM": {
412
+ "INBOX_MESSAGE": "Internal message",
413
+ "EMAIL": "Email",
414
+ "FEED": "Feed"
415
+ }
401
416
  },
402
417
  "ERROR": {
403
418
  "LOAD_USER_EVENTS_ERROR": "Error while loading notifications",
404
- "SAVE_USER_EVENT_ERROR": "Error while saving user message"
419
+ "SAVE_USER_EVENT_ERROR": "Error while saving user notification",
420
+ "SEND_MESSAGE_ERROR": "Error while sending message"
421
+ },
422
+ "INFO": {
423
+ "MESSAGE_SENT": "Message <b>sent</b>"
405
424
  }
406
425
  },
407
426
  "FILE": {
@@ -175,7 +175,7 @@
175
175
  },
176
176
  "TESTING": "Mode développeur ?",
177
177
  "ENTITY_TRASH": "Activer la corbeille du pod ?",
178
- "UPDATE_TECHNICAL_TABLES": "Mise à jour auto des tables techniques ?",
178
+ "UPDATE_TECHNICAL_TABLES": "Pod > Tables techniques : mise à jour auto ?",
179
179
  "ANALYTIC_REFERENCES_ENABLE": "Stratégie > Références analytiques : Activer ?",
180
180
  "AUTH_TOKEN_TYPE_PLACEHOLDER": "Securité > Type d'authentification",
181
181
  "AUTH_TOKEN_TYPE": {
@@ -347,6 +347,7 @@
347
347
  },
348
348
  "LIST": {
349
349
  "TITLE": "Utilisateurs",
350
+ "BTN_SEND_MESSAGE": "Envoyer un message",
350
351
  "FILTER": {
351
352
  "SEARCH": "Recherche : nom, prénom..."
352
353
  }
@@ -393,15 +394,34 @@
393
394
  "BTN_COPY_TO_LOCAL": "Copier localement",
394
395
  "INFO": {
395
396
  "COPIED_LOCALLY": "Copier localement avec succès"
397
+ },
398
+ "TYPE_ENUM": {
399
+ "DEBUG_DATA": "Donnée de debuggage",
400
+ "INBOX_MESSAGE": "Message entrant",
401
+ "FEED": "Actualité"
396
402
  }
397
403
  },
398
- "EVENT_TYPE_ENUM": {
399
- "DEBUG_DATA": "Donnée de debuggage",
400
- "INBOX_MESSAGE": "Message entrant"
404
+ "MESSAGE": {
405
+ "TYPE": "Type d'envoi",
406
+ "RECIPIENTS": "Destinataires",
407
+ "SUBJECT": "Objet",
408
+ "BODY_HELP": "Votre message...",
409
+ "NEW": {
410
+ "TITLE": "Nouveau message"
411
+ },
412
+ "TYPE_ENUM": {
413
+ "INBOX_MESSAGE": "Messagerie interne",
414
+ "EMAIL": "Email",
415
+ "FEED": "Actualité"
416
+ }
401
417
  },
402
418
  "ERROR": {
403
419
  "LOAD_USER_EVENTS_ERROR": "Erreur de chargement des notifications",
404
- "SAVE_USER_EVENT_ERROR": "Erreur de sauvegarde du message utilisateur"
420
+ "SAVE_USER_EVENT_ERROR": "Erreur de sauvegarde de la notification",
421
+ "SEND_MESSAGE_ERROR": "Erreur lors de l'envoi du message"
422
+ },
423
+ "INFO": {
424
+ "MESSAGE_SENT": "Message <b>envoyé</b>"
405
425
  }
406
426
  },
407
427
  "FILE": {
@@ -16,7 +16,8 @@ $screen-lg: 992px !default;
16
16
  $screen-lg-max: 1199px !default;
17
17
  $screen-xl: 1200px !default;
18
18
  $screen-breakpoints: (
19
- xs: 0,
19
+ xxs: 0,
20
+ xs: $screen-xs,
20
21
  sm: $screen-sm,
21
22
  md: $screen-md,
22
23
  lg: $screen-lg,