diff --git a/.vscode/tasks.json b/.vscode/tasks.json
index 1866296..8aa7b2c 100644
--- a/.vscode/tasks.json
+++ b/.vscode/tasks.json
@@ -22,6 +22,7 @@
},
"args": [
"build",
+ "--configuration=development",
"--base-href=http://localhost:5000"
],
"problemMatcher": "$msCompile"
diff --git a/ToDo.yaml b/ToDo.yaml
index e5128e5..9e59b7b 100755
--- a/ToDo.yaml
+++ b/ToDo.yaml
@@ -35,4 +35,10 @@ Task:
Create a server table inside the auth database
Point all requests after auth to the correct regional server. -> Currently only Mistox-West exists
- CompanyConnect | need to lookup company before making a new one
\ No newline at end of file
+ CompanyConnect | need to lookup company before making a new one
+
+ Finish Auth setup
+ Make sure autorenew works
+
+ Jobs/editor w/ Querystring JobID=# is not implimented yet
+ Company -> Edit employees not implimented yet
\ No newline at end of file
diff --git a/database/mistox.sql b/database/mistox.sql
index 995ee57..4f83a81 100755
--- a/database/mistox.sql
+++ b/database/mistox.sql
@@ -1,25 +1,6 @@
CREATE DATABASE IF NOT EXISTS `boredcareers`;
USE `boredcareers`;
--- Account Section
-
-CREATE TABLE IF NOT EXISTS `Account` (
- `ID` int NOT NULL AUTO_INCREMENT,
- `UserName` varchar(60) NOT NULL,
- `Email` varchar(255) NOT NULL,
- `EmailVerified` boolean DEFAULT 0,
- `PasswordHash` char(60) DEFAULT NULL,
- `FailedPasswordLock` boolean DEFAULT 0,
- `PasswordAttempts` int(11) DEFAULT NULL,
- `CurrentPasswordAttempts` int(11) DEFAULT NULL,
- `Role` varchar(45) DEFAULT NULL,
- `EmailToken` varchar(45) DEFAULT NULL,
- `DataServer` varchar(200) DEFAULT NULL,
- UNIQUE(`Email`),
- UNIQUE(`UserName`),
- PRIMARY KEY (`ID`)
-) AUTO_INCREMENT=1;
-
-- Resume Section
CREATE TABLE IF NOT EXISTS `Resume` (
diff --git a/src/Client/src/app/app.html b/src/Client/src/app/app.html
index 70d5048..369369b 100644
--- a/src/Client/src/app/app.html
+++ b/src/Client/src/app/app.html
@@ -1,19 +1,24 @@
diff --git a/src/Client/src/app/app.routes.ts b/src/Client/src/app/app.routes.ts
index 1a884a2..8331146 100644
--- a/src/Client/src/app/app.routes.ts
+++ b/src/Client/src/app/app.routes.ts
@@ -5,23 +5,29 @@ import { ContactComponent } from './pages/legal/contact/contact.component';
import { PrivacyComponent } from './pages/legal/privacy/privacy.component';
import { JobsComponent } from './pages/main/jobs/jobs.component';
import { ResumesComponent } from './pages/main/resumes/resumes.component';
-import { JobNewComponent } from './pages/main/jobs/new/jobnew.component';
-import { JobEditComponent } from './pages/main/jobs/edit/jobedit.component';
+import { JobEditorComponent } from './pages/main/jobs/editor/jobeditor.component';
import { CompanyConnectComponent } from './pages/main/company/connect/companyconnect.component';
+import { JobViewerComponent } from './pages/main/jobs/viewer/jobviewer.component';
+import { CompanyJobsComponent } from './pages/main/company/jobs/jobs.component';
+import { CompanyComponent } from './pages/main/company/company.component';
export const routes: Routes = [
// Home
{ path: "", component: HomeComponent },
+
+ // Resumes
{ path: "resumes", component: ResumesComponent },
// Jobs
{ path: "jobs", component: JobsComponent },
- { path: "jobs/new", component: JobNewComponent },
- { path: "jobs/edit", component: JobEditComponent },
+ { path: "jobs/editor", component: JobEditorComponent },
+ { path: "jobs/viewer", component: JobViewerComponent },
// Company
+ { path: "company", component: CompanyComponent },
{ path: "company/connect", component: CompanyConnectComponent },
+ { path: "company/jobs", component: CompanyJobsComponent },
// Legal
{ path: "about", component: AboutComponent },
diff --git a/src/Client/src/app/app.ts b/src/Client/src/app/app.ts
index bcba189..7c72022 100644
--- a/src/Client/src/app/app.ts
+++ b/src/Client/src/app/app.ts
@@ -3,6 +3,7 @@ import { Router, RouterModule, RouterOutlet, ActivatedRoute } from '@angular/rou
import { Authentication } from './services/Authentication';
import { CommonModule, Location } from '@angular/common';
import { HttpClient } from '@angular/common/http';
+import { isDevMode } from '@angular/core';
@Component({
selector: 'app-root',
@@ -12,11 +13,16 @@ import { HttpClient } from '@angular/common/http';
})
export class App {
- @ViewChild('homeLink') homeLink!: ElementRef
;
+ @ViewChild('companiesLink') companiesLink!: ElementRef;
@ViewChild('jobsLink') jobLink!: ElementRef;
@ViewChild('resumesLink') resumeLink!: ElementRef;
+ devMode: boolean = false;
+
constructor( private http: HttpClient, public auth: Authentication, private router: Router, private route: ActivatedRoute, private location: Location){
+
+ this.devMode = isDevMode();
+
this.route.queryParams.subscribe(params => {
const loginToken = params['LoginToken'];
@@ -43,7 +49,7 @@ export class App {
}
ngAfterViewInit(){
- let ViewLinks = [ this.homeLink, this.resumeLink, this.jobLink ];
+ let ViewLinks = [ this.companiesLink, this.resumeLink, this.jobLink ];
ViewLinks.forEach(link => {
if (new URL(link.nativeElement.href).pathname === new URL(window.location.href).pathname){
link.nativeElement.classList.add("active");
diff --git a/src/Client/src/app/models/Company.ts b/src/Client/src/app/models/Company.ts
index 4ceca30..d0762ca 100644
--- a/src/Client/src/app/models/Company.ts
+++ b/src/Client/src/app/models/Company.ts
@@ -1,5 +1,5 @@
export class Company {
- public id: number = 0;
+ public id: number = -1;
public name: string = "";
public email: string = "";
public emailVerified: boolean = false;
@@ -14,7 +14,7 @@ export class Company {
}
export class Employee {
- public id: number = 0;
+ public id: number = -1;
public accountID: number = 0;
public company: Company = new Company;
}
\ No newline at end of file
diff --git a/src/Client/src/app/models/JobListing.ts b/src/Client/src/app/models/JobListing.ts
index 3aae717..18b9427 100644
--- a/src/Client/src/app/models/JobListing.ts
+++ b/src/Client/src/app/models/JobListing.ts
@@ -1,5 +1,5 @@
export class JobListing {
- public id: number = 0;
+ public id: number = -1;
public companyID: number = 0;
public title: string = "";
public postalCode: string = "";
diff --git a/src/Client/src/app/models/Resume.ts b/src/Client/src/app/models/Resume.ts
index ef68ba7..4ac970f 100644
--- a/src/Client/src/app/models/Resume.ts
+++ b/src/Client/src/app/models/Resume.ts
@@ -1,5 +1,5 @@
export class Resume {
- public id: number = 0;
+ public id: number = -1;
public accountID: number = 0;
public name: string = "";
public field: string = "";
@@ -20,7 +20,7 @@ export class Resume {
}
export class ResumeExperience {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
jobTitle: string = "";
company: string = "";
@@ -35,14 +35,14 @@ export class ResumeExperience {
}
export class ResumeExperienceBullet {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
resumeExperienceID: number = 0;
jobFunction: string = "";
}
export class ResumeMilitary {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
country: string = "";
rank: string = "";
@@ -53,7 +53,7 @@ export class ResumeMilitary {
}
export class ResumeMilitaryBullet {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
resumeMilitaryID: number = 0;
achievement: string = "";
@@ -61,7 +61,7 @@ export class ResumeMilitaryBullet {
}
export class ResumeEducation {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
degreeType: string = "";
degreeField: string = "";
@@ -76,21 +76,21 @@ export class ResumeEducation {
}
export class ResumeSkill {
- id: number = 0; // PK
- resumeID: number = 0; // FK
+ id: number = -1;
+ resumeID: number = 0;
name: string = "";
description: string = "";
}
export class ResumeLanguage {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
language: string = "";
proficiency: string = "";
}
export class ResumeCertification {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
name: string = "";
verificationURL: string = "";
@@ -98,7 +98,7 @@ export class ResumeCertification {
}
export class ResumeProject {
- id: number = 0;
+ id: number = -1;
resumeID: number = 0;
name: string = "";
url: string = "";
diff --git a/src/Client/src/app/pages/main/company/company.component.css b/src/Client/src/app/pages/main/company/company.component.css
new file mode 100644
index 0000000..4263503
--- /dev/null
+++ b/src/Client/src/app/pages/main/company/company.component.css
@@ -0,0 +1,33 @@
+button {
+ height: 45px;
+ border-radius: 5px;
+ margin: 10px;
+ text-align: center;
+ padding: 15px 20px;
+ transition: 0.5s;
+ background-color: #00000000;
+ border: 1px solid var(--Mistox-Black);
+ color: var(--Mistox-Black);
+ text-decoration: none;
+ font: inherit;
+}
+
+ button:hover {
+ background-color: #00000044;
+ color: var(--Mistox-Light);
+ }
+
+.top-bar {
+ width: 100%;
+ height: 60px;
+}
+
+.content-frame {
+ background-color: #3c3c3c;
+ width: calc(100% - 40px);
+ height: calc(100vh - 400px);
+ border-radius: 20px;
+ margin: 10px;
+ overflow: scroll;
+ padding: 10px;
+}
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/company/company.component.html b/src/Client/src/app/pages/main/company/company.component.html
new file mode 100644
index 0000000..f2be310
--- /dev/null
+++ b/src/Client/src/app/pages/main/company/company.component.html
@@ -0,0 +1,20 @@
+
+ {{ company.company.name.toUpperCase() }}
+ CONNECT A COMPANY
+
+
+
+
{{ Comp.name }}
+ {{ Comp.email }}
+ {{ Comp.emailVerified }}
+ {{ Comp.websiteURL }}
+ {{ Comp.logoURL }}
+ {{ Comp.phone }}
+ {{ Comp.postalCode }}
+ {{ Comp.country }}
+ {{ Comp.stateOrRegion }}
+ {{ Comp.city }}
+ {{ Comp.description }}
+ ACTIVE JOB LISTINGS
+
+
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/company/company.component.ts b/src/Client/src/app/pages/main/company/company.component.ts
new file mode 100644
index 0000000..dc8ee16
--- /dev/null
+++ b/src/Client/src/app/pages/main/company/company.component.ts
@@ -0,0 +1,46 @@
+import { Component } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+import { FormsModule } from '@angular/forms';
+import { Router, ActivatedRoute, RouterModule } from '@angular/router';
+import { Title } from '@angular/platform-browser';
+import { CommonModule } from '@angular/common';
+import { Authentication } from 'app/services/Authentication';
+import { Company, Employee } from 'app/models/Company';
+
+@Component({
+ selector: 'main-company',
+ templateUrl: './company.component.html',
+ styleUrls: [ './company.component.css' ],
+ imports: [ FormsModule, CommonModule, RouterModule ]
+})
+export class CompanyComponent {
+ public ErrorMsg: string = "";
+
+ public Employers: Employee[] = [];
+ public Comp: Company | null = null;
+
+ constructor( private http: HttpClient, private router: Router, private route: ActivatedRoute, private title: Title, public auth: Authentication ) {
+ this.title.setTitle("Companies | BoredCareers");
+ http.get("api/employee/").subscribe({
+ next: data => {
+ this.Employers = data;
+ },
+ error: err => {
+ this.ErrorMsg = err.error;
+ }
+ });
+
+ };
+
+ changeSelectedCompany(companyID: number){
+ this.http.get("api/company?CompanyID=" + companyID).subscribe({
+ next: data => {
+ this.Comp = data;
+ },
+ error: err => {
+ this.ErrorMsg = err.error;
+ }
+ });
+ }
+
+}
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/company/jobs/jobs.component.css b/src/Client/src/app/pages/main/company/jobs/jobs.component.css
new file mode 100644
index 0000000..6044df9
--- /dev/null
+++ b/src/Client/src/app/pages/main/company/jobs/jobs.component.css
@@ -0,0 +1,87 @@
+button {
+ width: 150px;
+ border-radius: 5px;
+ margin: 10px;
+ text-align: center;
+ padding: 15px 0;
+ transition: .5s;
+ background-color: #0000;
+ border: 1px solid var(--Mistox-White);
+ color: var(--Mistox-White);
+ text-decoration: none;
+}
+
+ button:hover {
+ background-color: #00000044;
+ color: var(--Mistox-Light);
+ }
+
+.full-width {
+ display: block;
+ width: 100%;
+ column-count: 2;
+}
+
+.tile-frame {
+ display: grid;
+ grid-template-columns: repeat(4, 1fr);
+ column-gap: 20px;
+ padding: 20px;
+ width: calc(100% - 40px);
+}
+
+.tile{
+ background-color: var(--Mistox-Dark);
+ color: var(--Mistox-White);
+ break-inside: avoid;
+ padding: 20px;
+ border-radius: 20px;
+ margin-bottom: 20px;
+}
+
+.jobs-frame {
+ width: 100%;
+ background-color: #8888;
+ border-top: 2px solid black;
+}
+
+.post-job-frame {
+ display: flex;
+ justify-content: center;
+ padding: 10px 0;
+}
+
+.tile-title {
+ text-align: center;
+ border-bottom: 1px solid;
+}
+
+.tile-title h1 {
+ font-size: 40px;
+ margin: 5px 0;
+}
+
+.tile-title h2 {
+ font-size: 14px;
+}
+
+.tile-split {
+ columns: 2;
+ text-align: center;
+ padding: 10px 0;
+}
+
+.tile-split h1 {
+ margin: 0;
+}
+
+.tile-button {
+ display: flex;
+ width: 100%;
+ justify-content: center;
+}
+
+.post-job-frame button {
+ border-color: var(--Mistox-Black);
+ color: var(--Mistox-Black);
+}
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/company/jobs/jobs.component.html b/src/Client/src/app/pages/main/company/jobs/jobs.component.html
new file mode 100644
index 0000000..70552be
--- /dev/null
+++ b/src/Client/src/app/pages/main/company/jobs/jobs.component.html
@@ -0,0 +1,23 @@
+
+ POST JOB
+
+
+
+
+
+
{{ cur.title }}
+ {{ cur.jobType }}
+ Is Remote: {{ cur.remote }}
+ {{ cur.salaryMin }}
+ {{ cur.salaryMax }}
+ {{ cur.city }}
+ {{ cur.stateOrRegion }}
+ {{ cur.country }}
+ {{ cur.postalCode }}
+ Posted: {{ cur.createdTime }}
+ Modified: {{ cur.modifiedTime }}
+
+
EDIT
+
DELETE
+
+
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/jobs/edit/jobedit.component.ts b/src/Client/src/app/pages/main/company/jobs/jobs.component.ts
similarity index 58%
rename from src/Client/src/app/pages/main/jobs/edit/jobedit.component.ts
rename to src/Client/src/app/pages/main/company/jobs/jobs.component.ts
index 5b108a1..d81f192 100644
--- a/src/Client/src/app/pages/main/jobs/edit/jobedit.component.ts
+++ b/src/Client/src/app/pages/main/company/jobs/jobs.component.ts
@@ -8,35 +8,34 @@ import { JobListing } from 'app/models/JobListing';
import { Authentication } from 'app/services/Authentication';
@Component({
- selector: 'main-jobs-edit',
- templateUrl: './jobedit.component.html',
- styleUrls: [ './jobedit.component.css' ],
+ selector: 'main-company-jobs',
+ templateUrl: './jobs.component.html',
+ styleUrls: [ './jobs.component.css' ],
imports: [ FormsModule, CommonModule, RouterModule ]
})
-export class JobEditComponent {
+export class CompanyJobsComponent {
public MyJobListings: JobListing[] = [];
- public JobListingPage: JobListing[] = [];
public ErrorMsg: string = "";
- public Page: number = 1;
-
constructor( private http: HttpClient, private router: Router, private route: ActivatedRoute, private title: Title, public auth: Authentication ) {
- this.title.setTitle("Jobs - edit | BoredCareers");
-
- if (this.Page == 1){
-
- }
-
- http.get("api/joblisting?PageQuantity=" + 10 + "&Page=" + 1).subscribe({
- next: data => {
- this.JobListingPage = data;
- },
- error: err => {
- this.ErrorMsg = err.error;
- }
- });
+ this.title.setTitle("Company - Jobs | BoredCareers");
+ this.route.queryParams.subscribe(params => {
+ const companyID = params['CompanyID'];
+ if (companyID){
+ http.get("api/joblisting/company?CompanyID=" + companyID).subscribe({
+ next: data => {
+ this.MyJobListings = data;
+ },
+ error: err => {
+ this.ErrorMsg = err.error;
+ }
+ });
+ }else{
+ router.navigate(["/company"]);
+ }
+ });
};
RemoveJobListing( JobListingID: number ){
diff --git a/src/Client/src/app/pages/main/jobs/edit/jobedit.component.css b/src/Client/src/app/pages/main/jobs/edit/jobedit.component.css
deleted file mode 100644
index 9d97a2c..0000000
--- a/src/Client/src/app/pages/main/jobs/edit/jobedit.component.css
+++ /dev/null
@@ -1,12 +0,0 @@
-.tile-frame {
- column-count: 4;
- column-gap: 20px;
- padding: 20px;
- width: calc(100% - 40px);
-}
-
-.tile{
- background-color: var(--Mistox-Dark)\);
- height: 40px;
- break-inside: avoid;
-}
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/jobs/edit/jobedit.component.html b/src/Client/src/app/pages/main/jobs/edit/jobedit.component.html
deleted file mode 100644
index 05e4dca..0000000
--- a/src/Client/src/app/pages/main/jobs/edit/jobedit.component.html
+++ /dev/null
@@ -1,16 +0,0 @@
-
-
-
{{ cur.title }}
- {{ cur.jobType }}
- Is Remote: {{ cur.remote }}
- {{ cur.salaryMin }}
- {{ cur.salaryMax }}
- {{ cur.city }}
- {{ cur.stateOrRegion }}
- {{ cur.country }}
- {{ cur.postalCode }}
- {{ cur.description }}
- Posted: {{ cur.createdTime }}
- Modified: {{ cur.modifiedTime }}
-
-
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/jobs/new/jobnew.component.css b/src/Client/src/app/pages/main/jobs/editor/jobeditor.component.css
similarity index 100%
rename from src/Client/src/app/pages/main/jobs/new/jobnew.component.css
rename to src/Client/src/app/pages/main/jobs/editor/jobeditor.component.css
diff --git a/src/Client/src/app/pages/main/jobs/new/jobnew.component.html b/src/Client/src/app/pages/main/jobs/editor/jobeditor.component.html
similarity index 100%
rename from src/Client/src/app/pages/main/jobs/new/jobnew.component.html
rename to src/Client/src/app/pages/main/jobs/editor/jobeditor.component.html
diff --git a/src/Client/src/app/pages/main/jobs/new/jobnew.component.ts b/src/Client/src/app/pages/main/jobs/editor/jobeditor.component.ts
similarity index 91%
rename from src/Client/src/app/pages/main/jobs/new/jobnew.component.ts
rename to src/Client/src/app/pages/main/jobs/editor/jobeditor.component.ts
index 62324e2..bd69aad 100644
--- a/src/Client/src/app/pages/main/jobs/new/jobnew.component.ts
+++ b/src/Client/src/app/pages/main/jobs/editor/jobeditor.component.ts
@@ -9,12 +9,12 @@ import { Authentication } from 'app/services/Authentication';
import { Company, Employee } from 'app/models/Company';
@Component({
- selector: 'main-jobs-new',
- templateUrl: './jobnew.component.html',
- styleUrls: [ './jobnew.component.css' ],
+ selector: 'main-jobs-editor',
+ templateUrl: './jobeditor.component.html',
+ styleUrls: [ './jobeditor.component.css' ],
imports: [ FormsModule, CommonModule, RouterModule ]
})
-export class JobNewComponent {
+export class JobEditorComponent {
@ViewChildren('step') formSteps!: QueryList>;
currentStep: number = 0;
@@ -26,7 +26,7 @@ export class JobNewComponent {
public ErrorMsg: string = "";
constructor( private http: HttpClient, private router: Router, private route: ActivatedRoute, private title: Title, public auth: Authentication ) {
- this.title.setTitle("Jobs - new | BoredCareers");
+ this.title.setTitle("Jobs - Editor | BoredCareers");
this.http.get("api/employee").subscribe({
next: empOf => {
diff --git a/src/Client/src/app/pages/main/jobs/jobs.component.html b/src/Client/src/app/pages/main/jobs/jobs.component.html
index 5e5ab3d..f6bdacc 100644
--- a/src/Client/src/app/pages/main/jobs/jobs.component.html
+++ b/src/Client/src/app/pages/main/jobs/jobs.component.html
@@ -1,27 +1,3 @@
-
-
-
-
-
{{ cur.title }}
- {{ cur.jobType }}
- Is Remote: {{ cur.remote }}
- {{ cur.salaryMin }}
- {{ cur.salaryMax }}
- {{ cur.city }}
- {{ cur.stateOrRegion }}
- {{ cur.country }}
- {{ cur.postalCode }}
- Posted: {{ cur.createdTime }}
- Modified: {{ cur.modifiedTime }}
-
-
EDIT
-
DELETE
-
-
- POST JOB
-
-
-
@@ -38,7 +14,7 @@
{{ cur.stateOrRegion }}
- VIEW LISTING
+ VIEW LISTING
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/jobs/viewer/jobviewer.component.css b/src/Client/src/app/pages/main/jobs/viewer/jobviewer.component.css
new file mode 100644
index 0000000..c357862
--- /dev/null
+++ b/src/Client/src/app/pages/main/jobs/viewer/jobviewer.component.css
@@ -0,0 +1,11 @@
+.job-frame {
+
+}
+
+.job-warning {
+
+}
+
+.job-details {
+
+}
\ No newline at end of file
diff --git a/src/Client/src/app/pages/main/jobs/viewer/jobviewer.component.html b/src/Client/src/app/pages/main/jobs/viewer/jobviewer.component.html
new file mode 100644
index 0000000..a49aeb4
--- /dev/null
+++ b/src/Client/src/app/pages/main/jobs/viewer/jobviewer.component.html
@@ -0,0 +1,42 @@
+