Skip to content

JobsViewModel

reference
1 min readUpdated

Kind: Class

Source: Frontend/src/app/models/sales/jobs-view.model.ts (line 2)

Part of: Frontend

JobsViewModel represents sales job data for the frontend view layer. Its clone() method creates a copied view-model instance for workflows that need to preserve or compare job state.

Methods

MethodSignatureReturns
cloneclone(job: JobsViewModel)void

Properties

PropertyType
InquiryNumbernumber
CurrentJobStatusIDnumber
CompanyBranchIDnumber
JobNostring
InquiryDateDate
BidDueDateDate
ClientNamestring
EndUserstring
Projectstring
SupplierNamestring
InquiryTypestring
StatusNamestring
OrderBackLognumber
ActionDateDate
BranchNamestring
StatusDateDate
StatusReasonstring
DeliveredOnDate
CancellationFeesAmountnumber
CancellationFeesAmountInBaseCurrencynumber
ClientInquiryNumberstring
SupplierOfferNumberstring
SupplierOrderNumberstring
OrderDateDate
OrderActivationDateDate
OfferStatusstring
OrderChancestring
OrderStatusstring
JobVersionPricenumber
JobVersionPriceInBaseCurrencynumber
CurrencyCodestring
OfferValidationstring
DeliveryTimestring
RequirdProductstring
SalesResponsiblestring
ProductTypestring
PaymentMethodstring
DeliveryTermstring
ClientInquiryCountnumber
ClientOfferCountnumber
ClientOrderCountnumber
ClientDeliveredCountnumber
BidBondValuenumber
BidBondValueTypenumber
BidBondValueCurrencystring
BidBondValueInBaseCurrencynumber
AgreedCommissionPercentagenumber
CommissionPercentagenumber
ContractualCommissionPercentagenumber
CommissionValuenumber

Diagram

mermaid
graph LR
  JobsViewModel --> Clone[clone()]
  Clone --> CopiedJobsViewModel[Copied JobsViewModel]
  CopiedJobsViewModel --> SalesUI[Sales UI State]

Usage

ts
import { JobsViewModel } from '@/app/models/sales/jobs-view.model';

declare const jobsViewModel: JobsViewModel;

const copiedJobsViewModel = jobsViewModel.clone();

// Use the copied model without replacing the original reference.
console.log(copiedJobsViewModel);

AI Coding Instructions

  • Import JobsViewModel from app/models/sales/jobs-view.model when working with sales job view state.
  • Use clone() before changing state that must not affect the original model instance.
  • Check the clone() implementation before assuming whether nested values are copied or shared.
  • Keep presentation-specific logic in the view model and avoid placing API request logic in this class.

Relationships

  • IMPORTS → AppSettings

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)

  • InquiryServiceFrontend/src/app/services/sales/inquiry.service.ts:1

Was this page helpful?

Download as PDF