Commit 5b062c32 authored by hasan khaddour's avatar hasan khaddour

fix projects types info

parent ff0f181d
...@@ -7,29 +7,33 @@ ...@@ -7,29 +7,33 @@
<div class="card p-4"> <div class="card p-4">
<form class="php-email-form"> <form class="php-email-form">
<div class="row gy-4"> <div class="row gy-4">
<div class="row text-center">
<p>
إضافة جهة طارحة
</p>
</div>
<div class="col-12"> <div class="col-12">
<input type="text" [(ngModel)]="request.customerName" <input type="text" [(ngModel)]="request.customerName"
name="name" class="form-control" placeholder="Your Name" required> name="customerName" class="form-control" placeholder="اسم الجهة الطارحة" required>
</div> </div>
<div class="col-6 "> <div class="col-6 ">
<input type="email" [(ngModel)]="request.email" <input type="email" [(ngModel)]="request.email"
class="form-control" name="email" placeholder="Your Email" required> class="form-control" name="email" placeholder="البريد الالكتروني" required>
</div> </div>
<div class="col-6"> <div class="col-6">
<input type="text" [(ngModel)]="request.address.streetName" <input type="text" [(ngModel)]="request.address.streetName"
class="form-control" name="subject" placeholder="street Name" required> class="form-control" name="streetName" placeholder="اسم الشارع" required>
</div> </div>
<div class="col-6"> <div class="col-6">
<input type="number" [(ngModel)]="request.address.streetNumber" <input type="number" [(ngModel)]="request.address.streetNumber"
class="form-control" name="subject" placeholder="street Number" required> class="form-control" name="streetNumber" placeholder="رقم الشارع" required>
</div> </div>
<div class="col-6"> <div class="col-6">
<input type="text" [(ngModel)]="request.address.city" <input type="text" [(ngModel)]="request.address.city"
class="form-control" name="subject" placeholder="city " required> class="form-control" name="city" placeholder="المدينة " required>
</div> </div>
......
...@@ -48,10 +48,6 @@ ...@@ -48,10 +48,6 @@
<form (ngSubmit)="saveCustomer()"> <form (ngSubmit)="saveCustomer()">
<div class="row"> <div class="row">
<div class="mb-3 col-5 offset-1">
<label for="stepName" class="form-label">الجهة الطارحة</label>
<input type="text" name="stepName" id="stepName" class="form-control" [(ngModel)]="selectedCustomer.customerName" required>
</div>
<div class="mb-3 col-5"> <div class="mb-3 col-5">
<label for="expectedSpendingDate" class="form-label">البريد الاكتروني</label> <label for="expectedSpendingDate" class="form-label">البريد الاكتروني</label>
......
...@@ -64,7 +64,8 @@ export class CustomerDetailsComponent implements OnInit { ...@@ -64,7 +64,8 @@ export class CustomerDetailsComponent implements OnInit {
let request : UpdateCustomerRequest ={ let request : UpdateCustomerRequest ={
...this.selectedCustomer, ...this.selectedCustomer,
customerId: this.selectedCustomer.id customerId: this.selectedCustomer.id,
customerName:this.selectedCustomer.customerName
} }
this.customerService.updateCustomer(this.selectedCustomer.id,request).subscribe({ this.customerService.updateCustomer(this.selectedCustomer.id,request).subscribe({
......
...@@ -9,7 +9,7 @@ import { EmployeeParticipate } from '../models/responses/employeeParticipate'; ...@@ -9,7 +9,7 @@ import { EmployeeParticipate } from '../models/responses/employeeParticipate';
import { GetEmployeeTrackHistoryRequest } from '../models/requests/getEmployeeTrackHistoryRequest'; import { GetEmployeeTrackHistoryRequest } from '../models/requests/getEmployeeTrackHistoryRequest';
import { EmployeeTrack } from '../../tracks/models/responses/employeeTrack'; import { EmployeeTrack } from '../../tracks/models/responses/employeeTrack';
import { UpdateEmplyeeWorkHours } from '../models/requests/updateEmployeeWorkHoursRequest'; import { UpdateEmplyeeWorkHours } from '../models/requests/updateEmployeeWorkHoursRequest';
import { Department } from '../../projects/models/responses/Department'; import { Department } from '../../projects/models/responses/department';
@Injectable({ @Injectable({
providedIn: 'root' providedIn: 'root'
......
...@@ -2,12 +2,12 @@ ...@@ -2,12 +2,12 @@
<div class="row"> <div class="row">
<div class="mb-3 col-5 offset-1"> <div class="mb-3 col-5 offset-1">
<label for="stepName" class="form-label">اسم النوع </label> <label for="employee" class="form-label">عدد العمال المطلوب لهذا النوع </label>
<input type="text" name="stepName" id="stepName" class="form-control" [(ngModel)]="selectedItem.typeName" required> <input type="number" name="employee" id="employee" class="form-control"[min]="0" [(ngModel)]="selectedItem.expectedNumberOfWorker" required>
</div> </div>
<div class="mb-3 col-5 "> <div class="mb-3 col-5 ">
<label for="local" class="form-label">الجهد لهذا النوع من المشاريع</label> <label for="efort" class="form-label">الجهد لهذا النوع من المشاريع</label>
<input id="local" class="form-control" [(ngModel)]="selectedItem.expectedEffort" name="local" required> <input id="efort" class="form-control" [(ngModel)]="selectedItem.expectedEffort" [min]="0" name="efort" required>
</div> </div>
<div class="mb-3 col-9 offset-1"> <div class="mb-3 col-9 offset-1">
......
...@@ -21,6 +21,13 @@ ...@@ -21,6 +21,13 @@
</div> </div>
</div> </div>
<div class="col-8 ">
<div class="small mb-2 d-flex">
<span class="text-muted flex-fill">عدد العمال لهذا النوع من المشاريع : {{item.expectedNumberOfWorker}}</span>
</div>
</div>
<div class="col-8 "> <div class="col-8 ">
<div class="small mb-2 d-flex"> <div class="small mb-2 d-flex">
<span class="text-muted">الجهد المتوقع لهذا النوع من المشاريع {{item.expectedEffort}} ساعة عمل</span> <span class="text-muted">الجهد المتوقع لهذا النوع من المشاريع {{item.expectedEffort}} ساعة عمل</span>
......
...@@ -3,5 +3,6 @@ export class CreateNewTypeRequest { ...@@ -3,5 +3,6 @@ export class CreateNewTypeRequest {
typeName: string; typeName: string;
description: string; description: string;
expectedEffort: number; expectedEffort: number;
expectedNumberOfWorker :number;
} }
...@@ -3,5 +3,6 @@ export class UpdateTypeRequest{ ...@@ -3,5 +3,6 @@ export class UpdateTypeRequest{
typeName :string typeName :string
description :String description :String
expectedEffort :number expectedEffort :number
expectedNumberOfWorker :number;
} }
...@@ -3,4 +3,6 @@ export class ProjectType { ...@@ -3,4 +3,6 @@ export class ProjectType {
typeName :string typeName :string
description :string description :string
expectedEffort :number expectedEffort :number
expectedNumberOfWorker :number
} }
\ No newline at end of file
...@@ -15,18 +15,22 @@ ...@@ -15,18 +15,22 @@
<div class="col-12"> <div class="col-12">
<input type="text" [(ngModel)]="request.typeName" <input type="text" [(ngModel)]="request.typeName"
name="name" class="form-control" placeholder="اسم المشروع" required> name="typeName" class="form-control" placeholder="اسم المشروع" required>
</div> </div>
<div class="col-6 "> <div class="col-6 ">
<textarea type="tex" [(ngModel)]="request.description" [cols]="4" name="description" <textarea type="tex" [(ngModel)]="request.description" [cols]="4" name="description"
class="form-control" name="description" placeholder="الوصف" minlength="15" required> class="form-control" name="requestdescription" placeholder="الوصف" minlength="15" required>
</textarea> </textarea>
</div> </div>
<div class="col-6"> <div class="col-6">
<input type="number" [(ngModel)]="request.expectedEffort" <input type="number" [(ngModel)]="request.expectedEffort"
class="form-control" name="subject" placeholder="ساعات العمل اللازمة" required min="0" > class="form-control" name="expectedNumberOfWorker" placeholder="ساعات العمل اللازمة" required min="0" >
</div>
<div class="col-6">
<input type="number" [(ngModel)]="request.expectedNumberOfWorker"
class="form-control" name="expectedNumberOfWorker" placeholder="عدد العمال المتوقع" required min="0" >
</div> </div>
......
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
<p><strong>الوصف</strong></p> <p><strong>الوصف</strong></p>
<p> {{type.description}}</p> <p> {{type.description}}</p>
<p>عدد ساعات العمل المتوقعة لهذا النوع من المشاريع {{type.expectedEffort}}</p> <p>عدد ساعات العمل المتوقعة لهذا النوع من المشاريع {{type.expectedEffort}}</p>
<p>عدد العمال المتوقع لهذا النوع من المشاريع {{type.expectedNumberOfWorker}}</p>
</div> </div>
......
import { Component, EventEmitter, Input, Output } from '@angular/core'; import { Component, EventEmitter, Input, Output } from '@angular/core';
import { FinancialSpending } from '../../models/responses/FinancialSpending'; import { FinancialSpending } from '../../models/responses/financialSpending';
@Component({ @Component({
selector: 'financial-item', selector: 'financial-item',
......
import { Component, Input } from '@angular/core'; import { Component, Input } from '@angular/core';
import { FinancialSpending } from '../../../models/responses/FinancialSpending'; import { FinancialSpending } from '../../../models/responses/financialSpending';
import { CreateFinancialSpendItemRequest } from '../../../models/requests/financial-reuqests/CreateFinancialSpendItemRequest'; import { CreateFinancialSpendItemRequest } from '../../../models/requests/financial-reuqests/CreateFinancialSpendItemRequest';
import { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap'; import { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';
import { ToastrService } from 'ngx-toastr'; import { ToastrService } from 'ngx-toastr';
......
export class ParticipationChange {
employeeId: number;
projectId: number;
partialTimeBefore: number;
partialTimeAfter: number;
roleBefore: string;
roleAfter: string;
changeDate: Date;
}
...@@ -6,9 +6,9 @@ import { FinancialFund } from "../valueObjects/FinancialFund" ...@@ -6,9 +6,9 @@ import { FinancialFund } from "../valueObjects/FinancialFund"
import { ProjectInfo } from "../valueObjects/ProjectInfo" import { ProjectInfo } from "../valueObjects/ProjectInfo"
import { ProposalInfo } from "../valueObjects/proposalInfo" import { ProposalInfo } from "../valueObjects/proposalInfo"
import { ProjectClassification } from "../valueObjects/ProjectClassification" import { ProjectClassification } from "../valueObjects/ProjectClassification"
import { Department } from "./Department" import { Department } from "./department"
import { Step } from "./Step" import { Step } from "./Step"
import { FinancialSpending } from "./FinancialSpending" import { FinancialSpending } from "./financialSpending"
import { ProjectType } from "../../../projects-types/models/responses/projectType" import { ProjectType } from "../../../projects-types/models/responses/projectType"
export class Project export class Project
{ {
......
import { Component } from '@angular/core'; import { Component } from '@angular/core';
import { FinancialSpending } from '../../models/responses/FinancialSpending'; import { FinancialSpending } from '../../models/responses/financialSpending';
import { FinancialSpendingService } from '../../services/financial-spending.service'; import { FinancialSpendingService } from '../../services/financial-spending.service';
import { ActivatedRoute, Router } from '@angular/router'; import { ActivatedRoute, Router } from '@angular/router';
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'; import { NgbModal } from '@ng-bootstrap/ng-bootstrap';
......
...@@ -10,7 +10,7 @@ import { ProjectService } from '../../services/project.service'; ...@@ -10,7 +10,7 @@ import { ProjectService } from '../../services/project.service';
import { CreateProjectRequest } from '../../models/requests/project-requests/createProjectRequest'; import { CreateProjectRequest } from '../../models/requests/project-requests/createProjectRequest';
import { ToastrComponentlessModule, ToastrService } from 'ngx-toastr'; import { ToastrComponentlessModule, ToastrService } from 'ngx-toastr';
import { Router } from '@angular/router'; import { Router } from '@angular/router';
import { Department } from '../../models/responses/Department'; import { Department } from '../../models/responses/department';
import { ProjectType } from '../../../projects-types/models/responses/projectType'; import { ProjectType } from '../../../projects-types/models/responses/projectType';
import { ProjectsTypesService } from '../../../projects-types/services/projects-types.service'; import { ProjectsTypesService } from '../../../projects-types/services/projects-types.service';
//#endregion imports //#endregion imports
......
import { HttpClient } from '@angular/common/http'; import { HttpClient } from '@angular/common/http';
import { Injectable } from '@angular/core'; import { Injectable } from '@angular/core';
import { ConfigurationService } from '../../core/services/configuration/configuration.service'; import { ConfigurationService } from '../../core/services/configuration/configuration.service';
import { FinancialSpending } from '../models/responses/FinancialSpending'; import { FinancialSpending } from '../models/responses/financialSpending';
import { Observable } from 'rxjs'; import { Observable } from 'rxjs';
import { CreateFinancialSpendItemRequest } from '../models/requests/financial-reuqests/CreateFinancialSpendItemRequest'; import { CreateFinancialSpendItemRequest } from '../models/requests/financial-reuqests/CreateFinancialSpendItemRequest';
import { GetFinancialSpendItemByProjecRequest } from '../models/requests/financial-reuqests/GetFinancialSpendItemByProjectRequest'; import { GetFinancialSpendItemByProjecRequest } from '../models/requests/financial-reuqests/GetFinancialSpendItemByProjectRequest';
......
...@@ -15,7 +15,7 @@ import { CancelProjectRequest } from '../models/requests/project-requests/Cancel ...@@ -15,7 +15,7 @@ import { CancelProjectRequest } from '../models/requests/project-requests/Cancel
import { RePlanProjectRequest } from '../models/requests/project-requests/RePlanProjectRequest'; import { RePlanProjectRequest } from '../models/requests/project-requests/RePlanProjectRequest';
import { CreateProjectRequest } from '../models/requests/project-requests/createProjectRequest'; import { CreateProjectRequest } from '../models/requests/project-requests/createProjectRequest';
import { AddAttachmentRequest } from '../models/requests/project-requests/AddAttachmentRequest'; import { AddAttachmentRequest } from '../models/requests/project-requests/AddAttachmentRequest';
import { Attachment } from '../models/responses/Attachment'; import { Attachment } from '../models/responses/attachment';
import { CompleteProjectRequest } from '../models/requests/project-requests/completeProjectRequest'; import { CompleteProjectRequest } from '../models/requests/project-requests/completeProjectRequest';
import { ChangeEmployeeParticipationRequest } from '../models/requests/project-requests/ChangeEmployeeParticipationRequest'; import { ChangeEmployeeParticipationRequest } from '../models/requests/project-requests/ChangeEmployeeParticipationRequest';
......
import { Component, Input } from '@angular/core'; import { Component, Input } from '@angular/core';
import { FinancialSpending } from '../../../projects/models/responses/FinancialSpending'; import { FinancialSpending } from '../../../projects/models/responses/financialSpending';
@Component({ @Component({
selector: 'financial-spend-table', selector: 'financial-spend-table',
......
import { Component, Input } from '@angular/core'; import { Component, Input } from '@angular/core';
import { Customer } from '../../../customers/models/customer'; import { Customer } from '../../../customers/models/customer';
import { Employee } from '../../../employees/models/responses/employee'; import { Employee } from '../../../employees/models/responses/employee';
import { Department } from '../../../projects/models/responses/Department'; import { Department } from '../../../projects/models/responses/department';
@Component({ @Component({
selector: 'project-footer', selector: 'project-footer',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment