style: lint
All checks were successful
Build / Build-and-ng-test (pull_request) Successful in 4m45s

This commit is contained in:
Mihajlo Medjedovic 2024-06-18 00:38:01 +02:00
parent 5deba44d2b
commit 6df7d8d2ba
3 changed files with 93 additions and 73 deletions

View File

@ -1,34 +1,34 @@
import { BaseSASResponse } from './common/BaseSASResponse'
export interface EditorsStageDataSASResponse extends BaseSASResponse {
SYSDATE: string;
SYSTIME: string;
sasparams: Sasparam[];
_DEBUG: string;
_PROGRAM: string;
AUTOEXEC: string;
MF_GETUSER: string;
SYSCC: string;
SYSENCODING: string;
SYSERRORTEXT: string;
SYSHOSTINFOLONG: string;
SYSHOSTNAME: string;
SYSPROCESSID: string;
SYSPROCESSMODE: string;
SYSPROCESSNAME: string;
SYSJOBID: string;
SYSSCPL: string;
SYSSITE: string;
SYSTCPIPHOSTNAME: string;
SYSUSERID: string;
SYSVLONG: string;
SYSWARNINGTEXT: string;
END_DTTM: string;
MEMSIZE: string;
SYSDATE: string
SYSTIME: string
sasparams: Sasparam[]
_DEBUG: string
_PROGRAM: string
AUTOEXEC: string
MF_GETUSER: string
SYSCC: string
SYSENCODING: string
SYSERRORTEXT: string
SYSHOSTINFOLONG: string
SYSHOSTNAME: string
SYSPROCESSID: string
SYSPROCESSMODE: string
SYSPROCESSNAME: string
SYSJOBID: string
SYSSCPL: string
SYSSITE: string
SYSTCPIPHOSTNAME: string
SYSUSERID: string
SYSVLONG: string
SYSWARNINGTEXT: string
END_DTTM: string
MEMSIZE: string
}
export interface Sasparam {
STATUS: string | 'SUCCESS';
DSID: string;
URL: string;
STATUS: string | 'SUCCESS'
DSID: string
URL: string
}

View File

@ -23,16 +23,10 @@
<ng-container *ngIf="parsedDatasets.length && !submittedDatasets.length">
<div class="text-center mb-10">
<button
(click)="onDiscard()"
class="btn btn-danger btn-sm mr-10"
>
<button (click)="onDiscard()" class="btn btn-danger btn-sm mr-10">
Discard
</button>
<button
(click)="onSubmitAll()"
class="btn btn-primary btn-sm"
>
<button (click)="onSubmitAll()" class="btn btn-primary btn-sm">
Submit All
</button>
</div>
@ -187,7 +181,12 @@
class="is-info icon-dc-fill"
></clr-icon>
<p class="text-center color-gray mt-10" cds-text="section">
Please select a dataset on the left to {{ !submittedDatasets.length ? 'review data' : 'review submitted results' }}
Please select a dataset on the left to
{{
!submittedDatasets.length
? 'review data'
: 'review submitted results'
}}
</p>
</div>
@ -205,7 +204,8 @@
>
</p>
<p cds-text="secondary regular">
Matched with dataset: <strong>{{ activeParsedDataset.libds }}</strong>
Matched with dataset:
<strong>{{ activeParsedDataset.libds }}</strong>
</p>
</div>
@ -257,12 +257,12 @@
</div>
<clr-modal [(clrModalOpen)]="showSubmitReasonModal">
<h3 class="modal-title">Submit for approval {{parsedDatasets.length}} tables</h3>
<h3 class="modal-title">
Submit for approval {{ parsedDatasets.length }} tables
</h3>
<div class="modal-body">
<div class="text-area-full-width">
<label for="formFields_8" class="mb-5 d-block"
>Message</label
>
<label for="formFields_8" class="mb-5 d-block">Message</label>
<textarea
clrTextarea
[(ngModel)]="submitReasonMessage"
@ -274,11 +274,26 @@
</div>
<p cds-text="caption_clean" class="mt-10">
Sheets which did not match any dataset will be ignored. Tables will be sent sequentially, logs will be available after all tables are submitted.
Sheets which did not match any dataset will be ignored. Tables will be
sent sequentially, logs will be available after all tables are submitted.
</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-outline" [disabled]="submitLoading" (click)="showSubmitReasonModal = false">Cancel</button>
<button type="button" class="btn btn-primary" [clrLoading]="submitLoading" (click)="submitTables()">Submit</button>
<button
type="button"
class="btn btn-outline"
[disabled]="submitLoading"
(click)="showSubmitReasonModal = false"
>
Cancel
</button>
<button
type="button"
class="btn btn-primary"
[clrLoading]="submitLoading"
(click)="submitTables()"
>
Submit
</button>
</div>
</clr-modal>

View File

@ -1,4 +1,10 @@
import { ChangeDetectorRef, Component, HostBinding, OnInit, SimpleChanges } from '@angular/core'
import {
ChangeDetectorRef,
Component,
HostBinding,
OnInit,
SimpleChanges
} from '@angular/core'
import {
EventService,
HelperService,
@ -211,7 +217,8 @@ export class MultiDatasetComponent implements OnInit {
initHot() {
setTimeout(() => {
if (!this.hotInstance) this.hotInstance = this.hotRegisterer.getInstance('hotInstance')
if (!this.hotInstance)
this.hotInstance = this.hotRegisterer.getInstance('hotInstance')
if (this.activeParsedDataset) {
this.hotInstance.updateSettings({
@ -219,7 +226,7 @@ export class MultiDatasetComponent implements OnInit {
colHeaders: this.activeParsedDataset.datasetInfo.headerColumns,
columns: this.activeParsedDataset.datasetInfo.dcValidator?.getRules(),
readOnly: true,
height: '300px',
height: '300px'
})
}
})
@ -291,9 +298,7 @@ export class MultiDatasetComponent implements OnInit {
this.initHot()
}
onSubmittedDatasetClick(submittedDataset: SubmittedDatasetResult) {
}
onSubmittedDatasetClick(submittedDataset: SubmittedDatasetResult) {}
public get activeParsedDataset(): ParsedDataset | undefined {
return this.parsedDatasets.find((dataset) => dataset.active)
@ -588,17 +593,17 @@ export interface DatasetsObject extends EditorsGetDataServiceResponse {
export interface ParsedDataset {
libds: string
parseResult: ParseResult,
datasetInfo: DatasetsObject,
datasource: any[],
parseResult: ParseResult
datasetInfo: DatasetsObject
datasource: any[]
includeInSubmission: boolean
status?: 'success' | 'error'
active?: boolean
}
export interface SubmittedDatasetResult {
libds: string,
success: EditorsStageDataSASResponse | undefined,
error: any,
libds: string
success: EditorsStageDataSASResponse | undefined
error: any
active?: boolean
}