Repository navigation
Description
③ maintainer-directed task · Source: maintainer — 「先立卡,不需要fable,我会用新的agent账户接着评审」「立 objectstack 卡就可以」 (2026-11-19T05:33Z, planning thread on marketplace suites), answering the proposal that working calendars belong at the platform layer.
维护者速读
- 问题: 平台没有工作日历。审批超时、服务时效、交期都按自然小时算,周末和节假日也算在内;国内的调休补班更没法表达。
- 要做: 平台提供工作日历,包括工作日、工作时段、节假日和调休,可以按组织、地区或工厂各设一份。审批、服务时效和日期公式都按它计算。
- 不做会怎样: CRM 的服务时效、SRM 的交期、生产排产各算各的,客户看到的到期时间互相矛盾。
- 你要做的: 无。待评审账户给出设计意见后再定。这张卡等于解冻以前搁置的「工作时间」那半边。
Business reason
Who benefits: every suite with a deadline, and their users who expect "due in 2 working days" to skip the weekend and the National Day week.
- hotcrm. The case SLA matrix counts wall-clock hours, with a prose warning to say so (outcome of Make the wall-clock unit un-misreadable in authored duration declarations — the ruled A-half of the business-hours question (#13655) #13801).
- hotsrm. Delivery dates and audit or change-request deadlines.
- Production suite. Every schedule.
- Approvals. Escalation
timeoutHourscounts nights, weekends and holidays. The describe text atpackages/spec/src/automation/approval.zod.ts:865-872says so: "The platform ships no business-hours calendar".
China adds a twist a fixed weekly pattern can't express: 调休 make-up working Saturdays and Sundays around public holidays.
If this isn't done, each suite computes due dates its own way. The same request then shows different due times in different apps.
History (read)
The business-hours capability is the parked B-half of #13655 (ruling 2026-08-31, record 5478756633, cited from #13801; #13655 itself returns 404 to this session).
- It was frozen with a named-external-user unfreeze condition.
- The A-half, Make the wall-clock unit un-misreadable in authored duration declarations — the ruled A-half of the business-hours question (#13655) #13801 (closed, completed), made the wall-clock unit explicit instead of building a calendar. Its in-seat ruling (comment 5506987580) found a clock annotation inert while only one clock exists.
- This card is the maintainer's own order to card the B-half. Whether that order meets the unfreeze condition is the reviewer's first question, not this card's assumption.
Questions for the review (not prescriptions)
- Shape. Working week and hours, holidays, date-specific overrides (调休 working days, plant shutdowns). Assigned per organization, business unit, region or plant, with a default. Time zone from the existing
iana_time_zonedomain. - Holiday data. Shipped yearly sets per country (who maintains CN's yearly 调休 list?), or org-entered only, or imported?
- First consumers (ADR-0049, enforce-or-remove). Candidates:
- approval escalation (a business-time clock beside wall-clock);
- formula and date functions (
addWorkingDays,workingDaysBetween); - SLA due-date computation for hooks and flows;
- date macros in filters.
A calendar nobody reads is inert.
- Clock declaration. With two clocks, Make the wall-clock unit un-misreadable in authored duration declarations — the ruled A-half of the business-hours question (#13655) #13801's finding reverses: a clock marker on duration-shaped keys becomes readable. Which keys get it, and what is the default?
- Boundaries. Shift rostering (HR) and finite-capacity scheduling (production) are suite work on top of this, not platform.
Non-goals
Shift rostering, capacity planning, payroll calendars, fiscal periods (the ERP owns the books).
Reader
- The maintainer's reviewing agent account reads this first and writes the design opinion; per the maintainer, no fable pass on this card.
- After his decision, the automation/data seat implements.
- hotcrm (case SLA), hotsrm and the production suite adopt.
Prior rulings read
business hours, holiday, working calendar, wall-clock → #13655 B-half frozen (named-external-user unfreeze), #13801 A-half closed completed with in-seat ruling 5506987580, #14483 (skills wall-clock clause, closed). Also #35328 (ruled A, 2026-11-19).
Dedupe
"business hours"→ 14, all closed."business-hours"→ 14, all closed."working calendar" OR "work calendar"→ 19, all closed.holiday→ 14, all closed.
No open card covers the capability.
Grade
area:workflow · Feature · maintainer-sourced (not table-graded) · reach: approval escalation counts wall-clock (read, approval.zod.ts:865-872), hotcrm SLA matrix wall-clock · evidence: read → p3 pending the review; the maintainer may regrade.
Generated by Claude Code
Activity
os-bill commentedon Nov 19, 2026
Maintainer ruling (Bill, 2026-11-19 05:47Z): 「同意 p1」
Bill approved the design below and regraded this card to p1.
Unfreeze. #13655 B-half was frozen with a "named external user" condition. The pull now comes from our own suites (hotcrm case SLA, hotsrm delivery dates, production). The maintainer's approval counts as unfreezing on that basis. The other #13655 constraint still holds: the calendar never ships without its formula surface, so they land in the same release.
Design.
sys_work_calendar(weekly pattern,HH:mmworking periods, requiredtimezonefrom theiana_time_zonedomain,is_default) andsys_work_calendar_exception(dated off/on overrides, one table for holidays, 调休 make-up workdays and plant shutdowns). Packages reference a calendar by code and may ship seed rows. Precedent:sys_exchange_rate(ADR-0144). One calendar service resolves and computes.sys_business_unit.timezonehas no reader today; another unread inherited column would be inert under ADR-0049). Region/plant are mapped to codes by suites.addWorkingDays,workingDaysBetween,addWorkingHours) and the approval escalation business-time clock, same release, separate cards.escalation.clock: 'wall_clock' | 'working_time'plus optionalcalendarcode. Default stayswall_clock: the sweep reads stored snapshots (packages/plugins/plugin-approvals/src/approval-service.ts~8055), so flipping the default would move existing deadlines. OnlytimeoutHoursgets it now; other duration keys one card each. Rewrite the describe text atpackages/spec/src/automation/approval.zod.ts:863-872.cel-to-filterrefuses all function calls today), with a lint. To filter on due time, compute it at write time into a datetime column and compare with{now}. No SQL-side calendar math.timezoneis required, prefilled from the org's effective time zone. First cut refuses periods crossing midnight; night-shift attribution is rostering, out of scope.Slices (in order). ADR → objects + service + Setup page → formula functions → approval clock key (last three in one release) → acceptance on the hotcrm case SLA matrix. Later: CN holiday data package, business-unit inheritance, date macros in filters, gantt reading the platform calendar.
Also found. The gantt view carries its own
skipWeekends/holidays(ui/packages/types/src/zod/objectql.zod.ts:2956-2957), a second source of truth. Follow-up: switch it to the platform calendar.Non-goals. Shift rostering, finite-capacity scheduling, payroll calendars, fiscal periods, per-country holidays in core, a clock key on every duration key, flipping the default clock.
Generated by Claude Code
objectstack-fleet commentedon Nov 19, 2026
triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH
Triage: parent of the working-calendar children (#35354, #35355, #35357…); rationale: area:workflow · Feature · maintainer-directed.
trackingis added so the parent is not dispatched; the grade stands as set.docs(adr): ADR-0157 status Accepted on the maintainer's rulings
objectstack-fleet commentedon Nov 24, 2026
repo:objectstack#4 · os-justin · session_01QSeKYpEsWWE9Y5YtSsDgqZ
Close-out · 2026-11-24T10:32Z · completed
The platform half of the working-calendar design (ruling 7000950747, 「同意 p1」) is delivered: its four slices are closed as completed — #35354 (ADR), #35355 (
sys_work_calendarobjects, calendar service and Setup page), #35356 (formula functionsaddWorkingDays/workingDaysBetween/ …) and #35357 (approval escalation clock key). Sub-issue summary reads 4 of 4 completed.What remains is not this repository's: the ruling's last slice, acceptance on the hotcrm case SLA matrix, and adoption by hotsrm and the production suite belong to those suites' own repos. The ruling's "later" items (a CN holiday data package, business-unit inheritance, date macros in filters, gantt reading the platform calendar) were named as later work with no card owed now; each is filed when it gets a pull.