MOBILE-2327 core: Change all import paths
parent
2f95ccccf2
commit
11d052e659
|
@ -16,10 +16,10 @@ import { NgModule } from '@angular/core';
|
||||||
import { AddonCalendarProvider } from './providers/calendar';
|
import { AddonCalendarProvider } from './providers/calendar';
|
||||||
import { AddonCalendarHelperProvider } from './providers/helper';
|
import { AddonCalendarHelperProvider } from './providers/helper';
|
||||||
import { AddonCalendarMainMenuHandler } from './providers/mainmenu-handler';
|
import { AddonCalendarMainMenuHandler } from './providers/mainmenu-handler';
|
||||||
import { CoreMainMenuDelegate } from '../../core/mainmenu/providers/delegate';
|
import { CoreMainMenuDelegate } from '@core/mainmenu/providers/delegate';
|
||||||
import { CoreInitDelegate } from '../../providers/init';
|
import { CoreInitDelegate } from '@providers/init';
|
||||||
import { CoreLocalNotificationsProvider } from '../../providers/local-notifications';
|
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
||||||
import { CoreLoginHelperProvider } from '../../core/login/providers/helper';
|
import { CoreLoginHelperProvider } from '@core/login/providers/helper';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -15,9 +15,9 @@
|
||||||
import { NgModule } from '@angular/core';
|
import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CorePipesModule } from '../../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
import { AddonCalendarEventPage } from './event';
|
import { AddonCalendarEventPage } from './event';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -17,11 +17,11 @@ import { IonicPage, Content, NavParams } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { AddonCalendarProvider } from '../../providers/calendar';
|
import { AddonCalendarProvider } from '../../providers/calendar';
|
||||||
import { AddonCalendarHelperProvider } from '../../providers/helper';
|
import { AddonCalendarHelperProvider } from '../../providers/helper';
|
||||||
import { CoreCoursesProvider } from '../../../../core/courses/providers/courses';
|
import { CoreCoursesProvider } from '@core/courses/providers/courses';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreLocalNotificationsProvider } from '../../../../providers/local-notifications';
|
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
||||||
import { CoreCourseProvider } from '../../../../core/course/providers/course';
|
import { CoreCourseProvider } from '@core/course/providers/course';
|
||||||
import * as moment from 'moment';
|
import * as moment from 'moment';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -15,9 +15,9 @@
|
||||||
import { NgModule } from '@angular/core';
|
import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CorePipesModule } from '../../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
import { AddonCalendarListPage } from './list';
|
import { AddonCalendarListPage } from './list';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -17,15 +17,15 @@ import { IonicPage, Content, PopoverController, NavParams, NavController } from
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { AddonCalendarProvider } from '../../providers/calendar';
|
import { AddonCalendarProvider } from '../../providers/calendar';
|
||||||
import { AddonCalendarHelperProvider } from '../../providers/helper';
|
import { AddonCalendarHelperProvider } from '../../providers/helper';
|
||||||
import { CoreCoursesProvider } from '../../../../core/courses/providers/courses';
|
import { CoreCoursesProvider } from '@core/courses/providers/courses';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreUtilsProvider } from '../../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreLocalNotificationsProvider } from '../../../../providers/local-notifications';
|
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
||||||
import { CoreCoursePickerMenuPopoverComponent } from '../../../../components/course-picker-menu/course-picker-menu-popover';
|
import { CoreCoursePickerMenuPopoverComponent } from '@components/course-picker-menu/course-picker-menu-popover';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreAppProvider } from '../../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreSplitViewComponent } from '../../../../components/split-view/split-view';
|
import { CoreSplitViewComponent } from '@components/split-view/split-view';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Page that displays the list of calendar events.
|
* Page that displays the list of calendar events.
|
||||||
|
|
|
@ -16,7 +16,7 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonCalendarSettingsPage } from './settings';
|
import { AddonCalendarSettingsPage } from './settings';
|
||||||
import { CorePipesModule } from '../../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -15,8 +15,8 @@
|
||||||
import { Component } from '@angular/core';
|
import { Component } from '@angular/core';
|
||||||
import { IonicPage } from 'ionic-angular';
|
import { IonicPage } from 'ionic-angular';
|
||||||
import { AddonCalendarProvider } from '../../providers/calendar';
|
import { AddonCalendarProvider } from '../../providers/calendar';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Page that displays the calendar settings.
|
* Page that displays the calendar settings.
|
||||||
|
|
|
@ -13,15 +13,15 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreSite } from '../../../classes/site';
|
import { CoreSite } from '@classes/site';
|
||||||
import { CoreCoursesProvider } from '../../../core/courses/providers/courses';
|
import { CoreCoursesProvider } from '@core/courses/providers/courses';
|
||||||
import { CoreTimeUtilsProvider } from '../../../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
import { CoreGroupsProvider } from '../../../providers/groups';
|
import { CoreGroupsProvider } from '@providers/groups';
|
||||||
import { CoreConstants } from '../../../core/constants';
|
import { CoreConstants } from '@core/constants';
|
||||||
import { CoreLocalNotificationsProvider } from '../../../providers/local-notifications';
|
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
||||||
import { CoreConfigProvider } from '../../../providers/config';
|
import { CoreConfigProvider } from '@providers/config';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Service to handle calendar events.
|
* Service to handle calendar events.
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreCourseProvider } from '../../../core/course/providers/course';
|
import { CoreCourseProvider } from '@core/course/providers/course';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Service that provides some features regarding lists of courses and categories.
|
* Service that provides some features regarding lists of courses and categories.
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { AddonCalendarProvider } from './calendar';
|
import { AddonCalendarProvider } from './calendar';
|
||||||
import { CoreMainMenuHandler, CoreMainMenuHandlerData } from '../../../core/mainmenu/providers/delegate';
|
import { CoreMainMenuHandler, CoreMainMenuHandlerData } from '@core/mainmenu/providers/delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler to inject an option into main menu.
|
* Handler to inject an option into main menu.
|
||||||
|
|
|
@ -16,7 +16,7 @@ import { NgModule } from '@angular/core';
|
||||||
import { AddonFilesProvider } from './providers/files';
|
import { AddonFilesProvider } from './providers/files';
|
||||||
import { AddonFilesHelperProvider } from './providers/helper';
|
import { AddonFilesHelperProvider } from './providers/helper';
|
||||||
import { AddonFilesMainMenuHandler } from './providers/mainmenu-handler';
|
import { AddonFilesMainMenuHandler } from './providers/mainmenu-handler';
|
||||||
import { CoreMainMenuDelegate } from '../../core/mainmenu/providers/delegate';
|
import { CoreMainMenuDelegate } from '@core/mainmenu/providers/delegate';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -15,8 +15,8 @@
|
||||||
import { NgModule } from '@angular/core';
|
import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { AddonFilesListPage } from './list';
|
import { AddonFilesListPage } from './list';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -15,11 +15,11 @@
|
||||||
import { Component, ViewChild, OnDestroy } from '@angular/core';
|
import { Component, ViewChild, OnDestroy } from '@angular/core';
|
||||||
import { IonicPage, NavParams, NavController } from 'ionic-angular';
|
import { IonicPage, NavParams, NavController } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreAppProvider } from '../../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { AddonFilesProvider } from '../../providers/files';
|
import { AddonFilesProvider } from '../../providers/files';
|
||||||
import { AddonFilesHelperProvider } from '../../providers/helper';
|
import { AddonFilesHelperProvider } from '../../providers/helper';
|
||||||
|
|
||||||
|
|
|
@ -13,9 +13,9 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreMimetypeUtilsProvider } from '../../../providers/utils/mimetype';
|
import { CoreMimetypeUtilsProvider } from '@providers/utils/mimetype';
|
||||||
import { CoreSite } from '../../../classes/site';
|
import { CoreSite } from '@classes/site';
|
||||||
import { Md5 } from 'ts-md5/dist/md5';
|
import { Md5 } from 'ts-md5/dist/md5';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -13,9 +13,9 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreFileUploaderHelperProvider } from '../../../core/fileuploader/providers/helper';
|
import { CoreFileUploaderHelperProvider } from '@core/fileuploader/providers/helper';
|
||||||
import { AddonFilesProvider } from './files';
|
import { AddonFilesProvider } from './files';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { AddonFilesProvider } from './files';
|
import { AddonFilesProvider } from './files';
|
||||||
import { CoreMainMenuHandler, CoreMainMenuHandlerData } from '../../../core/mainmenu/providers/delegate';
|
import { CoreMainMenuHandler, CoreMainMenuHandlerData } from '@core/mainmenu/providers/delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler to inject an option into main menu.
|
* Handler to inject an option into main menu.
|
||||||
|
|
|
@ -16,14 +16,14 @@ import { NgModule } from '@angular/core';
|
||||||
import { CommonModule } from '@angular/common';
|
import { CommonModule } from '@angular/common';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CorePipesModule } from '../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
import { AddonMessagesDiscussionsComponent } from '../components/discussions/discussions';
|
import { AddonMessagesDiscussionsComponent } from '../components/discussions/discussions';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
AddonMessagesDiscussionsComponent
|
AddonMessagesDiscussionsComponent,
|
||||||
],
|
],
|
||||||
imports: [
|
imports: [
|
||||||
CommonModule,
|
CommonModule,
|
||||||
|
@ -36,7 +36,7 @@ import { AddonMessagesDiscussionsComponent } from '../components/discussions/dis
|
||||||
providers: [
|
providers: [
|
||||||
],
|
],
|
||||||
exports: [
|
exports: [
|
||||||
AddonMessagesDiscussionsComponent
|
AddonMessagesDiscussionsComponent,
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
export class AddonMessagesComponentsModule {}
|
export class AddonMessagesComponentsModule {}
|
||||||
|
|
|
@ -15,11 +15,13 @@
|
||||||
import { Component, OnDestroy, ViewChild } from '@angular/core';
|
import { Component, OnDestroy, ViewChild } from '@angular/core';
|
||||||
import { Platform, NavParams } from 'ionic-angular';
|
import { Platform, NavParams } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { AddonMessagesProvider } from '../../providers/messages';
|
import { AddonMessagesProvider } from '../../providers/messages';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreAppProvider } from '../../../../providers/app';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
import { CoreAppProvider } from '@providers/app';
|
||||||
|
import { AddonPushNotificationsDelegate } from '@addon/pushnotifications/providers/delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component that displays the list of discussions.
|
* Component that displays the list of discussions.
|
||||||
|
@ -51,7 +53,8 @@ export class AddonMessagesDiscussionsComponent implements OnDestroy {
|
||||||
|
|
||||||
constructor(private eventsProvider: CoreEventsProvider, sitesProvider: CoreSitesProvider, translate: TranslateService,
|
constructor(private eventsProvider: CoreEventsProvider, sitesProvider: CoreSitesProvider, translate: TranslateService,
|
||||||
private messagesProvider: AddonMessagesProvider, private domUtils: CoreDomUtilsProvider, navParams: NavParams,
|
private messagesProvider: AddonMessagesProvider, private domUtils: CoreDomUtilsProvider, navParams: NavParams,
|
||||||
private appProvider: CoreAppProvider, platform: Platform) {
|
private appProvider: CoreAppProvider, platform: Platform, utils: CoreUtilsProvider,
|
||||||
|
private pushNotificationsDelegate: AddonPushNotificationsDelegate) {
|
||||||
|
|
||||||
this.search.loading = translate.instant('core.searching');
|
this.search.loading = translate.instant('core.searching');
|
||||||
this.loadingMessages = translate.instant('core.loading');
|
this.loadingMessages = translate.instant('core.loading');
|
||||||
|
@ -109,6 +112,14 @@ export class AddonMessagesDiscussionsComponent implements OnDestroy {
|
||||||
});
|
});
|
||||||
|
|
||||||
this.discussionUserId = navParams.get('discussionUserId') || false;
|
this.discussionUserId = navParams.get('discussionUserId') || false;
|
||||||
|
|
||||||
|
// If a message push notification is received, refresh the view.
|
||||||
|
pushNotificationsDelegate.registerReceiveHandler('AddonMessagesDiscussionsComponent', (notification) => {
|
||||||
|
// New message received. If it's from current site, refresh the data.
|
||||||
|
if (utils.isFalseOrZero(notification.notif) && notification.site == this.siteId) {
|
||||||
|
this.refreshData();
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -234,5 +245,6 @@ export class AddonMessagesDiscussionsComponent implements OnDestroy {
|
||||||
this.readChangedObserver && this.readChangedObserver.off();
|
this.readChangedObserver && this.readChangedObserver.off();
|
||||||
this.cronObserver && this.cronObserver.off();
|
this.cronObserver && this.cronObserver.off();
|
||||||
this.appResumeSubscription && this.appResumeSubscription.unsubscribe();
|
this.appResumeSubscription && this.appResumeSubscription.unsubscribe();
|
||||||
|
this.pushNotificationsDelegate.unregisterReceiveHandler('AddonMessagesDiscussionsComponent');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -97,16 +97,13 @@ pushNotificationsDelegate: AddonPushNotificationsDelegate, utils: CoreUtilsProvi
|
||||||
localNotifications.registerClick(AddonMessagesProvider.PUSH_SIMULATION_COMPONENT, notificationClicked);
|
localNotifications.registerClick(AddonMessagesProvider.PUSH_SIMULATION_COMPONENT, notificationClicked);
|
||||||
}
|
}
|
||||||
|
|
||||||
// @todo: use addon manager $mmPushNotificationsDelegate = $mmAddonManager.get('$mmPushNotificationsDelegate');
|
|
||||||
// Register push notification clicks.
|
// Register push notification clicks.
|
||||||
if (pushNotificationsDelegate) {
|
pushNotificationsDelegate.registerHandler('mmaMessages', (notification) => {
|
||||||
pushNotificationsDelegate.registerHandler('mmaMessages', (notification) => {
|
if (utils.isFalseOrZero(notification.notif)) {
|
||||||
if (utils.isFalseOrZero(notification.notif)) {
|
notificationClicked(notification);
|
||||||
notificationClicked(notification);
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,9 +16,9 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonMessagesDiscussionPage } from './discussion';
|
import { AddonMessagesDiscussionPage } from './discussion';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CorePipesModule } from '../../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -15,16 +15,16 @@
|
||||||
import { Component, OnDestroy, ViewChild } from '@angular/core';
|
import { Component, OnDestroy, ViewChild } from '@angular/core';
|
||||||
import { IonicPage, NavParams, NavController, Content } from 'ionic-angular';
|
import { IonicPage, NavParams, NavController, Content } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { AddonMessagesProvider } from '../../providers/messages';
|
import { AddonMessagesProvider } from '../../providers/messages';
|
||||||
import { AddonMessagesSyncProvider } from '../../providers/sync';
|
import { AddonMessagesSyncProvider } from '../../providers/sync';
|
||||||
import { CoreUserProvider } from '../../../../core/user/providers/user';
|
import { CoreUserProvider } from '@core/user/providers/user';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreUtilsProvider } from '../../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreLoggerProvider } from '../../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreAppProvider } from '../../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { coreSlideInOut } from '../../../../classes/animations';
|
import { coreSlideInOut } from '@classes/animations';
|
||||||
import { Md5 } from 'ts-md5/dist/md5';
|
import { Md5 } from 'ts-md5/dist/md5';
|
||||||
import * as moment from 'moment';
|
import * as moment from 'moment';
|
||||||
|
|
||||||
|
|
|
@ -12,11 +12,11 @@
|
||||||
<addon-messages-discussions></addon-messages-discussions>
|
<addon-messages-discussions></addon-messages-discussions>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
</core-tab>
|
</core-tab>
|
||||||
<!-- <core-tab [title]="'addon.messages.contacts' | translate" icon="person">
|
<core-tab [title]="'addon.messages.contacts' | translate" icon="person">
|
||||||
<ng-template>
|
<ng-template>
|
||||||
<addon-messages-contacts></addon-messages-contacts>
|
<addon-messages-contacts></addon-messages-contacts>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
</core-tab>-->
|
</core-tab>
|
||||||
</core-tabs>
|
</core-tabs>
|
||||||
</ion-content>
|
</ion-content>
|
||||||
</core-split-view>
|
</core-split-view>
|
|
@ -16,9 +16,9 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonMessagesIndexPage } from './index';
|
import { AddonMessagesIndexPage } from './index';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CorePipesModule } from '../../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
import { AddonMessagesComponentsModule } from '../../components/components.module';
|
import { AddonMessagesComponentsModule } from '../../components/components.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -14,10 +14,10 @@
|
||||||
|
|
||||||
import { Component, OnDestroy, ViewChild } from '@angular/core';
|
import { Component, OnDestroy, ViewChild } from '@angular/core';
|
||||||
import { IonicPage } from 'ionic-angular';
|
import { IonicPage } from 'ionic-angular';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { AddonMessagesProvider } from '../../providers/messages';
|
import { AddonMessagesProvider } from '../../providers/messages';
|
||||||
import { CoreSplitViewComponent } from '../../../../components/split-view/split-view';
|
import { CoreSplitViewComponent } from '@components/split-view/split-view';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Page that displays the messages index page.
|
* Page that displays the messages index page.
|
||||||
|
|
|
@ -16,8 +16,8 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonMessagesSettingsPage } from './settings';
|
import { AddonMessagesSettingsPage } from './settings';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { AddonMessagesComponentsModule } from '../../components/components.module';
|
import { AddonMessagesComponentsModule } from '../../components/components.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -13,11 +13,11 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreContentLinksHandlerBase } from '../../../core/contentlinks/classes/base-handler';
|
import { CoreContentLinksHandlerBase } from '@core/contentlinks/classes/base-handler';
|
||||||
import { CoreContentLinksAction } from '../../../core/contentlinks/providers/delegate';
|
import { CoreContentLinksAction } from '@core/contentlinks/providers/delegate';
|
||||||
import { CoreContentLinksHelperProvider } from '../../../core/contentlinks/providers/helper';
|
import { CoreContentLinksHelperProvider } from '@core/contentlinks/providers/helper';
|
||||||
import { AddonMessagesProvider } from './messages';
|
import { AddonMessagesProvider } from './messages';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Content links handler for a discussion.
|
* Content links handler for a discussion.
|
||||||
|
|
|
@ -13,9 +13,9 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreContentLinksHandlerBase } from '../../../core/contentlinks/classes/base-handler';
|
import { CoreContentLinksHandlerBase } from '@core/contentlinks/classes/base-handler';
|
||||||
import { CoreContentLinksAction } from '../../../core/contentlinks/providers/delegate';
|
import { CoreContentLinksAction } from '@core/contentlinks/providers/delegate';
|
||||||
import { CoreContentLinksHelperProvider } from '../../../core/contentlinks/providers/helper';
|
import { CoreContentLinksHelperProvider } from '@core/contentlinks/providers/helper';
|
||||||
import { AddonMessagesProvider } from './messages';
|
import { AddonMessagesProvider } from './messages';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -20,8 +20,10 @@ import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreEventsProvider } from '@providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreAppProvider } from '@providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
||||||
import { AddonPushNotificationsProvider } from '@addon/pushnotifications/providers/pushnotifications';
|
import { AddonPushNotificationsProvider } from '@addon/pushnotifications/providers/pushnotifications';
|
||||||
|
import { AddonPushNotificationsDelegate } from '@addon/pushnotifications/providers/delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler to inject an option into main menu.
|
* Handler to inject an option into main menu.
|
||||||
|
@ -36,7 +38,8 @@ export class AddonMessagesMainMenuHandler implements CoreMainMenuHandler, CoreCr
|
||||||
constructor(private messagesProvider: AddonMessagesProvider, private sitesProvider: CoreSitesProvider,
|
constructor(private messagesProvider: AddonMessagesProvider, private sitesProvider: CoreSitesProvider,
|
||||||
private eventsProvider: CoreEventsProvider, private appProvider: CoreAppProvider,
|
private eventsProvider: CoreEventsProvider, private appProvider: CoreAppProvider,
|
||||||
private localNotificationsProvider: CoreLocalNotificationsProvider, private textUtils: CoreTextUtilsProvider,
|
private localNotificationsProvider: CoreLocalNotificationsProvider, private textUtils: CoreTextUtilsProvider,
|
||||||
private pushNotificationsProvider: AddonPushNotificationsProvider) {
|
private pushNotificationsProvider: AddonPushNotificationsProvider, utils: CoreUtilsProvider,
|
||||||
|
pushNotificationsDelegate: AddonPushNotificationsDelegate) {
|
||||||
|
|
||||||
eventsProvider.on(AddonMessagesProvider.READ_CHANGED_EVENT, (data) => {
|
eventsProvider.on(AddonMessagesProvider.READ_CHANGED_EVENT, (data) => {
|
||||||
this.updateBadge(data.siteId);
|
this.updateBadge(data.siteId);
|
||||||
|
@ -51,6 +54,17 @@ export class AddonMessagesMainMenuHandler implements CoreMainMenuHandler, CoreCr
|
||||||
this.badge = '';
|
this.badge = '';
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// If a message push notification is received, refresh the count.
|
||||||
|
pushNotificationsDelegate.registerReceiveHandler('AddonMessagesMainMenuHandler', (notification) => {
|
||||||
|
// New message received. If it's from current site, refresh the data.
|
||||||
|
if (utils.isFalseOrZero(notification.notif) && this.sitesProvider.isCurrentSite(notification.site)) {
|
||||||
|
this.updateBadge(notification.site);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// Register Badge counter.
|
||||||
|
pushNotificationsDelegate.registerCounterHandler('mmaMessages');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -97,11 +111,8 @@ export class AddonMessagesMainMenuHandler implements CoreMainMenuHandler, CoreCr
|
||||||
this.messagesProvider.getUnreadConversationsCount(undefined, siteId).then((unread) => {
|
this.messagesProvider.getUnreadConversationsCount(undefined, siteId).then((unread) => {
|
||||||
// Leave badge enter if there is a 0+ or a 0.
|
// Leave badge enter if there is a 0+ or a 0.
|
||||||
this.badge = parseInt(unread, 10) > 0 ? unread : '';
|
this.badge = parseInt(unread, 10) > 0 ? unread : '';
|
||||||
// @todo: use addon manager $mmaPushNotifications = $mmAddonManager.get('$mmaPushNotifications');
|
|
||||||
// Update badge.
|
// Update badge.
|
||||||
if (this.pushNotificationsProvider) {
|
this.pushNotificationsProvider.updateAddonCounter('mmaMessages', unread, siteId);
|
||||||
this.pushNotificationsProvider.updateAddonCounter('mmaMessages', unread, siteId);
|
|
||||||
}
|
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.badge = '';
|
this.badge = '';
|
||||||
}).finally(() => {
|
}).finally(() => {
|
||||||
|
@ -126,6 +137,7 @@ export class AddonMessagesMainMenuHandler implements CoreMainMenuHandler, CoreCr
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.appProvider.isDesktop() && this.localNotificationsProvider.isAvailable()) {
|
if (this.appProvider.isDesktop() && this.localNotificationsProvider.isAvailable()) {
|
||||||
|
// @todo
|
||||||
/*$mmEmulatorHelper.checkNewNotifications(
|
/*$mmEmulatorHelper.checkNewNotifications(
|
||||||
AddonMessagesProvider.PUSH_SIMULATION_COMPONENT, this.fetchMessages, this.getTitleAndText, siteId);*/
|
AddonMessagesProvider.PUSH_SIMULATION_COMPONENT, this.fetchMessages, this.getTitleAndText, siteId);*/
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,9 +13,9 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreAppProvider } from '../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Service to handle Offline messages.
|
* Service to handle Offline messages.
|
||||||
|
|
|
@ -13,13 +13,13 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreAppProvider } from '../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreUserProvider } from '../../../core/user/providers/user';
|
import { CoreUserProvider } from '@core/user/providers/user';
|
||||||
import { AddonMessagesOfflineProvider } from './messages-offline';
|
import { AddonMessagesOfflineProvider } from './messages-offline';
|
||||||
import { CoreUtilsProvider } from '../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreTimeUtilsProvider } from '../../../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Service to handle messages.
|
* Service to handle messages.
|
||||||
|
@ -872,13 +872,11 @@ export class AddonMessagesProvider {
|
||||||
protected storeUsersFromDiscussions(discussions: any, siteId?: string): void {
|
protected storeUsersFromDiscussions(discussions: any, siteId?: string): void {
|
||||||
const users = [];
|
const users = [];
|
||||||
for (const userId in discussions) {
|
for (const userId in discussions) {
|
||||||
if (typeof userId != 'undefined' && !isNaN(parseInt(userId))) {
|
users.push({
|
||||||
users.push({
|
id: userId,
|
||||||
id: userId,
|
fullname: discussions[userId].fullname,
|
||||||
fullname: discussions[userId].fullname,
|
profileimageurl: discussions[userId].profileimageurl
|
||||||
profileimageurl: discussions[userId].profileimageurl
|
});
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
this.userProvider.storeUsers(users, siteId);
|
this.userProvider.storeUsers(users, siteId);
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreCronHandler } from '../../../providers/cron';
|
import { CoreCronHandler } from '@providers/cron';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { AddonMessagesSyncProvider } from './sync';
|
import { AddonMessagesSyncProvider } from './sync';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -13,14 +13,14 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreSyncBaseProvider } from '../../../classes/base-sync';
|
import { CoreSyncBaseProvider } from '@classes/base-sync';
|
||||||
import { CoreAppProvider } from '../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { AddonMessagesOfflineProvider } from './messages-offline';
|
import { AddonMessagesOfflineProvider } from './messages-offline';
|
||||||
import { AddonMessagesProvider } from './messages';
|
import { AddonMessagesProvider } from './messages';
|
||||||
import { CoreUserProvider } from '../../../core/user/providers/user';
|
import { CoreUserProvider } from '@core/user/providers/user';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -13,9 +13,9 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreUserDelegate, CoreUserProfileHandler, CoreUserProfileHandlerData } from '../../../core/user/providers/user-delegate';
|
import { CoreUserDelegate, CoreUserProfileHandler, CoreUserProfileHandlerData } from '@core/user/providers/user-delegate';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreContentLinksHelperProvider } from '../../../core/contentlinks/providers/helper';
|
import { CoreContentLinksHelperProvider } from '@core/contentlinks/providers/helper';
|
||||||
import { AddonMessagesProvider } from './messages';
|
import { AddonMessagesProvider } from './messages';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -18,9 +18,9 @@ import { AddonModBookProvider } from './providers/book';
|
||||||
import { AddonModBookModuleHandler } from './providers/module-handler';
|
import { AddonModBookModuleHandler } from './providers/module-handler';
|
||||||
import { AddonModBookLinkHandler } from './providers/link-handler';
|
import { AddonModBookLinkHandler } from './providers/link-handler';
|
||||||
import { AddonModBookPrefetchHandler } from './providers/prefetch-handler';
|
import { AddonModBookPrefetchHandler } from './providers/prefetch-handler';
|
||||||
import { CoreCourseModuleDelegate } from '../../../core/course/providers/module-delegate';
|
import { CoreCourseModuleDelegate } from '@core/course/providers/module-delegate';
|
||||||
import { CoreContentLinksDelegate } from '../../../core/contentlinks/providers/delegate';
|
import { CoreContentLinksDelegate } from '@core/contentlinks/providers/delegate';
|
||||||
import { CoreCourseModulePrefetchDelegate } from '../../../core/course/providers/module-prefetch-delegate';
|
import { CoreCourseModulePrefetchDelegate } from '@core/course/providers/module-prefetch-delegate';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -16,9 +16,9 @@ import { NgModule } from '@angular/core';
|
||||||
import { CommonModule } from '@angular/common';
|
import { CommonModule } from '@angular/common';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CoreCourseComponentsModule } from '../../../../core/course/components/components.module';
|
import { CoreCourseComponentsModule } from '@core/course/components/components.module';
|
||||||
import { AddonModBookIndexComponent } from './index/index';
|
import { AddonModBookIndexComponent } from './index/index';
|
||||||
import { AddonModBookTocPopoverComponent } from './toc-popover/toc-popover';
|
import { AddonModBookTocPopoverComponent } from './toc-popover/toc-popover';
|
||||||
import { AddonModBookNavigationArrowsComponent } from './navigation-arrows/navigation-arrows';
|
import { AddonModBookNavigationArrowsComponent } from './navigation-arrows/navigation-arrows';
|
||||||
|
|
|
@ -15,12 +15,12 @@
|
||||||
import { Component, OnInit, OnDestroy, Input, Output, EventEmitter, Optional } from '@angular/core';
|
import { Component, OnInit, OnDestroy, Input, Output, EventEmitter, Optional } from '@angular/core';
|
||||||
import { NavParams, NavController, Content, PopoverController } from 'ionic-angular';
|
import { NavParams, NavController, Content, PopoverController } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreAppProvider } from '../../../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreDomUtilsProvider } from '../../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreCourseProvider } from '../../../../../core/course/providers/course';
|
import { CoreCourseProvider } from '@core/course/providers/course';
|
||||||
import { CoreCourseHelperProvider } from '../../../../../core/course/providers/helper';
|
import { CoreCourseHelperProvider } from '@core/course/providers/helper';
|
||||||
import { CoreCourseModuleMainComponent } from '../../../../../core/course/providers/module-delegate';
|
import { CoreCourseModuleMainComponent } from '@core/course/providers/module-delegate';
|
||||||
import { AddonModBookProvider, AddonModBookContentsMap, AddonModBookTocChapter } from '../../providers/book';
|
import { AddonModBookProvider, AddonModBookContentsMap, AddonModBookTocChapter } from '../../providers/book';
|
||||||
import { AddonModBookPrefetchHandler } from '../../providers/prefetch-handler';
|
import { AddonModBookPrefetchHandler } from '../../providers/prefetch-handler';
|
||||||
import { AddonModBookTocPopoverComponent } from '../../components/toc-popover/toc-popover';
|
import { AddonModBookTocPopoverComponent } from '../../components/toc-popover/toc-popover';
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
import { NgModule } from '@angular/core';
|
import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreDirectivesModule } from '../../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { AddonModBookComponentsModule } from '../../components/components.module';
|
import { AddonModBookComponentsModule } from '../../components/components.module';
|
||||||
import { AddonModBookIndexPage } from './index';
|
import { AddonModBookIndexPage } from './index';
|
||||||
|
|
||||||
|
|
|
@ -14,14 +14,14 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { Http, Response } from '@angular/http';
|
import { Http, Response } from '@angular/http';
|
||||||
import { CoreFileProvider } from '../../../../providers/file';
|
import { CoreFileProvider } from '@providers/file';
|
||||||
import { CoreFilepoolProvider } from '../../../../providers/filepool';
|
import { CoreFilepoolProvider } from '@providers/filepool';
|
||||||
import { CoreLoggerProvider } from '../../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreUtilsProvider } from '../../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreCourseProvider } from '../../../../core/course/providers/course';
|
import { CoreCourseProvider } from '@core/course/providers/course';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A book chapter inside the toc list.
|
* A book chapter inside the toc list.
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreContentLinksModuleIndexHandler } from '../../../../core/contentlinks/classes/module-index-handler';
|
import { CoreContentLinksModuleIndexHandler } from '@core/contentlinks/classes/module-index-handler';
|
||||||
import { CoreCourseHelperProvider } from '../../../../core/course/providers/helper';
|
import { CoreCourseHelperProvider } from '@core/course/providers/helper';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler to treat links to book.
|
* Handler to treat links to book.
|
||||||
|
|
|
@ -16,8 +16,8 @@ import { Injectable } from '@angular/core';
|
||||||
import { NavController, NavOptions } from 'ionic-angular';
|
import { NavController, NavOptions } from 'ionic-angular';
|
||||||
import { AddonModBookProvider } from './book';
|
import { AddonModBookProvider } from './book';
|
||||||
import { AddonModBookIndexComponent } from '../components/index/index';
|
import { AddonModBookIndexComponent } from '../components/index/index';
|
||||||
import { CoreCourseModuleHandler, CoreCourseModuleHandlerData } from '../../../../core/course/providers/module-delegate';
|
import { CoreCourseModuleHandler, CoreCourseModuleHandlerData } from '@core/course/providers/module-delegate';
|
||||||
import { CoreCourseProvider } from '../../../../core/course/providers/course';
|
import { CoreCourseProvider } from '@core/course/providers/course';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler to support book modules.
|
* Handler to support book modules.
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable, Injector } from '@angular/core';
|
import { Injectable, Injector } from '@angular/core';
|
||||||
import { CoreCourseModulePrefetchHandlerBase } from '../../../../core/course/classes/module-prefetch-handler';
|
import { CoreCourseModulePrefetchHandlerBase } from '@core/course/classes/module-prefetch-handler';
|
||||||
import { AddonModBookProvider } from './book';
|
import { AddonModBookProvider } from './book';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -15,8 +15,8 @@
|
||||||
import { NgModule } from '@angular/core';
|
import { NgModule } from '@angular/core';
|
||||||
import { AddonModLabelModuleHandler } from './providers/module-handler';
|
import { AddonModLabelModuleHandler } from './providers/module-handler';
|
||||||
import { AddonModLabelLinkHandler } from './providers/link-handler';
|
import { AddonModLabelLinkHandler } from './providers/link-handler';
|
||||||
import { CoreCourseModuleDelegate } from '../../../core/course/providers/module-delegate';
|
import { CoreCourseModuleDelegate } from '@core/course/providers/module-delegate';
|
||||||
import { CoreContentLinksDelegate } from '../../../core/contentlinks/providers/delegate';
|
import { CoreContentLinksDelegate } from '@core/contentlinks/providers/delegate';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreContentLinksModuleIndexHandler } from '../../../../core/contentlinks/classes/module-index-handler';
|
import { CoreContentLinksModuleIndexHandler } from '@core/contentlinks/classes/module-index-handler';
|
||||||
import { CoreCourseHelperProvider } from '../../../../core/course/providers/helper';
|
import { CoreCourseHelperProvider } from '@core/course/providers/helper';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler to treat links to label.
|
* Handler to treat links to label.
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreCourseModuleHandler, CoreCourseModuleHandlerData } from '../../../../core/course/providers/module-delegate';
|
import { CoreCourseModuleHandler, CoreCourseModuleHandlerData } from '@core/course/providers/module-delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Handler to support label modules.
|
* Handler to support label modules.
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Service to handle push notifications clicks.
|
* Service to handle push notifications clicks.
|
||||||
|
|
|
@ -78,14 +78,7 @@ export class AddonPushNotificationsProvider {
|
||||||
* @return {Promise<any>} Resolved when done.
|
* @return {Promise<any>} Resolved when done.
|
||||||
*/
|
*/
|
||||||
cleanSiteCounters(siteId: string): Promise<any> {
|
cleanSiteCounters(siteId: string): Promise<any> {
|
||||||
return this.appDB.getRecords(this.BADGE_TABLE, {siteid: siteId} ).then((entries) => {
|
return this.appDB.deleteRecords(this.BADGE_TABLE, {siteid: siteId} ).finally(() => {
|
||||||
const promises = [];
|
|
||||||
entries.forEach((entry) => {
|
|
||||||
promises.push(this.appDB.remove(this.BADGE_TABLE, { siteid: entry.siteid, addon: entry.addon }));
|
|
||||||
});
|
|
||||||
|
|
||||||
return Promise.all(promises);
|
|
||||||
}).finally(() => {
|
|
||||||
this.updateAppCounter();
|
this.updateAppCounter();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -95,7 +88,7 @@ export class AddonPushNotificationsProvider {
|
||||||
* @return {Promise<PushOptions>} [description]
|
* @return {Promise<PushOptions>} [description]
|
||||||
*/
|
*/
|
||||||
protected getOptions(): Promise<PushOptions> {
|
protected getOptions(): Promise<PushOptions> {
|
||||||
// @TODO: CoreSettingsProvider.NOTIFICATION_SOUND
|
// @todo: CoreSettingsProvider.NOTIFICATION_SOUND
|
||||||
return this.configProvider.get('CoreSettingsProvider.NOTIFICATION_SOUND', true).then((soundEnabled) => {
|
return this.configProvider.get('CoreSettingsProvider.NOTIFICATION_SOUND', true).then((soundEnabled) => {
|
||||||
return {
|
return {
|
||||||
android: {
|
android: {
|
||||||
|
@ -195,8 +188,8 @@ export class AddonPushNotificationsProvider {
|
||||||
this.pushNotificationsDelegate.received(data);
|
this.pushNotificationsDelegate.received(data);
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// The notification was clicked. For compatibility with old push plugin implementation
|
// The notification was clicked.
|
||||||
// we'll merge all the notification data in a single object.
|
// For compatibility with old push plugin implementation we'll merge all the notification data in a single object.
|
||||||
data.title = notification.title;
|
data.title = notification.title;
|
||||||
data.message = notification.message;
|
data.message = notification.message;
|
||||||
this.notificationClicked(data);
|
this.notificationClicked(data);
|
||||||
|
@ -289,9 +282,9 @@ export class AddonPushNotificationsProvider {
|
||||||
const addons = this.pushNotificationsDelegate.getCounterHandlers(),
|
const addons = this.pushNotificationsDelegate.getCounterHandlers(),
|
||||||
promises = [];
|
promises = [];
|
||||||
|
|
||||||
addons.forEach((addon) => {
|
for (const x in addons) {
|
||||||
promises.push(this.getAddonBadge(siteId, addon));
|
promises.push(this.getAddonBadge(siteId, addons[x]));
|
||||||
});
|
}
|
||||||
|
|
||||||
return Promise.all(promises).then((counters) => {
|
return Promise.all(promises).then((counters) => {
|
||||||
let plus = false,
|
let plus = false,
|
||||||
|
@ -334,7 +327,9 @@ export class AddonPushNotificationsProvider {
|
||||||
|
|
||||||
pushObject.on('registration').subscribe((registrationId: any) => {
|
pushObject.on('registration').subscribe((registrationId: any) => {
|
||||||
this.pushID = registrationId;
|
this.pushID = registrationId;
|
||||||
this.registerDeviceOnMoodle();
|
this.registerDeviceOnMoodle().catch((error) => {
|
||||||
|
this.logger.warn('Can\'t register device', error);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
pushObject.on('error').subscribe((error: any) => {
|
pushObject.on('error').subscribe((error: any) => {
|
||||||
|
|
|
@ -17,6 +17,7 @@ import { Platform } from 'ionic-angular';
|
||||||
import { AddonPushNotificationsProvider } from './providers/pushnotifications';
|
import { AddonPushNotificationsProvider } from './providers/pushnotifications';
|
||||||
import { AddonPushNotificationsDelegate } from './providers/delegate';
|
import { AddonPushNotificationsDelegate } from './providers/delegate';
|
||||||
import { CoreEventsProvider } from '@providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
@ -31,7 +32,9 @@ import { CoreLocalNotificationsProvider } from '@providers/local-notifications';
|
||||||
})
|
})
|
||||||
export class AddonPushNotificationsModule {
|
export class AddonPushNotificationsModule {
|
||||||
constructor(platform: Platform, pushNotificationsProvider: AddonPushNotificationsProvider, eventsProvider: CoreEventsProvider,
|
constructor(platform: Platform, pushNotificationsProvider: AddonPushNotificationsProvider, eventsProvider: CoreEventsProvider,
|
||||||
localNotificationsProvider: CoreLocalNotificationsProvider) {
|
localNotificationsProvider: CoreLocalNotificationsProvider, loggerProvider: CoreLoggerProvider) {
|
||||||
|
|
||||||
|
const logger = loggerProvider.getInstance('AddonPushNotificationsModule');
|
||||||
|
|
||||||
// Register device on GCM or APNS server.
|
// Register device on GCM or APNS server.
|
||||||
platform.ready().then(() => {
|
platform.ready().then(() => {
|
||||||
|
@ -45,11 +48,15 @@ export class AddonPushNotificationsModule {
|
||||||
|
|
||||||
// Register device on Moodle site when login.
|
// Register device on Moodle site when login.
|
||||||
eventsProvider.on(CoreEventsProvider.LOGIN, () => {
|
eventsProvider.on(CoreEventsProvider.LOGIN, () => {
|
||||||
pushNotificationsProvider.registerDeviceOnMoodle();
|
pushNotificationsProvider.registerDeviceOnMoodle().catch((error) => {
|
||||||
|
logger.warn('Can\'t register device', error);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
eventsProvider.on(CoreEventsProvider.SITE_DELETED, (site) => {
|
eventsProvider.on(CoreEventsProvider.SITE_DELETED, (site) => {
|
||||||
pushNotificationsProvider.unregisterDeviceOnMoodle(site);
|
pushNotificationsProvider.unregisterDeviceOnMoodle(site).catch((error) => {
|
||||||
|
logger.warn('Can\'t unregister device', error);
|
||||||
|
});
|
||||||
pushNotificationsProvider.cleanSiteCounters(site.id);
|
pushNotificationsProvider.cleanSiteCounters(site.id);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -16,9 +16,9 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonUserProfileFieldCheckboxHandler } from './providers/handler';
|
import { AddonUserProfileFieldCheckboxHandler } from './providers/handler';
|
||||||
import { CoreUserProfileFieldDelegate } from '../../../core/user/providers/user-profile-field-delegate';
|
import { CoreUserProfileFieldDelegate } from '@core/user/providers/user-profile-field-delegate';
|
||||||
import { AddonUserProfileFieldCheckboxComponent } from './component/checkbox';
|
import { AddonUserProfileFieldCheckboxComponent } from './component/checkbox';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Component, Input, OnInit } from '@angular/core';
|
import { Component, Input, OnInit } from '@angular/core';
|
||||||
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
||||||
import { CoreUtilsProvider } from '../../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Directive to render a checkbox user profile field.
|
* Directive to render a checkbox user profile field.
|
||||||
|
|
|
@ -14,8 +14,8 @@
|
||||||
|
|
||||||
import { Component, Input, OnInit } from '@angular/core';
|
import { Component, Input, OnInit } from '@angular/core';
|
||||||
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
||||||
import { CoreTimeUtilsProvider } from '../../../../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
import { CoreUtilsProvider } from '../../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Directive to render a datetime user profile field.
|
* Directive to render a datetime user profile field.
|
||||||
|
|
|
@ -16,10 +16,10 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonUserProfileFieldDatetimeHandler } from './providers/handler';
|
import { AddonUserProfileFieldDatetimeHandler } from './providers/handler';
|
||||||
import { CoreUserProfileFieldDelegate } from '../../../core/user/providers/user-profile-field-delegate';
|
import { CoreUserProfileFieldDelegate } from '@core/user/providers/user-profile-field-delegate';
|
||||||
import { AddonUserProfileFieldDatetimeComponent } from './component/datetime';
|
import { AddonUserProfileFieldDatetimeComponent } from './component/datetime';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CorePipesModule } from '../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -16,10 +16,10 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonUserProfileFieldMenuHandler } from './providers/handler';
|
import { AddonUserProfileFieldMenuHandler } from './providers/handler';
|
||||||
import { CoreUserProfileFieldDelegate } from '../../../core/user/providers/user-profile-field-delegate';
|
import { CoreUserProfileFieldDelegate } from '@core/user/providers/user-profile-field-delegate';
|
||||||
import { AddonUserProfileFieldMenuComponent } from './component/menu';
|
import { AddonUserProfileFieldMenuComponent } from './component/menu';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Component, Input, OnInit } from '@angular/core';
|
import { Component, Input, OnInit } from '@angular/core';
|
||||||
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
||||||
import { CoreUtilsProvider } from '../../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Directive to render a text user profile field.
|
* Directive to render a text user profile field.
|
||||||
|
|
|
@ -16,7 +16,7 @@ import { Injectable } from '@angular/core';
|
||||||
import { CoreUserProfileFieldHandler, CoreUserProfileFieldHandlerData } from
|
import { CoreUserProfileFieldHandler, CoreUserProfileFieldHandlerData } from
|
||||||
'../../../../core/user/providers/user-profile-field-delegate';
|
'../../../../core/user/providers/user-profile-field-delegate';
|
||||||
import { AddonUserProfileFieldTextComponent } from '../component/text';
|
import { AddonUserProfileFieldTextComponent } from '../component/text';
|
||||||
import { CoreTextUtilsProvider } from '../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Text user profile field handlers.
|
* Text user profile field handlers.
|
||||||
|
|
|
@ -16,10 +16,10 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonUserProfileFieldTextHandler } from './providers/handler';
|
import { AddonUserProfileFieldTextHandler } from './providers/handler';
|
||||||
import { CoreUserProfileFieldDelegate } from '../../../core/user/providers/user-profile-field-delegate';
|
import { CoreUserProfileFieldDelegate } from '@core/user/providers/user-profile-field-delegate';
|
||||||
import { AddonUserProfileFieldTextComponent } from './component/text';
|
import { AddonUserProfileFieldTextComponent } from './component/text';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -16,7 +16,7 @@ import { Injectable } from '@angular/core';
|
||||||
import { CoreUserProfileFieldHandler, CoreUserProfileFieldHandlerData } from
|
import { CoreUserProfileFieldHandler, CoreUserProfileFieldHandlerData } from
|
||||||
'../../../../core/user/providers/user-profile-field-delegate';
|
'../../../../core/user/providers/user-profile-field-delegate';
|
||||||
import { AddonUserProfileFieldTextareaComponent } from '../component/textarea';
|
import { AddonUserProfileFieldTextareaComponent } from '../component/textarea';
|
||||||
import { CoreTextUtilsProvider } from '../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Textarea user profile field handlers.
|
* Textarea user profile field handlers.
|
||||||
|
|
|
@ -16,10 +16,10 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { AddonUserProfileFieldTextareaHandler } from './providers/handler';
|
import { AddonUserProfileFieldTextareaHandler } from './providers/handler';
|
||||||
import { CoreUserProfileFieldDelegate } from '../../../core/user/providers/user-profile-field-delegate';
|
import { CoreUserProfileFieldDelegate } from '@core/user/providers/user-profile-field-delegate';
|
||||||
import { AddonUserProfileFieldTextareaComponent } from './component/textarea';
|
import { AddonUserProfileFieldTextareaComponent } from './component/textarea';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -12,10 +12,10 @@
|
||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { CoreSitesProvider } from '../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreSyncProvider } from '../providers/sync';
|
import { CoreSyncProvider } from '@providers/sync';
|
||||||
import { CoreLoggerProvider } from '../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreAppProvider } from '../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Base class to create sync providers. It provides some common functions.
|
* Base class to create sync providers. It provides some common functions.
|
||||||
|
|
|
@ -13,9 +13,9 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreEventsProvider } from '../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
|
|
||||||
export interface CoreDelegateHandler {
|
export interface CoreDelegateHandler {
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -16,18 +16,18 @@ import { Injector } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { HttpClient } from '@angular/common/http';
|
import { HttpClient } from '@angular/common/http';
|
||||||
import { SQLiteDB } from './sqlitedb';
|
import { SQLiteDB } from './sqlitedb';
|
||||||
import { CoreAppProvider } from '../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreDbProvider } from '../providers/db';
|
import { CoreDbProvider } from '@providers/db';
|
||||||
import { CoreEventsProvider } from '../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreFileProvider } from '../providers/file';
|
import { CoreFileProvider } from '@providers/file';
|
||||||
import { CoreLoggerProvider } from '../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreWSProvider, CoreWSPreSets, CoreWSFileUploadOptions } from '../providers/ws';
|
import { CoreWSProvider, CoreWSPreSets, CoreWSFileUploadOptions } from '@providers/ws';
|
||||||
import { CoreDomUtilsProvider } from '../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreTimeUtilsProvider } from '../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
import { CoreUrlUtilsProvider } from '../providers/utils/url';
|
import { CoreUrlUtilsProvider } from '@providers/utils/url';
|
||||||
import { CoreUtilsProvider } from '../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreConstants } from '../core/constants';
|
import { CoreConstants } from '@core/constants';
|
||||||
import { CoreConfigConstants } from '../configconstants';
|
import { CoreConfigConstants } from '../configconstants';
|
||||||
import { Md5 } from 'ts-md5/dist/md5';
|
import { Md5 } from 'ts-md5/dist/md5';
|
||||||
import { InAppBrowserObject } from '@ionic-native/in-app-browser';
|
import { InAppBrowserObject } from '@ionic-native/in-app-browser';
|
||||||
|
|
|
@ -15,8 +15,8 @@
|
||||||
import { NgModule } from '@angular/core';
|
import { NgModule } from '@angular/core';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreDirectivesModule } from '../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CorePipesModule } from '../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
import { CoreLoadingComponent } from './loading/loading';
|
import { CoreLoadingComponent } from './loading/loading';
|
||||||
import { CoreMarkRequiredComponent } from './mark-required/mark-required';
|
import { CoreMarkRequiredComponent } from './mark-required/mark-required';
|
||||||
import { CoreInputErrorsComponent } from './input-errors/input-errors';
|
import { CoreInputErrorsComponent } from './input-errors/input-errors';
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
import { Component } from '@angular/core';
|
import { Component } from '@angular/core';
|
||||||
import { NavParams, ViewController } from 'ionic-angular';
|
import { NavParams, ViewController } from 'ionic-angular';
|
||||||
import { CoreContextMenuItemComponent } from './context-menu-item';
|
import { CoreContextMenuItemComponent } from './context-menu-item';
|
||||||
import { CoreLoggerProvider } from '../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to display a list of items received by param in a popover.
|
* Component to display a list of items received by param in a popover.
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
import { Component, Input, OnInit, OnDestroy, ElementRef } from '@angular/core';
|
import { Component, Input, OnInit, OnDestroy, ElementRef } from '@angular/core';
|
||||||
import { PopoverController } from 'ionic-angular';
|
import { PopoverController } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreDomUtilsProvider } from '../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreContextMenuItemComponent } from './context-menu-item';
|
import { CoreContextMenuItemComponent } from './context-menu-item';
|
||||||
import { CoreContextMenuPopoverComponent } from './context-menu-popover';
|
import { CoreContextMenuPopoverComponent } from './context-menu-popover';
|
||||||
import { Subject } from 'rxjs';
|
import { Subject } from 'rxjs';
|
||||||
|
|
|
@ -16,7 +16,7 @@ import {
|
||||||
Component, Input, ViewChild, OnInit, OnChanges, DoCheck, ViewContainerRef, ComponentFactoryResolver,
|
Component, Input, ViewChild, OnInit, OnChanges, DoCheck, ViewContainerRef, ComponentFactoryResolver,
|
||||||
KeyValueDiffers, SimpleChange
|
KeyValueDiffers, SimpleChange
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { CoreLoggerProvider } from '../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to create another component dynamically.
|
* Component to create another component dynamically.
|
||||||
|
|
|
@ -14,15 +14,15 @@
|
||||||
|
|
||||||
import { Component, Input, Output, OnInit, OnDestroy, EventEmitter } from '@angular/core';
|
import { Component, Input, Output, OnInit, OnDestroy, EventEmitter } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreAppProvider } from '../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreEventsProvider } from '../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreFileProvider } from '../../providers/file';
|
import { CoreFileProvider } from '@providers/file';
|
||||||
import { CoreFilepoolProvider } from '../../providers/filepool';
|
import { CoreFilepoolProvider } from '@providers/filepool';
|
||||||
import { CoreSitesProvider } from '../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreMimetypeUtilsProvider } from '../../providers/utils/mimetype';
|
import { CoreMimetypeUtilsProvider } from '@providers/utils/mimetype';
|
||||||
import { CoreUtilsProvider } from '../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreConstants } from '../../core/constants';
|
import { CoreConstants } from '@core/constants';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to handle a remote file. Shows the file name, icon (depending on mimetype) and a button
|
* Component to handle a remote file. Shows the file name, icon (depending on mimetype) and a button
|
||||||
|
|
|
@ -15,13 +15,13 @@
|
||||||
import { Component, Input, OnInit, ViewChild, ElementRef } from '@angular/core';
|
import { Component, Input, OnInit, ViewChild, ElementRef } from '@angular/core';
|
||||||
import { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser';
|
import { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser';
|
||||||
import { Platform } from 'ionic-angular';
|
import { Platform } from 'ionic-angular';
|
||||||
import { CoreFileProvider } from '../../providers/file';
|
import { CoreFileProvider } from '@providers/file';
|
||||||
import { CoreLoggerProvider } from '../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreUrlUtilsProvider } from '../../providers/utils/url';
|
import { CoreUrlUtilsProvider } from '@providers/utils/url';
|
||||||
import { CoreUtilsProvider } from '../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Component, Input, OnInit } from '@angular/core';
|
import { Component, Input, OnInit } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { coreShowHideAnimation } from '../../classes/animations';
|
import { coreShowHideAnimation } from '@classes/animations';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to show a loading spinner and message while data is being loaded.
|
* Component to show a loading spinner and message while data is being loaded.
|
||||||
|
|
|
@ -14,11 +14,11 @@
|
||||||
|
|
||||||
import { Component, Input, Output, OnInit, EventEmitter } from '@angular/core';
|
import { Component, Input, Output, OnInit, EventEmitter } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreFileProvider } from '../../providers/file';
|
import { CoreFileProvider } from '@providers/file';
|
||||||
import { CoreDomUtilsProvider } from '../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreMimetypeUtilsProvider } from '../../providers/utils/mimetype';
|
import { CoreMimetypeUtilsProvider } from '@providers/utils/mimetype';
|
||||||
import { CoreTextUtilsProvider } from '../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreUtilsProvider } from '../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import * as moment from 'moment';
|
import * as moment from 'moment';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -14,8 +14,8 @@
|
||||||
|
|
||||||
import { Component, Input, OnInit, AfterViewInit, ElementRef } from '@angular/core';
|
import { Component, Input, OnInit, AfterViewInit, ElementRef } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreTextUtilsProvider } from '../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreUtilsProvider } from '../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Directive to add a red asterisk for required input fields.
|
* Directive to add a red asterisk for required input fields.
|
||||||
|
|
|
@ -14,8 +14,8 @@
|
||||||
|
|
||||||
import { Component, Input, OnInit, OnDestroy, ContentChildren, ElementRef, QueryList } from '@angular/core';
|
import { Component, Input, OnInit, OnDestroy, ContentChildren, ElementRef, QueryList } from '@angular/core';
|
||||||
import { Button } from 'ionic-angular';
|
import { Button } from 'ionic-angular';
|
||||||
import { CoreLoggerProvider } from '../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreDomUtilsProvider } from '../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreContextMenuComponent } from '../context-menu/context-menu';
|
import { CoreContextMenuComponent } from '../context-menu/context-menu';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Component, Input, Output, EventEmitter, ViewChild, ElementRef } from '@angular/core';
|
import { Component, Input, Output, EventEmitter, ViewChild, ElementRef } from '@angular/core';
|
||||||
import { TextInput } from 'ionic-angular';
|
import { TextInput } from 'ionic-angular';
|
||||||
import { CoreDomUtilsProvider } from '../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { FormControl } from '@angular/forms';
|
import { FormControl } from '@angular/forms';
|
||||||
import { Keyboard } from '@ionic-native/keyboard';
|
import { Keyboard } from '@ionic-native/keyboard';
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreUtilsProvider } from '../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to display a "search box".
|
* Component to display a "search box".
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
||||||
import { CoreUtilsProvider } from '../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreTextUtilsProvider } from '../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to display a "send message form".
|
* Component to display a "send message form".
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Component, OnInit, AfterViewInit, Input, ElementRef } from '@angular/core';
|
import { Component, OnInit, AfterViewInit, Input, ElementRef } from '@angular/core';
|
||||||
import { CoreUtilsProvider } from '../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to allow showing and hiding a password. The affected input MUST have a name to identify it.
|
* Component to allow showing and hiding a password. The affected input MUST have a name to identify it.
|
||||||
|
|
|
@ -14,8 +14,8 @@
|
||||||
|
|
||||||
import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreSitesProvider } from '../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreTextUtilsProvider } from '../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to display a site selector. It will display a select with the list of sites. If the selected site changes,
|
* Component to display a site selector. It will display a select with the list of sites. If the selected site changes,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
import { Component, Input, Output, OnInit, OnDestroy, ElementRef, EventEmitter, ContentChild, TemplateRef } from '@angular/core';
|
import { Component, Input, Output, OnInit, OnDestroy, ElementRef, EventEmitter, ContentChild, TemplateRef } from '@angular/core';
|
||||||
import { CoreTabsComponent } from './tabs';
|
import { CoreTabsComponent } from './tabs';
|
||||||
import { Content } from 'ionic-angular';
|
import { Content } from 'ionic-angular';
|
||||||
import { CoreDomUtilsProvider } from '../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreNavBarButtonsComponent } from '../navbar-buttons/navbar-buttons';
|
import { CoreNavBarButtonsComponent } from '../navbar-buttons/navbar-buttons';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -15,8 +15,8 @@
|
||||||
import { NavController } from 'ionic-angular';
|
import { NavController } from 'ionic-angular';
|
||||||
import { CoreContentLinksAction } from '../providers/delegate';
|
import { CoreContentLinksAction } from '../providers/delegate';
|
||||||
import { CoreContentLinksHandlerBase } from './base-handler';
|
import { CoreContentLinksHandlerBase } from './base-handler';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreCourseHelperProvider } from '../../course/providers/helper';
|
import { CoreCourseHelperProvider } from '../../course/providers/helper';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -16,8 +16,8 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { CoreContentLinksChooseSitePage } from './choose-site';
|
import { CoreContentLinksChooseSitePage } from './choose-site';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -14,8 +14,8 @@
|
||||||
|
|
||||||
import { Component, OnInit } from '@angular/core';
|
import { Component, OnInit } from '@angular/core';
|
||||||
import { IonicPage, NavController, NavParams } from 'ionic-angular';
|
import { IonicPage, NavController, NavParams } from 'ionic-angular';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreContentLinksDelegate, CoreContentLinksAction } from '../../providers/delegate';
|
import { CoreContentLinksDelegate, CoreContentLinksAction } from '../../providers/delegate';
|
||||||
import { CoreContentLinksHelperProvider } from '../../providers/helper';
|
import { CoreContentLinksHelperProvider } from '../../providers/helper';
|
||||||
|
|
||||||
|
|
|
@ -14,10 +14,10 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { NavController } from 'ionic-angular';
|
import { NavController } from 'ionic-angular';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreUrlUtilsProvider } from '../../../providers/utils/url';
|
import { CoreUrlUtilsProvider } from '@providers/utils/url';
|
||||||
import { CoreUtilsProvider } from '../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface that all handlers must implement.
|
* Interface that all handlers must implement.
|
||||||
|
|
|
@ -15,14 +15,14 @@
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { NavController } from 'ionic-angular';
|
import { NavController } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreAppProvider } from '../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreInitDelegate } from '../../../providers/init';
|
import { CoreInitDelegate } from '@providers/init';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreUrlUtilsProvider } from '../../../providers/utils/url';
|
import { CoreUrlUtilsProvider } from '@providers/utils/url';
|
||||||
import { CoreLoginHelperProvider } from '../../login/providers/helper';
|
import { CoreLoginHelperProvider } from '../../login/providers/helper';
|
||||||
import { CoreContentLinksDelegate, CoreContentLinksAction } from './delegate';
|
import { CoreContentLinksDelegate, CoreContentLinksAction } from './delegate';
|
||||||
import { CoreConstants } from '../../constants';
|
import { CoreConstants } from '../../constants';
|
||||||
|
|
|
@ -14,11 +14,11 @@
|
||||||
|
|
||||||
import { Injector } from '@angular/core';
|
import { Injector } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreAppProvider } from '../../../providers/app';
|
import { CoreAppProvider } from '@providers/app';
|
||||||
import { CoreFilepoolProvider } from '../../../providers/filepool';
|
import { CoreFilepoolProvider } from '@providers/filepool';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreUtilsProvider } from '../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreCourseProvider } from '../providers/course';
|
import { CoreCourseProvider } from '../providers/course';
|
||||||
import { CoreCourseModulePrefetchHandler } from '../providers/module-prefetch-delegate';
|
import { CoreCourseModulePrefetchHandler } from '../providers/module-prefetch-delegate';
|
||||||
import { CoreConstants } from '../../constants';
|
import { CoreConstants } from '../../constants';
|
||||||
|
|
|
@ -16,8 +16,8 @@ import { NgModule } from '@angular/core';
|
||||||
import { CommonModule } from '@angular/common';
|
import { CommonModule } from '@angular/common';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CoreCourseFormatComponent } from './format/format';
|
import { CoreCourseFormatComponent } from './format/format';
|
||||||
import { CoreCourseModuleComponent } from './module/module';
|
import { CoreCourseModuleComponent } from './module/module';
|
||||||
import { CoreCourseModuleCompletionComponent } from './module-completion/module-completion';
|
import { CoreCourseModuleCompletionComponent } from './module-completion/module-completion';
|
||||||
|
|
|
@ -17,14 +17,14 @@ import {
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { Content } from 'ionic-angular';
|
import { Content } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreCourseProvider } from '../../../course/providers/course';
|
import { CoreCourseProvider } from '../../../course/providers/course';
|
||||||
import { CoreCourseHelperProvider } from '../../../course/providers/helper';
|
import { CoreCourseHelperProvider } from '../../../course/providers/helper';
|
||||||
import { CoreCourseFormatDelegate } from '../../../course/providers/format-delegate';
|
import { CoreCourseFormatDelegate } from '../../../course/providers/format-delegate';
|
||||||
import { CoreCourseModulePrefetchDelegate } from '../../../course/providers/module-prefetch-delegate';
|
import { CoreCourseModulePrefetchDelegate } from '../../../course/providers/module-prefetch-delegate';
|
||||||
import { CoreDynamicComponent } from '../../../../components/dynamic-component/dynamic-component';
|
import { CoreDynamicComponent } from '@components/dynamic-component/dynamic-component';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to display course contents using a certain format. If the format isn't found, use default one.
|
* Component to display course contents using a certain format. If the format isn't found, use default one.
|
||||||
|
|
|
@ -14,9 +14,9 @@
|
||||||
|
|
||||||
import { Component, Input, Output, EventEmitter, OnChanges, SimpleChange } from '@angular/core';
|
import { Component, Input, Output, EventEmitter, OnChanges, SimpleChange } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreUserProvider } from '../../../user/providers/user';
|
import { CoreUserProvider } from '../../../user/providers/user';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -14,9 +14,9 @@
|
||||||
|
|
||||||
import { Component, Input, Output, EventEmitter, OnInit, OnDestroy } from '@angular/core';
|
import { Component, Input, Output, EventEmitter, OnInit, OnDestroy } from '@angular/core';
|
||||||
import { NavController } from 'ionic-angular';
|
import { NavController } from 'ionic-angular';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreCourseHelperProvider } from '../../providers/helper';
|
import { CoreCourseHelperProvider } from '../../providers/helper';
|
||||||
import { CoreCourseModuleHandlerButton } from '../../providers/module-delegate';
|
import { CoreCourseModuleHandlerButton } from '../../providers/module-delegate';
|
||||||
import { CoreCourseModulePrefetchDelegate, CoreCourseModulePrefetchHandler } from '../../providers/module-prefetch-delegate';
|
import { CoreCourseModulePrefetchDelegate, CoreCourseModulePrefetchHandler } from '../../providers/module-prefetch-delegate';
|
||||||
|
|
|
@ -16,7 +16,7 @@ import { NgModule } from '@angular/core';
|
||||||
import { CoreCourseFormatSingleActivityComponent } from './components/singleactivity';
|
import { CoreCourseFormatSingleActivityComponent } from './components/singleactivity';
|
||||||
import { CoreCourseFormatSingleActivityHandler } from './providers/handler';
|
import { CoreCourseFormatSingleActivityHandler } from './providers/handler';
|
||||||
import { CoreCourseFormatDelegate } from '../../providers/format-delegate';
|
import { CoreCourseFormatDelegate } from '../../providers/format-delegate';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreCourseFormatHandler } from '../../../providers/format-delegate';
|
import { CoreCourseFormatHandler } from '../../../providers/format-delegate';
|
||||||
import { CoreTimeUtilsProvider } from '../../../../../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
import { CoreConstants } from '../../../../constants';
|
import { CoreConstants } from '../../../../constants';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -16,8 +16,8 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreCourseSectionPage } from './section';
|
import { CoreCourseSectionPage } from './section';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CoreCourseComponentsModule } from '../../components/components.module';
|
import { CoreCourseComponentsModule } from '../../components/components.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -15,10 +15,10 @@
|
||||||
import { Component, ViewChild, OnDestroy } from '@angular/core';
|
import { Component, ViewChild, OnDestroy } from '@angular/core';
|
||||||
import { IonicPage, NavParams, Content, NavController } from 'ionic-angular';
|
import { IonicPage, NavParams, Content, NavController } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreCourseProvider } from '../../providers/course';
|
import { CoreCourseProvider } from '../../providers/course';
|
||||||
import { CoreCourseHelperProvider } from '../../providers/helper';
|
import { CoreCourseHelperProvider } from '../../providers/helper';
|
||||||
import { CoreCourseFormatDelegate } from '../../providers/format-delegate';
|
import { CoreCourseFormatDelegate } from '../../providers/format-delegate';
|
||||||
|
|
|
@ -16,8 +16,8 @@ import { NgModule } from '@angular/core';
|
||||||
import { IonicPageModule } from 'ionic-angular';
|
import { IonicPageModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreCourseUnsupportedModulePage } from './unsupported-module';
|
import { CoreCourseUnsupportedModulePage } from './unsupported-module';
|
||||||
import { CoreComponentsModule } from '../../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CoreCourseComponentsModule } from '../../components/components.module';
|
import { CoreCourseComponentsModule } from '../../components/components.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
import { Component } from '@angular/core';
|
import { Component } from '@angular/core';
|
||||||
import { IonicPage, NavParams } from 'ionic-angular';
|
import { IonicPage, NavParams } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreTextUtilsProvider } from '../../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Page that displays info about an unsupported module.
|
* Page that displays info about an unsupported module.
|
||||||
|
|
|
@ -14,12 +14,12 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreTimeUtilsProvider } from '../../../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
import { CoreUtilsProvider } from '../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreSiteWSPreSets } from '../../../classes/site';
|
import { CoreSiteWSPreSets } from '@classes/site';
|
||||||
import { CoreConstants } from '../../constants';
|
import { CoreConstants } from '../../constants';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -14,12 +14,12 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { NavController } from 'ionic-angular';
|
import { NavController } from 'ionic-angular';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreCourseProvider } from './course';
|
import { CoreCourseProvider } from './course';
|
||||||
import { CoreCourseFormatDefaultHandler } from './default-format';
|
import { CoreCourseFormatDefaultHandler } from './default-format';
|
||||||
import { CoreDelegate, CoreDelegateHandler } from '../../../classes/delegate';
|
import { CoreDelegate, CoreDelegateHandler } from '@classes/delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface that all course format handlers must implement.
|
* Interface that all course format handlers must implement.
|
||||||
|
|
|
@ -15,13 +15,13 @@
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { NavController } from 'ionic-angular';
|
import { NavController } from 'ionic-angular';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreFilepoolProvider } from '../../../providers/filepool';
|
import { CoreFilepoolProvider } from '@providers/filepool';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreTextUtilsProvider } from '../../../providers/utils/text';
|
import { CoreTextUtilsProvider } from '@providers/utils/text';
|
||||||
import { CoreTimeUtilsProvider } from '../../../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
import { CoreUtilsProvider } from '../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreCourseOptionsDelegate, CoreCourseOptionsHandlerToDisplay } from './options-delegate';
|
import { CoreCourseOptionsDelegate, CoreCourseOptionsHandlerToDisplay } from './options-delegate';
|
||||||
import { CoreSiteHomeProvider } from '../../sitehome/providers/sitehome';
|
import { CoreSiteHomeProvider } from '../../sitehome/providers/sitehome';
|
||||||
import { CoreCourseProvider } from './course';
|
import { CoreCourseProvider } from './course';
|
||||||
|
@ -29,7 +29,7 @@ import { CoreCourseModuleDelegate } from './module-delegate';
|
||||||
import { CoreCourseModulePrefetchDelegate } from './module-prefetch-delegate';
|
import { CoreCourseModulePrefetchDelegate } from './module-prefetch-delegate';
|
||||||
import { CoreLoginHelperProvider } from '../../login/providers/helper';
|
import { CoreLoginHelperProvider } from '../../login/providers/helper';
|
||||||
import { CoreConstants } from '../../constants';
|
import { CoreConstants } from '../../constants';
|
||||||
import { CoreSite } from '../../../classes/site';
|
import { CoreSite } from '@classes/site';
|
||||||
import * as moment from 'moment';
|
import * as moment from 'moment';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -14,12 +14,12 @@
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { NavController, NavOptions } from 'ionic-angular';
|
import { NavController, NavOptions } from 'ionic-angular';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreCourseProvider } from './course';
|
import { CoreCourseProvider } from './course';
|
||||||
import { CoreSite } from '../../../classes/site';
|
import { CoreSite } from '@classes/site';
|
||||||
import { CoreDelegate, CoreDelegateHandler } from '../../../classes/delegate';
|
import { CoreDelegate, CoreDelegateHandler } from '@classes/delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface that all course module handlers must implement.
|
* Interface that all course module handlers must implement.
|
||||||
|
|
|
@ -13,20 +13,20 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreFileProvider } from '../../../providers/file';
|
import { CoreFileProvider } from '@providers/file';
|
||||||
import { CoreFilepoolProvider } from '../../../providers/filepool';
|
import { CoreFilepoolProvider } from '@providers/filepool';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreTimeUtilsProvider } from '../../../providers/utils/time';
|
import { CoreTimeUtilsProvider } from '@providers/utils/time';
|
||||||
import { CoreUtilsProvider } from '../../../providers/utils/utils';
|
import { CoreUtilsProvider } from '@providers/utils/utils';
|
||||||
import { CoreCourseProvider } from './course';
|
import { CoreCourseProvider } from './course';
|
||||||
import { CoreCache } from '../../../classes/cache';
|
import { CoreCache } from '@classes/cache';
|
||||||
import { CoreSiteWSPreSets } from '../../../classes/site';
|
import { CoreSiteWSPreSets } from '@classes/site';
|
||||||
import { CoreConstants } from '../../constants';
|
import { CoreConstants } from '../../constants';
|
||||||
import { Md5 } from 'ts-md5/dist/md5';
|
import { Md5 } from 'ts-md5/dist/md5';
|
||||||
import { Subject, BehaviorSubject, Subscription } from 'rxjs';
|
import { Subject, BehaviorSubject, Subscription } from 'rxjs';
|
||||||
import { CoreDelegate, CoreDelegateHandler } from '../../../classes/delegate';
|
import { CoreDelegate, CoreDelegateHandler } from '@classes/delegate';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Progress of downloading a list of modules.
|
* Progress of downloading a list of modules.
|
||||||
|
|
|
@ -13,11 +13,11 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CoreDelegate, CoreDelegateHandler } from '../../../classes/delegate';
|
import { CoreDelegate, CoreDelegateHandler } from '@classes/delegate';
|
||||||
import { CoreEventsProvider } from '../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreLoggerProvider } from '../../../providers/logger';
|
import { CoreLoggerProvider } from '@providers/logger';
|
||||||
import { CoreSitesProvider } from '../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreUtilsProvider, PromiseDefer } from '../../../providers/utils/utils';
|
import { CoreUtilsProvider, PromiseDefer } from '@providers/utils/utils';
|
||||||
import { CoreCoursesProvider } from '../../courses/providers/courses';
|
import { CoreCoursesProvider } from '../../courses/providers/courses';
|
||||||
import { CoreCourseProvider } from './course';
|
import { CoreCourseProvider } from './course';
|
||||||
|
|
||||||
|
|
|
@ -16,9 +16,9 @@ import { NgModule } from '@angular/core';
|
||||||
import { CommonModule } from '@angular/common';
|
import { CommonModule } from '@angular/common';
|
||||||
import { IonicModule } from 'ionic-angular';
|
import { IonicModule } from 'ionic-angular';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import { CoreComponentsModule } from '../../../components/components.module';
|
import { CoreComponentsModule } from '@components/components.module';
|
||||||
import { CoreDirectivesModule } from '../../../directives/directives.module';
|
import { CoreDirectivesModule } from '@directives';
|
||||||
import { CorePipesModule } from '../../../pipes/pipes.module';
|
import { CorePipesModule } from '@pipes';
|
||||||
import { CoreCoursesCourseProgressComponent } from '../components/course-progress/course-progress';
|
import { CoreCoursesCourseProgressComponent } from '../components/course-progress/course-progress';
|
||||||
import { CoreCoursesCourseListItemComponent } from '../components/course-list-item/course-list-item';
|
import { CoreCoursesCourseListItemComponent } from '../components/course-list-item/course-list-item';
|
||||||
import { CoreCoursesOverviewEventsComponent } from '../components/overview-events/overview-events';
|
import { CoreCoursesOverviewEventsComponent } from '../components/overview-events/overview-events';
|
||||||
|
|
|
@ -14,9 +14,9 @@
|
||||||
|
|
||||||
import { Component, Input, OnInit, OnDestroy } from '@angular/core';
|
import { Component, Input, OnInit, OnDestroy } from '@angular/core';
|
||||||
import { NavController } from 'ionic-angular';
|
import { NavController } from 'ionic-angular';
|
||||||
import { CoreEventsProvider } from '../../../../providers/events';
|
import { CoreEventsProvider } from '@providers/events';
|
||||||
import { CoreSitesProvider } from '../../../../providers/sites';
|
import { CoreSitesProvider } from '@providers/sites';
|
||||||
import { CoreDomUtilsProvider } from '../../../../providers/utils/dom';
|
import { CoreDomUtilsProvider } from '@providers/utils/dom';
|
||||||
import { CoreCourseFormatDelegate } from '../../../course/providers/format-delegate';
|
import { CoreCourseFormatDelegate } from '../../../course/providers/format-delegate';
|
||||||
import { CoreCourseProvider } from '../../../course/providers/course';
|
import { CoreCourseProvider } from '../../../course/providers/course';
|
||||||
import { CoreCourseHelperProvider } from '../../../course/providers/helper';
|
import { CoreCourseHelperProvider } from '../../../course/providers/helper';
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue