mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 18:14:17 +00:00
Merge pull request #606 from 4Science/#603_mydspace_fixes
#603 mydspace fixes
This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
<ds-search-labels [inPlaceSearch]="inPlaceSearch"></ds-search-labels>
|
||||
<div class="row">
|
||||
<div id="search-body"
|
||||
class="row-offcanvas row-offcanvas-left"
|
||||
class="row-offcanvas row-offcanvas-left w-100"
|
||||
[@pushInOut]="(isSidebarCollapsed() | async) ? 'collapsed' : 'expanded'">
|
||||
<ds-search-sidebar *ngIf="(isXsOrSm$ | async)" class="col-12"
|
||||
id="search-sidebar-sm"
|
||||
|
@@ -3,7 +3,7 @@ import { Injectable } from '@angular/core';
|
||||
import { Store } from '@ngrx/store';
|
||||
import { Observable } from 'rxjs/internal/Observable';
|
||||
import { map, switchMap } from 'rxjs/operators';
|
||||
import { hasValue } from '../../shared/empty.util';
|
||||
import { hasValue, isNotEmpty } from '../../shared/empty.util';
|
||||
import { NotificationsService } from '../../shared/notifications/notifications.service';
|
||||
import { FollowLinkConfig } from '../../shared/utils/follow-link-config.model';
|
||||
import { dataService } from '../cache/builders/build-decorators';
|
||||
@@ -72,7 +72,7 @@ export class BitstreamDataService extends DataService<Bitstream> {
|
||||
public getThumbnailFor(item: Item): Observable<RemoteData<Bitstream>> {
|
||||
return this.bundleService.findByItemAndName(item, 'THUMBNAIL').pipe(
|
||||
switchMap((bundleRD: RemoteData<Bundle>) => {
|
||||
if (hasValue(bundleRD.payload)) {
|
||||
if (isNotEmpty(bundleRD.payload)) {
|
||||
return this.findAllByBundle(bundleRD.payload, { elementsPerPage: 1 }).pipe(
|
||||
map((bitstreamRD: RemoteData<PaginatedList<Bitstream>>) => {
|
||||
if (hasValue(bitstreamRD.payload) && hasValue(bitstreamRD.payload.page)) {
|
||||
@@ -108,7 +108,7 @@ export class BitstreamDataService extends DataService<Bitstream> {
|
||||
public getMatchingThumbnail(item: Item, bitstreamInOriginal: Bitstream): Observable<RemoteData<Bitstream>> {
|
||||
return this.bundleService.findByItemAndName(item, 'THUMBNAIL').pipe(
|
||||
switchMap((bundleRD: RemoteData<Bundle>) => {
|
||||
if (hasValue(bundleRD.payload)) {
|
||||
if (isNotEmpty(bundleRD.payload)) {
|
||||
return this.findAllByBundle(bundleRD.payload, { elementsPerPage: Number.MAX_SAFE_INTEGER }).pipe(
|
||||
map((bitstreamRD: RemoteData<PaginatedList<Bitstream>>) => {
|
||||
if (hasValue(bitstreamRD.payload) && hasValue(bitstreamRD.payload.page)) {
|
||||
|
@@ -18,6 +18,8 @@ import { RemoteData } from '../data/remote-data';
|
||||
import { PaginatedList } from '../data/paginated-list';
|
||||
import { NotificationsService } from '../../shared/notifications/notifications.service';
|
||||
import { DSOChangeAnalyzer } from '../data/dso-change-analyzer.service';
|
||||
import { dataService } from '../cache/builders/build-decorators';
|
||||
import { GROUP } from './models/group.resource-type';
|
||||
|
||||
/**
|
||||
* Provides methods to retrieve eperson group resources.
|
||||
@@ -25,6 +27,7 @@ import { DSOChangeAnalyzer } from '../data/dso-change-analyzer.service';
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
@dataService(GROUP)
|
||||
export class GroupDataService extends DataService<Group> {
|
||||
protected linkPath = 'groups';
|
||||
protected browseEndpoint = '';
|
||||
|
@@ -2,7 +2,7 @@ import { combineLatest as observableCombineLatest, Observable, of as observableO
|
||||
import { Injectable, OnDestroy } from '@angular/core';
|
||||
import { NavigationExtras, Router } from '@angular/router';
|
||||
import { first, map, switchMap, tap } from 'rxjs/operators';
|
||||
import { followLink } from '../../../shared/utils/follow-link-config.model';
|
||||
import { followLink, FollowLinkConfig } from '../../../shared/utils/follow-link-config.model';
|
||||
import { LinkService } from '../../cache/builders/link.service';
|
||||
import { FacetConfigSuccessResponse, FacetValueSuccessResponse, SearchSuccessResponse } from '../../cache/response.models';
|
||||
import { PaginatedList } from '../../data/paginated-list';
|
||||
@@ -107,10 +107,11 @@ export class SearchService implements OnDestroy {
|
||||
* Method to retrieve a paginated list of search results from the server
|
||||
* @param {PaginatedSearchOptions} searchOptions The configuration necessary to perform this search
|
||||
* @param responseMsToLive The amount of milliseconds for the response to live in cache
|
||||
* @param linksToFollow List of {@link FollowLinkConfig} that indicate which {@link HALLink}s should be automatically resolved
|
||||
* @returns {Observable<RemoteData<PaginatedList<SearchResult<DSpaceObject>>>>} Emits a paginated list with all search results found
|
||||
*/
|
||||
search(searchOptions?: PaginatedSearchOptions, responseMsToLive?: number): Observable<RemoteData<PaginatedList<SearchResult<DSpaceObject>>>> {
|
||||
return this.getPaginatedResults(this.searchEntries(searchOptions));
|
||||
search<T extends DSpaceObject>(searchOptions?: PaginatedSearchOptions, responseMsToLive?: number, ...linksToFollow: Array<FollowLinkConfig<T>>): Observable<RemoteData<PaginatedList<SearchResult<DSpaceObject>>>> {
|
||||
return this.getPaginatedResults<T>(this.searchEntries(searchOptions), ...linksToFollow);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -151,9 +152,10 @@ export class SearchService implements OnDestroy {
|
||||
/**
|
||||
* Method to convert the parsed responses into a paginated list of search results
|
||||
* @param searchEntries: The request entries from the search method
|
||||
* @param linksToFollow List of {@link FollowLinkConfig} that indicate which {@link HALLink}s should be automatically resolved
|
||||
* @returns {Observable<RemoteData<PaginatedList<SearchResult<DSpaceObject>>>>} Emits a paginated list with all search results found
|
||||
*/
|
||||
getPaginatedResults(searchEntries: Observable<{ searchOptions: PaginatedSearchOptions, requestEntry: RequestEntry }>): Observable<RemoteData<PaginatedList<SearchResult<DSpaceObject>>>> {
|
||||
getPaginatedResults<T extends DSpaceObject>(searchEntries: Observable<{ searchOptions: PaginatedSearchOptions, requestEntry: RequestEntry }>, ...linksToFollow: Array<FollowLinkConfig<T>>): Observable<RemoteData<PaginatedList<SearchResult<DSpaceObject>>>> {
|
||||
const requestEntryObs: Observable<RequestEntry> = searchEntries.pipe(
|
||||
map((entry) => entry.requestEntry),
|
||||
);
|
||||
@@ -174,7 +176,7 @@ export class SearchService implements OnDestroy {
|
||||
}),
|
||||
// Send a request for each item to ensure fresh cache
|
||||
tap((reqs: RestRequest[]) => reqs.forEach((req: RestRequest) => this.requestService.configure(req))),
|
||||
map((reqs: RestRequest[]) => reqs.map((req: RestRequest) => this.rdb.buildSingle(req.href))),
|
||||
map((reqs: RestRequest[]) => reqs.map((req: RestRequest) => this.rdb.buildSingle(req.href, ...linksToFollow))),
|
||||
switchMap((input: Array<Observable<RemoteData<DSpaceObject>>>) => this.rdb.aggregate(input)),
|
||||
);
|
||||
|
||||
|
@@ -1,6 +1,5 @@
|
||||
import { inheritSerialization } from 'cerialize';
|
||||
import { typedObject } from '../../cache/builders/build-decorators';
|
||||
import { DSpaceObject } from '../../shared/dspace-object.model';
|
||||
import { inheritLinkAnnotations, typedObject } from '../../cache/builders/build-decorators';
|
||||
import { CLAIMED_TASK } from './claimed-task-object.resource-type';
|
||||
import { TaskObject } from './task-object.model';
|
||||
|
||||
@@ -8,7 +7,8 @@ import { TaskObject } from './task-object.model';
|
||||
* A model class for a ClaimedTask.
|
||||
*/
|
||||
@typedObject
|
||||
@inheritSerialization(DSpaceObject)
|
||||
@inheritSerialization(TaskObject)
|
||||
@inheritLinkAnnotations(TaskObject)
|
||||
export class ClaimedTask extends TaskObject {
|
||||
static type = CLAIMED_TASK;
|
||||
}
|
||||
|
@@ -1,5 +1,5 @@
|
||||
import { inheritSerialization } from 'cerialize';
|
||||
import { typedObject } from '../../cache/builders/build-decorators';
|
||||
import { inheritLinkAnnotations, typedObject } from '../../cache/builders/build-decorators';
|
||||
import { POOL_TASK } from './pool-task-object.resource-type';
|
||||
import { TaskObject } from './task-object.model';
|
||||
|
||||
@@ -8,6 +8,7 @@ import { TaskObject } from './task-object.model';
|
||||
*/
|
||||
@typedObject
|
||||
@inheritSerialization(TaskObject)
|
||||
@inheritLinkAnnotations(TaskObject)
|
||||
export class PoolTask extends TaskObject {
|
||||
static type = POOL_TASK;
|
||||
}
|
||||
|
@@ -12,6 +12,7 @@ import { DSpaceObject } from '../../shared/dspace-object.model';
|
||||
import { HALLink } from '../../shared/hal-link.model';
|
||||
import { WorkflowItem } from '../../submission/models/workflowitem.model';
|
||||
import { TASK_OBJECT } from './task-object.resource-type';
|
||||
import { WORKFLOWITEM } from '../../eperson/models/workflowitem.resource-type';
|
||||
|
||||
/**
|
||||
* An abstract model class for a TaskObject.
|
||||
@@ -45,7 +46,7 @@ export class TaskObject extends DSpaceObject implements CacheableObject {
|
||||
@deserialize
|
||||
_links: {
|
||||
self: HALLink;
|
||||
eperson: HALLink;
|
||||
owner: HALLink;
|
||||
group: HALLink;
|
||||
workflowitem: HALLink;
|
||||
};
|
||||
@@ -54,7 +55,7 @@ export class TaskObject extends DSpaceObject implements CacheableObject {
|
||||
* The EPerson for this task
|
||||
* Will be undefined unless the eperson {@link HALLink} has been resolved.
|
||||
*/
|
||||
@link(EPERSON)
|
||||
@link(EPERSON, false, 'owner')
|
||||
eperson?: Observable<RemoteData<EPerson>>;
|
||||
|
||||
/**
|
||||
@@ -68,7 +69,7 @@ export class TaskObject extends DSpaceObject implements CacheableObject {
|
||||
* The WorkflowItem for this task
|
||||
* Will be undefined unless the workflowitem {@link HALLink} has been resolved.
|
||||
*/
|
||||
@link(WorkflowItem.type)
|
||||
@link(WORKFLOWITEM)
|
||||
workflowitem?: Observable<RemoteData<WorkflowItem>> | WorkflowItem;
|
||||
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@
|
||||
<a [class.disabled]="!(object.workflowitem | async)?.hasSucceeded"
|
||||
class="btn btn-primary mt-1 mb-3"
|
||||
ngbTooltip="{{'submission.workflow.tasks.claimed.edit_help' | translate}}"
|
||||
[routerLink]="['/workflowitems/' + (object.workflowitem | async)?.payload.id + '/edit']"
|
||||
[routerLink]="['/workflowitems/' + (object?.workflowitem | async)?.payload?.id + '/edit']"
|
||||
role="button">
|
||||
<i class="fa fa-edit"></i> {{'submission.workflow.tasks.claimed.edit' | translate}}
|
||||
</a>
|
||||
|
@@ -1,3 +1,4 @@
|
||||
<ng-container *ngVar="(workflowitemRD$ | async)?.payload as workflowitem">
|
||||
<ds-item-detail-preview *ngIf="workflowitem"
|
||||
[item]="(workflowitem.item | async)?.payload"
|
||||
[object]="object"
|
||||
@@ -6,3 +7,4 @@
|
||||
</ds-item-detail-preview>
|
||||
|
||||
<ds-claimed-task-actions *ngIf="workflowitem" [object]="dso"></ds-claimed-task-actions>
|
||||
</ng-container>
|
||||
|
@@ -11,6 +11,9 @@ import { MyDspaceItemStatusType } from '../../../object-collection/shared/mydspa
|
||||
import { WorkflowItem } from '../../../../core/submission/models/workflowitem.model';
|
||||
import { createSuccessfulRemoteDataObject } from '../../../testing/utils';
|
||||
import { ClaimedTaskSearchResult } from '../../../object-collection/shared/claimed-task-search-result.model';
|
||||
import { VarDirective } from '../../../utils/var.directive';
|
||||
import { getMockLinkService } from '../../../mocks/mock-link-service';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
|
||||
let component: ClaimedTaskSearchResultDetailElementComponent;
|
||||
let fixture: ComponentFixture<ClaimedTaskSearchResultDetailElementComponent>;
|
||||
@@ -53,12 +56,16 @@ const rdItem = createSuccessfulRemoteDataObject(item);
|
||||
const workflowitem = Object.assign(new WorkflowItem(), { item: observableOf(rdItem) });
|
||||
const rdWorkflowitem = createSuccessfulRemoteDataObject(workflowitem);
|
||||
mockResultObject.indexableObject = Object.assign(new ClaimedTask(), { workflowitem: observableOf(rdWorkflowitem) });
|
||||
const linkService = getMockLinkService();
|
||||
|
||||
describe('ClaimedTaskSearchResultDetailElementComponent', () => {
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [NoopAnimationsModule],
|
||||
declarations: [ClaimedTaskSearchResultDetailElementComponent],
|
||||
declarations: [ClaimedTaskSearchResultDetailElementComponent, VarDirective],
|
||||
providers: [
|
||||
{ provide: LinkService, useValue: linkService }
|
||||
],
|
||||
schemas: [NO_ERRORS_SCHEMA]
|
||||
}).overrideComponent(ClaimedTaskSearchResultDetailElementComponent, {
|
||||
set: { changeDetection: ChangeDetectionStrategy.Default }
|
||||
@@ -75,8 +82,12 @@ describe('ClaimedTaskSearchResultDetailElementComponent', () => {
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should init item properly', () => {
|
||||
expect(component.workflowitem).toEqual(workflowitem);
|
||||
it('should init workflowitem properly', (done) => {
|
||||
component.workflowitemRD$.subscribe((workflowitemRD) => {
|
||||
expect(linkService.resolveLink).toHaveBeenCalled();
|
||||
expect(workflowitemRD.payload).toEqual(workflowitem);
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
it('should have properly status', () => {
|
||||
|
@@ -1,17 +1,17 @@
|
||||
import { Component } from '@angular/core';
|
||||
|
||||
import { Observable } from 'rxjs';
|
||||
import { find } from 'rxjs/operators';
|
||||
|
||||
import { RemoteData } from '../../../../core/data/remote-data';
|
||||
import { ViewMode } from '../../../../core/shared/view-mode.model';
|
||||
import { isNotUndefined } from '../../../empty.util';
|
||||
import { WorkflowItem } from '../../../../core/submission/models/workflowitem.model';
|
||||
import { ClaimedTask } from '../../../../core/tasks/models/claimed-task-object.model';
|
||||
import { SearchResultDetailElementComponent } from '../search-result-detail-element.component';
|
||||
import { MyDspaceItemStatusType } from '../../../object-collection/shared/mydspace-item-status/my-dspace-item-status-type';
|
||||
import { listableObjectComponent } from '../../../object-collection/shared/listable-object/listable-object.decorator';
|
||||
import { ClaimedTaskSearchResult } from '../../../object-collection/shared/claimed-task-search-result.model';
|
||||
import { followLink } from '../../../utils/follow-link-config.model';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
|
||||
/**
|
||||
* This component renders claimed task object for the search result in the detail view.
|
||||
@@ -38,25 +38,24 @@ export class ClaimedTaskSearchResultDetailElementComponent extends SearchResultD
|
||||
/**
|
||||
* The workflowitem object that belonging to the result object
|
||||
*/
|
||||
public workflowitem: WorkflowItem;
|
||||
public workflowitemRD$: Observable<RemoteData<WorkflowItem>>;
|
||||
|
||||
constructor(protected linkService: LinkService) {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize all instance variables
|
||||
*/
|
||||
ngOnInit() {
|
||||
super.ngOnInit();
|
||||
this.initWorkflowItem(this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve workflow item from result object
|
||||
*/
|
||||
initWorkflowItem(wfi$: Observable<RemoteData<WorkflowItem>>) {
|
||||
wfi$.pipe(
|
||||
find((rd: RemoteData<WorkflowItem>) => (rd.hasSucceeded && isNotUndefined(rd.payload)))
|
||||
).subscribe((rd: RemoteData<WorkflowItem>) => {
|
||||
this.workflowitem = rd.payload;
|
||||
});
|
||||
this.linkService.resolveLink(this.dso, followLink(
|
||||
'workflowitem',
|
||||
null,
|
||||
followLink('item', null, followLink('bundles')),
|
||||
followLink('submitter')
|
||||
));
|
||||
this.workflowitemRD$ = this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -10,9 +10,9 @@
|
||||
<div class="row mb-1">
|
||||
<div class="col-xs-12 col-md-4">
|
||||
<ds-metadata-field-wrapper>
|
||||
<ds-thumbnail [thumbnail]="thumbnail$ | async"></ds-thumbnail>
|
||||
<ds-thumbnail [thumbnail]="getThumbnail() | async"></ds-thumbnail>
|
||||
</ds-metadata-field-wrapper>
|
||||
<ng-container *ngVar="(bitstreams$ | async) as bitstreams">
|
||||
<ng-container *ngVar="(getFiles() | async) as bitstreams">
|
||||
<ds-metadata-field-wrapper [label]="('item.page.files' | translate)">
|
||||
<div *ngIf="bitstreams?.length > 0" class="file-section">
|
||||
<button class="btn btn-link" *ngFor="let file of bitstreams; let last=last;" (click)="downloadBitstreamFile(file?.uuid)">
|
||||
|
@@ -5,8 +5,8 @@ import { NoopAnimationsModule } from '@angular/platform-browser/animations';
|
||||
import { Store } from '@ngrx/store';
|
||||
import { TranslateLoader, TranslateModule } from '@ngx-translate/core';
|
||||
|
||||
import { of as observableOf } from 'rxjs';
|
||||
import { Observable } from 'rxjs/internal/Observable';
|
||||
import { Observable, of as observableOf } from 'rxjs';
|
||||
|
||||
import { RemoteDataBuildService } from '../../../../core/cache/builders/remote-data-build.service';
|
||||
import { ObjectCacheService } from '../../../../core/cache/object-cache.service';
|
||||
import { BitstreamDataService } from '../../../../core/data/bitstream-data.service';
|
||||
@@ -28,7 +28,6 @@ import { HALEndpointServiceStub } from '../../../testing/hal-endpoint-service-st
|
||||
import { createSuccessfulRemoteDataObject$ } from '../../../testing/utils';
|
||||
import { FileSizePipe } from '../../../utils/file-size-pipe';
|
||||
import { FollowLinkConfig } from '../../../utils/follow-link-config.model';
|
||||
|
||||
import { TruncatePipe } from '../../../utils/truncate.pipe';
|
||||
import { VarDirective } from '../../../utils/var.directive';
|
||||
import { ItemDetailPreviewFieldComponent } from './item-detail-preview-field/item-detail-preview-field.component';
|
||||
@@ -127,8 +126,17 @@ describe('ItemDetailPreviewComponent', () => {
|
||||
|
||||
}));
|
||||
|
||||
it('should init thumbnail and bitstreams on init', () => {
|
||||
expect(component.thumbnail$).toBeDefined();
|
||||
expect(component.bitstreams$).toBeDefined();
|
||||
it('should get item thumbnail', (done) => {
|
||||
component.getThumbnail().subscribe((thumbnail) => {
|
||||
expect(thumbnail).toBeDefined();
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
it('should get item bitstreams', (done) => {
|
||||
component.getFiles().subscribe((bitstreams) => {
|
||||
expect(bitstreams).toBeDefined();
|
||||
done();
|
||||
})
|
||||
});
|
||||
});
|
||||
|
@@ -1,17 +1,13 @@
|
||||
import { Component, Input } from '@angular/core';
|
||||
|
||||
import { Observable } from 'rxjs';
|
||||
import { first, map } from 'rxjs/operators';
|
||||
import { first } from 'rxjs/operators';
|
||||
import { BitstreamDataService } from '../../../../core/data/bitstream-data.service';
|
||||
import { RemoteData } from '../../../../core/data/remote-data';
|
||||
|
||||
import { Item } from '../../../../core/shared/item.model';
|
||||
import {
|
||||
getAllSucceededRemoteListPayload,
|
||||
getFirstSucceededRemoteDataPayload,
|
||||
getFirstSucceededRemoteListPayload,
|
||||
getRemoteDataPayload,
|
||||
getSucceededRemoteData
|
||||
getFirstSucceededRemoteListPayload
|
||||
} from '../../../../core/shared/operators';
|
||||
import { MyDspaceItemStatusType } from '../../../object-collection/shared/mydspace-item-status/my-dspace-item-status-type';
|
||||
import { fadeInOut } from '../../../animations/fade';
|
||||
@@ -71,20 +67,13 @@ export class ItemDetailPreviewComponent {
|
||||
*
|
||||
* @param {FileService} fileService
|
||||
* @param {HALEndpointService} halService
|
||||
* @param {BitstreamDataService} bitstreamDataService
|
||||
*/
|
||||
constructor(private fileService: FileService,
|
||||
private halService: HALEndpointService,
|
||||
private bitstreamDataService: BitstreamDataService) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize all instance variables
|
||||
*/
|
||||
ngOnInit() {
|
||||
this.thumbnail$ = this.getThumbnail();
|
||||
this.bitstreams$ = this.getFiles();
|
||||
}
|
||||
|
||||
/**
|
||||
* Perform bitstream download
|
||||
*/
|
||||
@@ -98,14 +87,14 @@ export class ItemDetailPreviewComponent {
|
||||
}
|
||||
|
||||
// TODO refactor this method to return RemoteData, and the template to deal with loading and errors
|
||||
getThumbnail(): Observable<Bitstream> {
|
||||
public getThumbnail(): Observable<Bitstream> {
|
||||
return this.bitstreamDataService.getThumbnailFor(this.item).pipe(
|
||||
getFirstSucceededRemoteDataPayload()
|
||||
);
|
||||
}
|
||||
|
||||
// TODO refactor this method to return RemoteData, and the template to deal with loading and errors
|
||||
getFiles(): Observable<Bitstream[]> {
|
||||
public getFiles(): Observable<Bitstream[]> {
|
||||
return this.bitstreamDataService
|
||||
.findAllByItemAndBundleName(this.item, 'ORIGINAL', { elementsPerPage: Number.MAX_SAFE_INTEGER })
|
||||
.pipe(
|
||||
|
@@ -1,7 +1,9 @@
|
||||
<ng-container *ngVar="(workflowitemRD$ | async)?.payload as workflowitem">
|
||||
<ds-item-detail-preview *ngIf="workflowitem"
|
||||
[item]="(workflowitem.item | async)?.payload"
|
||||
[item]="(workflowitem?.item | async)?.payload"
|
||||
[object]="object"
|
||||
[showSubmitter]="showSubmitter"
|
||||
[status]="status"></ds-item-detail-preview>
|
||||
|
||||
<ds-pool-task-actions *ngIf="workflowitem" [object]="dso"></ds-pool-task-actions>
|
||||
</ng-container>
|
||||
|
@@ -11,6 +11,9 @@ import { WorkflowItem } from '../../../../core/submission/models/workflowitem.mo
|
||||
import { createSuccessfulRemoteDataObject } from '../../../testing/utils';
|
||||
import { PoolSearchResultDetailElementComponent } from './pool-search-result-detail-element.component';
|
||||
import { PoolTaskSearchResult } from '../../../object-collection/shared/pool-task-search-result.model';
|
||||
import { VarDirective } from '../../../utils/var.directive';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
import { getMockLinkService } from '../../../mocks/mock-link-service';
|
||||
|
||||
let component: PoolSearchResultDetailElementComponent;
|
||||
let fixture: ComponentFixture<PoolSearchResultDetailElementComponent>;
|
||||
@@ -53,15 +56,17 @@ const rdItem = createSuccessfulRemoteDataObject(item);
|
||||
const workflowitem = Object.assign(new WorkflowItem(), { item: observableOf(rdItem) });
|
||||
const rdWorkflowitem = createSuccessfulRemoteDataObject(workflowitem);
|
||||
mockResultObject.indexableObject = Object.assign(new PoolTask(), { workflowitem: observableOf(rdWorkflowitem) });
|
||||
const linkService = getMockLinkService();
|
||||
|
||||
describe('PoolSearchResultDetailElementComponent', () => {
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [NoopAnimationsModule],
|
||||
declarations: [PoolSearchResultDetailElementComponent],
|
||||
declarations: [PoolSearchResultDetailElementComponent, VarDirective],
|
||||
providers: [
|
||||
{ provide: 'objectElementProvider', useValue: (mockResultObject) },
|
||||
{ provide: 'indexElementProvider', useValue: (compIndex) }
|
||||
{ provide: 'indexElementProvider', useValue: (compIndex) },
|
||||
{ provide: LinkService, useValue: linkService }
|
||||
],
|
||||
schemas: [NO_ERRORS_SCHEMA]
|
||||
}).overrideComponent(PoolSearchResultDetailElementComponent, {
|
||||
@@ -79,8 +84,12 @@ describe('PoolSearchResultDetailElementComponent', () => {
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should init item properly', () => {
|
||||
expect(component.workflowitem).toEqual(workflowitem);
|
||||
it('should init workflowitem properly', (done) => {
|
||||
component.workflowitemRD$.subscribe((workflowitemRD) => {
|
||||
expect(linkService.resolveLink).toHaveBeenCalled();
|
||||
expect(workflowitemRD.payload).toEqual(workflowitem);
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
it('should have properly status', () => {
|
||||
|
@@ -1,9 +1,7 @@
|
||||
import { Component } from '@angular/core';
|
||||
|
||||
import { Observable } from 'rxjs';
|
||||
import { find } from 'rxjs/operators';
|
||||
import { RemoteData } from '../../../../core/data/remote-data';
|
||||
import { isNotUndefined } from '../../../empty.util';
|
||||
import { PoolTask } from '../../../../core/tasks/models/pool-task-object.model';
|
||||
import { SearchResultDetailElementComponent } from '../search-result-detail-element.component';
|
||||
import { MyDspaceItemStatusType } from '../../../object-collection/shared/mydspace-item-status/my-dspace-item-status-type';
|
||||
@@ -11,6 +9,8 @@ import { WorkflowItem } from '../../../../core/submission/models/workflowitem.mo
|
||||
import { ViewMode } from '../../../../core/shared/view-mode.model';
|
||||
import { listableObjectComponent } from '../../../object-collection/shared/listable-object/listable-object.decorator';
|
||||
import { PoolTaskSearchResult } from '../../../object-collection/shared/pool-task-search-result.model';
|
||||
import { followLink } from '../../../utils/follow-link-config.model';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
|
||||
/**
|
||||
* This component renders pool task object for the search result in the detail view.
|
||||
@@ -37,25 +37,24 @@ export class PoolSearchResultDetailElementComponent extends SearchResultDetailEl
|
||||
/**
|
||||
* The workflowitem object that belonging to the result object
|
||||
*/
|
||||
public workflowitem: WorkflowItem;
|
||||
public workflowitemRD$: Observable<RemoteData<WorkflowItem>>;
|
||||
|
||||
constructor(protected linkService: LinkService) {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize all instance variables
|
||||
*/
|
||||
ngOnInit() {
|
||||
super.ngOnInit();
|
||||
this.initWorkflowItem(this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve workflowitem from result object
|
||||
*/
|
||||
initWorkflowItem(wfi$: Observable<RemoteData<WorkflowItem>>) {
|
||||
wfi$.pipe(
|
||||
find((rd: RemoteData<WorkflowItem>) => (rd.hasSucceeded && isNotUndefined(rd.payload)))
|
||||
).subscribe((rd: RemoteData<WorkflowItem>) => {
|
||||
this.workflowitem = rd.payload;
|
||||
});
|
||||
this.linkService.resolveLink(this.dso, followLink(
|
||||
'workflowitem',
|
||||
null,
|
||||
followLink('item', null, followLink('bundles')),
|
||||
followLink('submitter')
|
||||
));
|
||||
this.workflowitemRD$ = this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -1,7 +1,10 @@
|
||||
<ng-container *ngVar="(workflowitemRD$ | async)?.payload as workflowitem">
|
||||
<ds-item-list-preview *ngIf="workflowitem"
|
||||
[item]="(workflowitem.item | async)?.payload"
|
||||
[item]="(workflowitem?.item | async)?.payload"
|
||||
[object]="object"
|
||||
[showSubmitter]="showSubmitter"
|
||||
[status]="status"></ds-item-list-preview>
|
||||
|
||||
<ds-claimed-task-actions *ngIf="workflowitem" [object]="dso"></ds-claimed-task-actions>
|
||||
</ng-container>
|
||||
|
||||
|
@@ -12,6 +12,9 @@ import { WorkflowItem } from '../../../../core/submission/models/workflowitem.mo
|
||||
import { createSuccessfulRemoteDataObject } from '../../../testing/utils';
|
||||
import { ClaimedTaskSearchResult } from '../../../object-collection/shared/claimed-task-search-result.model';
|
||||
import { TruncatableService } from '../../../truncatable/truncatable.service';
|
||||
import { VarDirective } from '../../../utils/var.directive';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
import { getMockLinkService } from '../../../mocks/mock-link-service';
|
||||
|
||||
let component: ClaimedSearchResultListElementComponent;
|
||||
let fixture: ComponentFixture<ClaimedSearchResultListElementComponent>;
|
||||
@@ -54,14 +57,16 @@ const rdItem = createSuccessfulRemoteDataObject(item);
|
||||
const workflowitem = Object.assign(new WorkflowItem(), { item: observableOf(rdItem) });
|
||||
const rdWorkflowitem = createSuccessfulRemoteDataObject(workflowitem);
|
||||
mockResultObject.indexableObject = Object.assign(new ClaimedTask(), { workflowitem: observableOf(rdWorkflowitem) });
|
||||
const linkService = getMockLinkService();
|
||||
|
||||
describe('ClaimedSearchResultListElementComponent', () => {
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [NoopAnimationsModule],
|
||||
declarations: [ClaimedSearchResultListElementComponent],
|
||||
declarations: [ClaimedSearchResultListElementComponent, VarDirective],
|
||||
providers: [
|
||||
{ provide: TruncatableService, useValue: {} },
|
||||
{ provide: LinkService, useValue: linkService }
|
||||
],
|
||||
schemas: [NO_ERRORS_SCHEMA]
|
||||
}).overrideComponent(ClaimedSearchResultListElementComponent, {
|
||||
@@ -79,8 +84,12 @@ describe('ClaimedSearchResultListElementComponent', () => {
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should init item properly', () => {
|
||||
expect(component.workflowitem).toEqual(workflowitem);
|
||||
it('should init workflowitem properly', (done) => {
|
||||
component.workflowitemRD$.subscribe((workflowitemRD) => {
|
||||
expect(linkService.resolveLink).toHaveBeenCalled();
|
||||
expect(workflowitemRD.payload).toEqual(workflowitem);
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
it('should have properly status', () => {
|
||||
|
@@ -2,17 +2,18 @@ import { Component } from '@angular/core';
|
||||
import { Location, LocationStrategy, PathLocationStrategy } from '@angular/common';
|
||||
|
||||
import { Observable } from 'rxjs';
|
||||
import { find } from 'rxjs/operators';
|
||||
|
||||
import { ViewMode } from '../../../../core/shared/view-mode.model';
|
||||
import { RemoteData } from '../../../../core/data/remote-data';
|
||||
import { isNotUndefined } from '../../../empty.util';
|
||||
import { WorkflowItem } from '../../../../core/submission/models/workflowitem.model';
|
||||
import { ClaimedTask } from '../../../../core/tasks/models/claimed-task-object.model';
|
||||
import { MyDspaceItemStatusType } from '../../../object-collection/shared/mydspace-item-status/my-dspace-item-status-type';
|
||||
import { listableObjectComponent } from '../../../object-collection/shared/listable-object/listable-object.decorator';
|
||||
import { ClaimedTaskSearchResult } from '../../../object-collection/shared/claimed-task-search-result.model';
|
||||
import { SearchResultListElementComponent } from '../../search-result-list-element/search-result-list-element.component';
|
||||
import { followLink } from '../../../utils/follow-link-config.model';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
import { TruncatableService } from '../../../truncatable/truncatable.service';
|
||||
|
||||
/**
|
||||
* This component renders claimed task object for the search result in the list view.
|
||||
@@ -40,24 +41,26 @@ export class ClaimedSearchResultListElementComponent extends SearchResultListEle
|
||||
/**
|
||||
* The workflowitem object that belonging to the result object
|
||||
*/
|
||||
public workflowitem: WorkflowItem;
|
||||
public workflowitemRD$: Observable<RemoteData<WorkflowItem>>;
|
||||
|
||||
constructor(
|
||||
protected linkService: LinkService,
|
||||
protected truncatableService: TruncatableService
|
||||
) {
|
||||
super(truncatableService);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize all instance variables
|
||||
*/
|
||||
ngOnInit() {
|
||||
super.ngOnInit();
|
||||
this.initWorkflowItem(this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve workflowitem from result object
|
||||
*/
|
||||
initWorkflowItem(wfi$: Observable<RemoteData<WorkflowItem>>) {
|
||||
wfi$.pipe(
|
||||
find((rd: RemoteData<WorkflowItem>) => (rd.hasSucceeded && isNotUndefined(rd.payload)))
|
||||
).subscribe((rd: RemoteData<WorkflowItem>) => {
|
||||
this.workflowitem = rd.payload;
|
||||
});
|
||||
this.linkService.resolveLink(this.dso, followLink(
|
||||
'workflowitem',
|
||||
null,
|
||||
followLink('item'),
|
||||
followLink('submitter')
|
||||
));
|
||||
this.workflowitemRD$ = this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>;
|
||||
}
|
||||
}
|
||||
|
@@ -1,7 +1,9 @@
|
||||
<ng-container *ngVar="(workflowitemRD$ | async)?.payload as workflowitem">
|
||||
<ds-item-list-preview *ngIf="workflowitem"
|
||||
[item]="(workflowitem.item | async)?.payload"
|
||||
[item]="(workflowitem?.item | async)?.payload"
|
||||
[object]="object"
|
||||
[showSubmitter]="showSubmitter"
|
||||
[status]="status"></ds-item-list-preview>
|
||||
|
||||
<ds-pool-task-actions [object]="dso"></ds-pool-task-actions>
|
||||
<ds-pool-task-actions *ngIf="workflowitem" [object]="dso"></ds-pool-task-actions>
|
||||
</ng-container>
|
||||
|
@@ -12,6 +12,9 @@ import { WorkflowItem } from '../../../../core/submission/models/workflowitem.mo
|
||||
import { createSuccessfulRemoteDataObject } from '../../../testing/utils';
|
||||
import { PoolTaskSearchResult } from '../../../object-collection/shared/pool-task-search-result.model';
|
||||
import { TruncatableService } from '../../../truncatable/truncatable.service';
|
||||
import { VarDirective } from '../../../utils/var.directive';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
import { getMockLinkService } from '../../../mocks/mock-link-service';
|
||||
|
||||
let component: PoolSearchResultListElementComponent;
|
||||
let fixture: ComponentFixture<PoolSearchResultListElementComponent>;
|
||||
@@ -54,14 +57,16 @@ const rdItem = createSuccessfulRemoteDataObject(item);
|
||||
const workflowitem = Object.assign(new WorkflowItem(), { item: observableOf(rdItem) });
|
||||
const rdWorkflowitem = createSuccessfulRemoteDataObject(workflowitem);
|
||||
mockResultObject.indexableObject = Object.assign(new PoolTask(), { workflowitem: observableOf(rdWorkflowitem) });
|
||||
const linkService = getMockLinkService();
|
||||
|
||||
describe('PoolSearchResultListElementComponent', () => {
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [NoopAnimationsModule],
|
||||
declarations: [PoolSearchResultListElementComponent],
|
||||
declarations: [PoolSearchResultListElementComponent, VarDirective],
|
||||
providers: [
|
||||
{ provide: TruncatableService, useValue: {} },
|
||||
{ provide: LinkService, useValue: linkService }
|
||||
],
|
||||
schemas: [NO_ERRORS_SCHEMA]
|
||||
}).overrideComponent(PoolSearchResultListElementComponent, {
|
||||
@@ -79,8 +84,12 @@ describe('PoolSearchResultListElementComponent', () => {
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should init item properly', () => {
|
||||
expect(component.workflowitem).toEqual(workflowitem);
|
||||
it('should init workflowitem properly', (done) => {
|
||||
component.workflowitemRD$.subscribe((workflowitemRD) => {
|
||||
expect(linkService.resolveLink).toHaveBeenCalled();
|
||||
expect(workflowitemRD.payload).toEqual(workflowitem);
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
it('should have properly status', () => {
|
||||
|
@@ -1,11 +1,9 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
|
||||
import { Observable } from 'rxjs';
|
||||
import { find } from 'rxjs/operators';
|
||||
|
||||
import { ViewMode } from '../../../../core/shared/view-mode.model';
|
||||
import { RemoteData } from '../../../../core/data/remote-data';
|
||||
import { isNotUndefined } from '../../../empty.util';
|
||||
import { WorkflowItem } from '../../../../core/submission/models/workflowitem.model';
|
||||
import { PoolTask } from '../../../../core/tasks/models/pool-task-object.model';
|
||||
import { MyDspaceItemStatusType } from '../../../object-collection/shared/mydspace-item-status/my-dspace-item-status-type';
|
||||
@@ -13,6 +11,8 @@ import { listableObjectComponent } from '../../../object-collection/shared/lista
|
||||
import { PoolTaskSearchResult } from '../../../object-collection/shared/pool-task-search-result.model';
|
||||
import { SearchResultListElementComponent } from '../../search-result-list-element/search-result-list-element.component';
|
||||
import { TruncatableService } from '../../../truncatable/truncatable.service';
|
||||
import { followLink } from '../../../utils/follow-link-config.model';
|
||||
import { LinkService } from '../../../../core/cache/builders/link.service';
|
||||
|
||||
/**
|
||||
* This component renders pool task object for the search result in the list view.
|
||||
@@ -39,14 +39,17 @@ export class PoolSearchResultListElementComponent extends SearchResultListElemen
|
||||
/**
|
||||
* The workflowitem object that belonging to the result object
|
||||
*/
|
||||
public workflowitem: WorkflowItem;
|
||||
public workflowitemRD$: Observable<RemoteData<WorkflowItem>>;
|
||||
|
||||
/**
|
||||
* The index of this list element
|
||||
*/
|
||||
public index: number;
|
||||
|
||||
constructor(protected truncatableService: TruncatableService) {
|
||||
constructor(
|
||||
protected linkService: LinkService,
|
||||
protected truncatableService: TruncatableService
|
||||
) {
|
||||
super(truncatableService);
|
||||
}
|
||||
|
||||
@@ -55,17 +58,12 @@ export class PoolSearchResultListElementComponent extends SearchResultListElemen
|
||||
*/
|
||||
ngOnInit() {
|
||||
super.ngOnInit();
|
||||
this.initWorkflowItem(this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve workflowitem from result object
|
||||
*/
|
||||
initWorkflowItem(wfi$: Observable<RemoteData<WorkflowItem>>) {
|
||||
wfi$.pipe(
|
||||
find((rd: RemoteData<WorkflowItem>) => (rd.hasSucceeded && isNotUndefined(rd.payload)))
|
||||
).subscribe((rd: RemoteData<WorkflowItem>) => {
|
||||
this.workflowitem = rd.payload;
|
||||
});
|
||||
this.linkService.resolveLink(this.dso, followLink(
|
||||
'workflowitem',
|
||||
null,
|
||||
followLink('item'),
|
||||
followLink('submitter')
|
||||
));
|
||||
this.workflowitemRD$ = this.dso.workflowitem as Observable<RemoteData<WorkflowItem>>;
|
||||
}
|
||||
}
|
||||
|
@@ -43,9 +43,6 @@ import { SubmissionSectionError } from '../../objects/submission-objects.reducer
|
||||
import { DynamicFormControlEvent, DynamicFormControlEventType } from '@ng-dynamic-forms/core';
|
||||
import { JsonPatchOperationPathCombiner } from '../../../core/json-patch/builder/json-patch-operation-path-combiner';
|
||||
import { FormRowModel } from '../../../core/config/models/config-submission-form.model';
|
||||
import { WorkspaceitemDataService } from '../../../core/submission/workspaceitem-data.service';
|
||||
import { RemoteData } from '../../../core/data/remote-data';
|
||||
import { WorkspaceItem } from '../../../core/submission/models/workspaceitem.model';
|
||||
|
||||
function getMockSubmissionFormsConfigService(): SubmissionFormsConfigService {
|
||||
return jasmine.createSpyObj('FormOperationsService', {
|
||||
@@ -183,7 +180,6 @@ describe('SubmissionSectionformComponent test suite', () => {
|
||||
{ provide: 'collectionIdProvider', useValue: collectionId },
|
||||
{ provide: 'sectionDataProvider', useValue: sectionObject },
|
||||
{ provide: 'submissionIdProvider', useValue: submissionId },
|
||||
{ provide: WorkspaceitemDataService, useValue: {findById: () => observableOf(new RemoteData(false, false, true, null, new WorkspaceItem()))}},
|
||||
ChangeDetectorRef,
|
||||
SubmissionSectionformComponent
|
||||
],
|
||||
|
@@ -15,10 +15,7 @@ import { hasValue, isNotEmpty, isUndefined } from '../../../shared/empty.util';
|
||||
import { ConfigData } from '../../../core/config/config-data';
|
||||
import { JsonPatchOperationPathCombiner } from '../../../core/json-patch/builder/json-patch-operation-path-combiner';
|
||||
import { SubmissionFormsModel } from '../../../core/config/models/config-submission-forms.model';
|
||||
import {
|
||||
SubmissionSectionError,
|
||||
SubmissionSectionObject
|
||||
} from '../../objects/submission-objects.reducer';
|
||||
import { SubmissionSectionError, SubmissionSectionObject } from '../../objects/submission-objects.reducer';
|
||||
import { FormFieldPreviousValueObject } from '../../../shared/form/builder/models/form-field-previous-value-object';
|
||||
import { GLOBAL_CONFIG } from '../../../../config';
|
||||
import { GlobalConfig } from '../../../../config/global-config.interface';
|
||||
@@ -31,11 +28,7 @@ import { NotificationsService } from '../../../shared/notifications/notification
|
||||
import { SectionsService } from '../sections.service';
|
||||
import { difference } from '../../../shared/object.util';
|
||||
import { WorkspaceitemSectionFormObject } from '../../../core/submission/models/workspaceitem-section-form.model';
|
||||
import { WorkspaceItem } from '../../../core/submission/models/workspaceitem.model';
|
||||
import { WorkspaceitemDataService } from '../../../core/submission/workspaceitem-data.service';
|
||||
import { combineLatest as combineLatestObservable } from 'rxjs';
|
||||
import { getSucceededRemoteData } from '../../../core/shared/operators';
|
||||
import { RemoteData } from '../../../core/data/remote-data';
|
||||
|
||||
/**
|
||||
* This component represents a section that contains a Form.
|
||||
@@ -108,7 +101,6 @@ export class SubmissionSectionformComponent extends SectionModelComponent {
|
||||
*/
|
||||
protected subs: Subscription[] = [];
|
||||
|
||||
protected workspaceItem: WorkspaceItem;
|
||||
/**
|
||||
* The FormComponent reference
|
||||
*/
|
||||
@@ -140,7 +132,6 @@ export class SubmissionSectionformComponent extends SectionModelComponent {
|
||||
protected sectionService: SectionsService,
|
||||
protected submissionService: SubmissionService,
|
||||
protected translate: TranslateService,
|
||||
protected workspaceItemDataService: WorkspaceitemDataService,
|
||||
@Inject(GLOBAL_CONFIG) protected EnvConfig: GlobalConfig,
|
||||
@Inject('collectionIdProvider') public injectedCollectionId: string,
|
||||
@Inject('sectionDataProvider') public injectedSectionData: SectionDataObject,
|
||||
@@ -157,16 +148,11 @@ export class SubmissionSectionformComponent extends SectionModelComponent {
|
||||
this.formConfigService.getConfigByHref(this.sectionData.config).pipe(
|
||||
map((configData: ConfigData) => configData.payload),
|
||||
tap((config: SubmissionFormsModel) => this.formConfig = config),
|
||||
flatMap(() =>
|
||||
combineLatestObservable(
|
||||
this.sectionService.getSectionData(this.submissionId, this.sectionData.id),
|
||||
this.workspaceItemDataService.findById(this.submissionId).pipe(getSucceededRemoteData(), map((wsiRD: RemoteData<WorkspaceItem>) => wsiRD.payload))
|
||||
)),
|
||||
flatMap(() => this.sectionService.getSectionData(this.submissionId, this.sectionData.id)),
|
||||
take(1))
|
||||
.subscribe(([sectionData, workspaceItem]: [WorkspaceitemSectionFormObject, WorkspaceItem]) => {
|
||||
.subscribe((sectionData: WorkspaceitemSectionFormObject) => {
|
||||
if (isUndefined(this.formModel)) {
|
||||
this.sectionData.errors = [];
|
||||
this.workspaceItem = workspaceItem;
|
||||
// Is the first loading so init form
|
||||
this.initForm(sectionData);
|
||||
this.sectionData.data = sectionData;
|
||||
|
Reference in New Issue
Block a user