Update all pages to new angular format

This commit is contained in:
2025-08-07 17:44:28 -07:00
parent 6d81c001df
commit 8f70977a27
7 changed files with 183 additions and 137 deletions
@@ -1,58 +1,84 @@
<div class="top-bar">
<button *ngFor="let company of Employers" (click)="changeSelectedCompany(company.company.id!)">{{ company.company.name.toUpperCase() }}</button>
<button routerLink="/company/editor" >CONNECT A COMPANY</button>
@for(company of Employers; track company.accountID){
<button (click)="changeSelectedCompany(company.company.id!)">{{ company.company.name.toUpperCase() }}</button>
<button routerLink="/company/editor" >CONNECT A COMPANY</button>
}
</div>
<div class="content-frame">
<div *ngIf="Comp != null">
<button class="content-edit" style="color: #fff; border-color: #fff;" routerLink="/company/editor" [queryParams]="{ CompanyID: Comp.id }" >EDIT COMPANY</button>
<div class="center-item">
<a [href]="Comp.websiteURL">
<img [src]="Comp.logo" />
</a>
</div>
<div class="center-item">
<div class="content-link"><a [href]="'mailto:' + Comp.email" >{{ Comp.email }}</a></div>
<div class="content-name"><h1>{{ Comp.name }}</h1></div>
<div class="content-link"><a [href]="'tel:' + Comp.phone">{{ Comp.phone }}</a></div>
</div>
<div class="center-item">
<h1>{{ Comp.city }}, {{ Comp.stateOrRegion }} {{ Comp.postalCode }}</h1>
</div>
<div class="content-desc">
<h1 *ngFor="let line of Desc">{{ line }}</h1>
</div>
<div class="content-button" *ngIf="Comp.emailVerified">
<button style="color: #fff; border-color: #fff;" routerLink="/jobs/editor" [queryParams]="{ CompanyID: Comp.id }" >POST JOB</button>
</div>
<div class="content-button" *ngIf="!Comp.emailVerified">
<a style="color: #fff; border-color: #fff;" [href]="'/api/company/sendverifyemail?CompanyID=' + Comp.id" >VERIFY EMAIL></a>
<span>You must verify your company email before you can post job listings.</span>
</div>
<hr />
<div class="split-frame">
<div class="half-frame">
<h2>Active Job Listings</h2>
<div class="job-tile" *ngFor="let listing of List">
<div class="center-text">
<h1>{{ listing.title }}</h1>
</div>
<button [routerLink]="['/jobs/viewer']" [queryParams]="{ JobID: listing.id }" >VIEW LISTING</button>
<button [routerLink]="['/jobs/editor']" [queryParams]="{ JobID: listing.id }" >EDIT LISTING</button>
<button (click)="RemoveJobListing(listing.id!)">DELETE LISTING</button>
</div>
@if(Comp != null){
<div>
<button class="content-edit" style="color: #fff; border-color: #fff;" routerLink="/company/editor" [queryParams]="{ CompanyID: Comp.id }" >EDIT COMPANY</button>
<div class="center-item">
<a [href]="Comp.websiteURL">
<img [src]="Comp.logo" />
</a>
</div>
<div class="half-frame">
<h2>Employees</h2>
@for (listing of CompEmployees; track listing.id) {
<div class="job-tile">
<div class="center-text">
<h1>{{ listing.accountName }}</h1>
</div>
<button [routerLink]="['/']" [queryParams]="{ JobID: listing.id }" >REMOVE</button>
<button (click)="RemoveJobListing(listing.id!)">DELETE LISTING</button>
</div>
<div class="center-item">
<div class="content-link"><a [href]="'mailto:' + Comp.email" >{{ Comp.email }}</a></div>
<div class="content-name"><h1>{{ Comp.name }}</h1></div>
<div class="content-link"><a [href]="'tel:' + Comp.phone">{{ Comp.phone }}</a></div>
</div>
<div class="center-item">
<h1>{{ Comp.city }}, {{ Comp.stateOrRegion }} {{ Comp.postalCode }}</h1>
</div>
<div class="content-desc">
@for (line of Desc; track line.length){
<h1>{{ line }}</h1>
}
</div>
<hr />
<div class="split-frame">
<div class="half-frame">
@if (Comp.emailVerified){
<div class="content-button">
<button style="color: #fff; border-color: #fff;" routerLink="/jobs/editor" [queryParams]="{ CompanyID: Comp.id }" >POST JOB</button>
</div>
} @else {
<div class="content-button">
<a style="color: #fff; border-color: #fff;" [href]="'/api/company/sendverifyemail?CompanyID=' + Comp.id" >VERIFY EMAIL></a>
<span>You must verify your company email before you can post job listings.</span>
</div>
}
<hr />
<h2>Active Job Listings</h2>
@for (listing of List; track listing.id) {
<div class="job-tile">
<div class="center-text">
<h1>{{ listing.title }}</h1>
</div>
<button [routerLink]="['/jobs/viewer']" [queryParams]="{ JobID: listing.id }" >VIEW LISTING</button>
<button [routerLink]="['/jobs/editor']" [queryParams]="{ JobID: listing.id }" >EDIT LISTING</button>
<button (click)="RemoveJobListing(listing.id!)">DELETE LISTING</button>
</div>
}
</div>
<div class="half-frame">
@if (Comp.emailVerified){
<div class="content-button">
<button style="color: #fff; border-color: #fff;" routerLink="/jobs/editor" [queryParams]="{ CompanyID: Comp.id }" >ADD EMPLOYEE</button>
</div>
} @else {
<div class="content-button">
<a style="color: #fff; border-color: #fff;" [href]="'/api/company/sendverifyemail?CompanyID=' + Comp.id" >VERIFY EMAIL></a>
<span>You must verify your company email before you can post job listings.</span>
</div>
}
<hr />
<h2>Employees</h2>
@for (listing of CompEmployees; track listing.id) {
<div class="job-tile">
<div class="center-text">
<h1>{{ listing.accountName }}</h1>
</div>
@if (listing.accountID != auth.loggedInUser.id){
<button (click)="RemoveJobListing(listing.id!)">Remove</button>
} @else {
<button disabled>SELF</button>
}
</div>
}
</div>
</div>
</div>
</div>
}
</div>
@@ -148,9 +148,11 @@
<span>postal code: {{ newListing.postalCode }}</span>
</div>
</div>
<div *ngFor="let descLine of newListing.description.split('\n')">
<span>{{ descLine }}</span><br />
</div>
@for(descLine of newListing.description.split('\n'); track descLine.length){
<div>
<span>{{ descLine }}</span><br />
</div>
}
</div>
<div class="content-frame">
<button type="button" (click)="prevStep()">Back</button>
@@ -40,35 +40,37 @@
</div>
<!-- Location -->
<div #step *ngIf="!Listing.remote" class="sub-frame">
<div class="center">
<h2>Job Location</h2>
<div>
<div class="content-frame split" style="border-radius: 10px 10px 0 0;">
<div class="half-frame">
<label>City</label>
<input name="city" [(ngModel)]="Listing.city" type="text" />
@if(!Listing.remote){
<div #step class="sub-frame">
<div class="center">
<h2>Job Location</h2>
<div>
<div class="content-frame split" style="border-radius: 10px 10px 0 0;">
<div class="half-frame">
<label>City</label>
<input name="city" [(ngModel)]="Listing.city" type="text" />
</div>
<div class="half-frame">
<label>2 Letter State/Region</label>
<input name="stateOrRegion" maxlength="2" minlength="2" [(ngModel)]="Listing.stateOrRegion" type="text" />
</div>
</div>
<div class="half-frame">
<label>2 Letter State/Region</label>
<input name="stateOrRegion" maxlength="2" minlength="2" [(ngModel)]="Listing.stateOrRegion" type="text" />
<div class="content-frame split" style="border-radius: 0 0 10px 10px;">
<div class="half-frame">
<label>2 Letter Country</label>
<input name="country" maxlength="2" minlength="2" [(ngModel)]="Listing.country" type="text" />
</div>
<div class="half-frame">
<label>Postal Code</label>
<input name="postalCode" [(ngModel)]="Listing.postalCode" type="text" />
</div>
</div>
<button type="button" (click)="prevStep()">Back</button>
<button type="button" (click)="nextStep()">Next</button>
</div>
<div class="content-frame split" style="border-radius: 0 0 10px 10px;">
<div class="half-frame">
<label>2 Letter Country</label>
<input name="country" maxlength="2" minlength="2" [(ngModel)]="Listing.country" type="text" />
</div>
<div class="half-frame">
<label>Postal Code</label>
<input name="postalCode" [(ngModel)]="Listing.postalCode" type="text" />
</div>
</div>
<button type="button" (click)="prevStep()">Back</button>
<button type="button" (click)="nextStep()">Next</button>
</div>
</div>
</div>
}
<!-- Salary Range -->
<div #step class="sub-frame">
@@ -1,20 +1,24 @@
<!-- Avaliable Jobs -->
<div class="tile-frame" *ngFor="let cur of JobListingPage">
<div class="tile">
<div class="tile-title">
<h1>{{ cur.title }}</h1>
<h2>${{ cur.salaryMin }} - ${{ cur.salaryMax }}</h2>
</div>
<div class="tile-split">
<h1>{{ cur.jobType }}</h1>
<h1 *ngIf="cur.remote" >Remote</h1>
</div>
<div class="tile-split">
<h1>{{ cur.city }}</h1>
<h1>{{ cur.stateOrRegion }}</h1>
</div>
<div class="tile-button">
<button [routerLink]="['/jobs/viewer']" [queryParams]="{ JobID: cur.id }" >VIEW LISTING</button>
@for (cur of JobListingPage; track cur.id){
<div class="tile-frame">
<div class="tile">
<div class="tile-title">
<h1>{{ cur.title }}</h1>
<h2>${{ cur.salaryMin }} - ${{ cur.salaryMax }}</h2>
</div>
<div class="tile-split">
<h1>{{ cur.jobType }}</h1>
@if(cur.remote){
<h1>Remote</h1>
}
</div>
<div class="tile-split">
<h1>{{ cur.city }}</h1>
<h1>{{ cur.stateOrRegion }}</h1>
</div>
<div class="tile-button">
<button [routerLink]="['/jobs/viewer']" [queryParams]="{ JobID: cur.id }" >VIEW LISTING</button>
</div>
</div>
</div>
</div>
}
@@ -1,45 +1,53 @@
<div class="job-frame">
<div class="company-details" *ngIf="jobsCompany != null" >
<div class="center-item">
<a [href]="jobsCompany.websiteURL">
<img [src]="jobsCompany.logo" />
</a>
</div>
<div class="center-item">
<div class="content-link"><a [href]="'mailto:' + jobsCompany.email" >{{ jobsCompany.email }}</a></div>
<div class="content-name"><h1>{{ jobsCompany.name }}</h1></div>
<div class="content-link"><a [href]="'tel:' + jobsCompany.phone">{{ jobsCompany.phone }}</a></div>
</div>
<div class="center-item">
<h1>{{ jobsCompany.city }}, {{ jobsCompany.stateOrRegion }} {{ jobsCompany.postalCode }}</h1>
</div>
<div class="content-desc">
<h1 *ngFor="let line of jobsCompany.description.split('\n')">{{ line }}</h1>
</div>
</div>
<div class="job-details" *ngIf="selectedJob != null" >
<div class="job-timestamp">
<h1>Opened: {{ selectedJob.createdTime }}</h1>
<h1>Modified: {{ selectedJob.modifiedTime }}</h1>
@if (jobsCompany != null){
<div class="company-details">
<div class="center-item">
<a [href]="jobsCompany.websiteURL">
<img [src]="jobsCompany.logo" />
</a>
</div>
<div class="center-item">
<div class="content-link"><a [href]="'mailto:' + jobsCompany.email" >{{ jobsCompany.email }}</a></div>
<div class="content-name"><h1>{{ jobsCompany.name }}</h1></div>
<div class="content-link"><a [href]="'tel:' + jobsCompany.phone">{{ jobsCompany.phone }}</a></div>
</div>
<div class="center-item">
<h1>{{ jobsCompany.city }}, {{ jobsCompany.stateOrRegion }} {{ jobsCompany.postalCode }}</h1>
</div>
<div class="content-desc">
@for(line of jobsCompany.description.split('\n'); track line.length){
<h1>{{ line }}</h1>
}
</div>
</div>
}
@if (selectedJob != null) {
<div class="job-details">
<div class="job-timestamp">
<h1>Opened: {{ selectedJob.createdTime }}</h1>
<h1>Modified: {{ selectedJob.modifiedTime }}</h1>
</div>
<div class="job-warning" *ngIf="selectedJob.isDeleted" >
<h2>THIS JOB POSTING IS CLOSED</h2>
@if (selectedJob.isDeleted){
<div class="job-warning">
<h2>THIS JOB POSTING IS CLOSED</h2>
</div>
}
<h1>{{ selectedJob.title }}</h1>
<h1>{{ selectedJob.jobType }}</h1>
<h1>{{ selectedJob.remote }}</h1>
<h1>{{ selectedJob.salaryMin }}</h1>
<h1>{{ selectedJob.salaryMax }}</h1>
<h1>{{ selectedJob.city }}</h1>
<h1>{{ selectedJob.stateOrRegion }}</h1>
<h1>{{ selectedJob.country }}</h1>
<h1>{{ selectedJob.postalCode }}</h1>
<h1>{{ selectedJob.description }}</h1>
</div>
<h1>{{ selectedJob.title }}</h1>
<h1>{{ selectedJob.jobType }}</h1>
<h1>{{ selectedJob.remote }}</h1>
<h1>{{ selectedJob.salaryMin }}</h1>
<h1>{{ selectedJob.salaryMax }}</h1>
<h1>{{ selectedJob.city }}</h1>
<h1>{{ selectedJob.stateOrRegion }}</h1>
<h1>{{ selectedJob.country }}</h1>
<h1>{{ selectedJob.postalCode }}</h1>
<h1>{{ selectedJob.description }}</h1>
</div>
}
</div>
@@ -1,4 +1,6 @@
<!-- My Resumes -->
<div *ngIf="auth.isLoggedIn" class="jobs-frame">
@if (auth.isLoggedIn){
<div class="jobs-frame">
</div>
</div>
}