refactor: rename Application → Aanvraag across the wire (Step 1/8)

The wire said Application, the domain said Aanvraag — one aggregate with
two names at every hop. Rename the backend DTOs and the /applications
route to /aanvragen, regenerate the typed client, and rename the frontend
adapter/store to match.

Renamed: ApplicationSummaryDto/DetailDto, CreateApplicationRequest,
SubmitApplicationRequest/Response → Aanvraag* equivalents;
ApplicationsAdapter/Store → AanvragenAdapter/Store;
applications.adapter.ts/applications.store.ts → aanvragen.*.

Left untouched: the admin Case/Zaak vocabulary (/admin/cases,
AdminCasesStore) — a separate read model, not part of this rename; the
internal BigRegister.Domain.Applications namespace and the Applications
EF table (renaming those needs a new EF migration, out of scope here).

Part of the dashboard-readability refactor (see the approved plan).

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
eho
2026-09-04 14:33:16 +02:00
co-authored by Claude Opus 5
parent faad772f85
commit 194cccfd02
36 changed files with 400 additions and 412 deletions
+71 -71
View File
@@ -637,8 +637,8 @@ export class ApiClient {
/**
* @return OK
*/
applicationsAll(): Promise<ApplicationSummaryDto[]> {
let url_ = this.baseUrl + "/api/v1/applications";
aanvragenAll(): Promise<AanvraagSummaryDto[]> {
let url_ = this.baseUrl + "/api/v1/aanvragen";
url_ = url_.replace(/[?&]$/, "");
let options_: RequestInit = {
@@ -649,17 +649,17 @@ export class ApiClient {
};
return this.http.fetch(url_, options_).then((_response: Response) => {
return this.processApplicationsAll(_response);
return this.processAanvragenAll(_response);
});
}
protected processApplicationsAll(response: Response): Promise<ApplicationSummaryDto[]> {
protected processAanvragenAll(response: Response): Promise<AanvraagSummaryDto[]> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 200) {
return response.text().then((_responseText) => {
let result200: any = null;
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ApplicationSummaryDto[];
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as AanvraagSummaryDto[];
return result200;
});
} else if (status !== 200 && status !== 204) {
@@ -667,14 +667,14 @@ export class ApiClient {
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
});
}
return Promise.resolve<ApplicationSummaryDto[]>(null as any);
return Promise.resolve<AanvraagSummaryDto[]>(null as any);
}
/**
* @return Created
*/
applicationsPOST(body: CreateApplicationRequest): Promise<ApplicationDetailDto> {
let url_ = this.baseUrl + "/api/v1/applications";
aanvragenPOST(body: CreateAanvraagRequest): Promise<AanvraagDetailDto> {
let url_ = this.baseUrl + "/api/v1/aanvragen";
url_ = url_.replace(/[?&]$/, "");
const content_ = JSON.stringify(body);
@@ -689,17 +689,17 @@ export class ApiClient {
};
return this.http.fetch(url_, options_).then((_response: Response) => {
return this.processApplicationsPOST(_response);
return this.processAanvragenPOST(_response);
});
}
protected processApplicationsPOST(response: Response): Promise<ApplicationDetailDto> {
protected processAanvragenPOST(response: Response): Promise<AanvraagDetailDto> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 201) {
return response.text().then((_responseText) => {
let result201: any = null;
result201 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ApplicationDetailDto;
result201 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as AanvraagDetailDto;
return result201;
});
} else if (status === 409) {
@@ -713,14 +713,14 @@ export class ApiClient {
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
});
}
return Promise.resolve<ApplicationDetailDto>(null as any);
return Promise.resolve<AanvraagDetailDto>(null as any);
}
/**
* @return OK
*/
applicationsGET(id: string): Promise<ApplicationDetailDto> {
let url_ = this.baseUrl + "/api/v1/applications/{id}";
aanvragenGET(id: string): Promise<AanvraagDetailDto> {
let url_ = this.baseUrl + "/api/v1/aanvragen/{id}";
if (id === undefined || id === null)
throw new globalThis.Error("The parameter 'id' must be defined.");
url_ = url_.replace("{id}", encodeURIComponent("" + id));
@@ -734,17 +734,17 @@ export class ApiClient {
};
return this.http.fetch(url_, options_).then((_response: Response) => {
return this.processApplicationsGET(_response);
return this.processAanvragenGET(_response);
});
}
protected processApplicationsGET(response: Response): Promise<ApplicationDetailDto> {
protected processAanvragenGET(response: Response): Promise<AanvraagDetailDto> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 200) {
return response.text().then((_responseText) => {
let result200: any = null;
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ApplicationDetailDto;
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as AanvraagDetailDto;
return result200;
});
} else if (status === 404) {
@@ -756,14 +756,14 @@ export class ApiClient {
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
});
}
return Promise.resolve<ApplicationDetailDto>(null as any);
return Promise.resolve<AanvraagDetailDto>(null as any);
}
/**
* @return No Content
*/
applicationsPUT(id: string, body: DraftSyncRequest): Promise<void> {
let url_ = this.baseUrl + "/api/v1/applications/{id}";
aanvragenPUT(id: string, body: DraftSyncRequest): Promise<void> {
let url_ = this.baseUrl + "/api/v1/aanvragen/{id}";
if (id === undefined || id === null)
throw new globalThis.Error("The parameter 'id' must be defined.");
url_ = url_.replace("{id}", encodeURIComponent("" + id));
@@ -780,11 +780,11 @@ export class ApiClient {
};
return this.http.fetch(url_, options_).then((_response: Response) => {
return this.processApplicationsPUT(_response);
return this.processAanvragenPUT(_response);
});
}
protected processApplicationsPUT(response: Response): Promise<void> {
protected processAanvragenPUT(response: Response): Promise<void> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 204) {
@@ -812,8 +812,8 @@ export class ApiClient {
/**
* @return No Content
*/
applicationsDELETE(id: string): Promise<void> {
let url_ = this.baseUrl + "/api/v1/applications/{id}";
aanvragenDELETE(id: string): Promise<void> {
let url_ = this.baseUrl + "/api/v1/aanvragen/{id}";
if (id === undefined || id === null)
throw new globalThis.Error("The parameter 'id' must be defined.");
url_ = url_.replace("{id}", encodeURIComponent("" + id));
@@ -826,11 +826,11 @@ export class ApiClient {
};
return this.http.fetch(url_, options_).then((_response: Response) => {
return this.processApplicationsDELETE(_response);
return this.processAanvragenDELETE(_response);
});
}
protected processApplicationsDELETE(response: Response): Promise<void> {
protected processAanvragenDELETE(response: Response): Promise<void> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 204) {
@@ -858,8 +858,8 @@ export class ApiClient {
/**
* @return OK
*/
submit(id: string, body: SubmitApplicationRequest): Promise<SubmitApplicationResponse> {
let url_ = this.baseUrl + "/api/v1/applications/{id}/submit";
submit(id: string, body: AanvraagIndienenRequest): Promise<AanvraagIndienenResponse> {
let url_ = this.baseUrl + "/api/v1/aanvragen/{id}/submit";
if (id === undefined || id === null)
throw new globalThis.Error("The parameter 'id' must be defined.");
url_ = url_.replace("{id}", encodeURIComponent("" + id));
@@ -881,13 +881,13 @@ export class ApiClient {
});
}
protected processSubmit(response: Response): Promise<SubmitApplicationResponse> {
protected processSubmit(response: Response): Promise<AanvraagIndienenResponse> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 200) {
return response.text().then((_responseText) => {
let result200: any = null;
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as SubmitApplicationResponse;
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as AanvraagIndienenResponse;
return result200;
});
} else if (status === 400) {
@@ -911,13 +911,13 @@ export class ApiClient {
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
});
}
return Promise.resolve<SubmitApplicationResponse>(null as any);
return Promise.resolve<AanvraagIndienenResponse>(null as any);
}
/**
* @return OK
*/
casesAll(): Promise<ApplicationSummaryDto[]> {
casesAll(): Promise<AanvraagSummaryDto[]> {
let url_ = this.baseUrl + "/api/v1/admin/cases";
url_ = url_.replace(/[?&]$/, "");
@@ -933,13 +933,13 @@ export class ApiClient {
});
}
protected processCasesAll(response: Response): Promise<ApplicationSummaryDto[]> {
protected processCasesAll(response: Response): Promise<AanvraagSummaryDto[]> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 200) {
return response.text().then((_responseText) => {
let result200: any = null;
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ApplicationSummaryDto[];
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as AanvraagSummaryDto[];
return result200;
});
} else if (status === 403) {
@@ -953,7 +953,7 @@ export class ApiClient {
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
});
}
return Promise.resolve<ApplicationSummaryDto[]>(null as any);
return Promise.resolve<AanvraagSummaryDto[]>(null as any);
}
/**
@@ -1047,7 +1047,7 @@ export class ApiClient {
/**
* @return OK
*/
werkvoorraad(): Promise<ApplicationSummaryDto[]> {
werkvoorraad(): Promise<AanvraagSummaryDto[]> {
let url_ = this.baseUrl + "/api/v1/werkvoorraad";
url_ = url_.replace(/[?&]$/, "");
@@ -1063,13 +1063,13 @@ export class ApiClient {
});
}
protected processWerkvoorraad(response: Response): Promise<ApplicationSummaryDto[]> {
protected processWerkvoorraad(response: Response): Promise<AanvraagSummaryDto[]> {
const status = response.status;
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
if (status === 200) {
return response.text().then((_responseText) => {
let result200: any = null;
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ApplicationSummaryDto[];
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as AanvraagSummaryDto[];
return result200;
});
} else if (status === 403) {
@@ -1083,7 +1083,7 @@ export class ApiClient {
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
});
}
return Promise.resolve<ApplicationSummaryDto[]>(null as any);
return Promise.resolve<AanvraagSummaryDto[]>(null as any);
}
/**
@@ -1898,22 +1898,7 @@ export interface AantekeningDto {
datum?: string | undefined;
}
export interface AanvraagStatusDto {
tag?: string | undefined;
stepIndex?: number | undefined;
stepCount?: number | undefined;
referentie?: string | undefined;
manual?: boolean | undefined;
reden?: string | undefined;
}
export interface AdresDto {
straat?: string | undefined;
postcode?: string | undefined;
woonplaats?: string | undefined;
}
export interface ApplicationDetailDto {
export interface AanvraagDetailDto {
id?: string | undefined;
type?: string | undefined;
status?: AanvraagStatusDto;
@@ -1924,7 +1909,29 @@ export interface ApplicationDetailDto {
submittedAt?: string | undefined;
}
export interface ApplicationSummaryDto {
export interface AanvraagIndienenRequest {
diplomaHerkomst?: string | undefined;
uren?: number | undefined;
documents?: DocumentRefDto[] | undefined;
aanvullendeScholing?: boolean | undefined;
scholingPunten?: number | undefined;
}
export interface AanvraagIndienenResponse {
referentie?: string | undefined;
status?: AanvraagStatusDto;
}
export interface AanvraagStatusDto {
tag?: string | undefined;
stepIndex?: number | undefined;
stepCount?: number | undefined;
referentie?: string | undefined;
manual?: boolean | undefined;
reden?: string | undefined;
}
export interface AanvraagSummaryDto {
id?: string | undefined;
type?: string | undefined;
status?: AanvraagStatusDto;
@@ -1935,6 +1942,12 @@ export interface ApplicationSummaryDto {
owner?: string | undefined;
}
export interface AdresDto {
straat?: string | undefined;
postcode?: string | undefined;
woonplaats?: string | undefined;
}
export interface AuthzAuditDto {
at?: string | undefined;
action?: string | undefined;
@@ -1955,7 +1968,7 @@ export interface BeoordelingDocumentDto {
}
export interface BeoordelingViewDto {
aanvraag?: ApplicationSummaryDto;
aanvraag?: AanvraagSummaryDto;
documenten?: BeoordelingDocumentDto[] | undefined;
decisions?: BeoordelingDecisionsDto;
}
@@ -2014,7 +2027,7 @@ export interface ChangeRequestRequest {
telefoon?: string | undefined;
}
export interface CreateApplicationRequest {
export interface CreateAanvraagRequest {
type?: string | undefined;
}
@@ -2275,19 +2288,6 @@ export interface SubOrgSummaryDto {
publishedVersion?: number;
}
export interface SubmitApplicationRequest {
diplomaHerkomst?: string | undefined;
uren?: number | undefined;
documents?: DocumentRefDto[] | undefined;
aanvullendeScholing?: boolean | undefined;
scholingPunten?: number | undefined;
}
export interface SubmitApplicationResponse {
referentie?: string | undefined;
status?: AanvraagStatusDto;
}
export interface UploadCategoriesDto {
categories?: DocumentCategoryDto[] | undefined;
}