Skip to content

Project

reference
1 min readUpdated

Kind: Class

Source: Pams/Web/Pams.WebApp/Client/app/models/sales/project.model.ts (line 8)

Part of: Pams

Project represents a sales project model in the client application. Its clone() method creates and returns a separate Project instance for workflows that need a copy of the current model.

Methods

MethodSignatureReturns
cloneclone(proj: Project)Project

Properties

PropertyType
ProjectIDnumber
ProjectCodestring
ProjectNamestring
ProjectDescriptionstring
IsImportantboolean
ProjectStatusIDnumber
StartDateDate
ExpectedCommissioningDateDate
EstimatedCostnumber
CurrencySymbolstring
CurrencyCodestring
FinalProductstring
EngineeringBystring
ContractorBystring
ProcurementBystring
VendorListBystring
LicenseBystring
KMCBystring
ProjectLocationstring
ShareholdersShareholder[]
ProjectCommentsProjectComment[]
ContactPersonListArray<ContactPersons>
OwnerIDnumber
UserIDnumber

Where it refuses work

  • Project stops the work with an early return when this.StartDate == null.

Diagram

mermaid
graph LR
    Project[Project instance] --> Clone[clone()]
    Clone --> Copy[New Project instance]

Usage

ts
import { Project } from './project.model';

const project = new Project();

const projectCopy = project.clone();

// Update the copy without replacing the original reference.
console.log(projectCopy);

AI Coding Instructions

  • Use clone() when a workflow needs a separate Project instance rather than sharing the same object reference.
  • Keep cloning behavior aligned with the properties defined on Project as the model changes.
  • Avoid mutating a cloned instance when the intended change belongs on the original project.
  • Import the model from the sales project model module when adding project-related client logic.

Relationships

  • IMPORTS → AppSettings
  • IMPORTS → Shareholder
  • IMPORTS → ProjectRegistered
  • IMPORTS → ProjectComment
  • IMPORTS → ProjectContactPersons
  • IMPORTS → ContactPersons
  • IMPORTS → ContactInfo

Used by

1 reference from 1 file. Each is a place in this repository where the symbol is actually used — go read one rather than trusting an example.

Imported by (1)

  • ProjectServicePams/Web/Pams.WebApp/Client/app/services/sales/project.service.ts:1

Was this page helpful?

Download as PDF