You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
45 lines
1.2 KiB
TypeScript
45 lines
1.2 KiB
TypeScript
import { Component, OnInit } from '@angular/core';
|
|
import { CommonService } from 'src/app/hmg-common/services/common/common.service';
|
|
import { ModalController } from '@ionic/angular';
|
|
import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service';
|
|
|
|
@Component({
|
|
selector: 'app-more-action-modal',
|
|
templateUrl: './more-action-modal.component.html',
|
|
styleUrls: ['./more-action-modal.component.scss'],
|
|
})
|
|
export class MoreActionModalComponent implements OnInit {
|
|
actionBtns :any =[];
|
|
radioButtonValue: any;
|
|
constructor( public ts: TranslatorService,private modalCtrl: ModalController, private cs: CommonService){}
|
|
|
|
ngOnInit() {
|
|
console.log("modal");
|
|
this.actionBtns = this.cs.sharedService.getSharedData("passActionMore" , false);
|
|
console.log("modal");
|
|
|
|
}
|
|
closeModal() {
|
|
this.modalCtrl.dismiss();
|
|
}
|
|
|
|
radioSelect(v) {
|
|
this.radioButtonValue = v;
|
|
console.log("radio selected"+v);
|
|
}
|
|
|
|
OkBtnModal() {
|
|
if (!this.radioButtonValue) {
|
|
let msg: string = this.ts.trPK("replacementRoll", "msg");
|
|
this.cs.presentAlert(msg);
|
|
return;
|
|
} else {
|
|
let data = this.radioButtonValue;
|
|
this.modalCtrl.dismiss(data);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
}
|