mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 10:04:11 +00:00
resolved PR feedback
This commit is contained in:
@@ -25,7 +25,7 @@
|
|||||||
"prebuild:prod": "yarn run prebuild",
|
"prebuild:prod": "yarn run prebuild",
|
||||||
"build": "webpack --progress --mode development",
|
"build": "webpack --progress --mode development",
|
||||||
"build:aot": "webpack --env.aot --env.server --mode development && webpack --env.aot --env.client --mode development",
|
"build:aot": "webpack --env.aot --env.server --mode development && webpack --env.aot --env.client --mode development",
|
||||||
"build:prod": "webpack --env.aot --env.server --env.production && webpack --env.aot --env.client --env.production",
|
"build:prod": "webpack --env.aot --env.server --mode production && webpack --env.aot --env.client --mode production",
|
||||||
"postbuild:prod": "yarn run rollup",
|
"postbuild:prod": "yarn run rollup",
|
||||||
"rollup": "rollup -c rollup.config.js",
|
"rollup": "rollup -c rollup.config.js",
|
||||||
"prestart": "yarn run build:prod",
|
"prestart": "yarn run build:prod",
|
||||||
|
2
src/app/core/cache/response-cache.models.ts
vendored
2
src/app/core/cache/response-cache.models.ts
vendored
@@ -140,7 +140,7 @@ export class ErrorResponse extends RestResponse {
|
|||||||
|
|
||||||
constructor(error: RequestError) {
|
constructor(error: RequestError) {
|
||||||
super(false, error.statusText);
|
super(false, error.statusText);
|
||||||
// console.error(error);
|
console.error(error);
|
||||||
this.errorMessage = error.message;
|
this.errorMessage = error.message;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -37,25 +37,8 @@ export abstract class ComColDataService<TNormalized extends NormalizedObject, TD
|
|||||||
tap((href: string) => {
|
tap((href: string) => {
|
||||||
const request = new FindByIDRequest(this.requestService.generateRequestId(), href, options.scopeID);
|
const request = new FindByIDRequest(this.requestService.generateRequestId(), href, options.scopeID);
|
||||||
this.requestService.configure(request);
|
this.requestService.configure(request);
|
||||||
}),);
|
}));
|
||||||
|
|
||||||
// return scopeCommunityHrefObs.pipe(
|
|
||||||
// mergeMap((href: string) => this.responseCache.get(href)),
|
|
||||||
// map((entry: ResponseCacheEntry) => entry.response),
|
|
||||||
// mergeMap((response) => {
|
|
||||||
// if (response.isSuccessful) {
|
|
||||||
// const community$: Observable<NormalizedCommunity> = this.objectCache.getByUUID(scopeID);
|
|
||||||
// return community$.pipe(
|
|
||||||
// map((community) => community._links[this.linkPath]),
|
|
||||||
// filter((href) => isNotEmpty(href)),
|
|
||||||
// distinctUntilChanged()
|
|
||||||
// );
|
|
||||||
// } else if (!response.isSuccessful) {
|
|
||||||
// return observableThrowError(new Error(`The Community with scope ${scopeID} couldn't be retrieved`))
|
|
||||||
// }
|
|
||||||
// }),
|
|
||||||
// distinctUntilChanged()
|
|
||||||
// );
|
|
||||||
const responses = scopeCommunityHrefObs.pipe(
|
const responses = scopeCommunityHrefObs.pipe(
|
||||||
mergeMap((href: string) => this.responseCache.get(href)),
|
mergeMap((href: string) => this.responseCache.get(href)),
|
||||||
map((entry: ResponseCacheEntry) => entry.response));
|
map((entry: ResponseCacheEntry) => entry.response));
|
||||||
|
@@ -2,7 +2,11 @@ import { Store, StoreModule } from '@ngrx/store';
|
|||||||
import { async, inject, TestBed } from '@angular/core/testing';
|
import { async, inject, TestBed } from '@angular/core/testing';
|
||||||
import { AbstractControl, FormControl, FormGroup, Validators } from '@angular/forms';
|
import { AbstractControl, FormControl, FormGroup, Validators } from '@angular/forms';
|
||||||
|
|
||||||
import { DynamicFormControlModel, DynamicInputModel } from '@ng-dynamic-forms/core';
|
import {
|
||||||
|
DynamicFormControlModel,
|
||||||
|
DynamicFormGroupModel,
|
||||||
|
DynamicInputModel
|
||||||
|
} from '@ng-dynamic-forms/core';
|
||||||
|
|
||||||
import { FormService } from './form.service';
|
import { FormService } from './form.service';
|
||||||
import { FormBuilderService } from './builder/form-builder.service';
|
import { FormBuilderService } from './builder/form-builder.service';
|
||||||
@@ -37,30 +41,30 @@ describe('FormService test suite', () => {
|
|||||||
}),
|
}),
|
||||||
new DynamicInputModel({ id: 'date' }),
|
new DynamicInputModel({ id: 'date' }),
|
||||||
new DynamicInputModel({ id: 'description' }),
|
new DynamicInputModel({ id: 'description' }),
|
||||||
// new DynamicFormGroupModel({
|
new DynamicFormGroupModel({
|
||||||
//
|
|
||||||
// id: 'addressLocation',
|
id: 'addressLocation',
|
||||||
// group: [
|
group: [
|
||||||
// new DynamicInputModel({
|
new DynamicInputModel({
|
||||||
//
|
|
||||||
// id: 'zipCode',
|
id: 'zipCode',
|
||||||
// label: 'Zip Code',
|
label: 'Zip Code',
|
||||||
// placeholder: 'ZIP'
|
placeholder: 'ZIP'
|
||||||
// }),
|
}),
|
||||||
// new DynamicInputModel({
|
new DynamicInputModel({
|
||||||
//
|
|
||||||
// id: 'state',
|
id: 'state',
|
||||||
// label: 'State',
|
label: 'State',
|
||||||
// placeholder: 'State'
|
placeholder: 'State'
|
||||||
// }),
|
}),
|
||||||
// new DynamicInputModel({
|
new DynamicInputModel({
|
||||||
//
|
|
||||||
// id: 'city',
|
id: 'city',
|
||||||
// label: 'City',
|
label: 'City',
|
||||||
// placeholder: 'City'
|
placeholder: 'City'
|
||||||
// })
|
})
|
||||||
// ]
|
]
|
||||||
// }),
|
}),
|
||||||
];
|
];
|
||||||
|
|
||||||
let controls;
|
let controls;
|
||||||
|
@@ -27,7 +27,7 @@ module.exports = function(env, options) {
|
|||||||
getAotPlugin('client', !!env.aot)
|
getAotPlugin('client', !!env.aot)
|
||||||
]
|
]
|
||||||
});
|
});
|
||||||
if (env.production) {
|
if (options.mode === 'production') {
|
||||||
serverConfig = webpackMerge({}, serverConfig, prodPartial);
|
serverConfig = webpackMerge({}, serverConfig, prodPartial);
|
||||||
clientConfig = webpackMerge({}, clientConfig, prodPartial);
|
clientConfig = webpackMerge({}, clientConfig, prodPartial);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user