feat(appointments): unify pre-inbound planning and confirmed FBA bookings
This commit is contained in:
+1
-1
@@ -20,7 +20,7 @@ public final class AppointmentTimePolicy {
|
||||
final ZoneId zone;
|
||||
try { zone = ZoneId.of(timezone); }
|
||||
catch (DateTimeException error) { throw new IllegalArgumentException("预约地点时区无效", error); }
|
||||
if (zone instanceof ZoneOffset) throw new IllegalArgumentException("预约地点需要地区时区,不能仅填写固定时差");
|
||||
if (zone instanceof ZoneOffset || zone.getRules().isFixedOffset()) throw new IllegalArgumentException("预约地点需要地区时区,不能仅填写固定时差");
|
||||
Instant first = instant(start, zone, startOffset);
|
||||
Instant last = end == null ? null : instant(end, zone, endOffset);
|
||||
if (end == null && endOffset != null) throw new IllegalArgumentException("未填写结束时间,不能指定结束时差");
|
||||
|
||||
Reference in New Issue
Block a user