Skip to content

Commit a126fe9

Browse files
committed
add labor presets to API, new fields to project items
1 parent 3ae8fcf commit a126fe9

File tree

3 files changed

+88
-0
lines changed

3 files changed

+88
-0
lines changed

source/customers/index.html.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ includes:
1111
- customers/company
1212
- customers/clients
1313
- customers/clients/contacts
14+
- customers/labor_presets
1415
- customers/market_segments
1516
- customers/phases
1617
- customers/products
Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
# Labor Presets
2+
3+
## Get all labor presets in your company
4+
5+
<%= shell_example('/labor_presets') %>
6+
7+
> Response:
8+
9+
```json
10+
[
11+
{
12+
"id": 1,
13+
"name": "Labor Preset Name",
14+
"description": "Labor preset description",
15+
"project_item_count": 1,
16+
"created_at": "2025-02-04T14:31:52.488-08:00",
17+
"updated_at": "2025-02-05T12:34:16.028-08:00",
18+
"labor_values": [
19+
{
20+
"id": 6218030,
21+
"category": "engineering",
22+
"name": "Junior Designer",
23+
"cost": "10.0",
24+
"rate": "50.0",
25+
"minutes": "90.0",
26+
"created_at": "2025-02-04T14:31:52.491-08:00",
27+
"updated_at": "2025-02-05T12:34:16.024-08:00"
28+
},
29+
{
30+
"id": 6218031,
31+
"category": "install",
32+
"name": "Pre-Wire",
33+
"cost": "70.0",
34+
"rate": "165.0",
35+
"minutes": "15.0",
36+
"created_at": "2025-02-04T14:31:52.494-08:00",
37+
"updated_at": "2025-02-04T14:31:52.494-08:00"
38+
},
39+
{
40+
...
41+
}
42+
]
43+
}
44+
]
45+
```
46+
47+
> Status: 200 OK
48+
49+
This endpoint retrieves the labor presets in your company.
50+
51+
### Project Item Count
52+
53+
A labor preset's `project_item_count` is the number of project items that are using this labor preset.
54+
55+
### Labor Values
56+
Labor values include Labor Rate settings.
57+
58+
## Get one labor preset in your company
59+
60+
This endpoint retrieves a single labor preset in your company.
61+
62+
<%= shell_example('/labor_presets/<ID>') %>
63+
64+
> Response:
65+
66+
```json
67+
{
68+
"id": 1,
69+
"name": "Labor Preset Name",
70+
"description": "Labor preset description",
71+
"project_item_count": 1,
72+
"created_at": "2025-02-04T14:31:52.488-08:00",
73+
"updated_at": "2025-02-05T12:34:16.028-08:00",
74+
"labor_values": [
75+
{
76+
...
77+
},
78+
]
79+
}
80+
```
81+
82+
> Status: 200 OK

source/includes/customers/projects/_items.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
"currency_iso": "CAD"
4545
},
4646
"avso_item_name": "Subwoofer",
47+
"msrp_discount_percent": "-14.08",
4748
"discount": "0.0",
4849
"custom": false,
4950
"product_id": 1251085,
@@ -75,6 +76,10 @@
7576
},
7677
"phase": null,
7778
"option": null,
79+
"labor_preset": {
80+
"id": 1,
81+
"name": "Labor Preset Name"
82+
},
7883
"labor": [
7984
{
8085
"category": "install",

0 commit comments

Comments
 (0)