Display deployer base domain in overview tab

This commit is contained in:
Neeraj 2024-10-29 17:51:50 +05:30
parent 0f18bc978e
commit a70fc6ab71
7 changed files with 14 additions and 5 deletions

View File

@ -140,6 +140,7 @@ export class Database {
) )
.leftJoinAndSelect('deployments.createdBy', 'user') .leftJoinAndSelect('deployments.createdBy', 'user')
.leftJoinAndSelect('deployments.domain', 'domain') .leftJoinAndSelect('deployments.domain', 'domain')
.leftJoinAndSelect('deployments.deployer', 'deployer')
.leftJoinAndSelect('project.owner', 'owner') .leftJoinAndSelect('project.owner', 'owner')
.leftJoinAndSelect('project.deployers', 'deployers') .leftJoinAndSelect('project.deployers', 'deployers')
.leftJoinAndSelect('project.organization', 'organization') .leftJoinAndSelect('project.organization', 'organization')

View File

@ -143,6 +143,7 @@ type Deployer {
paymentAddress: String paymentAddress: String
createdAt: String! createdAt: String!
updatedAt: String! updatedAt: String!
baseDomain: String
} }
type AuthResult { type AuthResult {

View File

@ -41,6 +41,7 @@ const deployment: Deployment = {
deployerId: 'bafyreicrtgmkir4evvvysxdqxddf2ftdq2wrzuodgvwnxr4rmubi4obdfu', deployerId: 'bafyreicrtgmkir4evvvysxdqxddf2ftdq2wrzuodgvwnxr4rmubi4obdfu',
deployerLrn: 'lrn://example/deployers/webapp-deployer-api.example.com', deployerLrn: 'lrn://example/deployers/webapp-deployer-api.example.com',
minimumPayment: '1000alnt', minimumPayment: '1000alnt',
baseDomain: 'pwa.wireitin.com'
}, },
status: DeploymentStatus.Ready, status: DeploymentStatus.Ready,
createdBy: { createdBy: {

View File

@ -129,16 +129,16 @@ const OverviewTabPanel = () => {
<Heading className="text-lg leading-6 font-medium truncate"> <Heading className="text-lg leading-6 font-medium truncate">
{project.name} {project.name}
</Heading> </Heading>
{project.baseDomains && {project.deployments &&
project.baseDomains.length > 0 && project.deployments.length > 0 &&
project.baseDomains.map((baseDomain, index) => ( project.deployments.map((deployment, index) => (
<p> <p>
<a <a
key={index} key={index}
href={`https://${project.name.toLowerCase()}.${baseDomain}`} href={`https://${project.name.toLowerCase()}.${deployment.deployer.baseDomain}`}
className="text-sm text-elements-low-em tracking-tight truncate" className="text-sm text-elements-low-em tracking-tight truncate"
> >
{baseDomain} {deployment.deployer.baseDomain}
</a> </a>
</p> </p>
))} ))}

View File

@ -107,6 +107,7 @@ export const deployment0: Deployment = {
deployerId: 'bafyreicrtgmkir4evvvysxdqxddf2ftdq2wrzuodgvwnxr4rmubi4obdfu', deployerId: 'bafyreicrtgmkir4evvvysxdqxddf2ftdq2wrzuodgvwnxr4rmubi4obdfu',
deployerLrn: 'lrn://deployer.apps.snowballtools.com ', deployerLrn: 'lrn://deployer.apps.snowballtools.com ',
minimumPayment: '1000alnt', minimumPayment: '1000alnt',
baseDomain: 'pwa.wireitin.com'
}, },
applicationDeploymentRequestId: applicationDeploymentRequestId:
'bafyreiaycvq6imoppnpwdve4smj6t6ql5svt5zl3x6rimu4qwyzgjorize', 'bafyreiaycvq6imoppnpwdve4smj6t6ql5svt5zl3x6rimu4qwyzgjorize',
@ -134,6 +135,7 @@ export const project: Project = {
deployerId: 'bafyreicrtgmkir4evvvysxdqxddf2ftdq2wrzuodgvwnxr4rmubi4obdfu', deployerId: 'bafyreicrtgmkir4evvvysxdqxddf2ftdq2wrzuodgvwnxr4rmubi4obdfu',
deployerLrn: 'lrn://deployer.apps.snowballtools.com ', deployerLrn: 'lrn://deployer.apps.snowballtools.com ',
minimumPayment: '1000alnt', minimumPayment: '1000alnt',
baseDomain: 'pwa.wireitin.com'
}, },
], ],
paymentAddress: '0x657868687686rb4787987br8497298r79284797487', paymentAddress: '0x657868687686rb4787987br8497298r79284797487',

View File

@ -57,6 +57,9 @@ query ($projectId: String!) {
commitHash commitHash
createdAt createdAt
environment environment
deployer {
baseDomain
}
domain { domain {
status status
branch branch

View File

@ -119,6 +119,7 @@ export type Deployer = {
deployerLrn: string; deployerLrn: string;
deployerId: string; deployerId: string;
deployerApiUrl: string; deployerApiUrl: string;
baseDomain: string;
minimumPayment: string | null; minimumPayment: string | null;
} }