Project

General

Profile

« Previous | Next » 

Revision 54637

Added by Enrico Ottonello about 5 years ago

supported all patches for nonavcreation entity type

View differences:

PatchEditorController.java
136 136

  
137 137
		final PatchedRecord patchedRecord = createPatchedRecord(recordId);
138 138
		patchedRecord.getData().put("repositoryId", patchedRecord.getRepositoryId());
139
		patchedRecord.getData().put("entityType", patchedRecord.getType());
139 140
		return patchedRecord.getData();
140 141
	}
141 142

  
......
153 154
			HttpSession httpSession,
154 155
			@RequestParam(value = "id", required = true) String id,
155 156
			@RequestParam(value = "patches", required = true) String patches) {
156
		generateActions(map, httpSession, id, patches, EntityTypes.avcreation);
157
		generateActions(map, httpSession, id, patches);
157 158
		return "ok";
158 159
	}
159 160

  
......
277 278
	private void generateActions(ModelMap map,
278 279
			HttpSession httpSession,
279 280
			String recordId,
280
			String jsonPatches,
281
			EntityTypes entityType) {
281
			String jsonPatches) {
282 282
		try {
283 283
			final PatchedRecord record = createPatchedRecord(recordId);
284
			final String type = record.getType();
285
			final EntityTypes entityType = UIAction.EntityTypes.valueOf(type);
284 286

  
285 287
			final List<Patch> patches = new ArrayList<Patch>();
286 288

  

Also available in: Unified diff