FG3-5 executable build — business-trip settlement process
Upgrades the FG3-5 sub-process from a composition stub to a Level 4 atomic executable: BPMN process Process_KomandejumaNorekina (trip-request processing, cancellation branch, expense-report submission and approval, VPC processing, reconciliation and outcome handling across the Nodarbinatais/Iestade/VPC lanes), DMN decision Decision_KomandejumaNorekins (FIRST hit policy, advance-vs-expense reconciliation with carry-forward to a next approved trip), resource roles/agents/mappings and policies metadata. Transcribed from the Valsts Kase FG3 register section 3.5.3. Validates against the UAPF 2.2.0 schemas and the uapf-cli validator.
This commit is contained in:
@@ -1,16 +1,76 @@
|
|||||||
# FG3-5 — Komandējuma norēķina veikšana
|
# FG3-5 — Komandējuma norēķina veikšana
|
||||||
|
|
||||||
Business-trip settlement: processing of travel advances and post-trip expense settlements against approved travel orders.
|
Level 4 atomic executable process for business-trip (travel) settlement — the
|
||||||
|
processing of trip requests, cancellations, post-trip expense reports and the
|
||||||
|
reconciliation of travel advances against documented expenses. The third FG3
|
||||||
|
sub-process taken to executable depth.
|
||||||
|
|
||||||
- **UAPF level:** L4 (atomic sub-process)
|
- **UAPF level:** L4 (atomic executable)
|
||||||
- **Package id:** `vk.gramatvediba.fg3-5`
|
- **Package id:** `vk.gramatvediba.fg3-5`
|
||||||
- **Source:** Valsts Kase *Grāmatvedības uzskaites procesu apraksts* — FG3
|
|
||||||
schema and process register.
|
|
||||||
- **Included by:** `processes/fg3` (function group FG3).
|
- **Included by:** `processes/fg3` (function group FG3).
|
||||||
|
- **Source:** Valsts Kase *Grāmatvedības uzskaites procesu apraksts* — FG3
|
||||||
|
process register, section 3.5.3 (*Komandējuma (darba brauciena) dokumenti un
|
||||||
|
to kustība*), with the advance-repayment tail in section 3.5.4.
|
||||||
|
|
||||||
|
## Process
|
||||||
|
|
||||||
|
`bpmn/komandejuma-norekina.bpmn` (`Process_KomandejumaNorekina`) transcribes
|
||||||
|
the business-trip settlement flow across three lanes mapped from the source
|
||||||
|
RACI columns:
|
||||||
|
|
||||||
|
- **Nodarbinātais** — submits the trip request (3.5.3.1) and, after the trip,
|
||||||
|
the expense report (3.5.3.3).
|
||||||
|
- **Iestāde** — approves the trip expense report in its defined flow.
|
||||||
|
- **VPC** — processes the request, annuls it if the trip is cancelled
|
||||||
|
(3.5.3.2), processes the report (3.5.3.4), reconciles it, and prepares a
|
||||||
|
repayment request, an additional payment, or posts the document.
|
||||||
|
|
||||||
|
Flow: request processing → cancellation branch → expense-report submission and
|
||||||
|
approval → VPC processing → reconciliation decision → one of three outcomes.
|
||||||
|
Two terminating states: *settlement posted* or *trip request annulled*.
|
||||||
|
|
||||||
|
## Decision
|
||||||
|
|
||||||
|
`dmn/komandejuma-norekins.dmn` (`Decision_KomandejumaNorekins`) is a `FIRST`
|
||||||
|
hit-policy decision table that sets the outcome variable `norekinResultats`
|
||||||
|
from two inputs:
|
||||||
|
|
||||||
|
| Input | Values |
|
||||||
|
|-------|--------|
|
||||||
|
| `avansaSituacija` | `nav-avansa`, `avanss-lielaks`, `avanss-vienads`, `izdevumi-lielaki` |
|
||||||
|
| `nakamaisKomandejums` | `ir`, `nav` |
|
||||||
|
|
||||||
|
Outcomes: `papildu-izmaksa` (no advance, or expenses exceed the advance —
|
||||||
|
the difference is paid to the employee), `slegts` (advance equals expenses),
|
||||||
|
`parnesums` (the advance exceeds expenses and the employee has a next approved
|
||||||
|
trip from the same funding — the balance carries forward to that trip),
|
||||||
|
`atmaksa` (the advance exceeds expenses with no next trip — the difference is
|
||||||
|
repaid). The `Task_NoteiktRezultatu` business-rule task evaluates it.
|
||||||
|
|
||||||
|
## Resources
|
||||||
|
|
||||||
|
`resources/mappings.yaml` binds every BPMN user task and the DMN decision to a
|
||||||
|
target in `resources/roles.yaml` / `resources/agents.yaml`. Human steps are
|
||||||
|
`manual`; the AI agent `agent.komandejumu-asistents` is bound `assisted` to the
|
||||||
|
request processing, the report processing and the reconciliation decision — it
|
||||||
|
extracts document data and proposes the outcome, the accountant decides. No
|
||||||
|
step is `autonomous`.
|
||||||
|
|
||||||
|
## Transcription note
|
||||||
|
|
||||||
|
The trip request itself is prepared and approved in the personnel-management
|
||||||
|
process (PP); FG3-5 begins where the request enters accounting handling, so
|
||||||
|
the start event represents that hand-off. Advance disbursement, the additional
|
||||||
|
payment and the detailed advance-repayment steps (3.5.4) are executed in their
|
||||||
|
own processes and are referenced rather than duplicated here. The carry-forward
|
||||||
|
rule (`parnesums`) transcribes the 3.5.4 condition that an advance surplus is
|
||||||
|
retained against a next approved trip from the same funding. Step identifiers
|
||||||
|
use stable BPMN/DMN element ids; reconciliation against the register `process
|
||||||
|
nr.` numbering is a tracked follow-up and any schema/register discrepancy is
|
||||||
|
recorded rather than silently resolved (see `docs/conventions.md`).
|
||||||
|
|
||||||
## Status
|
## Status
|
||||||
|
|
||||||
Draft composition placeholder. The sub-process is identified and wired into
|
Draft. The package is structurally complete and validates against the UAPF
|
||||||
FG3 via `includes`; its executable build (BPMN + DMN + resource mappings)
|
2.2.0 schemas; lifecycle status advances to `review` once the source-numbering
|
||||||
follows in a later step. FG3-1 is the sub-process taken to executable depth in
|
reconciliation is signed off.
|
||||||
this proof-of-concept.
|
|
||||||
|
|||||||
138
processes/fg3-5/bpmn/komandejuma-norekina.bpmn
Normal file
138
processes/fg3-5/bpmn/komandejuma-norekina.bpmn
Normal file
@@ -0,0 +1,138 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<bpmn:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL"
|
||||||
|
id="Defs_FG3_5_KomandejumaNorekina"
|
||||||
|
targetNamespace="https://uapf.dev/vk-gramatvediba/fg3-5">
|
||||||
|
<bpmn:process id="Process_KomandejumaNorekina"
|
||||||
|
name="Komandējuma norēķina veikšana"
|
||||||
|
isExecutable="true">
|
||||||
|
|
||||||
|
<bpmn:laneSet id="LaneSet_FG3_5">
|
||||||
|
<bpmn:lane id="Lane_Nodarbinatais" name="Nodarbinātais">
|
||||||
|
<bpmn:flowNodeRef>Start_PieteikumsIesniegts</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Task_IesniegtAtskaiti</bpmn:flowNodeRef>
|
||||||
|
</bpmn:lane>
|
||||||
|
<bpmn:lane id="Lane_Iestade" name="Iestāde (atbildīgā amatpersona)">
|
||||||
|
<bpmn:flowNodeRef>Task_SaskanotAtskaiti</bpmn:flowNodeRef>
|
||||||
|
</bpmn:lane>
|
||||||
|
<bpmn:lane id="Lane_VPC" name="VPC (Vienotais pakalpojumu centrs)">
|
||||||
|
<bpmn:flowNodeRef>Task_ApstradatPieteikumu</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Gateway_Atcelts</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Task_AnuletPieteikumu</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>End_Anulets</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Task_ApstradatAtskaiti</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Task_NoteiktRezultatu</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Gateway_Rezultats</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Task_PieprasitAtmaksu</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Task_SagatavotPapilduIzmaksu</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>Task_Iegramatot</bpmn:flowNodeRef>
|
||||||
|
<bpmn:flowNodeRef>End_Iegramatots</bpmn:flowNodeRef>
|
||||||
|
</bpmn:lane>
|
||||||
|
</bpmn:laneSet>
|
||||||
|
|
||||||
|
<bpmn:startEvent id="Start_PieteikumsIesniegts" name="Komandējuma pieteikums iesniegts">
|
||||||
|
<bpmn:documentation>Nodarbinātais iesniedz komandējuma (darba brauciena) pieteikumu Pašapkalpošanās portālā (HoP lietotnē "Komandējumi"). Pieteikuma sagatavošana un saskaņošana notiek personāla pārvaldības procesā (PP); FG3-5 sākas, kad pieteikums nonāk grāmatvedības apstrādē.</bpmn:documentation>
|
||||||
|
<bpmn:outgoing>F1</bpmn:outgoing>
|
||||||
|
</bpmn:startEvent>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_ApstradatPieteikumu" name="Apstrādāt komandējuma pieteikumu">
|
||||||
|
<bpmn:documentation>VPC, saņemot pieteikumu par komandējumu vai tā izmaiņām, veic pieteikuma apstrādi komandējuma dokumentos saskaņā ar Horizon projektējumā norādīto. Ja Nodarbinātajam komandējuma vajadzībām ir piešķirta Iestādei piesaistītā norēķinu karte, izmaksas tiek veiktas uz to, pārējos gadījumos — uz darbinieka algas kontu. Sistēma: RVS Horizon. SLA: ne vēlāk kā 2 darba dienas pirms komandējuma par dienas naudu; 3 darba dienas no apstiprināta pieteikuma saņemšanas, ja avanss pieprasīts citiem komandējuma izdevumiem. Procesa solis 3.5.3.1.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F1</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F2</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:exclusiveGateway id="Gateway_Atcelts" name="Komandējums atcelts?" default="F3">
|
||||||
|
<bpmn:incoming>F2</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F3</bpmn:outgoing>
|
||||||
|
<bpmn:outgoing>F4</bpmn:outgoing>
|
||||||
|
</bpmn:exclusiveGateway>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_AnuletPieteikumu" name="Anulēt komandējuma pieteikumu">
|
||||||
|
<bpmn:documentation>VPC, saņemot informāciju par komandējuma atcelšanu, anulē pieteikumu un pārbauda veiktās izmaksas. Izmaksu gadījumā tālāk rīkojas atbilstoši komandējuma pieteikumā norādītajam. Sistēma: RVS Horizon. SLA: 3 darba dienas no informācijas saņemšanas. Procesa solis 3.5.3.2.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F4</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F5</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:endEvent id="End_Anulets" name="Komandējuma pieteikums anulēts">
|
||||||
|
<bpmn:incoming>F5</bpmn:incoming>
|
||||||
|
</bpmn:endEvent>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_IesniegtAtskaiti" name="Iesniegt komandējuma izdevumu atskaiti">
|
||||||
|
<bpmn:documentation>Nodarbinātais (vai Iestāde, ja komandējumā nosūtīta persona, kas nav Iestādes Nodarbinātais) iesniedz komandējuma atskaiti Pašapkalpošanās portālā (HoP lietotnē "Komandējumi"). Atskaite jāiesniedz arī gadījumos, ja nav radušies papildu izdevumi. Sistēma: Pašapkalpošanās portāls. SLA: 10 darba dienas pēc atgriešanās no komandējuma. Procesa solis 3.5.3.3.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F3</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F6</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_SaskanotAtskaiti" name="Saskaņot komandējuma atskaiti">
|
||||||
|
<bpmn:documentation>Iestādes atbildīgā amatpersona saskaņo iesniegto komandējuma izdevumu atskaiti atbilstoši Iestādes definētajai saskaņošanas plūsmai. Sistēma: Pašapkalpošanās portāls.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F6</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F7</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_ApstradatAtskaiti" name="Apstrādāt komandējuma atskaiti">
|
||||||
|
<bpmn:documentation>VPC, saņemot komandējuma izdevumu atskaiti, veic atskaites apstrādi komandējuma dokumentos vai avansa norēķina dokumentos un nepieciešamības gadījumā atzīst prasības pret uzaicinātājpusi. Rezultāts: mainīgie avansaSituacija = "nav-avansa" | "avanss-lielaks" | "avanss-vienads" | "izdevumi-lielaki" un nakamaisKomandejums = "ir" | "nav". Sistēma: RVS Horizon. SLA: 3 darba dienas no atskaites apstiprināšanas. Procesa solis 3.5.3.4.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F7</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F8</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:businessRuleTask id="Task_NoteiktRezultatu" name="Noteikt norēķina rezultātu">
|
||||||
|
<bpmn:documentation>Automatizēti izvērtē komandējuma norēķina rezultātu, izpildot lēmumu Decision_KomandejumaNorekins (dmn/komandejuma-norekins.dmn). Ievaddati: avansaSituacija, nakamaisKomandejums. Rezultāts: mainīgais norekinResultats.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F8</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F9</bpmn:outgoing>
|
||||||
|
</bpmn:businessRuleTask>
|
||||||
|
|
||||||
|
<bpmn:exclusiveGateway id="Gateway_Rezultats" name="Norēķina rezultāts?" default="F10">
|
||||||
|
<bpmn:incoming>F9</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F10</bpmn:outgoing>
|
||||||
|
<bpmn:outgoing>F11</bpmn:outgoing>
|
||||||
|
<bpmn:outgoing>F12</bpmn:outgoing>
|
||||||
|
</bpmn:exclusiveGateway>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_PieprasitAtmaksu" name="Pieprasīt avansa atmaksu">
|
||||||
|
<bpmn:documentation>VPC informē Atbalsta sistēmā (Redmine) Iestādi par nepieciešamību veikt avansa atmaksu, ja izmaksātais komandējuma avanss pārsniedz iesniegtos attaisnojuma izdevumus un nav apstiprināts nākamais komandējums no tā paša finansējuma. Sistēma: RVS Horizon, Atbalsta sistēma (Redmine). Saistīts process: 3.5.4 (Avansa atmaksas).</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F11</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F13</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_SagatavotPapilduIzmaksu" name="Sagatavot papildu izmaksas priekšlikumu">
|
||||||
|
<bpmn:documentation>Ja iesniegtie attaisnojuma izdevumi pārsniedz izmaksāto avansu (vai avanss nav bijis), VPC sagatavo papildu izmaksas priekšlikumu Nodarbinātajam par starpību. Izmaksa tiek veikta FG2 maksājumu procesā. Sistēma: RVS Horizon.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F12</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F14</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:userTask id="Task_Iegramatot" name="Iegrāmatot komandējuma norēķinu">
|
||||||
|
<bpmn:documentation>VPC iegrāmato komandējuma norēķina dokumentu grāmatvedības informācijas sistēmā. Ja izmaksātais avanss pārsniedz izdevumus un Nodarbinātajam ir apstiprināts nākamais komandējums no tā paša finansējuma, avansa atlikums tiek saglabāts (pārnests) uz nākamo apstiprināto komandējumu. Sistēma: RVS Horizon.</bpmn:documentation>
|
||||||
|
<bpmn:incoming>F10</bpmn:incoming>
|
||||||
|
<bpmn:incoming>F13</bpmn:incoming>
|
||||||
|
<bpmn:incoming>F14</bpmn:incoming>
|
||||||
|
<bpmn:outgoing>F15</bpmn:outgoing>
|
||||||
|
</bpmn:userTask>
|
||||||
|
|
||||||
|
<bpmn:endEvent id="End_Iegramatots" name="Komandējuma norēķins iegrāmatots">
|
||||||
|
<bpmn:incoming>F15</bpmn:incoming>
|
||||||
|
</bpmn:endEvent>
|
||||||
|
|
||||||
|
<bpmn:sequenceFlow id="F1" sourceRef="Start_PieteikumsIesniegts" targetRef="Task_ApstradatPieteikumu"/>
|
||||||
|
<bpmn:sequenceFlow id="F2" sourceRef="Task_ApstradatPieteikumu" targetRef="Gateway_Atcelts"/>
|
||||||
|
<bpmn:sequenceFlow id="F3" name="norisinās" sourceRef="Gateway_Atcelts" targetRef="Task_IesniegtAtskaiti"/>
|
||||||
|
<bpmn:sequenceFlow id="F4" name="atcelts" sourceRef="Gateway_Atcelts" targetRef="Task_AnuletPieteikumu">
|
||||||
|
<bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">komandejumsAtcelts = "ja"</bpmn:conditionExpression>
|
||||||
|
</bpmn:sequenceFlow>
|
||||||
|
<bpmn:sequenceFlow id="F5" sourceRef="Task_AnuletPieteikumu" targetRef="End_Anulets"/>
|
||||||
|
<bpmn:sequenceFlow id="F6" sourceRef="Task_IesniegtAtskaiti" targetRef="Task_SaskanotAtskaiti"/>
|
||||||
|
<bpmn:sequenceFlow id="F7" sourceRef="Task_SaskanotAtskaiti" targetRef="Task_ApstradatAtskaiti"/>
|
||||||
|
<bpmn:sequenceFlow id="F8" sourceRef="Task_ApstradatAtskaiti" targetRef="Task_NoteiktRezultatu"/>
|
||||||
|
<bpmn:sequenceFlow id="F9" sourceRef="Task_NoteiktRezultatu" targetRef="Gateway_Rezultats"/>
|
||||||
|
<bpmn:sequenceFlow id="F10" name="slēgts / pārnesums" sourceRef="Gateway_Rezultats" targetRef="Task_Iegramatot"/>
|
||||||
|
<bpmn:sequenceFlow id="F11" name="atmaksa" sourceRef="Gateway_Rezultats" targetRef="Task_PieprasitAtmaksu">
|
||||||
|
<bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">norekinResultats = "atmaksa"</bpmn:conditionExpression>
|
||||||
|
</bpmn:sequenceFlow>
|
||||||
|
<bpmn:sequenceFlow id="F12" name="papildu-izmaksa" sourceRef="Gateway_Rezultats" targetRef="Task_SagatavotPapilduIzmaksu">
|
||||||
|
<bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">norekinResultats = "papildu-izmaksa"</bpmn:conditionExpression>
|
||||||
|
</bpmn:sequenceFlow>
|
||||||
|
<bpmn:sequenceFlow id="F13" sourceRef="Task_PieprasitAtmaksu" targetRef="Task_Iegramatot"/>
|
||||||
|
<bpmn:sequenceFlow id="F14" sourceRef="Task_SagatavotPapilduIzmaksu" targetRef="Task_Iegramatot"/>
|
||||||
|
<bpmn:sequenceFlow id="F15" sourceRef="Task_Iegramatot" targetRef="End_Iegramatots"/>
|
||||||
|
|
||||||
|
</bpmn:process>
|
||||||
|
</bpmn:definitions>
|
||||||
74
processes/fg3-5/dmn/komandejuma-norekins.dmn
Normal file
74
processes/fg3-5/dmn/komandejuma-norekins.dmn
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<dmn:definitions xmlns:dmn="https://www.omg.org/spec/DMN/20191111/MODEL/"
|
||||||
|
id="Defs_FG3_5_KomandejumaNorekins"
|
||||||
|
name="KomandejumaNorekins"
|
||||||
|
namespace="https://uapf.dev/vk-gramatvediba/fg3-5">
|
||||||
|
|
||||||
|
<dmn:inputData id="Input_AvansaSituacija" name="avansaSituacija"/>
|
||||||
|
<dmn:inputData id="Input_NakamaisKomandejums" name="nakamaisKomandejums"/>
|
||||||
|
|
||||||
|
<dmn:decision id="Decision_KomandejumaNorekins" name="Komandējuma norēķina rezultāts">
|
||||||
|
<dmn:description>Nosaka komandējuma avansa norēķina rezultātu, salīdzinot izmaksāto avansu ar iesniegtajiem attaisnojuma izdevumiem un ņemot vērā, vai Nodarbinātajam ir apstiprināts nākamais komandējums no tā paša finansējuma.</dmn:description>
|
||||||
|
<dmn:informationRequirement id="IR_Situacija">
|
||||||
|
<dmn:requiredInput href="#Input_AvansaSituacija"/>
|
||||||
|
</dmn:informationRequirement>
|
||||||
|
<dmn:informationRequirement id="IR_Nakamais">
|
||||||
|
<dmn:requiredInput href="#Input_NakamaisKomandejums"/>
|
||||||
|
</dmn:informationRequirement>
|
||||||
|
|
||||||
|
<dmn:decisionTable id="DT_KomandejumaNorekins" hitPolicy="FIRST">
|
||||||
|
<dmn:input id="In_Situacija" label="Avansa un izdevumu attiecība">
|
||||||
|
<dmn:inputExpression id="InExpr_Situacija" typeRef="string">
|
||||||
|
<dmn:text>avansaSituacija</dmn:text>
|
||||||
|
</dmn:inputExpression>
|
||||||
|
<dmn:inputValues id="InVals_Situacija">
|
||||||
|
<dmn:text>"nav-avansa","avanss-lielaks","avanss-vienads","izdevumi-lielaki"</dmn:text>
|
||||||
|
</dmn:inputValues>
|
||||||
|
</dmn:input>
|
||||||
|
<dmn:input id="In_Nakamais" label="Nākamais komandējums no tā paša finansējuma">
|
||||||
|
<dmn:inputExpression id="InExpr_Nakamais" typeRef="string">
|
||||||
|
<dmn:text>nakamaisKomandejums</dmn:text>
|
||||||
|
</dmn:inputExpression>
|
||||||
|
<dmn:inputValues id="InVals_Nakamais">
|
||||||
|
<dmn:text>"ir","nav"</dmn:text>
|
||||||
|
</dmn:inputValues>
|
||||||
|
</dmn:input>
|
||||||
|
<dmn:output id="Out_Rezultats" label="Norēķina rezultāts" name="norekinResultats" typeRef="string">
|
||||||
|
<dmn:outputValues id="OutVals_Rezultats">
|
||||||
|
<dmn:text>"slegts","atmaksa","papildu-izmaksa","parnesums"</dmn:text>
|
||||||
|
</dmn:outputValues>
|
||||||
|
</dmn:output>
|
||||||
|
|
||||||
|
<dmn:rule id="Rule_1">
|
||||||
|
<dmn:description>Avanss nav bijis — izdevumi atlīdzināmi pilnā apmērā kā papildu izmaksa.</dmn:description>
|
||||||
|
<dmn:inputEntry id="R1_Situacija"><dmn:text>"nav-avansa"</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:inputEntry id="R1_Nakamais"><dmn:text>-</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:outputEntry id="R1_Out"><dmn:text>"papildu-izmaksa"</dmn:text></dmn:outputEntry>
|
||||||
|
</dmn:rule>
|
||||||
|
<dmn:rule id="Rule_2">
|
||||||
|
<dmn:description>Izdevumi pārsniedz avansu — starpība atlīdzināma kā papildu izmaksa.</dmn:description>
|
||||||
|
<dmn:inputEntry id="R2_Situacija"><dmn:text>"izdevumi-lielaki"</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:inputEntry id="R2_Nakamais"><dmn:text>-</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:outputEntry id="R2_Out"><dmn:text>"papildu-izmaksa"</dmn:text></dmn:outputEntry>
|
||||||
|
</dmn:rule>
|
||||||
|
<dmn:rule id="Rule_3">
|
||||||
|
<dmn:description>Avanss vienāds ar izdevumiem — norēķins slēgts bez papildu darbībām.</dmn:description>
|
||||||
|
<dmn:inputEntry id="R3_Situacija"><dmn:text>"avanss-vienads"</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:inputEntry id="R3_Nakamais"><dmn:text>-</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:outputEntry id="R3_Out"><dmn:text>"slegts"</dmn:text></dmn:outputEntry>
|
||||||
|
</dmn:rule>
|
||||||
|
<dmn:rule id="Rule_4">
|
||||||
|
<dmn:description>Avanss pārsniedz izdevumus un ir apstiprināts nākamais komandējums no tā paša finansējuma — atlikums pārnests.</dmn:description>
|
||||||
|
<dmn:inputEntry id="R4_Situacija"><dmn:text>"avanss-lielaks"</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:inputEntry id="R4_Nakamais"><dmn:text>"ir"</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:outputEntry id="R4_Out"><dmn:text>"parnesums"</dmn:text></dmn:outputEntry>
|
||||||
|
</dmn:rule>
|
||||||
|
<dmn:rule id="Rule_5">
|
||||||
|
<dmn:description>Avanss pārsniedz izdevumus un nav nākamā komandējuma — starpība atmaksājama.</dmn:description>
|
||||||
|
<dmn:inputEntry id="R5_Situacija"><dmn:text>"avanss-lielaks"</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:inputEntry id="R5_Nakamais"><dmn:text>-</dmn:text></dmn:inputEntry>
|
||||||
|
<dmn:outputEntry id="R5_Out"><dmn:text>"atmaksa"</dmn:text></dmn:outputEntry>
|
||||||
|
</dmn:rule>
|
||||||
|
</dmn:decisionTable>
|
||||||
|
</dmn:decision>
|
||||||
|
</dmn:definitions>
|
||||||
@@ -2,3 +2,8 @@ kind: uapf.metadata.lifecycle
|
|||||||
status: draft
|
status: draft
|
||||||
created: "2026-05-19T00:00:00Z"
|
created: "2026-05-19T00:00:00Z"
|
||||||
lastModified: "2026-05-19T00:00:00Z"
|
lastModified: "2026-05-19T00:00:00Z"
|
||||||
|
changeHistory:
|
||||||
|
- version: 0.1.0
|
||||||
|
date: "2026-05-19"
|
||||||
|
summary: "Initial executable build — BPMN process, DMN settlement-reconciliation decision and resource mappings."
|
||||||
|
author: vpc.process-office
|
||||||
|
|||||||
18
processes/fg3-5/metadata/policies.yaml
Normal file
18
processes/fg3-5/metadata/policies.yaml
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
kind: uapf.policies
|
||||||
|
classification:
|
||||||
|
level: internal
|
||||||
|
dataCategories:
|
||||||
|
- financial-records
|
||||||
|
- employee-data
|
||||||
|
execution:
|
||||||
|
requiresApproval: false
|
||||||
|
auditRequired: true
|
||||||
|
allowedEnvironments:
|
||||||
|
- development
|
||||||
|
- staging
|
||||||
|
- production
|
||||||
|
delegation:
|
||||||
|
allowAgentDelegation: true
|
||||||
|
maxDelegationDepth: 2
|
||||||
|
trustedAgents:
|
||||||
|
- agent.komandejumu-asistents
|
||||||
9
processes/fg3-5/resources/agents.yaml
Normal file
9
processes/fg3-5/resources/agents.yaml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
kind: uapf.resources.agents
|
||||||
|
agents:
|
||||||
|
- id: agent.komandejumu-asistents
|
||||||
|
name: Komandējumu norēķinu apstrādes asistents
|
||||||
|
type: ai_agent
|
||||||
|
capabilities:
|
||||||
|
- capability.document.extract
|
||||||
|
- capability.policy.lookup
|
||||||
|
- capability.decision.assist
|
||||||
83
processes/fg3-5/resources/mappings.yaml
Normal file
83
processes/fg3-5/resources/mappings.yaml
Normal file
@@ -0,0 +1,83 @@
|
|||||||
|
kind: uapf.resources.mapping
|
||||||
|
|
||||||
|
targets:
|
||||||
|
- id: role.nodarbinatais
|
||||||
|
type: human_role
|
||||||
|
name: Nodarbinātais (iestāde)
|
||||||
|
- id: role.atbildigais
|
||||||
|
type: human_role
|
||||||
|
name: Atbildīgā amatpersona (iestāde)
|
||||||
|
- id: role.gramatvedis
|
||||||
|
type: human_role
|
||||||
|
name: Grāmatvedis (VPC)
|
||||||
|
- id: agent.komandejumu-asistents
|
||||||
|
type: ai_agent
|
||||||
|
name: Komandējumu norēķinu apstrādes asistents
|
||||||
|
capabilities:
|
||||||
|
- capability.document.extract
|
||||||
|
- capability.policy.lookup
|
||||||
|
- capability.decision.assist
|
||||||
|
|
||||||
|
bindings:
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_ApstradatPieteikumu
|
||||||
|
targetId: agent.komandejumu-asistents
|
||||||
|
mode: assisted
|
||||||
|
notes: "Asistents apstrādā komandējuma pieteikumu komandējuma dokumentos un sagatavo avansa aprēķinu; grāmatvedis apstiprina."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_AnuletPieteikumu
|
||||||
|
targetId: role.gramatvedis
|
||||||
|
mode: manual
|
||||||
|
notes: "Grāmatvedis anulē atcelto komandējuma pieteikumu un pārbauda veiktās izmaksas."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_IesniegtAtskaiti
|
||||||
|
targetId: role.nodarbinatais
|
||||||
|
mode: manual
|
||||||
|
notes: "Nodarbinātais iesniedz komandējuma izdevumu atskaiti un pievieno apliecinošos dokumentus."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_SaskanotAtskaiti
|
||||||
|
targetId: role.atbildigais
|
||||||
|
mode: manual
|
||||||
|
notes: "Iestādes atbildīgā amatpersona saskaņo komandējuma izdevumu atskaiti."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_ApstradatAtskaiti
|
||||||
|
targetId: agent.komandejumu-asistents
|
||||||
|
mode: assisted
|
||||||
|
notes: "Asistents izgūst rekvizītus no apliecinošajiem dokumentiem un sagatavo avansa/izdevumu salīdzinājumu; grāmatvedis apstiprina."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: dmn.decision
|
||||||
|
ref: Decision_KomandejumaNorekins
|
||||||
|
targetId: agent.komandejumu-asistents
|
||||||
|
mode: assisted
|
||||||
|
notes: "Asistents izpilda norēķina rezultāta lēmumu tabulu un sniedz rezultāta priekšlikumu ar pamatojumu."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_PieprasitAtmaksu
|
||||||
|
targetId: role.gramatvedis
|
||||||
|
mode: manual
|
||||||
|
notes: "Grāmatvedis sagatavo avansa atmaksas pieprasījumu Atbalsta sistēmā (Redmine)."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_SagatavotPapilduIzmaksu
|
||||||
|
targetId: role.gramatvedis
|
||||||
|
mode: manual
|
||||||
|
notes: "Grāmatvedis sagatavo papildu izmaksas priekšlikumu par avansu pārsniedzošajiem izdevumiem."
|
||||||
|
|
||||||
|
- source:
|
||||||
|
type: bpmn.userTask
|
||||||
|
ref: Task_Iegramatot
|
||||||
|
targetId: role.gramatvedis
|
||||||
|
mode: manual
|
||||||
|
notes: "Grāmatvedis iegrāmato komandējuma norēķina dokumentu grāmatvedības informācijas sistēmā."
|
||||||
11
processes/fg3-5/resources/roles.yaml
Normal file
11
processes/fg3-5/resources/roles.yaml
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
kind: uapf.resources.roles
|
||||||
|
roles:
|
||||||
|
- id: role.nodarbinatais
|
||||||
|
name: Nodarbinātais (iestāde)
|
||||||
|
description: Iesniedz komandējuma pieteikumu un pēc komandējuma — komandējuma izdevumu atskaiti ar apliecinošiem dokumentiem.
|
||||||
|
- id: role.atbildigais
|
||||||
|
name: Atbildīgā amatpersona (iestāde)
|
||||||
|
description: Saskaņo iesniegto komandējuma izdevumu atskaiti atbilstoši Iestādes definētajai plūsmai.
|
||||||
|
- id: role.gramatvedis
|
||||||
|
name: Grāmatvedis (VPC)
|
||||||
|
description: Apstrādā komandējuma pieteikumu un atskaiti, anulē atceltus pieteikumus, sagatavo avansa atmaksas pieprasījumu vai papildu izmaksas priekšlikumu un iegrāmato norēķinu.
|
||||||
@@ -1,15 +1,60 @@
|
|||||||
kind: uapf.package
|
kind: uapf.package
|
||||||
id: vk.gramatvediba.fg3-5
|
id: vk.gramatvediba.fg3-5
|
||||||
name: "FG3-5 — Komandējuma norēķina veikšana"
|
name: "FG3-5 — Komandējuma norēķina veikšana"
|
||||||
description: "Business-trip settlement: processing of travel advances and post-trip expense settlements against approved travel orders."
|
description: "Level 4 atomic executable process: processing of business-trip (travel) requests and cancellations, submission and approval of post-trip expense reports, VPC processing, advance-vs-expense reconciliation and the resulting repayment, additional payment or carry-forward to a next approved trip. The third FG3 sub-process taken to executable depth (BPMN + DMN + resource mappings)."
|
||||||
level: 4
|
level: 4
|
||||||
version: 0.1.0
|
version: 0.1.0
|
||||||
includes: []
|
includes: []
|
||||||
cornerstones:
|
cornerstones:
|
||||||
bpmn: false
|
bpmn: true
|
||||||
dmn: false
|
dmn: true
|
||||||
cmmn: false
|
cmmn: false
|
||||||
resources: false
|
resources: true
|
||||||
|
paths:
|
||||||
|
bpmn: bpmn
|
||||||
|
dmn: dmn
|
||||||
|
cmmn: cmmn
|
||||||
|
resources: resources
|
||||||
|
metadata: metadata
|
||||||
|
exposure:
|
||||||
|
mcp:
|
||||||
|
enabled: true
|
||||||
|
runnable: true
|
||||||
|
exposedEntrypoints:
|
||||||
|
- process: Process_KomandejumaNorekina
|
||||||
|
tool: vk.fg3-5.run
|
||||||
|
- decision: Decision_KomandejumaNorekins
|
||||||
|
tool: vk.fg3-5.evaluate-settlement
|
||||||
|
exposedArtifacts:
|
||||||
|
- manifest
|
||||||
|
- bpmn
|
||||||
|
- dmn
|
||||||
|
inputs:
|
||||||
|
- komandejuma-pieteikums
|
||||||
|
- komandejuma-izdevumu-atskaite
|
||||||
|
outputs:
|
||||||
|
- iegramatots-norekins
|
||||||
|
- avansa-atmaksas-pieprasijums
|
||||||
|
- papildu-izmaksas-priekslikums
|
||||||
|
artifacts:
|
||||||
|
bpmn:
|
||||||
|
- path: bpmn/komandejuma-norekina.bpmn
|
||||||
|
role: primary-process
|
||||||
|
description: "Business-trip settlement: trip-request processing, cancellation branch, expense-report submission and approval, VPC processing, reconciliation and outcome handling."
|
||||||
|
dmn:
|
||||||
|
- path: dmn/komandejuma-norekins.dmn
|
||||||
|
role: routing-decision
|
||||||
|
description: "Reconciles the trip advance against documented expenses and the existence of a next trip, and sets the settlement outcome."
|
||||||
|
resources:
|
||||||
|
- path: resources/roles.yaml
|
||||||
|
role: roles
|
||||||
|
description: "Human roles participating in the process."
|
||||||
|
- path: resources/agents.yaml
|
||||||
|
role: agents
|
||||||
|
description: "AI agent declared for assisted steps."
|
||||||
|
- path: resources/mappings.yaml
|
||||||
|
role: resource-mapping
|
||||||
|
description: "Bindings of BPMN tasks and the DMN decision to targets."
|
||||||
owners:
|
owners:
|
||||||
- type: team
|
- type: team
|
||||||
id: vpc
|
id: vpc
|
||||||
|
|||||||
Reference in New Issue
Block a user