App credential to string type

This commit is contained in:
MaxKey
2022-11-04 21:13:31 +08:00
parent 9bf04827e0
commit 6bd2231a1c
7 changed files with 76 additions and 74 deletions

View File

@@ -19,65 +19,64 @@ import format from 'date-fns/format';
import { BaseEntity } from './BaseEntity';
export class Apps extends BaseEntity {
appName!: String;
loginUrl!: String;
category!: String;
protocol!: String;
secret!: String;
iconBase64!: String;
visible!: String;
inducer!: String;
vendor!: String;
vendorUrl!: String;
credential!: String;
sharedUsername!: String;
sharedPassword!: String;
systemUserAttr!: String;
principal!: String;
credentials!: String;
appName!: String;
loginUrl!: String;
category!: String;
protocol!: String;
secret!: String;
iconBase64!: String;
visible!: String;
inducer!: String;
vendor!: String;
vendorUrl!: String;
credential!: String;
sharedUsername!: String;
sharedPassword!: String;
systemUserAttr!: String;
principal!: String;
credentials!: String;
logoutUrl!: String;
logoutType!: String;
isExtendAttr!: String;
extendAttr!: String;
userPropertys!: String;
isSignature!: String;
isAdapter!: String;
adapterId!: String;
adapterName!: String;
adapter!: String;
iconId!: String;
frequently!: String;
logoutUrl!: String;
logoutType!: String;
isExtendAttr!: String;
extendAttr!: String;
resourceMgt!: String;
userPropertys!: String;
isSignature!: String;
isAdapter!: String;
adapterId!: String;
adapterName!: String;
adapter!: String;
iconId!: String;
frequently!: String;
select_userPropertys!: String[];
select_userPropertys!: String[];
constructor() {
super();
this.category = 'none';
this.visible = '0';
this.isAdapter = '0';
this.logoutType = '0';
this.frequently = 'no';
constructor() {
super();
this.category = 'none';
this.frequently = 'no';
this.resourceMgt = 'false';
this.visible = '0';
this.isAdapter = '0';
this.logoutType = '0';
this.isExtendAttr = '0';
}
override init(data: any): void {
Object.assign(this, data);
if (this.status == 1) {
this.switch_status = true;
} else {
this.switch_status = false;
}
}
override init(data: any): void {
Object.assign(this, data);
if (this.status == 1) {
this.switch_status = true;
} else {
this.switch_status = false;
}
this.isAdapter = `${data.isAdapter}`;
this.isExtendAttr = `${data.isExtendAttr}`;
this.logoutType = `${data.logoutType}`;
this.visible = `${data.visible}`;
}
override trans(): void {
if (this.switch_status) {
this.status = 1;
} else {
this.status = 0;
}
override trans(): void {
if (this.switch_status) {
this.status = 1;
} else {
this.status = 0;
}
}
}