"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/app/my-dspace-page/my-dspace-new-submission/my-dspace-new-submission.component.ts" between
dspace-angular-dspace-7.0.tar.gz and dspace-angular-dspace-7.1.tar.gz

About: dspace-angular is the Angular-based frontend of DSpace, a digital repository system to capture, store, index, preserve and redistribute an organization’s research material in digital formats.

my-dspace-new-submission.component.ts  (dspace-angular-dspace-7.0):my-dspace-new-submission.component.ts  (dspace-angular-dspace-7.1)
skipping to change at line 17 skipping to change at line 17
import { AuthService } from '../../core/auth/auth.service'; import { AuthService } from '../../core/auth/auth.service';
import { DSpaceObject } from '../../core/shared/dspace-object.model'; import { DSpaceObject } from '../../core/shared/dspace-object.model';
import { NotificationsService } from '../../shared/notifications/notifications.s ervice'; import { NotificationsService } from '../../shared/notifications/notifications.s ervice';
import { NotificationOptions } from '../../shared/notifications/models/notificat ion-options.model'; import { NotificationOptions } from '../../shared/notifications/models/notificat ion-options.model';
import { UploaderOptions } from '../../shared/uploader/uploader-options.model'; import { UploaderOptions } from '../../shared/uploader/uploader-options.model';
import { HALEndpointService } from '../../core/shared/hal-endpoint.service'; import { HALEndpointService } from '../../core/shared/hal-endpoint.service';
import { NotificationType } from '../../shared/notifications/models/notification -type'; import { NotificationType } from '../../shared/notifications/models/notification -type';
import { hasValue } from '../../shared/empty.util'; import { hasValue } from '../../shared/empty.util';
import { SearchResult } from '../../shared/search/search-result.model'; import { SearchResult } from '../../shared/search/search-result.model';
import { CreateItemParentSelectorComponent } from '../../shared/dso-selector/mod al-wrappers/create-item-parent-selector/create-item-parent-selector.component';
import { CollectionSelectorComponent } from '../collection-selector/collection-s elector.component'; import { CollectionSelectorComponent } from '../collection-selector/collection-s elector.component';
import { UploaderComponent } from '../../shared/uploader/uploader.component'; import { UploaderComponent } from '../../shared/uploader/uploader.component';
import { UploaderError } from '../../shared/uploader/uploader-error.model'; import { UploaderError } from '../../shared/uploader/uploader-error.model';
/** /**
* This component represents the whole mydspace page header * This component represents the whole mydspace page header
*/ */
@Component({ @Component({
selector: 'ds-my-dspace-new-submission', selector: 'ds-my-dspace-new-submission',
styleUrls: ['./my-dspace-new-submission.component.scss'], styleUrls: ['./my-dspace-new-submission.component.scss'],
skipping to change at line 122 skipping to change at line 121
*/ */
public onUploadError(error: UploaderError) { public onUploadError(error: UploaderError) {
let errorMessageKey = 'mydspace.upload.upload-failed'; let errorMessageKey = 'mydspace.upload.upload-failed';
if (hasValue(error.status) && error.status === 422) { if (hasValue(error.status) && error.status === 422) {
errorMessageKey = 'mydspace.upload.upload-failed-manyentries'; errorMessageKey = 'mydspace.upload.upload-failed-manyentries';
} }
this.notificationsService.error(null, this.translate.get(errorMessageKey)); this.notificationsService.error(null, this.translate.get(errorMessageKey));
} }
/** /**
* Method called on clicking the button "New Submition", It opens a dialog for
* select a collection.
*/
openDialog() {
this.modalService.open(CreateItemParentSelectorComponent);
}
/**
* Method invoked after all file are loaded from upload plugin * Method invoked after all file are loaded from upload plugin
*/ */
afterFileLoaded(items) { afterFileLoaded(items) {
const uploader = this.uploaderComponent.uploader; const uploader = this.uploaderComponent.uploader;
if (hasValue(items) && items.length > 1) { if (hasValue(items) && items.length > 1) {
this.notificationsService.error(null, this.translate.get('mydspace.upload. upload-failed-moreonefile')); this.notificationsService.error(null, this.translate.get('mydspace.upload. upload-failed-moreonefile'));
uploader.clearQueue(); uploader.clearQueue();
this.changeDetectorRef.detectChanges(); this.changeDetectorRef.detectChanges();
} else { } else {
const modalRef = this.modalService.open(CollectionSelectorComponent); const modalRef = this.modalService.open(CollectionSelectorComponent);
 End of changes. 2 change blocks. 
9 lines changed or deleted 0 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)