Skip to content

FilesController

reference
4 min readUpdated

Kind: Controller

Source: Pams/API/Pams.API/Controllers/Common/FilesController.cs (line 27)

Part of: Pams

Where it refuses work

  • FilesController stops the work with HttpResponseException when !Request.Content.IsMimeMultipartContent(), in 2 places.
  • FilesController stops the work with an early return when !success, in 6 places.
  • FilesController stops the work with an early return when !ModelState.IsValid, in 4 places.
  • FilesController stops the work with an early return when httpRequest.Files.Count <= 0, in 2 places.
  • FilesController stops the work with an early return when parentId == 0, in 2 places.
  • FilesController stops the work with an early return when stProvider == null, in 2 places.

When something fails

  • FilesController handles failure in 20 places: it turns it into a return value in 18, and discards it silently in 2. A failure discarded silently leaves no trace for whoever debugs this later.

Relationships

  • MODULE_DECLARES → GetbyParentFileID_old
  • MODULE_DECLARES → GetbyParentFileId
  • MODULE_DECLARES → GetLinkedFiles
  • MODULE_DECLARES → GetTagsListByType
  • MODULE_DECLARES → GetByID
  • MODULE_DECLARES → DownloadFiles
  • MODULE_DECLARES → DeleteTempAfterDownload
  • MODULE_DECLARES → GetFromGoogleToOneDrive
  • MODULE_DECLARES → UpdateFromGoogleToOneDrive
  • MODULE_DECLARES → UploadFiles
  • MODULE_DECLARES → UploadFileToOneDrive
  • MODULE_DECLARES → UploadFileListToOneDrive
  • MODULE_DECLARES → UploadFileToGoogleCloud
  • MODULE_DECLARES → Save
  • MODULE_DECLARES → EditFileCategory
  • MODULE_DECLARES → SaveFileList
  • MODULE_DECLARES → Delete
  • MODULE_DECLARES → AttachFiels
  • MODULE_DECLARES → AttachFiles
  • MODULE_DECLARES → AttachFielsByTags
  • MODULE_DECLARES → loadAttachedFiles
  • MODULE_DECLARES → unAttachFile
  • MODULE_DECLARES → LoadAttachments
  • MODULE_DECLARES → LoadAllDocuments
  • MODULE_DECLARES → GetRelatedObjectByCloudId
  • MODULE_DECLARES → GetTagsListByTypeForOutlook
  • IMPORTS → BaseController
  • IMPORTS → CRMLinqDataContext
  • IMPORTS → PamsLinqDataContext
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → Insert
  • IMPORTS → File
  • IMPORTS → Person
  • IMPORTS → Project
  • IMPORTS → Account
  • IMPORTS → Employee
  • IMPORTS → Task
  • IMPORTS → Activity
  • IMPORTS → Invoice
  • IMPORTS → Payment
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → GetAll
  • IMPORTS → LetterOfGuarantee
  • IMPORTS → InspectionSheet
  • IMPORTS → InspectionDefect
  • IMPORTS → StoreProduct
  • IMPORTS → ProductionOrder
  • IMPORTS → IssueNote
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → GetByID
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Delete
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → Save
  • IMPORTS → UploadFile
  • IMPORTS → Comment
  • IMPORTS → StorageFile
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → Update
  • IMPORTS → RelatedToType

Used by

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

calls by (8)

  • UploadFilePopupFrontend/src/app/services/common/files.service.ts:1
  • AttachementOutlook_plugin/src/attachement/attachement.service.ts:1
  • AuthOutlook_plugin/src/auth/auth.service.ts:1
  • UploadFilePopupPams/Web/Pams.Web/Client/app/services/common/files.service.ts:1
  • FilesServicePams/Web/Pams.WebApp/Client/app/services/common/files.service.ts:1
  • AppSettingsFrontend/src/app/settings/app/app.settings.ts:241
  • AppSettingsPams/Web/Pams.Web/Client/app/settings/app/app.settings.ts:126
  • AppSettingsPams/Web/Pams.WebApp/Client/app/settings/app/app.settings.ts:6

Was this page helpful?

Download as PDF