-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #102 from dfpc-coe/group-select
Mission CoTs
- Loading branch information
Showing
106 changed files
with
10,132 additions
and
1,550 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
import { Connection } from './schema.js'; | ||
import { InferSelectModel } from 'drizzle-orm'; | ||
|
||
export type ConnectionAuth = { | ||
cert: string; | ||
key: string; | ||
} | ||
|
||
export default interface ConnectionConfig { | ||
id: string | number; | ||
name: string; | ||
enabled: boolean; | ||
auth: ConnectionAuth; | ||
} | ||
|
||
export class MachineConnConfig implements ConnectionConfig { | ||
id: number; | ||
name: string; | ||
enabled: boolean; | ||
auth: ConnectionAuth; | ||
|
||
constructor(connection: InferSelectModel<typeof Connection>) { | ||
this.id = connection.id; | ||
this.name = connection.name; | ||
this.enabled = connection.enabled; | ||
this.auth = connection.auth; | ||
} | ||
} | ||
|
||
export class ProfileConnConfig implements ConnectionConfig { | ||
id: string; | ||
name: string; | ||
enabled: boolean; | ||
auth: ConnectionAuth; | ||
|
||
constructor( | ||
email: string, | ||
auth: ConnectionAuth | ||
) { | ||
this.id = email; | ||
this.name = email; | ||
this.enabled = true; | ||
this.auth = auth; | ||
} | ||
} | ||
|
Oops, something went wrong.