src/app/deploy/deploy.component.ts
| encapsulation | ViewEncapsulation.None |
| host | { |
| selector | app-deploy |
| styleUrls | ./deploy.component.scss |
| templateUrl | ./deploy.component.html |
Properties |
|
Methods |
|
constructor(appStoreService: AppStoreService, sasService: SasService)
|
|||||||||
|
Defined in src/app/deploy/deploy.component.ts:30
|
|||||||||
|
Parameters :
|
| ngOnInit |
ngOnInit()
|
|
Defined in src/app/deploy/deploy.component.ts:43
|
|
Returns :
void
|
| Public onNavigateToHome |
onNavigateToHome()
|
|
Defined in src/app/deploy/deploy.component.ts:62
|
|
Returns :
void
|
| Public setDeployDefaults |
setDeployDefaults()
|
|
Defined in src/app/deploy/deploy.component.ts:50
|
|
Setting default values used for deploy request
Returns :
void
|
| Public termsAgreeChange |
termsAgreeChange()
|
|
Defined in src/app/deploy/deploy.component.ts:58
|
|
Accepting terms of service shows next screen
Returns :
void
|
| Public appLoc |
Type : string
|
Default value : ''
|
|
Defined in src/app/deploy/deploy.component.ts:21
|
| Public dcAdapterSettings |
Type : DcAdapterSettings | undefined
|
|
Defined in src/app/deploy/deploy.component.ts:28
|
| Public dcPath |
Type : string
|
Default value : ''
|
|
Defined in src/app/deploy/deploy.component.ts:22
|
| Public sasJs |
Type : any
|
|
Defined in src/app/deploy/deploy.component.ts:25
|
| Public sasJsConfig |
Type : SASjsConfig
|
Default value : new SASjsConfig()
|
|
Defined in src/app/deploy/deploy.component.ts:26
|
| Public selectedAdminGroup |
Type : string
|
Default value : ''
|
|
Defined in src/app/deploy/deploy.component.ts:23
|
| ServerType |
Type : unknown
|
Default value : ServerType
|
|
Defined in src/app/deploy/deploy.component.ts:30
|
| Public step |
Type : number
|
Default value : 0
|
|
Defined in src/app/deploy/deploy.component.ts:19
|
import { Component, OnInit, ViewEncapsulation } from '@angular/core'
import { SasService } from '../services/sas.service'
import { SASjsConfig } from '@sasjs/adapter'
import { ServerType } from '@sasjs/utils/types/serverType'
import { AppStoreService } from '../services/app-store.service'
import { DcAdapterSettings } from '../models/DcAdapterSettings'
@Component({
selector: 'app-deploy',
templateUrl: './deploy.component.html',
styleUrls: ['./deploy.component.scss'],
host: {
class: 'content-container'
},
encapsulation: ViewEncapsulation.None,
standalone: false
})
export class DeployComponent implements OnInit {
public step: number = 0
public appLoc: string = ''
public dcPath: string = ''
public selectedAdminGroup: string = ''
public sasJs: any
public sasJsConfig: SASjsConfig = new SASjsConfig()
public dcAdapterSettings: DcAdapterSettings | undefined
ServerType = ServerType
constructor(
private appStoreService: AppStoreService,
private sasService: SasService
) {
this.dcAdapterSettings = this.appStoreService.getDcAdapterSettings()
this.sasJs = this.sasService.getSasjsInstance()
this.sasJsConfig = this.sasService.getSasjsConfig()
this.appLoc = this.dcAdapterSettings?.appLoc || ''
}
ngOnInit() {
this.setDeployDefaults()
}
/**
* Setting default values used for deploy request
*/
public setDeployDefaults() {
this.dcPath = this.dcAdapterSettings?.dcPath || ''
this.selectedAdminGroup = 'SASAdministrators'
}
/**
* Accepting terms of service shows next screen
*/
public termsAgreeChange() {
this.step++
}
public onNavigateToHome() {
window.open(location.href.split('#')[0], '_blank')
}
}
<main class="content-area position-relative">
<div class="clr-row">
<!-- T&C section -->
@if (step === 0) {
<div id="TCS" class="card">
<div class="card-header">Terms and Conditions</div>
<div class="card-block">
<div class="card-text">
<p class="mt-0">
The Demo version of Data Controller is free for EVALUATION
purposes only. Before proceeding with configuration, please
confirm that you have read, understood, and agreed to the
<a
href="https://docs.datacontroller.io/evaluation-licence-agreement"
target="_blank"
>Data Controller for SAS© Evaluation Agreement</a
>.
</p>
</div>
<hr class="light" />
<clr-checkbox-wrapper>
<input clrCheckbox type="checkbox" (change)="termsAgreeChange()" />
<label
>I have read and agree to the terms of the
<a
href="https://docs.datacontroller.io/evaluation-licence-agreement"
target="_blank"
>Data Controller for SAS© Evaluation Agreement</a
></label
>
</clr-checkbox-wrapper>
</div>
</div>
}
</div>
<!-- T&C section end -->
@if (step > 0) {
@switch (true) {
@case (sasJsConfig.serverType === ServerType.SasViya) {
<div class="autodeploy-section card">
<app-automatic-deploy
[sasJs]="sasJs"
[sasJsConfig]="sasJsConfig"
[dcAdapterSettings]="dcAdapterSettings"
[appLoc]="appLoc"
[dcPath]="dcPath"
[selectedAdminGroup]="selectedAdminGroup"
(onNavigateToHome)="onNavigateToHome()"
></app-automatic-deploy>
</div>
}
@case (sasJsConfig.serverType === ServerType.Sasjs) {
<div class="autodeploy-section card">
<app-sasjs-configurator
[sasJs]="sasJs"
[sasJsConfig]="sasJsConfig"
[dcAdapterSettings]="dcAdapterSettings"
(onNavigateToHome)="onNavigateToHome()"
></app-sasjs-configurator>
</div>
}
@case (sasJsConfig.serverType === ServerType.Sas9) {
<div class="autodeploy-section card">
<app-sasjs-configurator
[sasJs]="sasJs"
[sasJsConfig]="sasJsConfig"
[dcAdapterSettings]="dcAdapterSettings"
(onNavigateToHome)="onNavigateToHome()"
></app-sasjs-configurator>
</div>
}
}
}
</main>
./deploy.component.scss