src/app/deploy/deploy.component.ts

Implements

OnInit

Metadata

Relationships

Used by

Depends on

Index

Properties
Methods

Constructor

constructor(appStoreService: AppStoreService, sasService: SasService)
Parameters :
Name Type Optional
appStoreService AppStoreService No
sasService SasService No

Methods

ngOnInit
ngOnInit()
Returns : void
Public onNavigateToHome
onNavigateToHome()
Returns : void
Public setDeployDefaults
setDeployDefaults()

Setting default values used for deploy request

Returns : void
Public termsAgreeChange
termsAgreeChange()

Accepting terms of service shows next screen

Returns : void

Properties

Public appLoc
Type : string
Default value : ''
Public dcAdapterSettings
Type : DcAdapterSettings | undefined
Public dcPath
Type : string
Default value : ''
Public sasJs
Type : any
Public sasJsConfig
Type : SASjsConfig
Default value : new SASjsConfig()
Public selectedAdminGroup
Type : string
Default value : ''
ServerType
Type : unknown
Default value : ServerType
Public step
Type : number
Default value : 0
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&#169; 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&#169; 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

Legend
Html element
Component
Html element with directive

results matching ""

    No results matching ""