MOBILE-4470 workshop: Improve assessment strategies loading
parent
f82b14d2fd
commit
7519ef7bdf
|
@ -35,13 +35,6 @@ export class AddonModWorkshopAssessmentStrategyAccumulativeHandlerLazyService
|
||||||
extends AddonModWorkshopAssessmentStrategyAccumulativeHandlerService
|
extends AddonModWorkshopAssessmentStrategyAccumulativeHandlerService
|
||||||
implements AddonWorkshopAssessmentStrategyHandler {
|
implements AddonWorkshopAssessmentStrategyHandler {
|
||||||
|
|
||||||
/**
|
|
||||||
* @inheritdoc
|
|
||||||
*/
|
|
||||||
async isEnabled(): Promise<boolean> {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @inheritdoc
|
* @inheritdoc
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -20,11 +20,19 @@ import {
|
||||||
} from '@addons/mod/workshop/assessment/constants';
|
} from '@addons/mod/workshop/assessment/constants';
|
||||||
import type { AddonModWorkshopAssessmentStrategyAccumulativeHandlerLazyService } from './handler-lazy';
|
import type { AddonModWorkshopAssessmentStrategyAccumulativeHandlerLazyService } from './handler-lazy';
|
||||||
|
|
||||||
export class AddonModWorkshopAssessmentStrategyAccumulativeHandlerService {
|
export class AddonModWorkshopAssessmentStrategyAccumulativeHandlerService
|
||||||
|
implements Partial<AddonWorkshopAssessmentStrategyHandler> {
|
||||||
|
|
||||||
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_ACCUMULATIVE_NAME;
|
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_ACCUMULATIVE_NAME;
|
||||||
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_ACCUMULATIVE_STRATEGY_NAME;
|
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_ACCUMULATIVE_STRATEGY_NAME;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @inheritdoc
|
||||||
|
*/
|
||||||
|
async isEnabled(): Promise<boolean> {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -44,7 +52,6 @@ export function getAssessmentStrategyHandlerInstance(): AddonWorkshopAssessmentS
|
||||||
|
|
||||||
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyAccumulativeHandlerService());
|
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyAccumulativeHandlerService());
|
||||||
lazyHandler.setLazyInstanceMethods([
|
lazyHandler.setLazyInstanceMethods([
|
||||||
'isEnabled',
|
|
||||||
'getComponent',
|
'getComponent',
|
||||||
'getOriginalValues',
|
'getOriginalValues',
|
||||||
'hasDataChanged',
|
'hasDataChanged',
|
||||||
|
|
|
@ -34,13 +34,6 @@ export class AddonModWorkshopAssessmentStrategyCommentsHandlerLazyService
|
||||||
extends AddonModWorkshopAssessmentStrategyCommentsHandlerService
|
extends AddonModWorkshopAssessmentStrategyCommentsHandlerService
|
||||||
implements AddonWorkshopAssessmentStrategyHandler {
|
implements AddonWorkshopAssessmentStrategyHandler {
|
||||||
|
|
||||||
/**
|
|
||||||
* @inheritdoc
|
|
||||||
*/
|
|
||||||
async isEnabled(): Promise<boolean> {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @inheritdoc
|
* @inheritdoc
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -20,11 +20,19 @@ import {
|
||||||
} from '@addons/mod/workshop/assessment/constants';
|
} from '@addons/mod/workshop/assessment/constants';
|
||||||
import type { AddonModWorkshopAssessmentStrategyCommentsHandlerLazyService } from './handler-lazy';
|
import type { AddonModWorkshopAssessmentStrategyCommentsHandlerLazyService } from './handler-lazy';
|
||||||
|
|
||||||
export class AddonModWorkshopAssessmentStrategyCommentsHandlerService {
|
export class AddonModWorkshopAssessmentStrategyCommentsHandlerService
|
||||||
|
implements Partial<AddonWorkshopAssessmentStrategyHandler> {
|
||||||
|
|
||||||
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_COMMENTS_NAME;
|
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_COMMENTS_NAME;
|
||||||
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_COMMENTS_STRATEGY_NAME;
|
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_COMMENTS_STRATEGY_NAME;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @inheritdoc
|
||||||
|
*/
|
||||||
|
async isEnabled(): Promise<boolean> {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -44,7 +52,6 @@ export function getAssessmentStrategyHandlerInstance(): AddonWorkshopAssessmentS
|
||||||
|
|
||||||
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyCommentsHandlerService());
|
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyCommentsHandlerService());
|
||||||
lazyHandler.setLazyInstanceMethods([
|
lazyHandler.setLazyInstanceMethods([
|
||||||
'isEnabled',
|
|
||||||
'getComponent',
|
'getComponent',
|
||||||
'getOriginalValues',
|
'getOriginalValues',
|
||||||
'hasDataChanged',
|
'hasDataChanged',
|
||||||
|
|
|
@ -34,13 +34,6 @@ export class AddonModWorkshopAssessmentStrategyNumErrorsHandlerLazyService
|
||||||
extends AddonModWorkshopAssessmentStrategyNumErrorsHandlerService
|
extends AddonModWorkshopAssessmentStrategyNumErrorsHandlerService
|
||||||
implements AddonWorkshopAssessmentStrategyHandler {
|
implements AddonWorkshopAssessmentStrategyHandler {
|
||||||
|
|
||||||
/**
|
|
||||||
* @inheritdoc
|
|
||||||
*/
|
|
||||||
async isEnabled(): Promise<boolean> {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @inheritdoc
|
* @inheritdoc
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -20,11 +20,19 @@ import {
|
||||||
} from '@addons/mod/workshop/assessment/constants';
|
} from '@addons/mod/workshop/assessment/constants';
|
||||||
import type { AddonModWorkshopAssessmentStrategyNumErrorsHandlerLazyService } from './handler-lazy';
|
import type { AddonModWorkshopAssessmentStrategyNumErrorsHandlerLazyService } from './handler-lazy';
|
||||||
|
|
||||||
export class AddonModWorkshopAssessmentStrategyNumErrorsHandlerService {
|
export class AddonModWorkshopAssessmentStrategyNumErrorsHandlerService
|
||||||
|
implements Partial<AddonWorkshopAssessmentStrategyHandler> {
|
||||||
|
|
||||||
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_NUMERRORS_NAME;
|
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_NUMERRORS_NAME;
|
||||||
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_NUMERRORS_STRATEGY_NAME;
|
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_NUMERRORS_STRATEGY_NAME;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @inheritdoc
|
||||||
|
*/
|
||||||
|
async isEnabled(): Promise<boolean> {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -44,7 +52,6 @@ export function getAssessmentStrategyHandlerInstance(): AddonWorkshopAssessmentS
|
||||||
|
|
||||||
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyNumErrorsHandlerService());
|
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyNumErrorsHandlerService());
|
||||||
lazyHandler.setLazyInstanceMethods([
|
lazyHandler.setLazyInstanceMethods([
|
||||||
'isEnabled',
|
|
||||||
'getComponent',
|
'getComponent',
|
||||||
'getOriginalValues',
|
'getOriginalValues',
|
||||||
'hasDataChanged',
|
'hasDataChanged',
|
||||||
|
|
|
@ -34,13 +34,6 @@ export class AddonModWorkshopAssessmentStrategyRubricHandlerLazyService
|
||||||
extends AddonModWorkshopAssessmentStrategyRubricHandlerService
|
extends AddonModWorkshopAssessmentStrategyRubricHandlerService
|
||||||
implements AddonWorkshopAssessmentStrategyHandler {
|
implements AddonWorkshopAssessmentStrategyHandler {
|
||||||
|
|
||||||
/**
|
|
||||||
* @inheritdoc
|
|
||||||
*/
|
|
||||||
async isEnabled(): Promise<boolean> {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @inheritdoc
|
* @inheritdoc
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -20,11 +20,19 @@ import {
|
||||||
} from '@addons/mod/workshop/assessment/constants';
|
} from '@addons/mod/workshop/assessment/constants';
|
||||||
import type { AddonModWorkshopAssessmentStrategyRubricHandlerLazyService } from './handler-lazy';
|
import type { AddonModWorkshopAssessmentStrategyRubricHandlerLazyService } from './handler-lazy';
|
||||||
|
|
||||||
export class AddonModWorkshopAssessmentStrategyRubricHandlerService {
|
export class AddonModWorkshopAssessmentStrategyRubricHandlerService
|
||||||
|
implements Partial<AddonWorkshopAssessmentStrategyHandler> {
|
||||||
|
|
||||||
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_RUBRIC_NAME;
|
name = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_RUBRIC_NAME;
|
||||||
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_RUBRIC_STRATEGY_NAME;
|
strategyName = ADDON_MOD_WORKSHOP_ASSESSMENT_STRATEGY_RUBRIC_STRATEGY_NAME;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @inheritdoc
|
||||||
|
*/
|
||||||
|
async isEnabled(): Promise<boolean> {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -44,7 +52,6 @@ export function getAssessmentStrategyHandlerInstance(): AddonWorkshopAssessmentS
|
||||||
|
|
||||||
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyRubricHandlerService());
|
lazyHandler.setEagerInstance(new AddonModWorkshopAssessmentStrategyRubricHandlerService());
|
||||||
lazyHandler.setLazyInstanceMethods([
|
lazyHandler.setLazyInstanceMethods([
|
||||||
'isEnabled',
|
|
||||||
'getComponent',
|
'getComponent',
|
||||||
'getOriginalValues',
|
'getOriginalValues',
|
||||||
'hasDataChanged',
|
'hasDataChanged',
|
||||||
|
|
Loading…
Reference in New Issue