Skip to content

AttachedfileView

reference
1 min readUpdated

Kind: Class

Source: Frontend/src/app/models/common/files.model.ts (line 181)

Part of: Frontend

AttachedfileView represents an attached file in the common file model layer. It supports copying file data with cloneFile() and copying the view model with clone() so callers can work with separate instances.

Methods

MethodSignatureReturns
cloneFilecloneFile(file: File)void
cloneclone(e: AttachedfileView)void

Properties

PropertyType
FileNamestring
CompanyBranchIDnumber
FileIDnumber
refrenceToIDnumber
refrenceToTypeIDnumber
FileTypeIdnumber
FileCategoryIdnumber
FileCategorystring
VersionNonumber
NameSuffixstring
MarkDeleteboolean
TagIDnumber
FileTypestring
FilePathstring
CloudTypeIdnumber
CloudItemIdstring
SizeInBytesstring
ModificationDateDate
downloadingboolean

Diagram

mermaid
graph LR
  A[AttachedfileView] --> B[cloneFile()]
  A --> C[clone()]
  B --> D[Copied file data]
  C --> E[Copied AttachedfileView]

Usage

ts
import { AttachedfileView } from 'src/app/models/common/files.model';

const attachedFile = new AttachedfileView();

const copiedFile = attachedFile.cloneFile();
const copiedView = attachedFile.clone();

// Modify a copied instance without changing the original reference.
console.log(copiedFile, copiedView);

AI Coding Instructions

  • Use cloneFile() when code needs a separate copy of the attached file data.
  • Use clone() when passing an AttachedfileView instance to code that may modify it.
  • Keep clone behavior aligned with any fields added to AttachedfileView.
  • Avoid mutating shared file-view instances when a copied instance is required.

Used by

6 references from 6 files. Each is a place in this repository where the symbol is actually used — go read one rather than trusting an example.

Imported by (6)

  • DocsListComponentFrontend/src/app/components/shared/attached-docs/shared-attached-docs/docs-list/docs-list.component.ts:1
  • SharedAttachedDocsComponentFrontend/src/app/components/shared/attached-docs/shared-attached-docs/shared-attached-docs.component.ts:1
  • AttachmentDropdownComponentFrontend/src/app/components/shared/dropdown/attachment-dropdown/attachment-dropdown.component.ts:1
  • InspectionDetailsComponentFrontend/src/app/components/warehouse/inspection-details/inspection-details.component.ts:1
  • UploadFilePopupFrontend/src/app/services/common/files.service.ts:1
  • ClientDelayFrontend/src/app/models/sales/client-delay.model.ts:2

Was this page helpful?

Download as PDF