Skip to main content

Module as_built

Module as_built 

Source
Expand description

As-built records: hardware as it was really built.

An as-built item (type as_built, numbers AB-…) is one physical unit or lot. It has the usual lifecycle, revisions, files (photos, measurement reports, a 3D scan, the traveller) and change orders. A new revision of the as-built item is a new state of the same unit (rework, repair, retrofit); the old revision stays for traceability. On top of that an as-built revision has

  • a build record – the design revision (part, assembly or software) the unit was built to, serial or lot number, build date and note. The serial number is unique per design item. The design revision may be in work, in review or released (prototypes are built before the release); an obsolete revision is refused for a new record;
  • deviations – how the unit departs from its design (kind, feature, as designed, as built) and the disposition (open, use as is, rework, repair, scrap);
  • its BOM – the regular BOM of the revision, holding what was really installed. record_unit starts it as a copy of the design’s BOM; the BOM comparison between the design and the as-built revision shows the differences.

Record and deviations belong to the revision like BOM lines: changed only while it is checked out, copied by Revise, frozen at release. A change order with an as-built revision cannot be submitted while that revision has no build record or an open deviation (ensure_ready).

Structs§

BuildRecord
What an as-built revision was built to.
BuiltUnit
A unit built to a revision of a design item (the latest revision of its as-built item).
ConcessionReview
What the revision page shows about concessions: whether the group wants each “use as is” deviation confirmed, and whether the actor may confirm (a reviewer of a change order in review that contains the revision).
Deviation
How the built unit departs from its design.
DeviationInput
A deviation as entered.
DeviationPatch
Changed fields of a deviation; None keeps the stored value (patch_deviation).
DeviationSummary
Deviation counts of an as-built revision.
NewUnit
A new physical unit built to a design revision (record_unit).
RecordInput
The build record as entered.

Constants§

MAX_DEVIATIONS
At most this many deviations per as-built revision.
MAX_UNITS_LISTED
At most this many built units are listed on a design item.

Functions§

add_deviation
Adds a deviation to an as-built revision checked out by the actor.
built_units
Units built to any revision of the design item the actor may see (at most MAX_UNITS_LISTED); the second value counts the hidden ones.
concession_review
confirm_concession
A reviewer confirms a “use as is” deviation of an as-built revision in review – the separate acceptance of a concession (#152 step 9).
deviations
The deviations of an as-built revision the actor may read.
get_deviation
newer_design
“PRT-1/C is released (built to: B)” when a design revision newer than the one the unit was built to is released (pure).
parse_built_on
Parses an optional build date (YYYY-MM-DD; empty = none).
patch_deviation
Changes the given fields of a deviation of an as-built revision checked out by the actor. The stored deviation is read and merged while the revision row is locked – every writer of a deviation holds that lock – so two concurrent changes cannot overwrite each other’s fields.
record
The build record of an as-built revision the actor may read (None while none was entered).
record_unit
Records a physical unit built to the design revision design_revision_id: creates the as-built item (revision A, checked out by the actor) with its build record and, optionally, the design’s BOM – in one transaction.
remove_deviation
Removes a deviation from an as-built revision checked out by the actor.
set_record
Sets the build record of an as-built revision checked out by the actor.
summarize
update_deviation
Replaces every field of a deviation of an as-built revision checked out by the actor.