After a clean check the page loads the existing works of each object and
shows how many works will be created and updated. "Import" writes them
with the same requests as the work dialog: a work with the same title on
the object gets only its planned volume and unit updated, so loading the
same file again does not duplicate works.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The /Import/StroyBot/Reports endpoint only validates the file, so the
check now runs as soon as a file is picked. When there are no errors,
"Import" builds the reports from the ids in the response and saves them
with the same Dataverse code as the report form: one report per date,
company, shift and object; resources nested under their work; idle and
repair hours as separate rows.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Ports the weather check added to stroy-bot-main on 2026-10-16: daily
station weather, report positions with weather per shift and the AI
assessment of working conditions. Opens as ?page=weather&start=&end=
instead of the #weathercheck hash, and hub dates survive the way back.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Import tests wait for an estimate in the catalogue: the API returns
totalCount 0 for every project.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Units dictionary has around a hundred entries; typing now filters the
list and Enter picks the first match. Only dictionary values can be
chosen, as before. Generic SearchableSelect lives in shared until the
ui-kit gets one.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
With two tabs open (or two users) the same profession or company could
be assigned twice, because only the list loaded in the tab was checked.
Before creating an assignment the server is now asked whether it already
exists; if so its id is reused. Found in T-RES-03.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Status choices in the Проекты list are Текущий / Архивный, so the legacy
archive rule matches real data; the projects portal writes its own
status to the API catalogue, which StroyBot does not read.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Scenarios per section with expected results, role switching with one
account, side-by-side comparison with the legacy pages and a bug report
template, so the workbench check can be done systematically.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
All eight sections of the old stroy-bot-* web parts are now reachable
from the app. Unknown routes fall back to the hub.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Tree table of an object's works from Dataverse with add / add child /
edit / delete, "save and add more", units dictionary and parent
re-binding, 1:1 with the legacy web part. Reuses the tree widgets from
the objects page; the parent navigation property lookup is cached as a
single promise so concurrent saves don't race.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Project object tree with add/edit/delete, drag & drop re-parenting,
context menu and Excel export, 1:1 with the legacy web part. The tree
widgets live in pages/_tree so the works page can reuse them.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Moves estimate work import into the app as ?page=import&projectId=.
Behaviour is kept 1:1 with the legacy web part: project lookup with
UniqueId0 check, project objects query, works paging by 200 with the
progress text, 250 ms debounced search over the same fields, 100 rows
per page, select-all over all filtered not-imported works, duplicate
protection via cree9_comment, the same Dataverse POST body, import into
the selected object and import with object creation (find or create
root and child in «Объекты», cached per pair), toasts and all texts.
The object picker still shows only the first 100 matches (legacy bug).
HTTP-response errors are detected by their status field instead of
instanceof HttpError, which does not survive the ES5 build target.
Deviations are listed in docs/MIGRATION-CHECKLIST.md section 6.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Moves the project report list into the app as ?page=reports&projectId=.
Behaviour is kept 1:1 with the legacy web part: the same «Доступы» query
(lookup user/Id + project/Id), «Компании»/«Объекты» reference loads,
Dataverse cree9_reports query with the date filter and ordering, client
side sort and search, permission rules for send/copy/delete, soft delete
via PATCH cree9_deleted=true and all user-facing texts.
Known bugs are ported as-is (no Dataverse paging, default week in UTC).
Links to SendReport.aspx now point to the in-app report form route; the
report and copy links still open in a new tab. Deviations are listed in
docs/MIGRATION-CHECKLIST.md section 4.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Add the "binder" section (?page=binder&projectId=): links a SharePoint
project to the TNSU API project catalogue by writing UniqueId0/UniqueName
to the "Проекты" list.
The class component is rewritten as function components with hooks while
keeping the legacy behaviour and texts: the same project GET with
odata=nometadata and empty odata-version, MERGE with IF-MATCH * for
bind/unbind (no confirmation), catalogue search with 400 ms debounce and
20-per-page paging, card select/deselect, status colours, ru-RU dates and
HTML-entity decoding of the address. Fluent UI is replaced with ui-kit.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Add the "resources" section (?page=resources&projectId=): professions and
companies assigned to a project, with the same lists, fields, texts and
optimistic add/remove with rollback as the legacy web part.
PnPjs is replaced by SharePoint REST through the app's IHttpClient so the
bundle needs no new dependency: the same $select/$expand/$filter, PnP paging
replaced by following odata.nextLink, adds as POST to items with the same
body, deletes as POST with X-HTTP-Method DELETE and IF-MATCH *. Known legacy
edge cases (temporary negative id) are kept and listed in the checklist.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Common rules for moving the remaining stroy-bot-* sections into the
monorepo, so every section follows the same structure and keeps 1:1
behaviour with its old web part.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Project picker, section cards and the period Excel export now live on the
app's home page. The selected project is shared app state, so the sidebar
hides sections with the same rules main used to disable its cards
(archived, finished, no edit0 right).
Queries are 1:1 with stroy-bot-main and covered by tests against a fake
HTTP client. Behaviour differences are listed in the migration checklist.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
One web part replaces the separate stroy-bot-* web parts. The section and
its parameters live in the page query string (?page=objects&projectId=5),
so links can be copied, opened in a new tab and the browser Back button works.
- shared config: site/Dataverse/API addresses, list and table names
- HTTP layer behind IHttpClient so repositories can be unit-tested
- ui-kit AppLayout + Sidebar, placeholder for sections not ported yet
- migration checklist with every feature of the old web parts
- design tokens mirrored from ui-kit instead of 8 copies
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>