|
|
@ -37,23 +37,71 @@ public class TestController extends BaseController { |
|
|
|
|
|
|
|
@ResponseBody |
|
|
|
@PostMapping("/api/test/emergency-append") |
|
|
|
public ApiResponse testEmergencyAppend( @RequestBody ParamTestEmergencyAppend param) { |
|
|
|
public ApiResponse testEmergencyAppend( @RequestBody Object param) { |
|
|
|
// this.deviceService.testEmergencyAppend(param); |
|
|
|
return this.success(); |
|
|
|
} |
|
|
|
|
|
|
|
@ResponseBody |
|
|
|
@PostMapping("/api/test/regular-append") |
|
|
|
@PostMapping("/api/test/test-tube-rack-append") |
|
|
|
public ApiResponse testRegularAppend(@RequestBody ParamTestRegularAppend param ) { |
|
|
|
// this.deviceService.regularTaskAppend(param); |
|
|
|
return this.success(); |
|
|
|
} |
|
|
|
|
|
|
|
@ResponseBody |
|
|
|
@PostMapping("/api/test/test-tube-rack-list") |
|
|
|
public ApiResponse testTubeRackList( @RequestBody Map<String,Object> params ) { |
|
|
|
List<Map<String,Object>> list = new ArrayList<>(); |
|
|
|
for ( int i=0; i<2; i++ ) { |
|
|
|
Map<String,Object> item = new HashMap<>(); |
|
|
|
item.put("tubeIndex", Integer.toString(i)); |
|
|
|
item.put("tubeType", "WB"); |
|
|
|
item.put("sampleType", "FB"); |
|
|
|
item.put("projectIds", new int[]{1,2,3,4,5}); |
|
|
|
item.put("barCode", "123456"); |
|
|
|
item.put("sampleUid", "123"); |
|
|
|
item.put("appendBy", "manual"); |
|
|
|
item.put("status", "WAITING"); |
|
|
|
item.put("locked", false); |
|
|
|
item.put("editable", true); |
|
|
|
list.add(item); |
|
|
|
} |
|
|
|
|
|
|
|
return this.success(); |
|
|
|
} |
|
|
|
|
|
|
|
@ResponseBody |
|
|
|
@PostMapping("/api/test/test-tube-rack-update") |
|
|
|
public ApiResponse testTubeRackUpdate( @RequestBody Map<String,Object> params ) { |
|
|
|
return this.success(); |
|
|
|
} |
|
|
|
|
|
|
|
@ResponseBody |
|
|
|
@PostMapping("/api/test/test-tube-rack-lock") |
|
|
|
public ApiResponse testTubeRackLock() { |
|
|
|
return this.success(); |
|
|
|
} |
|
|
|
|
|
|
|
@ResponseBody |
|
|
|
@PostMapping("/api/test/test-tube-rack-unlock") |
|
|
|
public ApiResponse testTubeRackUnlock() { |
|
|
|
return this.success(); |
|
|
|
} |
|
|
|
|
|
|
|
@ResponseBody |
|
|
|
@PostMapping("/api/test/search") |
|
|
|
public ApiResponse search( @RequestBody Map<String,Object> params ) { |
|
|
|
List<Map<String,Object>> list = new ArrayList<>(); |
|
|
|
for (int i = 0; i < 20; i++) { |
|
|
|
List<Map<String, String>> results = new ArrayList<>(); |
|
|
|
for (int j = 0; j < 2; j++) { |
|
|
|
Map<String, String> result = new HashMap<>(); |
|
|
|
result.put("name", "sth01"); |
|
|
|
result.put("value", "123.45mg/L"); |
|
|
|
results.add(result); |
|
|
|
} |
|
|
|
|
|
|
|
Map<String,Object> item = new HashMap<>(); |
|
|
|
item.put("recordUUID", "202110-01"); |
|
|
|
item.put("samplePID", "ABCD1234"); |
|
|
@ -67,6 +115,7 @@ public class TestController extends BaseController { |
|
|
|
item.put("incubateTime", "3600"); |
|
|
|
item.put("status", "INUSE"); |
|
|
|
item.put("slotIndex", Integer.toString(i)); |
|
|
|
item.put("results", results); |
|
|
|
list.add(item); |
|
|
|
} |
|
|
|
|
|
|
|