Skip to content

Commit

Permalink
[MIGRATION] - Fixed type
Browse files Browse the repository at this point in the history
  • Loading branch information
VitoAlbano committed Dec 6, 2024
1 parent a7a3e7f commit 6c50b59
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ export class AttachFileCloudWidgetComponent extends UploadCloudWidgetComponent i
}

isRetrieveMetadataOptionEnabled(): boolean {
return this.field?.params?.menuOptions && this.field.params.menuOptions[RETRIEVE_METADATA_OPTION];
return this.field?.params?.menuOptions?.[RETRIEVE_METADATA_OPTION];
}

isValidAlias(alias: string): boolean {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,13 @@ describe('FormUtilsService', () => {

/**
* Test the getRestUrlVariablesMap method
*
* @param restUrl The rest URL for getRestUrlVariablesMap
* @param inputBody The input body for getRestUrlVariablesMap
* @param expected The expected result of getRestUrlVariablesMap
*/
function testRestUrlVariablesMap(restUrl: string, inputBody: { [key: string]: any }, expected: { [key: string]: any }) {
const formModel = new FormModel({ variables });
spyOn(formModel, 'getProcessVariableValue').and.callFake((name) => {
return variables.find((variable) => variable.name === name)?.value;
});
spyOn(formModel, 'getProcessVariableValue').and.callFake((name) => variables.find((variable) => variable.name === name)?.value);
const result = service.getRestUrlVariablesMap(formModel, restUrl, inputBody);
expect(result).toEqual(expected);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ export class ProcessListCloudService extends BaseCloudService {

/**
* Finds a process using an object with optional query properties.
*
* @deprecated From Activiti 8.7.0 forward, use ProcessListCloudService.fetchProcessList instead.
* @param requestNode Query object
* @param queryUrl Query url
Expand All @@ -71,7 +70,6 @@ export class ProcessListCloudService extends BaseCloudService {
/**
* Available from Activiti version 8.7.0 onwards.
* Retrieves a list of processes using an object with optional query properties.
*
* @param requestNode Query object
* @param queryUrl Query url
* @returns List of processes
Expand Down Expand Up @@ -153,7 +151,6 @@ export class ProcessListCloudService extends BaseCloudService {

/**
* Finds a process using an object with optional query properties.
*
* @param appName app name
* @param status filter status
* @returns Total items
Expand Down Expand Up @@ -195,7 +192,6 @@ export class ProcessListCloudService extends BaseCloudService {

/**
* Finds a process using an object with optional query properties in admin app.
*
* @param requestNode Query object
* @param queryUrl Query url
* @returns Process information
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ export class ProcessTaskListCloudService extends BaseCloudService {

/**
* Retrieves a list of tasks using an object with optional query properties.
*
* @param requestNode Query object
* @param queryUrl Query url
* @returns List of tasks
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ export abstract class BaseTaskListCloudComponent<T = unknown>
pagination: BehaviorSubject<PaginationModel>;

requestNode: TaskQueryCloudRequestModel;
rows: unknown[] = [];
rows = [];
size: number;
skipCount: number = 0;
currentInstanceId: string;
Expand Down Expand Up @@ -265,7 +265,6 @@ export abstract class BaseTaskListCloudComponent<T = unknown>
/**
* Resets the pagination values and
* Reloads the task list
*
* @param pagination Pagination values to be set
*/
updatePagination(pagination: PaginationModel) {
Expand Down

0 comments on commit 6c50b59

Please sign in to comment.