@Controller @Scope(value="session") @RequestMapping(value="api/command") @Transactional public class CommandController extends Object
| Constructor and Description |
|---|
CommandController() |
| Modifier and Type | Method and Description |
|---|---|
org.openforis.commons.web.Response |
addAttribute(AddAttributeCommand command) |
Object |
addEntity(AddEntityCommand command) |
org.openforis.commons.web.Response |
addOrUpdateAttributes(org.openforis.collect.web.controller.CommandController.UpdateAttributesCommandWrapper commandsWrapper) |
org.openforis.commons.web.Response |
createRecord(CreateRecordCommand command) |
List<org.openforis.collect.web.controller.CommandController.RecordEventView> |
createRecordPreview(CreateRecordPreviewCommand command) |
Object |
deleteAttribute(DeleteAttributeCommand command) |
Object |
deleteAttributeFile(DeleteAttributeCommand command) |
Object |
deleteEntity(DeleteEntityCommand command) |
org.openforis.commons.web.Response |
deleteRecord(DeleteRecordCommand command) |
Object |
updateAttribute(org.openforis.collect.web.controller.CommandController.UpdateAttributeCommandWrapper commandWrapper) |
org.openforis.commons.web.Response |
updateAttributeFile(String commandWrapperJsonString,
org.springframework.web.multipart.MultipartFile multipartFile) |
@RequestMapping(value="record",
method=POST,
consumes="application/json")
@ResponseBody
public org.openforis.commons.web.Response createRecord(@RequestBody
CreateRecordCommand command)
@RequestMapping(value="record_preview",
method=POST,
consumes="application/json")
@ResponseBody
public List<org.openforis.collect.web.controller.CommandController.RecordEventView> createRecordPreview(@RequestBody
CreateRecordPreviewCommand command)
@RequestMapping(value="record",
method=DELETE,
consumes="application/json")
@ResponseBody
public org.openforis.commons.web.Response deleteRecord(@RequestBody
DeleteRecordCommand command)
@RequestMapping(value="record/attribute/new",
method=POST,
consumes="application/json")
@ResponseBody
public org.openforis.commons.web.Response addAttribute(@RequestBody
AddAttributeCommand command)
@RequestMapping(value="record/attributes",
method=POST,
consumes="application/json")
@ResponseBody
public org.openforis.commons.web.Response addOrUpdateAttributes(@RequestBody
org.openforis.collect.web.controller.CommandController.UpdateAttributesCommandWrapper commandsWrapper)
@RequestMapping(value="record/attribute",
method=POST,
consumes="application/json")
@ResponseBody
public Object updateAttribute(@RequestBody
org.openforis.collect.web.controller.CommandController.UpdateAttributeCommandWrapper commandWrapper)
@RequestMapping(value="record/attribute/file",
method=POST,
consumes="multipart/form-data")
@ResponseBody
public org.openforis.commons.web.Response updateAttributeFile(@RequestParam(value="command")
String commandWrapperJsonString,
@RequestParam(value="file")
org.springframework.web.multipart.MultipartFile multipartFile)
throws Exception
Exception@RequestMapping(value="record/attribute/file/delete",
method=POST,
consumes="application/json")
@ResponseBody
public Object deleteAttributeFile(@RequestBody
DeleteAttributeCommand command)
throws Exception
Exception@RequestMapping(value="record/attribute/delete",
method=POST,
consumes="application/json")
@ResponseBody
public Object deleteAttribute(@RequestBody
DeleteAttributeCommand command)
@RequestMapping(value="record/entity",
method=POST,
consumes="application/json")
@ResponseBody
public Object addEntity(@RequestBody
AddEntityCommand command)
@RequestMapping(value="record/entity/delete",
method=POST,
consumes="application/json")
@ResponseBody
public Object deleteEntity(@RequestBody
DeleteEntityCommand command)
Copyright © 2020 Open Foris. All rights reserved.