Class AssetTypeTemplateService
java.lang.Object
overit.geocallapp.utilities.rs.common.PrivateService
overit.geocallapp.wfm.assets.rs1.type.template.AssetTypeTemplateService
@RestController
@RequestMapping("assets/r1/types/{typeId:[0-9]+}/templates")
@Resource(logging=true)
public class AssetTypeTemplateService
extends PrivateService
Services to manage asset type templates.
- Since:
- 16.0
- GCApi:
- rest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<DTOAssetTypeTemplate> get(Long typeId, Long templateId, Collection<String> fields) Retrieves the required asset type template.org.springframework.http.ResponseEntity<PageResponse<DTOAssetTypeTemplate>> getCollection(Long typeId, @Valid Page page, Collection<String> fields, String order, @Valid DTOAssetTypeTemplateFilter filter) Retrieve the all stored asset type templates.org.springframework.http.ResponseEntity<Void> patch(Long typeId, Long templateId, @Valid DTOAssetTypeTemplateUpdate input) Modifies the required asset type template.org.springframework.http.ResponseEntity<DTOIdentifier<Long>> post(Long typeId, @Valid DTOAssetTypeTemplateInsert input) Create a new asset type template.
-
Constructor Details
-
AssetTypeTemplateService
public AssetTypeTemplateService()
-
-
Method Details
-
getCollection
@GetMapping(produces="application/json") public org.springframework.http.ResponseEntity<PageResponse<DTOAssetTypeTemplate>> getCollection(@PathVariable("typeId") Long typeId, @RequestParam("_page") @Valid @Valid Page page, @RequestParam(required=false,name="_fields") Collection<String> fields, @RequestParam(required=false,name="_order") String order, @Valid @Valid DTOAssetTypeTemplateFilter filter) throws DAValidateException, DAException Retrieve the all stored asset type templates.AssetTypeTemplateSearchEvent- Parameters:
typeId- the asset type idpage- the required result pagefields- the collection of fields the response will containorder- the ordering fieldfilter- theDTOAssetTypeTemplateFilter- Returns:
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
get
@GetMapping(value="{templateId:[0-9]+}", produces="application/json") public org.springframework.http.ResponseEntity<DTOAssetTypeTemplate> get(@PathVariable("typeId") Long typeId, @PathVariable("templateId") Long templateId, @RequestParam(required=false,name="_fields") Collection<String> fields) throws DAValidateException, DAException Retrieves the required asset type template.AssetTypeTemplateLoadEvent- Parameters:
typeId- the type idtemplateId- the template idfields- the collection of fields the response will contain- Returns:
- the response entity DTO asset type template>
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
post
@PostMapping(consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<DTOIdentifier<Long>> post(@PathVariable("typeId") Long typeId, @Valid @RequestBody @Valid DTOAssetTypeTemplateInsert input) throws DAValidateException, DAException Create a new asset type template.AssetTypeTemplateInsertEvent- Parameters:
typeId- the asset type idinput- theDTOAssetTypeTemplateInsert- Returns:
- the response entity
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
patch
@PatchMapping(value="{templateId:[0-9]+}", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<Void> patch(@PathVariable("typeId") Long typeId, @PathVariable("templateId") Long templateId, @Valid @RequestBody @Valid DTOAssetTypeTemplateUpdate input) throws DAValidateException, DAException Modifies the required asset type template.AssetTypeTemplateUpdateEvent- Parameters:
typeId- the asset type idtemplateId- the asset type template idinput- theDTOAssetTypeTemplateUpdate- Returns:
- the response entity
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-