feat(appointments): expose destination warehouse options

This commit is contained in:
2026-10-19 17:02:25 +08:00
parent eb167347f6
commit a563f63857
5 changed files with 62 additions and 0 deletions
@@ -35,6 +35,11 @@ public class AppointmentCargoService {
return new PageResult<>(rows, page, size, total, (total + size - 1) / size);
}
/** 查询下拉框与货物分页共用权威目录范围,不从当前页猜测目的仓。 */
public List<String> destinations() {
return scope().destinations().stream().distinct().sorted().toList();
}
private record Scope(List<String> origins, List<String> destinations) { }
private Scope scope() {
final List<AppointmentWarehouseClient.Warehouse> catalog;