Commit e0823de
authored
OFBIZ-13248 Calculate labor cost when production run is completed (#1026)
OFBIZ-13248 Calculate labor cost when production run is completed
Implemented the automatic calculation and recording of labor costs when
a production run is completed. This is achieved by creating TimeEntry
records associated with the production run task, using a specific labor
rate type.
**Changes made:**
**Data (Seed/Demo):**
- Added FLC (Factory Labor Cost) RateType in ManufacturingSeedData.xml.
- Added sample PartyRate data in ManufacturingDemoData.xml to support
testing of labor cost calculations.
**UI Labels:**
- Introduced new UI labels in ManufacturingUiLabels.xml for labor cost
visibility.
**Service Logic (ProductionRunServices.java):**
- Enhanced the production run completion flow to calculate labor hours
from the reported task time.
- Automatically invokes the createTimeEntry service with
rateTypeId="FLC" to record the labor cost for the work effort.
Thanks Pierre Smits and Jacopo for design details on ticket.1 parent 87adcf4 commit e0823de
4 files changed
Lines changed: 84 additions & 0 deletions
File tree
- applications
- datamodel/data
- demo
- seed
- manufacturing
- config
- src/main/java/org/apache/ofbiz/manufacturing/jobshopmgt
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
64 | 67 | | |
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
55 | 59 | | |
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4265 | 4265 | | |
4266 | 4266 | | |
4267 | 4267 | | |
| 4268 | + | |
| 4269 | + | |
| 4270 | + | |
| 4271 | + | |
| 4272 | + | |
| 4273 | + | |
| 4274 | + | |
| 4275 | + | |
4268 | 4276 | | |
4269 | 4277 | | |
4270 | 4278 | | |
| |||
Lines changed: 69 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1324 | 1324 | | |
1325 | 1325 | | |
1326 | 1326 | | |
| 1327 | + | |
| 1328 | + | |
| 1329 | + | |
| 1330 | + | |
| 1331 | + | |
| 1332 | + | |
| 1333 | + | |
| 1334 | + | |
| 1335 | + | |
| 1336 | + | |
| 1337 | + | |
| 1338 | + | |
| 1339 | + | |
| 1340 | + | |
| 1341 | + | |
| 1342 | + | |
| 1343 | + | |
| 1344 | + | |
| 1345 | + | |
| 1346 | + | |
| 1347 | + | |
| 1348 | + | |
| 1349 | + | |
| 1350 | + | |
| 1351 | + | |
| 1352 | + | |
| 1353 | + | |
| 1354 | + | |
| 1355 | + | |
| 1356 | + | |
| 1357 | + | |
| 1358 | + | |
| 1359 | + | |
| 1360 | + | |
| 1361 | + | |
| 1362 | + | |
| 1363 | + | |
| 1364 | + | |
| 1365 | + | |
| 1366 | + | |
| 1367 | + | |
| 1368 | + | |
| 1369 | + | |
| 1370 | + | |
| 1371 | + | |
| 1372 | + | |
| 1373 | + | |
| 1374 | + | |
| 1375 | + | |
| 1376 | + | |
| 1377 | + | |
1327 | 1378 | | |
1328 | 1379 | | |
1329 | 1380 | | |
| |||
2433 | 2484 | | |
2434 | 2485 | | |
2435 | 2486 | | |
| 2487 | + | |
| 2488 | + | |
| 2489 | + | |
| 2490 | + | |
| 2491 | + | |
| 2492 | + | |
| 2493 | + | |
| 2494 | + | |
| 2495 | + | |
| 2496 | + | |
| 2497 | + | |
| 2498 | + | |
| 2499 | + | |
| 2500 | + | |
| 2501 | + | |
| 2502 | + | |
| 2503 | + | |
| 2504 | + | |
2436 | 2505 | | |
2437 | 2506 | | |
2438 | 2507 | | |
| |||
0 commit comments