wenmar 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/LICENSE +21 -0
- data/README.md +162 -0
- data/lib/wenmar/auth.rb +98 -0
- data/lib/wenmar/client.rb +222 -0
- data/lib/wenmar/config.rb +34 -0
- data/lib/wenmar/credentials.rb +124 -0
- data/lib/wenmar/error.rb +108 -0
- data/lib/wenmar/oauth.rb +53 -0
- data/lib/wenmar/pagination.rb +90 -0
- data/lib/wenmar/resources.rb +2588 -0
- data/lib/wenmar/token.rb +54 -0
- data/lib/wenmar/version.rb +5 -0
- data/lib/wenmar.rb +15 -0
- metadata +97 -0
|
@@ -0,0 +1,2588 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# AUTO-GENERATED by scripts/generate_ruby_resources.rb from spec/operations.json. DO NOT EDIT.
|
|
4
|
+
|
|
5
|
+
module Wenmar
|
|
6
|
+
class Client
|
|
7
|
+
# Runs archive_customer (PATCH /customers/{id}/archive).
|
|
8
|
+
def archive_customer(id)
|
|
9
|
+
patch("/customers/#{id}/archive")
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
# Runs archive_inspection (PATCH /inspections/{id}/archive).
|
|
13
|
+
def archive_inspection(id)
|
|
14
|
+
patch("/inspections/#{id}/archive")
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
# Runs archive_labor_rate (PATCH /labor_rates/{id}/archive).
|
|
18
|
+
def archive_labor_rate(id)
|
|
19
|
+
patch("/labor_rates/#{id}/archive")
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
# Runs archive_package (PATCH /packages/{id}/archive).
|
|
23
|
+
def archive_package(id)
|
|
24
|
+
patch("/packages/#{id}/archive")
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
# Runs archive_service_category (PATCH /service_categories/{id}/archive).
|
|
28
|
+
def archive_service_category(id)
|
|
29
|
+
patch("/service_categories/#{id}/archive")
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
# Runs archive_vehicle (PATCH /vehicles/{id}/archive).
|
|
33
|
+
def archive_vehicle(id)
|
|
34
|
+
patch("/vehicles/#{id}/archive")
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Runs archive_vendor (PATCH /vendors/{id}/archive).
|
|
38
|
+
def archive_vendor(id)
|
|
39
|
+
patch("/vendors/#{id}/archive")
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
# Fetches check_customer_duplicate.
|
|
43
|
+
def check_customer_duplicate(email: nil, first_name: nil, last_name: nil, phone: nil)
|
|
44
|
+
params = {"email" => email, "first_name" => first_name, "last_name" => last_name, "phone" => phone}
|
|
45
|
+
get("/customers/check_duplicate", params.compact)
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Fetches check_vehicle_duplicate.
|
|
49
|
+
def check_vehicle_duplicate(vin: nil)
|
|
50
|
+
params = {"vin" => vin}
|
|
51
|
+
get("/vehicles/check_duplicate", params.compact)
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
# Runs close_work_order (POST /work_orders/{id}/close).
|
|
55
|
+
def close_work_order(id)
|
|
56
|
+
post("/work_orders/#{id}/close")
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
# Runs complete_inspection_report (PATCH /inspection_reports/{id}/complete).
|
|
60
|
+
def complete_inspection_report(id)
|
|
61
|
+
patch("/inspection_reports/#{id}/complete")
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
# Runs complete_work_order (POST /work_orders/{id}/complete).
|
|
65
|
+
def complete_work_order(id, work_order_completion_form:)
|
|
66
|
+
post("/work_orders/#{id}/complete", {work_order_completion_form: work_order_completion_form})
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
# Runs create_account_api_token (POST /account/api_tokens).
|
|
70
|
+
def create_account_api_token(api_token:)
|
|
71
|
+
post("/account/api_tokens", {api_token: api_token})
|
|
72
|
+
end
|
|
73
|
+
|
|
74
|
+
# Runs create_account_station_link_regenerate (POST /account/station_link/regenerate).
|
|
75
|
+
def create_account_station_link_regenerate
|
|
76
|
+
post("/account/station_link/regenerate")
|
|
77
|
+
end
|
|
78
|
+
|
|
79
|
+
# Runs create_appointment (POST /appointments).
|
|
80
|
+
def create_appointment(appointment:)
|
|
81
|
+
post("/appointments", {appointment: appointment})
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
# Runs create_appointments_approval (POST /appointments/{id}/approvals).
|
|
85
|
+
def create_appointments_approval(id)
|
|
86
|
+
post("/appointments/#{id}/approvals")
|
|
87
|
+
end
|
|
88
|
+
|
|
89
|
+
# Runs create_appointments_cancellation (POST /appointments/{id}/cancellations).
|
|
90
|
+
def create_appointments_cancellation(id)
|
|
91
|
+
post("/appointments/#{id}/cancellations")
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
# Runs create_appointments_follow_up (POST /appointments/{id}/follow_ups).
|
|
95
|
+
def create_appointments_follow_up(id, appointment:)
|
|
96
|
+
post("/appointments/#{id}/follow_ups", {appointment: appointment})
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
# Runs create_appointments_rejection (POST /appointments/{id}/rejections).
|
|
100
|
+
def create_appointments_rejection(id)
|
|
101
|
+
post("/appointments/#{id}/rejections")
|
|
102
|
+
end
|
|
103
|
+
|
|
104
|
+
# Runs create_appointments_vehicle_reconciliation (POST /appointments/{id}/vehicle_reconciliations).
|
|
105
|
+
def create_appointments_vehicle_reconciliation(id, vehicle_action:, vehicle_id:)
|
|
106
|
+
post("/appointments/#{id}/vehicle_reconciliations", {vehicle_action: vehicle_action, vehicle_id: vehicle_id})
|
|
107
|
+
end
|
|
108
|
+
|
|
109
|
+
# Runs create_appointments_work_order (POST /appointments/{id}/work_orders).
|
|
110
|
+
def create_appointments_work_order(id)
|
|
111
|
+
post("/appointments/#{id}/work_orders")
|
|
112
|
+
end
|
|
113
|
+
|
|
114
|
+
# Runs create_calendar_blocked_time (POST /calendar/blocked_times).
|
|
115
|
+
def create_calendar_blocked_time(blocked_time:)
|
|
116
|
+
post("/calendar/blocked_times", {blocked_time: blocked_time})
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
# Runs create_campaign (POST /campaigns).
|
|
120
|
+
def create_campaign(broadcast_campaign:)
|
|
121
|
+
post("/campaigns", {broadcast_campaign: broadcast_campaign})
|
|
122
|
+
end
|
|
123
|
+
|
|
124
|
+
# Runs create_cash_drawer_session (POST /cash_drawer_session).
|
|
125
|
+
def create_cash_drawer_session(cash_drawer_session:)
|
|
126
|
+
post("/cash_drawer_session", {cash_drawer_session: cash_drawer_session})
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
# Runs create_cash_entry (POST /cash_entries).
|
|
130
|
+
def create_cash_entry(cash_entry:)
|
|
131
|
+
post("/cash_entries", {cash_entry: cash_entry})
|
|
132
|
+
end
|
|
133
|
+
|
|
134
|
+
# Runs create_conversation (POST /conversations).
|
|
135
|
+
def create_conversation(conversation:)
|
|
136
|
+
post("/conversations", {conversation: conversation})
|
|
137
|
+
end
|
|
138
|
+
|
|
139
|
+
# Runs create_conversations_bulk_mark_read (POST /conversations/bulk_mark_read).
|
|
140
|
+
def create_conversations_bulk_mark_read
|
|
141
|
+
post("/conversations/bulk_mark_read")
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
# Runs create_conversations_customer_link (POST /conversations/{conversation_id}/customer_links).
|
|
145
|
+
def create_conversations_customer_link(conversation_id, customer_id:)
|
|
146
|
+
post("/conversations/#{conversation_id}/customer_links", {customer_id: customer_id})
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
# Runs create_conversations_ignore (POST /conversations/{conversation_id}/ignores).
|
|
150
|
+
def create_conversations_ignore(conversation_id)
|
|
151
|
+
post("/conversations/#{conversation_id}/ignores")
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# Runs create_conversations_message (POST /conversations/{conversation_id}/messages).
|
|
155
|
+
def create_conversations_message(conversation_id, message:)
|
|
156
|
+
post("/conversations/#{conversation_id}/messages", {message: message})
|
|
157
|
+
end
|
|
158
|
+
|
|
159
|
+
# Runs create_counter_sale (POST /counter_sales).
|
|
160
|
+
def create_counter_sale
|
|
161
|
+
post("/counter_sales")
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
# Runs create_counter_sales_line_item (POST /counter_sales/{counter_sale_id}/line_items).
|
|
165
|
+
def create_counter_sales_line_item(counter_sale_id)
|
|
166
|
+
post("/counter_sales/#{counter_sale_id}/line_items")
|
|
167
|
+
end
|
|
168
|
+
|
|
169
|
+
# Runs create_counter_sales_payment (POST /counter_sales/{counter_sale_id}/payments).
|
|
170
|
+
def create_counter_sales_payment(counter_sale_id, payment:)
|
|
171
|
+
post("/counter_sales/#{counter_sale_id}/payments", {payment: payment})
|
|
172
|
+
end
|
|
173
|
+
|
|
174
|
+
# Runs create_customer (POST /customers).
|
|
175
|
+
def create_customer(customer:)
|
|
176
|
+
post("/customers", {customer: customer})
|
|
177
|
+
end
|
|
178
|
+
|
|
179
|
+
# Runs create_customer_tag (POST /customer_tags).
|
|
180
|
+
def create_customer_tag(name:)
|
|
181
|
+
post("/customer_tags", {name: name})
|
|
182
|
+
end
|
|
183
|
+
|
|
184
|
+
# Runs create_driver (POST /customers/{customer_id}/drivers).
|
|
185
|
+
def create_driver(customer_id, driver:)
|
|
186
|
+
post("/customers/#{customer_id}/drivers", {driver: driver})
|
|
187
|
+
end
|
|
188
|
+
|
|
189
|
+
# Runs create_expense (POST /expenses).
|
|
190
|
+
def create_expense(expense:)
|
|
191
|
+
post("/expenses", {expense: expense})
|
|
192
|
+
end
|
|
193
|
+
|
|
194
|
+
# Runs create_inspection (POST /inspections).
|
|
195
|
+
def create_inspection(inspection:)
|
|
196
|
+
post("/inspections", {inspection: inspection})
|
|
197
|
+
end
|
|
198
|
+
|
|
199
|
+
# Runs create_inspection_report (POST /inspection_reports).
|
|
200
|
+
def create_inspection_report(inspection_id: nil, work_order_id: nil)
|
|
201
|
+
params = {inspection_id: inspection_id, work_order_id: work_order_id}
|
|
202
|
+
post("/inspection_reports", params.compact)
|
|
203
|
+
end
|
|
204
|
+
|
|
205
|
+
# Runs create_inspections_group (POST /inspections/{inspection_id}/groups).
|
|
206
|
+
def create_inspections_group(inspection_id, inspection_group:)
|
|
207
|
+
post("/inspections/#{inspection_id}/groups", {inspection_group: inspection_group})
|
|
208
|
+
end
|
|
209
|
+
|
|
210
|
+
# Runs create_inspections_item (POST /inspections/{inspection_id}/items).
|
|
211
|
+
def create_inspections_item(inspection_id, inspection_item:, group_id:)
|
|
212
|
+
post("/inspections/#{inspection_id}/items", {inspection_item: inspection_item, group_id: group_id})
|
|
213
|
+
end
|
|
214
|
+
|
|
215
|
+
# Runs create_inspections_preset (POST /inspections/{inspection_id}/presets).
|
|
216
|
+
def create_inspections_preset(inspection_id, inspection_preset:, item_id: nil)
|
|
217
|
+
params = {item_id: item_id}
|
|
218
|
+
post("/inspections/#{inspection_id}/presets", {inspection_preset: inspection_preset}, params.compact)
|
|
219
|
+
end
|
|
220
|
+
|
|
221
|
+
# Runs create_inventory_level_extraction (POST /inventory_levels/extractions).
|
|
222
|
+
def create_inventory_level_extraction(text:, extraction_id:)
|
|
223
|
+
post("/inventory_levels/extractions", {text: text, extraction_id: extraction_id})
|
|
224
|
+
end
|
|
225
|
+
|
|
226
|
+
# Runs create_inventory_levels_adjust (POST /inventory_levels/{id}/adjust).
|
|
227
|
+
def create_inventory_levels_adjust(id, adjustment:)
|
|
228
|
+
post("/inventory_levels/#{id}/adjust", {adjustment: adjustment})
|
|
229
|
+
end
|
|
230
|
+
|
|
231
|
+
# Runs create_labor_matrix (POST /labor_matrices).
|
|
232
|
+
def create_labor_matrix(labor_matrix:)
|
|
233
|
+
post("/labor_matrices", {labor_matrix: labor_matrix})
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
# Runs create_labor_rate (POST /labor_rates).
|
|
237
|
+
def create_labor_rate(labor_rate:)
|
|
238
|
+
post("/labor_rates", {labor_rate: labor_rate})
|
|
239
|
+
end
|
|
240
|
+
|
|
241
|
+
# Runs create_lead_source (POST /lead_sources).
|
|
242
|
+
def create_lead_source(lead_source:)
|
|
243
|
+
post("/lead_sources", {lead_source: lead_source})
|
|
244
|
+
end
|
|
245
|
+
|
|
246
|
+
# Runs create_lead_sources_seed_default (POST /lead_sources/seed_defaults).
|
|
247
|
+
def create_lead_sources_seed_default
|
|
248
|
+
post("/lead_sources/seed_defaults")
|
|
249
|
+
end
|
|
250
|
+
|
|
251
|
+
# Runs create_messages_resend (POST /messages/{message_id}/resends).
|
|
252
|
+
def create_messages_resend(message_id)
|
|
253
|
+
post("/messages/#{message_id}/resends")
|
|
254
|
+
end
|
|
255
|
+
|
|
256
|
+
# Runs create_notifications_bulk_mark_read (POST /notifications/bulk_mark_read).
|
|
257
|
+
def create_notifications_bulk_mark_read
|
|
258
|
+
post("/notifications/bulk_mark_read")
|
|
259
|
+
end
|
|
260
|
+
|
|
261
|
+
# Runs create_orders_purchase_order (POST /orders/purchase_orders).
|
|
262
|
+
def create_orders_purchase_order(purchase_order:)
|
|
263
|
+
post("/orders/purchase_orders", {purchase_order: purchase_order})
|
|
264
|
+
end
|
|
265
|
+
|
|
266
|
+
# Runs create_orders_purchase_orders_cancellation (POST /orders/purchase_orders/{purchase_order_id}/cancellations).
|
|
267
|
+
def create_orders_purchase_orders_cancellation(purchase_order_id)
|
|
268
|
+
post("/orders/purchase_orders/#{purchase_order_id}/cancellations")
|
|
269
|
+
end
|
|
270
|
+
|
|
271
|
+
# Runs create_orders_return_orders_refund_completion (POST /orders/return_orders/{return_order_id}/refund_completions).
|
|
272
|
+
def create_orders_return_orders_refund_completion(return_order_id)
|
|
273
|
+
post("/orders/return_orders/#{return_order_id}/refund_completions")
|
|
274
|
+
end
|
|
275
|
+
|
|
276
|
+
# Runs create_package (POST /packages).
|
|
277
|
+
def create_package(package:)
|
|
278
|
+
post("/packages", {package: package})
|
|
279
|
+
end
|
|
280
|
+
|
|
281
|
+
# Runs create_packages_duplicate (POST /packages/{id}/duplicate).
|
|
282
|
+
def create_packages_duplicate(id)
|
|
283
|
+
post("/packages/#{id}/duplicate")
|
|
284
|
+
end
|
|
285
|
+
|
|
286
|
+
# Runs create_part (POST /parts).
|
|
287
|
+
def create_part(part:)
|
|
288
|
+
post("/parts", {part: part})
|
|
289
|
+
end
|
|
290
|
+
|
|
291
|
+
# Runs create_parts_matrix (POST /parts_matrices).
|
|
292
|
+
def create_parts_matrix(parts_matrix:)
|
|
293
|
+
post("/parts_matrices", {parts_matrix: parts_matrix})
|
|
294
|
+
end
|
|
295
|
+
|
|
296
|
+
# Runs create_payments_cancellation (POST /payments/{id}/cancellation).
|
|
297
|
+
def create_payments_cancellation(id)
|
|
298
|
+
post("/payments/#{id}/cancellation")
|
|
299
|
+
end
|
|
300
|
+
|
|
301
|
+
# Runs create_payments_confirmation (POST /payments/{id}/confirmation).
|
|
302
|
+
def create_payments_confirmation(id)
|
|
303
|
+
post("/payments/#{id}/confirmation")
|
|
304
|
+
end
|
|
305
|
+
|
|
306
|
+
# Runs create_payments_failure (POST /payments/{id}/failure).
|
|
307
|
+
def create_payments_failure(id)
|
|
308
|
+
post("/payments/#{id}/failure")
|
|
309
|
+
end
|
|
310
|
+
|
|
311
|
+
# Runs create_permission_group (POST /users/permission_groups).
|
|
312
|
+
def create_permission_group(permission_group:)
|
|
313
|
+
post("/users/permission_groups", {permission_group: permission_group})
|
|
314
|
+
end
|
|
315
|
+
|
|
316
|
+
# Runs create_reports_tax_period (POST /reports/tax_periods).
|
|
317
|
+
def create_reports_tax_period(tax_period:)
|
|
318
|
+
post("/reports/tax_periods", {tax_period: tax_period})
|
|
319
|
+
end
|
|
320
|
+
|
|
321
|
+
# Runs create_service_category (POST /service_categories).
|
|
322
|
+
def create_service_category(service_category:)
|
|
323
|
+
post("/service_categories", {service_category: service_category})
|
|
324
|
+
end
|
|
325
|
+
|
|
326
|
+
# Runs create_shop_discount (POST /shop_discounts).
|
|
327
|
+
def create_shop_discount(shop_discount_config:)
|
|
328
|
+
post("/shop_discounts", {shop_discount_config: shop_discount_config})
|
|
329
|
+
end
|
|
330
|
+
|
|
331
|
+
# Runs create_shop_discounts_duplicate (POST /shop_discounts/{id}/duplicate).
|
|
332
|
+
def create_shop_discounts_duplicate(id)
|
|
333
|
+
post("/shop_discounts/#{id}/duplicate")
|
|
334
|
+
end
|
|
335
|
+
|
|
336
|
+
# Runs create_shop_fee (POST /shop_fees).
|
|
337
|
+
def create_shop_fee(shop_fee_config:)
|
|
338
|
+
post("/shop_fees", {shop_fee_config: shop_fee_config})
|
|
339
|
+
end
|
|
340
|
+
|
|
341
|
+
# Runs create_shop_fees_duplicate (POST /shop_fees/{id}/duplicate).
|
|
342
|
+
def create_shop_fees_duplicate(id)
|
|
343
|
+
post("/shop_fees/#{id}/duplicate")
|
|
344
|
+
end
|
|
345
|
+
|
|
346
|
+
# Runs create_statements_bulk_send (POST /statements/bulk_send).
|
|
347
|
+
def create_statements_bulk_send(statement_ids:, cc_emails:, include_invoice_pdfs:, body:)
|
|
348
|
+
post("/statements/bulk_send", {statement_ids: statement_ids, cc_emails: cc_emails, include_invoice_pdfs: include_invoice_pdfs, body: body})
|
|
349
|
+
end
|
|
350
|
+
|
|
351
|
+
# Runs create_statements_generate (POST /statements/generate).
|
|
352
|
+
def create_statements_generate
|
|
353
|
+
post("/statements/generate")
|
|
354
|
+
end
|
|
355
|
+
|
|
356
|
+
# Runs create_store_credits_void (POST /store_credits/{store_credit_id}/voids).
|
|
357
|
+
def create_store_credits_void(store_credit_id)
|
|
358
|
+
post("/store_credits/#{store_credit_id}/voids")
|
|
359
|
+
end
|
|
360
|
+
|
|
361
|
+
# Runs create_sub_status (POST /sub_statuses).
|
|
362
|
+
def create_sub_status(sub_status_type:)
|
|
363
|
+
post("/sub_statuses", {sub_status_type: sub_status_type})
|
|
364
|
+
end
|
|
365
|
+
|
|
366
|
+
# Runs create_sublet_package (POST /sublet_packages).
|
|
367
|
+
def create_sublet_package(sublet_package:)
|
|
368
|
+
post("/sublet_packages", {sublet_package: sublet_package})
|
|
369
|
+
end
|
|
370
|
+
|
|
371
|
+
# Runs create_tire (POST /tires).
|
|
372
|
+
def create_tire(tire:)
|
|
373
|
+
post("/tires", {tire: tire})
|
|
374
|
+
end
|
|
375
|
+
|
|
376
|
+
# Runs create_tire_event (POST /tire_events).
|
|
377
|
+
def create_tire_event(tire_event:)
|
|
378
|
+
post("/tire_events", {tire_event: tire_event})
|
|
379
|
+
end
|
|
380
|
+
|
|
381
|
+
# Runs create_tire_storage_slot (POST /tire_storage_slots).
|
|
382
|
+
def create_tire_storage_slot(tire_storage_slot:)
|
|
383
|
+
post("/tire_storage_slots", {tire_storage_slot: tire_storage_slot})
|
|
384
|
+
end
|
|
385
|
+
|
|
386
|
+
# Runs create_tire_storage_slots_check_out (POST /tire_storage_slots/{tire_storage_slot_id}/check_outs).
|
|
387
|
+
def create_tire_storage_slots_check_out(tire_storage_slot_id)
|
|
388
|
+
post("/tire_storage_slots/#{tire_storage_slot_id}/check_outs")
|
|
389
|
+
end
|
|
390
|
+
|
|
391
|
+
# Runs create_user (POST /users).
|
|
392
|
+
def create_user(user:)
|
|
393
|
+
post("/users", {user: user})
|
|
394
|
+
end
|
|
395
|
+
|
|
396
|
+
# Runs create_users_disable (POST /users/{id}/disable).
|
|
397
|
+
def create_users_disable(id)
|
|
398
|
+
post("/users/#{id}/disable")
|
|
399
|
+
end
|
|
400
|
+
|
|
401
|
+
# Runs create_users_enable (POST /users/{id}/enable).
|
|
402
|
+
def create_users_enable(id)
|
|
403
|
+
post("/users/#{id}/enable")
|
|
404
|
+
end
|
|
405
|
+
|
|
406
|
+
# Runs create_users_permission_groups_assign (POST /users/permission_groups/{id}/assign).
|
|
407
|
+
def create_users_permission_groups_assign(id, user_id:)
|
|
408
|
+
post("/users/permission_groups/#{id}/assign", {user_id: user_id})
|
|
409
|
+
end
|
|
410
|
+
|
|
411
|
+
# Runs create_users_reset_pin (POST /users/{id}/reset_pin).
|
|
412
|
+
def create_users_reset_pin(id)
|
|
413
|
+
post("/users/#{id}/reset_pin")
|
|
414
|
+
end
|
|
415
|
+
|
|
416
|
+
# Runs create_users_send_confirmation (POST /users/{id}/send_confirmation).
|
|
417
|
+
def create_users_send_confirmation(id)
|
|
418
|
+
post("/users/#{id}/send_confirmation")
|
|
419
|
+
end
|
|
420
|
+
|
|
421
|
+
# Runs create_users_send_password_reset (POST /users/{id}/send_password_reset).
|
|
422
|
+
def create_users_send_password_reset(id)
|
|
423
|
+
post("/users/#{id}/send_password_reset")
|
|
424
|
+
end
|
|
425
|
+
|
|
426
|
+
# Runs create_users_unlock (POST /users/{id}/unlock).
|
|
427
|
+
def create_users_unlock(id)
|
|
428
|
+
post("/users/#{id}/unlock")
|
|
429
|
+
end
|
|
430
|
+
|
|
431
|
+
# Runs create_vehicle (POST /vehicles).
|
|
432
|
+
def create_vehicle(vehicle:)
|
|
433
|
+
post("/vehicles", {vehicle: vehicle})
|
|
434
|
+
end
|
|
435
|
+
|
|
436
|
+
# Runs create_vendor (POST /vendors).
|
|
437
|
+
def create_vendor(vendor:)
|
|
438
|
+
post("/vendors", {vendor: vendor})
|
|
439
|
+
end
|
|
440
|
+
|
|
441
|
+
# Runs create_work_order (POST /work_orders).
|
|
442
|
+
def create_work_order(work_order:)
|
|
443
|
+
post("/work_orders", {work_order: work_order})
|
|
444
|
+
end
|
|
445
|
+
|
|
446
|
+
# Runs create_work_order_payment (POST /work_orders/{work_order_id}/payments).
|
|
447
|
+
def create_work_order_payment(work_order_id, payment:)
|
|
448
|
+
post("/work_orders/#{work_order_id}/payments", {payment: payment})
|
|
449
|
+
end
|
|
450
|
+
|
|
451
|
+
# Runs create_work_order_tag (POST /work_order_tags).
|
|
452
|
+
def create_work_order_tag(name:, color:)
|
|
453
|
+
post("/work_order_tags", {name: name, color: color})
|
|
454
|
+
end
|
|
455
|
+
|
|
456
|
+
# Runs create_work_order_tech_assignment (POST /tech_assignments).
|
|
457
|
+
def create_work_order_tech_assignment(technician_id:, work_order_id: nil)
|
|
458
|
+
params = {work_order_id: work_order_id}
|
|
459
|
+
post("/tech_assignments", {technician_id: technician_id}, params.compact)
|
|
460
|
+
end
|
|
461
|
+
|
|
462
|
+
# Runs create_work_orders_activity_log (POST /work_orders/{work_order_id}/activity_logs).
|
|
463
|
+
def create_work_orders_activity_log(work_order_id, activity_log:)
|
|
464
|
+
post("/work_orders/#{work_order_id}/activity_logs", {activity_log: activity_log})
|
|
465
|
+
end
|
|
466
|
+
|
|
467
|
+
# Runs create_work_orders_authorization (POST /work_orders/{work_order_id}/authorizations).
|
|
468
|
+
def create_work_orders_authorization(work_order_id, authorization_method:, service_ids:, service_decisions:)
|
|
469
|
+
post("/work_orders/#{work_order_id}/authorizations", {authorization_method: authorization_method, service_ids: service_ids, service_decisions: service_decisions})
|
|
470
|
+
end
|
|
471
|
+
|
|
472
|
+
# Runs create_work_orders_authorization_decision (POST /work_orders/{work_order_id}/authorization_decisions).
|
|
473
|
+
def create_work_orders_authorization_decision(work_order_id, service_decision_reasons:)
|
|
474
|
+
post("/work_orders/#{work_order_id}/authorization_decisions", {service_decision_reasons: service_decision_reasons})
|
|
475
|
+
end
|
|
476
|
+
|
|
477
|
+
# Runs create_work_orders_concern (POST /work_orders/{work_order_id}/concerns).
|
|
478
|
+
def create_work_orders_concern(work_order_id, concern:)
|
|
479
|
+
post("/work_orders/#{work_order_id}/concerns", {concern: concern})
|
|
480
|
+
end
|
|
481
|
+
|
|
482
|
+
# Runs create_work_orders_concerns_add_package (POST /work_orders/{work_order_id}/concerns/{id}/add_package).
|
|
483
|
+
def create_work_orders_concerns_add_package(work_order_id, id, package_id:)
|
|
484
|
+
post("/work_orders/#{work_order_id}/concerns/#{id}/add_package", {package_id: package_id})
|
|
485
|
+
end
|
|
486
|
+
|
|
487
|
+
# Runs create_work_orders_concerns_copy_all_to_estimate (POST /work_orders/{work_order_id}/concerns/copy_all_to_estimate).
|
|
488
|
+
def create_work_orders_concerns_copy_all_to_estimate(work_order_id)
|
|
489
|
+
post("/work_orders/#{work_order_id}/concerns/copy_all_to_estimate")
|
|
490
|
+
end
|
|
491
|
+
|
|
492
|
+
# Runs create_work_orders_concerns_copy_to_estimate (POST /work_orders/{work_order_id}/concerns/{id}/copy_to_estimate).
|
|
493
|
+
def create_work_orders_concerns_copy_to_estimate(work_order_id, id)
|
|
494
|
+
post("/work_orders/#{work_order_id}/concerns/#{id}/copy_to_estimate")
|
|
495
|
+
end
|
|
496
|
+
|
|
497
|
+
# Runs create_work_orders_courtesy_car_assignment (POST /work_orders/{id}/courtesy_car_assignment).
|
|
498
|
+
def create_work_orders_courtesy_car_assignment(id, vehicle_id:)
|
|
499
|
+
post("/work_orders/#{id}/courtesy_car_assignment", {vehicle_id: vehicle_id})
|
|
500
|
+
end
|
|
501
|
+
|
|
502
|
+
# Runs create_work_orders_credit_resolution (POST /work_orders/{work_order_id}/credit_resolution).
|
|
503
|
+
def create_work_orders_credit_resolution(work_order_id, resolution:)
|
|
504
|
+
post("/work_orders/#{work_order_id}/credit_resolution", {resolution: resolution})
|
|
505
|
+
end
|
|
506
|
+
|
|
507
|
+
# Runs create_work_orders_fee_exclusion (POST /work_orders/{work_order_id}/fee_exclusions).
|
|
508
|
+
def create_work_orders_fee_exclusion(work_order_id, work_order_fee_exclusion:)
|
|
509
|
+
post("/work_orders/#{work_order_id}/fee_exclusions", {work_order_fee_exclusion: work_order_fee_exclusion})
|
|
510
|
+
end
|
|
511
|
+
|
|
512
|
+
# Runs create_work_orders_payment_link_send (POST /work_orders/{work_order_id}/payment_link/send).
|
|
513
|
+
def create_work_orders_payment_link_send(work_order_id, message:)
|
|
514
|
+
post("/work_orders/#{work_order_id}/payment_link/send", {message: message})
|
|
515
|
+
end
|
|
516
|
+
|
|
517
|
+
# Runs create_work_orders_purchase_order (POST /work_orders/{work_order_id}/purchase_orders).
|
|
518
|
+
def create_work_orders_purchase_order(work_order_id, purchase_order:)
|
|
519
|
+
post("/work_orders/#{work_order_id}/purchase_orders", {purchase_order: purchase_order})
|
|
520
|
+
end
|
|
521
|
+
|
|
522
|
+
# Runs create_work_orders_purchase_orders_receive (POST /work_orders/{work_order_id}/purchase_orders/{id}/receive).
|
|
523
|
+
def create_work_orders_purchase_orders_receive(work_order_id, id, lines:)
|
|
524
|
+
post("/work_orders/#{work_order_id}/purchase_orders/#{id}/receive", {lines: lines})
|
|
525
|
+
end
|
|
526
|
+
|
|
527
|
+
# Runs create_work_orders_purchase_orders_return (POST /work_orders/{work_order_id}/purchase_orders/{id}/return).
|
|
528
|
+
def create_work_orders_purchase_orders_return(work_order_id, id, lines:, return_order:)
|
|
529
|
+
post("/work_orders/#{work_order_id}/purchase_orders/#{id}/return", {lines: lines, return_order: return_order})
|
|
530
|
+
end
|
|
531
|
+
|
|
532
|
+
# Runs create_work_orders_quick_intake (POST /work_orders/quick_intake).
|
|
533
|
+
def create_work_orders_quick_intake(customer:, work_order:)
|
|
534
|
+
post("/work_orders/quick_intake", {customer: customer, work_order: work_order})
|
|
535
|
+
end
|
|
536
|
+
|
|
537
|
+
# Runs create_work_orders_refund (POST /work_orders/{work_order_id}/refunds).
|
|
538
|
+
def create_work_orders_refund(work_order_id, refund:)
|
|
539
|
+
post("/work_orders/#{work_order_id}/refunds", {refund: refund})
|
|
540
|
+
end
|
|
541
|
+
|
|
542
|
+
# Runs create_work_orders_service (POST /work_orders/{work_order_id}/services).
|
|
543
|
+
def create_work_orders_service(work_order_id, work_order_service:)
|
|
544
|
+
post("/work_orders/#{work_order_id}/services", {work_order_service: work_order_service})
|
|
545
|
+
end
|
|
546
|
+
|
|
547
|
+
# Runs create_work_orders_services_bulk_pull (POST /work_orders/{work_order_id}/services/{id}/bulk_pull).
|
|
548
|
+
def create_work_orders_services_bulk_pull(work_order_id, id)
|
|
549
|
+
post("/work_orders/#{work_order_id}/services/#{id}/bulk_pull")
|
|
550
|
+
end
|
|
551
|
+
|
|
552
|
+
# Runs create_work_orders_services_comment (POST /work_orders/{work_order_id}/services/{service_id}/comments).
|
|
553
|
+
def create_work_orders_services_comment(work_order_id, service_id, service_comment:)
|
|
554
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/comments", {service_comment: service_comment})
|
|
555
|
+
end
|
|
556
|
+
|
|
557
|
+
# Runs create_work_orders_services_completion (POST /work_orders/{work_order_id}/services/{id}/completion).
|
|
558
|
+
def create_work_orders_services_completion(work_order_id, id)
|
|
559
|
+
post("/work_orders/#{work_order_id}/services/#{id}/completion")
|
|
560
|
+
end
|
|
561
|
+
|
|
562
|
+
# Runs create_work_orders_services_copy (POST /work_orders/{work_order_id}/services/{id}/copies).
|
|
563
|
+
def create_work_orders_services_copy(work_order_id, id)
|
|
564
|
+
post("/work_orders/#{work_order_id}/services/#{id}/copies")
|
|
565
|
+
end
|
|
566
|
+
|
|
567
|
+
# Runs create_work_orders_services_extraction (POST /work_orders/{work_order_id}/services/{service_id}/extractions).
|
|
568
|
+
def create_work_orders_services_extraction(work_order_id, service_id, text:, extraction_id:)
|
|
569
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/extractions", {text: text, extraction_id: extraction_id})
|
|
570
|
+
end
|
|
571
|
+
|
|
572
|
+
# Runs create_work_orders_services_line_item (POST /work_orders/{work_order_id}/services/{service_id}/line_items).
|
|
573
|
+
def create_work_orders_services_line_item(work_order_id, service_id, work_order_line_item:)
|
|
574
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/line_items", {work_order_line_item: work_order_line_item})
|
|
575
|
+
end
|
|
576
|
+
|
|
577
|
+
# Runs create_work_orders_services_line_items_copy (POST /work_orders/{work_order_id}/services/{service_id}/line_items/{id}/copies).
|
|
578
|
+
def create_work_orders_services_line_items_copy(work_order_id, service_id, id)
|
|
579
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}/copies")
|
|
580
|
+
end
|
|
581
|
+
|
|
582
|
+
# Runs create_work_orders_services_line_items_inventory_addition (POST /work_orders/{work_order_id}/services/{service_id}/line_items/{id}/inventory_additions).
|
|
583
|
+
def create_work_orders_services_line_items_inventory_addition(work_order_id, service_id, id)
|
|
584
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}/inventory_additions")
|
|
585
|
+
end
|
|
586
|
+
|
|
587
|
+
# Runs create_work_orders_services_line_items_price_refresh (POST /work_orders/{work_order_id}/services/{service_id}/line_items/{id}/price_refreshes).
|
|
588
|
+
def create_work_orders_services_line_items_price_refresh(work_order_id, service_id, id)
|
|
589
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}/price_refreshes")
|
|
590
|
+
end
|
|
591
|
+
|
|
592
|
+
# Runs create_work_orders_services_line_items_reorder (POST /work_orders/{work_order_id}/services/{service_id}/line_items/{id}/reorder).
|
|
593
|
+
def create_work_orders_services_line_items_reorder(work_order_id, service_id, id)
|
|
594
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}/reorder")
|
|
595
|
+
end
|
|
596
|
+
|
|
597
|
+
# Runs create_work_orders_services_package (POST /work_orders/{work_order_id}/services/{id}/packages).
|
|
598
|
+
def create_work_orders_services_package(work_order_id, id, package_id:)
|
|
599
|
+
post("/work_orders/#{work_order_id}/services/#{id}/packages", {package_id: package_id})
|
|
600
|
+
end
|
|
601
|
+
|
|
602
|
+
# Runs create_work_orders_services_sublet_order (POST /work_orders/{work_order_id}/services/{service_id}/sublet_orders).
|
|
603
|
+
def create_work_orders_services_sublet_order(work_order_id, service_id, sublet_order:)
|
|
604
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/sublet_orders", {sublet_order: sublet_order})
|
|
605
|
+
end
|
|
606
|
+
|
|
607
|
+
# Runs create_work_orders_services_sublet_orders_duplicate (POST /work_orders/{work_order_id}/services/{service_id}/sublet_orders/{id}/duplicate).
|
|
608
|
+
def create_work_orders_services_sublet_orders_duplicate(work_order_id, service_id, id)
|
|
609
|
+
post("/work_orders/#{work_order_id}/services/#{service_id}/sublet_orders/#{id}/duplicate")
|
|
610
|
+
end
|
|
611
|
+
|
|
612
|
+
# Runs create_work_orders_services_time_entry (POST /work_orders/{work_order_id}/services/{id}/time_entries).
|
|
613
|
+
def create_work_orders_services_time_entry(work_order_id, id)
|
|
614
|
+
post("/work_orders/#{work_order_id}/services/#{id}/time_entries")
|
|
615
|
+
end
|
|
616
|
+
|
|
617
|
+
# Runs create_work_orders_tire_storage (POST /work_orders/{work_order_id}/tire_storage).
|
|
618
|
+
def create_work_orders_tire_storage(work_order_id, tire_storage_slot:)
|
|
619
|
+
post("/work_orders/#{work_order_id}/tire_storage", {tire_storage_slot: tire_storage_slot})
|
|
620
|
+
end
|
|
621
|
+
|
|
622
|
+
# Runs create_work_orders_void (POST /work_orders/{work_order_id}/voids).
|
|
623
|
+
def create_work_orders_void(work_order_id, payment_id:)
|
|
624
|
+
post("/work_orders/#{work_order_id}/voids", {payment_id: payment_id})
|
|
625
|
+
end
|
|
626
|
+
|
|
627
|
+
# Runs decline_all_work_order_concerns (POST /work_orders/{work_order_id}/concerns/decline_all).
|
|
628
|
+
def decline_all_work_order_concerns(work_order_id, decline_reason:)
|
|
629
|
+
post("/work_orders/#{work_order_id}/concerns/decline_all", {decline_reason: decline_reason})
|
|
630
|
+
end
|
|
631
|
+
|
|
632
|
+
# Runs decline_work_order (POST /work_orders/{id}/decline).
|
|
633
|
+
def decline_work_order(id, closure_reason:)
|
|
634
|
+
post("/work_orders/#{id}/decline", {closure_reason: closure_reason})
|
|
635
|
+
end
|
|
636
|
+
|
|
637
|
+
# Fetches decode_vin.
|
|
638
|
+
def decode_vin(vin: nil)
|
|
639
|
+
params = {"vin" => vin}
|
|
640
|
+
get("/vehicles/vin_decode", params.compact)
|
|
641
|
+
end
|
|
642
|
+
|
|
643
|
+
# Deletes delete_account.
|
|
644
|
+
def delete_account
|
|
645
|
+
delete("/account")
|
|
646
|
+
end
|
|
647
|
+
|
|
648
|
+
# Deletes delete_account_api_token.
|
|
649
|
+
def delete_account_api_token(id)
|
|
650
|
+
delete("/account/api_tokens/#{id}")
|
|
651
|
+
end
|
|
652
|
+
|
|
653
|
+
# Deletes delete_appointment.
|
|
654
|
+
def delete_appointment(id)
|
|
655
|
+
delete("/appointments/#{id}")
|
|
656
|
+
end
|
|
657
|
+
|
|
658
|
+
# Deletes delete_calendar_blocked_time.
|
|
659
|
+
def delete_calendar_blocked_time(id)
|
|
660
|
+
delete("/calendar/blocked_times/#{id}")
|
|
661
|
+
end
|
|
662
|
+
|
|
663
|
+
# Deletes delete_cash_entry.
|
|
664
|
+
def delete_cash_entry(id)
|
|
665
|
+
delete("/cash_entries/#{id}")
|
|
666
|
+
end
|
|
667
|
+
|
|
668
|
+
# Deletes delete_counter_sales_line_item.
|
|
669
|
+
def delete_counter_sales_line_item(counter_sale_id, id)
|
|
670
|
+
delete("/counter_sales/#{counter_sale_id}/line_items/#{id}")
|
|
671
|
+
end
|
|
672
|
+
|
|
673
|
+
# Deletes delete_driver.
|
|
674
|
+
def delete_driver(customer_id, id)
|
|
675
|
+
delete("/customers/#{customer_id}/drivers/#{id}")
|
|
676
|
+
end
|
|
677
|
+
|
|
678
|
+
# Deletes delete_expense.
|
|
679
|
+
def delete_expense(id)
|
|
680
|
+
delete("/expenses/#{id}")
|
|
681
|
+
end
|
|
682
|
+
|
|
683
|
+
# Deletes delete_inspection_report.
|
|
684
|
+
def delete_inspection_report(id)
|
|
685
|
+
delete("/inspection_reports/#{id}")
|
|
686
|
+
end
|
|
687
|
+
|
|
688
|
+
# Deletes delete_inspections_group.
|
|
689
|
+
def delete_inspections_group(inspection_id, id)
|
|
690
|
+
delete("/inspections/#{inspection_id}/groups/#{id}")
|
|
691
|
+
end
|
|
692
|
+
|
|
693
|
+
# Deletes delete_inspections_item.
|
|
694
|
+
def delete_inspections_item(inspection_id, id)
|
|
695
|
+
delete("/inspections/#{inspection_id}/items/#{id}")
|
|
696
|
+
end
|
|
697
|
+
|
|
698
|
+
# Deletes delete_inspections_preset.
|
|
699
|
+
def delete_inspections_preset(inspection_id, id)
|
|
700
|
+
delete("/inspections/#{inspection_id}/presets/#{id}")
|
|
701
|
+
end
|
|
702
|
+
|
|
703
|
+
# Deletes delete_labor_matrix.
|
|
704
|
+
def delete_labor_matrix(id)
|
|
705
|
+
delete("/labor_matrices/#{id}")
|
|
706
|
+
end
|
|
707
|
+
|
|
708
|
+
# Deletes delete_labor_template.
|
|
709
|
+
def delete_labor_template(id)
|
|
710
|
+
delete("/labor_templates/#{id}")
|
|
711
|
+
end
|
|
712
|
+
|
|
713
|
+
# Deletes delete_lead_source.
|
|
714
|
+
def delete_lead_source(id)
|
|
715
|
+
delete("/lead_sources/#{id}")
|
|
716
|
+
end
|
|
717
|
+
|
|
718
|
+
# Deletes delete_orders_purchase_order.
|
|
719
|
+
def delete_orders_purchase_order(id)
|
|
720
|
+
delete("/orders/purchase_orders/#{id}")
|
|
721
|
+
end
|
|
722
|
+
|
|
723
|
+
# Deletes delete_orders_return_order.
|
|
724
|
+
def delete_orders_return_order(id)
|
|
725
|
+
delete("/orders/return_orders/#{id}")
|
|
726
|
+
end
|
|
727
|
+
|
|
728
|
+
# Deletes delete_part.
|
|
729
|
+
def delete_part(id)
|
|
730
|
+
delete("/parts/#{id}")
|
|
731
|
+
end
|
|
732
|
+
|
|
733
|
+
# Deletes delete_parts_matrix.
|
|
734
|
+
def delete_parts_matrix(id)
|
|
735
|
+
delete("/parts_matrices/#{id}")
|
|
736
|
+
end
|
|
737
|
+
|
|
738
|
+
# Deletes delete_shop_discount.
|
|
739
|
+
def delete_shop_discount(id)
|
|
740
|
+
delete("/shop_discounts/#{id}")
|
|
741
|
+
end
|
|
742
|
+
|
|
743
|
+
# Deletes delete_shop_fee.
|
|
744
|
+
def delete_shop_fee(id)
|
|
745
|
+
delete("/shop_fees/#{id}")
|
|
746
|
+
end
|
|
747
|
+
|
|
748
|
+
# Deletes delete_sublet_package.
|
|
749
|
+
def delete_sublet_package(id)
|
|
750
|
+
delete("/sublet_packages/#{id}")
|
|
751
|
+
end
|
|
752
|
+
|
|
753
|
+
# Deletes delete_tire.
|
|
754
|
+
def delete_tire(id)
|
|
755
|
+
delete("/tires/#{id}")
|
|
756
|
+
end
|
|
757
|
+
|
|
758
|
+
# Deletes delete_tire_storage_slot.
|
|
759
|
+
def delete_tire_storage_slot(id)
|
|
760
|
+
delete("/tire_storage_slots/#{id}")
|
|
761
|
+
end
|
|
762
|
+
|
|
763
|
+
# Deletes delete_user.
|
|
764
|
+
def delete_user(id)
|
|
765
|
+
delete("/users/#{id}")
|
|
766
|
+
end
|
|
767
|
+
|
|
768
|
+
# Deletes delete_users_permission_groups_unassign.
|
|
769
|
+
def delete_users_permission_groups_unassign(id, assignment_id: nil)
|
|
770
|
+
params = {assignment_id: assignment_id}
|
|
771
|
+
delete("/users/permission_groups/#{id}/unassign", params.compact)
|
|
772
|
+
end
|
|
773
|
+
|
|
774
|
+
# Deletes delete_work_orders_concern.
|
|
775
|
+
def delete_work_orders_concern(work_order_id, id)
|
|
776
|
+
delete("/work_orders/#{work_order_id}/concerns/#{id}")
|
|
777
|
+
end
|
|
778
|
+
|
|
779
|
+
# Deletes delete_work_orders_courtesy_car_assignment.
|
|
780
|
+
def delete_work_orders_courtesy_car_assignment(id)
|
|
781
|
+
delete("/work_orders/#{id}/courtesy_car_assignment")
|
|
782
|
+
end
|
|
783
|
+
|
|
784
|
+
# Deletes delete_work_orders_fee_exclusion.
|
|
785
|
+
def delete_work_orders_fee_exclusion(work_order_id, id)
|
|
786
|
+
delete("/work_orders/#{work_order_id}/fee_exclusions/#{id}")
|
|
787
|
+
end
|
|
788
|
+
|
|
789
|
+
# Deletes delete_work_orders_purchase_order.
|
|
790
|
+
def delete_work_orders_purchase_order(work_order_id, id)
|
|
791
|
+
delete("/work_orders/#{work_order_id}/purchase_orders/#{id}")
|
|
792
|
+
end
|
|
793
|
+
|
|
794
|
+
# Deletes delete_work_orders_service.
|
|
795
|
+
def delete_work_orders_service(work_order_id, id)
|
|
796
|
+
delete("/work_orders/#{work_order_id}/services/#{id}")
|
|
797
|
+
end
|
|
798
|
+
|
|
799
|
+
# Deletes delete_work_orders_services_authorization.
|
|
800
|
+
def delete_work_orders_services_authorization(work_order_id, id)
|
|
801
|
+
delete("/work_orders/#{work_order_id}/services/#{id}/authorization")
|
|
802
|
+
end
|
|
803
|
+
|
|
804
|
+
# Deletes delete_work_orders_services_comment.
|
|
805
|
+
def delete_work_orders_services_comment(work_order_id, service_id, id)
|
|
806
|
+
delete("/work_orders/#{work_order_id}/services/#{service_id}/comments/#{id}")
|
|
807
|
+
end
|
|
808
|
+
|
|
809
|
+
# Deletes delete_work_orders_services_completion.
|
|
810
|
+
def delete_work_orders_services_completion(work_order_id, id)
|
|
811
|
+
delete("/work_orders/#{work_order_id}/services/#{id}/completion")
|
|
812
|
+
end
|
|
813
|
+
|
|
814
|
+
# Deletes delete_work_orders_services_line_item.
|
|
815
|
+
def delete_work_orders_services_line_item(work_order_id, service_id, id)
|
|
816
|
+
delete("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}")
|
|
817
|
+
end
|
|
818
|
+
|
|
819
|
+
# Deletes delete_work_orders_services_sublet_order.
|
|
820
|
+
def delete_work_orders_services_sublet_order(work_order_id, service_id, id)
|
|
821
|
+
delete("/work_orders/#{work_order_id}/services/#{service_id}/sublet_orders/#{id}")
|
|
822
|
+
end
|
|
823
|
+
|
|
824
|
+
# Deletes delete_work_orders_tire_storage.
|
|
825
|
+
def delete_work_orders_tire_storage(work_order_id, id)
|
|
826
|
+
delete("/work_orders/#{work_order_id}/tire_storage/#{id}")
|
|
827
|
+
end
|
|
828
|
+
|
|
829
|
+
# Runs duplicate_campaign (POST /campaigns/{id}/duplicate).
|
|
830
|
+
def duplicate_campaign(id)
|
|
831
|
+
post("/campaigns/#{id}/duplicate")
|
|
832
|
+
end
|
|
833
|
+
|
|
834
|
+
# Fetches list_account.
|
|
835
|
+
def list_account
|
|
836
|
+
get("/account")
|
|
837
|
+
end
|
|
838
|
+
|
|
839
|
+
# Fetches list_account_api_tokens.
|
|
840
|
+
def list_account_api_tokens
|
|
841
|
+
get("/account/api_tokens")
|
|
842
|
+
end
|
|
843
|
+
|
|
844
|
+
# Fetches list_account_billing.
|
|
845
|
+
def list_account_billing
|
|
846
|
+
get("/account/billing")
|
|
847
|
+
end
|
|
848
|
+
|
|
849
|
+
# Fetches list_account_capabilities.
|
|
850
|
+
def list_account_capabilities
|
|
851
|
+
get("/account/capabilities")
|
|
852
|
+
end
|
|
853
|
+
|
|
854
|
+
# Fetches list_account_driveon.
|
|
855
|
+
def list_account_driveon
|
|
856
|
+
get("/account/driveon")
|
|
857
|
+
end
|
|
858
|
+
|
|
859
|
+
# Fetches list_account_payments.
|
|
860
|
+
def list_account_payments
|
|
861
|
+
get("/account/payments")
|
|
862
|
+
end
|
|
863
|
+
|
|
864
|
+
# Fetches list_account_phone_numbers.
|
|
865
|
+
def list_account_phone_numbers
|
|
866
|
+
get("/account/phone_numbers")
|
|
867
|
+
end
|
|
868
|
+
|
|
869
|
+
# Fetches list_account_quickbooks.
|
|
870
|
+
def list_account_quickbooks
|
|
871
|
+
get("/account/quickbooks")
|
|
872
|
+
end
|
|
873
|
+
|
|
874
|
+
# Fetches list_account_station_link.
|
|
875
|
+
def list_account_station_link
|
|
876
|
+
get("/account/station_link")
|
|
877
|
+
end
|
|
878
|
+
|
|
879
|
+
# Lists list_appointments resources (paginated).
|
|
880
|
+
# @return [Wenmar::Paginator]
|
|
881
|
+
def list_appointments(per_page: nil, q: nil, scheduling_status: nil)
|
|
882
|
+
params = {"per_page" => per_page, "q" => q, "scheduling_status" => scheduling_status}
|
|
883
|
+
get("/appointments", params.compact)
|
|
884
|
+
end
|
|
885
|
+
|
|
886
|
+
# Fetches all appointments, up to 1000 by default.
|
|
887
|
+
# @return [Array<Hash>]
|
|
888
|
+
def get_all_appointments(per_page: nil, q: nil, scheduling_status: nil)
|
|
889
|
+
paginator_to_a(list_appointments(per_page: per_page, q: q, scheduling_status: scheduling_status), 1000)
|
|
890
|
+
end
|
|
891
|
+
|
|
892
|
+
# Lists list_appointments_available_slots resources (paginated).
|
|
893
|
+
# @return [Wenmar::Paginator]
|
|
894
|
+
def list_appointments_available_slots(date: nil, duration_minutes: nil)
|
|
895
|
+
params = {"date" => date, "duration_minutes" => duration_minutes}
|
|
896
|
+
get("/appointments/available_slots", params.compact)
|
|
897
|
+
end
|
|
898
|
+
|
|
899
|
+
# Fetches all appointments_available_slots, up to 1000 by default.
|
|
900
|
+
# @return [Array<Hash>]
|
|
901
|
+
def get_all_appointments_available_slots(date: nil, duration_minutes: nil)
|
|
902
|
+
paginator_to_a(list_appointments_available_slots(date: date, duration_minutes: duration_minutes), 1000)
|
|
903
|
+
end
|
|
904
|
+
|
|
905
|
+
# Lists list_campaigns resources (paginated).
|
|
906
|
+
# @return [Wenmar::Paginator]
|
|
907
|
+
def list_campaigns
|
|
908
|
+
get("/campaigns")
|
|
909
|
+
end
|
|
910
|
+
|
|
911
|
+
# Fetches all campaigns, up to 1000 by default.
|
|
912
|
+
# @return [Array<Hash>]
|
|
913
|
+
def get_all_campaigns
|
|
914
|
+
paginator_to_a(list_campaigns, 1000)
|
|
915
|
+
end
|
|
916
|
+
|
|
917
|
+
# Lists list_cash_entries resources (paginated).
|
|
918
|
+
# @return [Wenmar::Paginator]
|
|
919
|
+
def list_cash_entries(cash_drawer_session_id: nil)
|
|
920
|
+
params = {"cash_drawer_session_id" => cash_drawer_session_id}
|
|
921
|
+
get("/cash_entries", params.compact)
|
|
922
|
+
end
|
|
923
|
+
|
|
924
|
+
# Fetches all cash_entries, up to 1000 by default.
|
|
925
|
+
# @return [Array<Hash>]
|
|
926
|
+
def get_all_cash_entries(cash_drawer_session_id: nil)
|
|
927
|
+
paginator_to_a(list_cash_entries(cash_drawer_session_id: cash_drawer_session_id), 1000)
|
|
928
|
+
end
|
|
929
|
+
|
|
930
|
+
# Lists list_conversations resources (paginated).
|
|
931
|
+
# @return [Wenmar::Paginator]
|
|
932
|
+
def list_conversations
|
|
933
|
+
get("/conversations")
|
|
934
|
+
end
|
|
935
|
+
|
|
936
|
+
# Fetches all conversations, up to 1000 by default.
|
|
937
|
+
# @return [Array<Hash>]
|
|
938
|
+
def get_all_conversations
|
|
939
|
+
paginator_to_a(list_conversations, 1000)
|
|
940
|
+
end
|
|
941
|
+
|
|
942
|
+
# Lists list_conversations_messages resources (paginated).
|
|
943
|
+
# @return [Wenmar::Paginator]
|
|
944
|
+
def list_conversations_messages(conversation_id)
|
|
945
|
+
get("/conversations/#{conversation_id}/messages")
|
|
946
|
+
end
|
|
947
|
+
|
|
948
|
+
# Fetches all conversations_messages, up to 1000 by default.
|
|
949
|
+
# @return [Array<Hash>]
|
|
950
|
+
def get_all_conversations_messages(conversation_id)
|
|
951
|
+
paginator_to_a(list_conversations_messages(conversation_id), 1000)
|
|
952
|
+
end
|
|
953
|
+
|
|
954
|
+
# Lists list_core_tax_rules resources (paginated).
|
|
955
|
+
# @return [Wenmar::Paginator]
|
|
956
|
+
def list_core_tax_rules
|
|
957
|
+
get("/core_tax_rules")
|
|
958
|
+
end
|
|
959
|
+
|
|
960
|
+
# Fetches all core_tax_rules, up to 1000 by default.
|
|
961
|
+
# @return [Array<Hash>]
|
|
962
|
+
def get_all_core_tax_rules
|
|
963
|
+
paginator_to_a(list_core_tax_rules, 1000)
|
|
964
|
+
end
|
|
965
|
+
|
|
966
|
+
# Lists list_counter_sales resources (paginated).
|
|
967
|
+
# @return [Wenmar::Paginator]
|
|
968
|
+
def list_counter_sales
|
|
969
|
+
get("/counter_sales")
|
|
970
|
+
end
|
|
971
|
+
|
|
972
|
+
# Fetches all counter_sales, up to 1000 by default.
|
|
973
|
+
# @return [Array<Hash>]
|
|
974
|
+
def get_all_counter_sales
|
|
975
|
+
paginator_to_a(list_counter_sales, 1000)
|
|
976
|
+
end
|
|
977
|
+
|
|
978
|
+
# Fetches list_counter_sales_line_items_brands.
|
|
979
|
+
def list_counter_sales_line_items_brands(counter_sale_id)
|
|
980
|
+
get("/counter_sales/#{counter_sale_id}/line_items/brands")
|
|
981
|
+
end
|
|
982
|
+
|
|
983
|
+
# Fetches list_current_location.
|
|
984
|
+
def list_current_location
|
|
985
|
+
get("/current_location")
|
|
986
|
+
end
|
|
987
|
+
|
|
988
|
+
# Lists list_customer_tags resources (paginated).
|
|
989
|
+
# @return [Wenmar::Paginator]
|
|
990
|
+
def list_customer_tags(status: nil)
|
|
991
|
+
params = {"status" => status}
|
|
992
|
+
get("/customer_tags", params.compact)
|
|
993
|
+
end
|
|
994
|
+
|
|
995
|
+
# Fetches all customer_tags, up to 1000 by default.
|
|
996
|
+
# @return [Array<Hash>]
|
|
997
|
+
def get_all_customer_tags(status: nil)
|
|
998
|
+
paginator_to_a(list_customer_tags(status: status), 1000)
|
|
999
|
+
end
|
|
1000
|
+
|
|
1001
|
+
# Lists list_customers resources (paginated).
|
|
1002
|
+
# @return [Wenmar::Paginator]
|
|
1003
|
+
def list_customers(customer_tag_id: nil, has_balance: nil, has_vehicle: nil, last_visit_months: nil, page: nil, per_page: nil, q: nil, status: nil, type: nil)
|
|
1004
|
+
params = {"customer_tag_id" => customer_tag_id, "has_balance" => has_balance, "has_vehicle" => has_vehicle, "last_visit_months" => last_visit_months, "page" => page, "per_page" => per_page, "q" => q, "status" => status, "type" => type}
|
|
1005
|
+
get("/customers", params.compact)
|
|
1006
|
+
end
|
|
1007
|
+
|
|
1008
|
+
# Fetches all customers, up to 1000 by default.
|
|
1009
|
+
# @return [Array<Hash>]
|
|
1010
|
+
def get_all_customers(customer_tag_id: nil, has_balance: nil, has_vehicle: nil, last_visit_months: nil, page: nil, per_page: nil, q: nil, status: nil, type: nil)
|
|
1011
|
+
paginator_to_a(list_customers(customer_tag_id: customer_tag_id, has_balance: has_balance, has_vehicle: has_vehicle, last_visit_months: last_visit_months, page: page, per_page: per_page, q: q, status: status, type: type), 1000)
|
|
1012
|
+
end
|
|
1013
|
+
|
|
1014
|
+
# Lists list_customers_drivers resources (paginated).
|
|
1015
|
+
# @return [Wenmar::Paginator]
|
|
1016
|
+
def list_customers_drivers(customer_id)
|
|
1017
|
+
get("/customers/#{customer_id}/drivers")
|
|
1018
|
+
end
|
|
1019
|
+
|
|
1020
|
+
# Fetches all customers_drivers, up to 1000 by default.
|
|
1021
|
+
# @return [Array<Hash>]
|
|
1022
|
+
def get_all_customers_drivers(customer_id)
|
|
1023
|
+
paginator_to_a(list_customers_drivers(customer_id), 1000)
|
|
1024
|
+
end
|
|
1025
|
+
|
|
1026
|
+
# Lists list_customers_statements resources (paginated).
|
|
1027
|
+
# @return [Wenmar::Paginator]
|
|
1028
|
+
def list_customers_statements(customer_id)
|
|
1029
|
+
get("/customers/#{customer_id}/statements")
|
|
1030
|
+
end
|
|
1031
|
+
|
|
1032
|
+
# Fetches all customers_statements, up to 1000 by default.
|
|
1033
|
+
# @return [Array<Hash>]
|
|
1034
|
+
def get_all_customers_statements(customer_id)
|
|
1035
|
+
paginator_to_a(list_customers_statements(customer_id), 1000)
|
|
1036
|
+
end
|
|
1037
|
+
|
|
1038
|
+
# Lists list_customers_vehicles resources (paginated).
|
|
1039
|
+
# @return [Wenmar::Paginator]
|
|
1040
|
+
def list_customers_vehicles(customer_id)
|
|
1041
|
+
get("/customers/#{customer_id}/vehicles")
|
|
1042
|
+
end
|
|
1043
|
+
|
|
1044
|
+
# Fetches all customers_vehicles, up to 1000 by default.
|
|
1045
|
+
# @return [Array<Hash>]
|
|
1046
|
+
def get_all_customers_vehicles(customer_id)
|
|
1047
|
+
paginator_to_a(list_customers_vehicles(customer_id), 1000)
|
|
1048
|
+
end
|
|
1049
|
+
|
|
1050
|
+
# Fetches list_customers_vehicles_history.
|
|
1051
|
+
def list_customers_vehicles_history(customer_id, vehicle_id)
|
|
1052
|
+
get("/customers/#{customer_id}/vehicles/#{vehicle_id}/history")
|
|
1053
|
+
end
|
|
1054
|
+
|
|
1055
|
+
# Lists list_customers_work_orders resources (paginated).
|
|
1056
|
+
# @return [Wenmar::Paginator]
|
|
1057
|
+
def list_customers_work_orders(customer_id)
|
|
1058
|
+
get("/customers/#{customer_id}/work_orders")
|
|
1059
|
+
end
|
|
1060
|
+
|
|
1061
|
+
# Fetches all customers_work_orders, up to 1000 by default.
|
|
1062
|
+
# @return [Array<Hash>]
|
|
1063
|
+
def get_all_customers_work_orders(customer_id)
|
|
1064
|
+
paginator_to_a(list_customers_work_orders(customer_id), 1000)
|
|
1065
|
+
end
|
|
1066
|
+
|
|
1067
|
+
# Lists list_drivers resources (paginated).
|
|
1068
|
+
# @return [Wenmar::Paginator]
|
|
1069
|
+
def list_drivers(filters_has_open_work_order: nil, filters_q: nil)
|
|
1070
|
+
params = {"filters[has_open_work_order]" => filters_has_open_work_order, "filters[q]" => filters_q}
|
|
1071
|
+
get("/drivers", params.compact)
|
|
1072
|
+
end
|
|
1073
|
+
|
|
1074
|
+
# Fetches all drivers, up to 1000 by default.
|
|
1075
|
+
# @return [Array<Hash>]
|
|
1076
|
+
def get_all_drivers(filters_has_open_work_order: nil, filters_q: nil)
|
|
1077
|
+
paginator_to_a(list_drivers(filters_has_open_work_order: filters_has_open_work_order, filters_q: filters_q), 1000)
|
|
1078
|
+
end
|
|
1079
|
+
|
|
1080
|
+
# Lists list_expenses resources (paginated).
|
|
1081
|
+
# @return [Wenmar::Paginator]
|
|
1082
|
+
def list_expenses
|
|
1083
|
+
get("/expenses")
|
|
1084
|
+
end
|
|
1085
|
+
|
|
1086
|
+
# Fetches all expenses, up to 1000 by default.
|
|
1087
|
+
# @return [Array<Hash>]
|
|
1088
|
+
def get_all_expenses
|
|
1089
|
+
paginator_to_a(list_expenses, 1000)
|
|
1090
|
+
end
|
|
1091
|
+
|
|
1092
|
+
# Lists list_fleets resources (paginated).
|
|
1093
|
+
# @return [Wenmar::Paginator]
|
|
1094
|
+
def list_fleets
|
|
1095
|
+
get("/fleets")
|
|
1096
|
+
end
|
|
1097
|
+
|
|
1098
|
+
# Fetches all fleets, up to 1000 by default.
|
|
1099
|
+
# @return [Array<Hash>]
|
|
1100
|
+
def get_all_fleets
|
|
1101
|
+
paginator_to_a(list_fleets, 1000)
|
|
1102
|
+
end
|
|
1103
|
+
|
|
1104
|
+
# Lists list_inspections resources (paginated).
|
|
1105
|
+
# @return [Wenmar::Paginator]
|
|
1106
|
+
def list_inspections(per_page: nil)
|
|
1107
|
+
params = {"per_page" => per_page}
|
|
1108
|
+
get("/inspections", params.compact)
|
|
1109
|
+
end
|
|
1110
|
+
|
|
1111
|
+
# Fetches all inspections, up to 1000 by default.
|
|
1112
|
+
# @return [Array<Hash>]
|
|
1113
|
+
def get_all_inspections(per_page: nil)
|
|
1114
|
+
paginator_to_a(list_inspections(per_page: per_page), 1000)
|
|
1115
|
+
end
|
|
1116
|
+
|
|
1117
|
+
# Lists list_labor_matrices resources (paginated).
|
|
1118
|
+
# @return [Wenmar::Paginator]
|
|
1119
|
+
def list_labor_matrices
|
|
1120
|
+
get("/labor_matrices")
|
|
1121
|
+
end
|
|
1122
|
+
|
|
1123
|
+
# Fetches all labor_matrices, up to 1000 by default.
|
|
1124
|
+
# @return [Array<Hash>]
|
|
1125
|
+
def get_all_labor_matrices
|
|
1126
|
+
paginator_to_a(list_labor_matrices, 1000)
|
|
1127
|
+
end
|
|
1128
|
+
|
|
1129
|
+
# Lists list_labor_rates resources (paginated).
|
|
1130
|
+
# @return [Wenmar::Paginator]
|
|
1131
|
+
def list_labor_rates
|
|
1132
|
+
get("/labor_rates")
|
|
1133
|
+
end
|
|
1134
|
+
|
|
1135
|
+
# Fetches all labor_rates, up to 1000 by default.
|
|
1136
|
+
# @return [Array<Hash>]
|
|
1137
|
+
def get_all_labor_rates
|
|
1138
|
+
paginator_to_a(list_labor_rates, 1000)
|
|
1139
|
+
end
|
|
1140
|
+
|
|
1141
|
+
# Lists list_labor_templates resources (paginated).
|
|
1142
|
+
# @return [Wenmar::Paginator]
|
|
1143
|
+
def list_labor_templates
|
|
1144
|
+
get("/labor_templates")
|
|
1145
|
+
end
|
|
1146
|
+
|
|
1147
|
+
# Fetches all labor_templates, up to 1000 by default.
|
|
1148
|
+
# @return [Array<Hash>]
|
|
1149
|
+
def get_all_labor_templates
|
|
1150
|
+
paginator_to_a(list_labor_templates, 1000)
|
|
1151
|
+
end
|
|
1152
|
+
|
|
1153
|
+
# Lists list_lead_sources resources (paginated).
|
|
1154
|
+
# @return [Wenmar::Paginator]
|
|
1155
|
+
def list_lead_sources
|
|
1156
|
+
get("/lead_sources")
|
|
1157
|
+
end
|
|
1158
|
+
|
|
1159
|
+
# Fetches all lead_sources, up to 1000 by default.
|
|
1160
|
+
# @return [Array<Hash>]
|
|
1161
|
+
def get_all_lead_sources
|
|
1162
|
+
paginator_to_a(list_lead_sources, 1000)
|
|
1163
|
+
end
|
|
1164
|
+
|
|
1165
|
+
# Fetches list_locations_business_profile.
|
|
1166
|
+
def list_locations_business_profile(id)
|
|
1167
|
+
get("/locations/#{id}/business_profile")
|
|
1168
|
+
end
|
|
1169
|
+
|
|
1170
|
+
# Fetches list_locations_close_requirements.
|
|
1171
|
+
def list_locations_close_requirements(location_id)
|
|
1172
|
+
get("/locations/#{location_id}/close_requirements")
|
|
1173
|
+
end
|
|
1174
|
+
|
|
1175
|
+
# Fetches list_locations_courtesy_cars.
|
|
1176
|
+
def list_locations_courtesy_cars(location_id)
|
|
1177
|
+
get("/locations/#{location_id}/courtesy_cars")
|
|
1178
|
+
end
|
|
1179
|
+
|
|
1180
|
+
# Fetches list_locations_documents.
|
|
1181
|
+
def list_locations_documents(location_id)
|
|
1182
|
+
get("/locations/#{location_id}/documents")
|
|
1183
|
+
end
|
|
1184
|
+
|
|
1185
|
+
# Fetches list_locations_lead_source_requirements.
|
|
1186
|
+
def list_locations_lead_source_requirements(location_id)
|
|
1187
|
+
get("/locations/#{location_id}/lead_source_requirements")
|
|
1188
|
+
end
|
|
1189
|
+
|
|
1190
|
+
# Fetches list_locations_operations.
|
|
1191
|
+
def list_locations_operations(id)
|
|
1192
|
+
get("/locations/#{id}/operations")
|
|
1193
|
+
end
|
|
1194
|
+
|
|
1195
|
+
# Fetches list_locations_reminders.
|
|
1196
|
+
def list_locations_reminders(location_id)
|
|
1197
|
+
get("/locations/#{location_id}/reminders")
|
|
1198
|
+
end
|
|
1199
|
+
|
|
1200
|
+
# Fetches list_locations_schedule_config.
|
|
1201
|
+
def list_locations_schedule_config(location_id)
|
|
1202
|
+
get("/locations/#{location_id}/schedule_config")
|
|
1203
|
+
end
|
|
1204
|
+
|
|
1205
|
+
# Fetches list_me_notifications.
|
|
1206
|
+
def list_me_notifications
|
|
1207
|
+
get("/me/notifications")
|
|
1208
|
+
end
|
|
1209
|
+
|
|
1210
|
+
# Fetches list_me_preferences.
|
|
1211
|
+
def list_me_preferences
|
|
1212
|
+
get("/me/preferences")
|
|
1213
|
+
end
|
|
1214
|
+
|
|
1215
|
+
# Fetches list_me_profile.
|
|
1216
|
+
def list_me_profile
|
|
1217
|
+
get("/me/profile")
|
|
1218
|
+
end
|
|
1219
|
+
|
|
1220
|
+
# Lists list_messages resources (paginated).
|
|
1221
|
+
# @return [Wenmar::Paginator]
|
|
1222
|
+
def list_messages(conversation_id: nil)
|
|
1223
|
+
params = {"conversation_id" => conversation_id}
|
|
1224
|
+
get("/messages", params.compact)
|
|
1225
|
+
end
|
|
1226
|
+
|
|
1227
|
+
# Fetches all messages, up to 1000 by default.
|
|
1228
|
+
# @return [Array<Hash>]
|
|
1229
|
+
def get_all_messages(conversation_id: nil)
|
|
1230
|
+
paginator_to_a(list_messages(conversation_id: conversation_id), 1000)
|
|
1231
|
+
end
|
|
1232
|
+
|
|
1233
|
+
# Lists list_notifications resources (paginated).
|
|
1234
|
+
# @return [Wenmar::Paginator]
|
|
1235
|
+
def list_notifications(category: nil, limit: nil, location_id: nil, read: nil, since: nil, trigger_type: nil)
|
|
1236
|
+
params = {"category" => category, "limit" => limit, "location_id" => location_id, "read" => read, "since" => since, "trigger_type" => trigger_type}
|
|
1237
|
+
get("/notifications", params.compact)
|
|
1238
|
+
end
|
|
1239
|
+
|
|
1240
|
+
# Fetches all notifications, up to 1000 by default.
|
|
1241
|
+
# @return [Array<Hash>]
|
|
1242
|
+
def get_all_notifications(category: nil, limit: nil, location_id: nil, read: nil, since: nil, trigger_type: nil)
|
|
1243
|
+
paginator_to_a(list_notifications(category: category, limit: limit, location_id: location_id, read: read, since: since, trigger_type: trigger_type), 1000)
|
|
1244
|
+
end
|
|
1245
|
+
|
|
1246
|
+
# Lists list_orders_purchase_orders resources (paginated).
|
|
1247
|
+
# @return [Wenmar::Paginator]
|
|
1248
|
+
def list_orders_purchase_orders(page: nil, per_page: nil, vendor_id: nil)
|
|
1249
|
+
params = {"page" => page, "per_page" => per_page, "vendor_id" => vendor_id}
|
|
1250
|
+
get("/orders/purchase_orders", params.compact)
|
|
1251
|
+
end
|
|
1252
|
+
|
|
1253
|
+
# Fetches all orders_purchase_orders, up to 1000 by default.
|
|
1254
|
+
# @return [Array<Hash>]
|
|
1255
|
+
def get_all_orders_purchase_orders(page: nil, per_page: nil, vendor_id: nil)
|
|
1256
|
+
paginator_to_a(list_orders_purchase_orders(page: page, per_page: per_page, vendor_id: vendor_id), 1000)
|
|
1257
|
+
end
|
|
1258
|
+
|
|
1259
|
+
# Lists list_orders_return_orders resources (paginated).
|
|
1260
|
+
# @return [Wenmar::Paginator]
|
|
1261
|
+
def list_orders_return_orders
|
|
1262
|
+
get("/orders/return_orders")
|
|
1263
|
+
end
|
|
1264
|
+
|
|
1265
|
+
# Fetches all orders_return_orders, up to 1000 by default.
|
|
1266
|
+
# @return [Array<Hash>]
|
|
1267
|
+
def get_all_orders_return_orders
|
|
1268
|
+
paginator_to_a(list_orders_return_orders, 1000)
|
|
1269
|
+
end
|
|
1270
|
+
|
|
1271
|
+
# Lists list_orders_sublet_orders resources (paginated).
|
|
1272
|
+
# @return [Wenmar::Paginator]
|
|
1273
|
+
def list_orders_sublet_orders
|
|
1274
|
+
get("/orders/sublet_orders")
|
|
1275
|
+
end
|
|
1276
|
+
|
|
1277
|
+
# Fetches all orders_sublet_orders, up to 1000 by default.
|
|
1278
|
+
# @return [Array<Hash>]
|
|
1279
|
+
def get_all_orders_sublet_orders
|
|
1280
|
+
paginator_to_a(list_orders_sublet_orders, 1000)
|
|
1281
|
+
end
|
|
1282
|
+
|
|
1283
|
+
# Lists list_packages resources (paginated).
|
|
1284
|
+
# @return [Wenmar::Paginator]
|
|
1285
|
+
def list_packages
|
|
1286
|
+
get("/packages")
|
|
1287
|
+
end
|
|
1288
|
+
|
|
1289
|
+
# Fetches all packages, up to 1000 by default.
|
|
1290
|
+
# @return [Array<Hash>]
|
|
1291
|
+
def get_all_packages
|
|
1292
|
+
paginator_to_a(list_packages, 1000)
|
|
1293
|
+
end
|
|
1294
|
+
|
|
1295
|
+
# Lists list_parts resources (paginated).
|
|
1296
|
+
# @return [Wenmar::Paginator]
|
|
1297
|
+
def list_parts(brand: nil, page: nil, per_page: nil, q: nil, stock_status: nil, stocked: nil)
|
|
1298
|
+
params = {"brand" => brand, "page" => page, "per_page" => per_page, "q" => q, "stock_status" => stock_status, "stocked" => stocked}
|
|
1299
|
+
get("/parts", params.compact)
|
|
1300
|
+
end
|
|
1301
|
+
|
|
1302
|
+
# Fetches all parts, up to 1000 by default.
|
|
1303
|
+
# @return [Array<Hash>]
|
|
1304
|
+
def get_all_parts(brand: nil, page: nil, per_page: nil, q: nil, stock_status: nil, stocked: nil)
|
|
1305
|
+
paginator_to_a(list_parts(brand: brand, page: page, per_page: per_page, q: q, stock_status: stock_status, stocked: stocked), 1000)
|
|
1306
|
+
end
|
|
1307
|
+
|
|
1308
|
+
# Lists list_parts_matrices resources (paginated).
|
|
1309
|
+
# @return [Wenmar::Paginator]
|
|
1310
|
+
def list_parts_matrices
|
|
1311
|
+
get("/parts_matrices")
|
|
1312
|
+
end
|
|
1313
|
+
|
|
1314
|
+
# Fetches all parts_matrices, up to 1000 by default.
|
|
1315
|
+
# @return [Array<Hash>]
|
|
1316
|
+
def get_all_parts_matrices
|
|
1317
|
+
paginator_to_a(list_parts_matrices, 1000)
|
|
1318
|
+
end
|
|
1319
|
+
|
|
1320
|
+
# Lists list_payments resources (paginated).
|
|
1321
|
+
# @return [Wenmar::Paginator]
|
|
1322
|
+
def list_payments(method: nil)
|
|
1323
|
+
params = {"method" => method}
|
|
1324
|
+
get("/payments", params.compact)
|
|
1325
|
+
end
|
|
1326
|
+
|
|
1327
|
+
# Fetches all payments, up to 1000 by default.
|
|
1328
|
+
# @return [Array<Hash>]
|
|
1329
|
+
def get_all_payments(method: nil)
|
|
1330
|
+
paginator_to_a(list_payments(method: method), 1000)
|
|
1331
|
+
end
|
|
1332
|
+
|
|
1333
|
+
# Lists list_payments_pending resources (paginated).
|
|
1334
|
+
# @return [Wenmar::Paginator]
|
|
1335
|
+
def list_payments_pending
|
|
1336
|
+
get("/payments/pending")
|
|
1337
|
+
end
|
|
1338
|
+
|
|
1339
|
+
# Fetches all payments_pending, up to 1000 by default.
|
|
1340
|
+
# @return [Array<Hash>]
|
|
1341
|
+
def get_all_payments_pending
|
|
1342
|
+
paginator_to_a(list_payments_pending, 1000)
|
|
1343
|
+
end
|
|
1344
|
+
|
|
1345
|
+
# Lists list_permission_groups resources (paginated).
|
|
1346
|
+
# @return [Wenmar::Paginator]
|
|
1347
|
+
def list_permission_groups
|
|
1348
|
+
get("/users/permission_groups")
|
|
1349
|
+
end
|
|
1350
|
+
|
|
1351
|
+
# Fetches all permission_groups, up to 1000 by default.
|
|
1352
|
+
# @return [Array<Hash>]
|
|
1353
|
+
def get_all_permission_groups
|
|
1354
|
+
paginator_to_a(list_permission_groups, 1000)
|
|
1355
|
+
end
|
|
1356
|
+
|
|
1357
|
+
# Fetches list_reports_accounting.
|
|
1358
|
+
def list_reports_accounting
|
|
1359
|
+
get("/reports/accounting")
|
|
1360
|
+
end
|
|
1361
|
+
|
|
1362
|
+
# Fetches list_reports_ar_aging.
|
|
1363
|
+
def list_reports_ar_aging
|
|
1364
|
+
get("/reports/ar_aging")
|
|
1365
|
+
end
|
|
1366
|
+
|
|
1367
|
+
# Lists list_reports_cash_drawer_sessions resources (paginated).
|
|
1368
|
+
# @return [Wenmar::Paginator]
|
|
1369
|
+
def list_reports_cash_drawer_sessions
|
|
1370
|
+
get("/reports/cash_drawer_sessions")
|
|
1371
|
+
end
|
|
1372
|
+
|
|
1373
|
+
# Fetches all reports_cash_drawer_sessions, up to 1000 by default.
|
|
1374
|
+
# @return [Array<Hash>]
|
|
1375
|
+
def get_all_reports_cash_drawer_sessions
|
|
1376
|
+
paginator_to_a(list_reports_cash_drawer_sessions, 1000)
|
|
1377
|
+
end
|
|
1378
|
+
|
|
1379
|
+
# Fetches list_reports_cash_drawer_sessions_close.
|
|
1380
|
+
def list_reports_cash_drawer_sessions_close(id)
|
|
1381
|
+
get("/reports/cash_drawer_sessions/#{id}/close")
|
|
1382
|
+
end
|
|
1383
|
+
|
|
1384
|
+
# Fetches list_reports_declined_work.
|
|
1385
|
+
def list_reports_declined_work
|
|
1386
|
+
get("/reports/declined_work")
|
|
1387
|
+
end
|
|
1388
|
+
|
|
1389
|
+
# Fetches list_reports_end_of_day.
|
|
1390
|
+
def list_reports_end_of_day
|
|
1391
|
+
get("/reports/end_of_day")
|
|
1392
|
+
end
|
|
1393
|
+
|
|
1394
|
+
# Fetches list_reports_financial.
|
|
1395
|
+
def list_reports_financial
|
|
1396
|
+
get("/reports/financial")
|
|
1397
|
+
end
|
|
1398
|
+
|
|
1399
|
+
# Fetches list_reports_open_work.
|
|
1400
|
+
def list_reports_open_work
|
|
1401
|
+
get("/reports/open_work")
|
|
1402
|
+
end
|
|
1403
|
+
|
|
1404
|
+
# Fetches list_reports_parts_purchases.
|
|
1405
|
+
def list_reports_parts_purchases
|
|
1406
|
+
get("/reports/parts_purchases")
|
|
1407
|
+
end
|
|
1408
|
+
|
|
1409
|
+
# Fetches list_reports_parts_usage.
|
|
1410
|
+
def list_reports_parts_usage
|
|
1411
|
+
get("/reports/parts_usage")
|
|
1412
|
+
end
|
|
1413
|
+
|
|
1414
|
+
# Fetches list_reports_performance.
|
|
1415
|
+
def list_reports_performance
|
|
1416
|
+
get("/reports/performance")
|
|
1417
|
+
end
|
|
1418
|
+
|
|
1419
|
+
# Fetches list_reports_profit_and_loss.
|
|
1420
|
+
def list_reports_profit_and_loss
|
|
1421
|
+
get("/reports/profit_and_loss")
|
|
1422
|
+
end
|
|
1423
|
+
|
|
1424
|
+
# Fetches list_reports_sales_summary.
|
|
1425
|
+
def list_reports_sales_summary
|
|
1426
|
+
get("/reports/sales_summary")
|
|
1427
|
+
end
|
|
1428
|
+
|
|
1429
|
+
# Fetches list_reports_service_categories.
|
|
1430
|
+
def list_reports_service_categories
|
|
1431
|
+
get("/reports/service_categories")
|
|
1432
|
+
end
|
|
1433
|
+
|
|
1434
|
+
# Lists list_reports_statements resources (paginated).
|
|
1435
|
+
# @return [Wenmar::Paginator]
|
|
1436
|
+
def list_reports_statements(filter_billing_status: nil)
|
|
1437
|
+
params = {"filter[billing_status]" => filter_billing_status}
|
|
1438
|
+
get("/reports/statements", params.compact)
|
|
1439
|
+
end
|
|
1440
|
+
|
|
1441
|
+
# Fetches all reports_statements, up to 1000 by default.
|
|
1442
|
+
# @return [Array<Hash>]
|
|
1443
|
+
def get_all_reports_statements(filter_billing_status: nil)
|
|
1444
|
+
paginator_to_a(list_reports_statements(filter_billing_status: filter_billing_status), 1000)
|
|
1445
|
+
end
|
|
1446
|
+
|
|
1447
|
+
# Fetches list_reports_store_credit.
|
|
1448
|
+
def list_reports_store_credit
|
|
1449
|
+
get("/reports/store_credit")
|
|
1450
|
+
end
|
|
1451
|
+
|
|
1452
|
+
# Lists list_reports_tax_periods resources (paginated).
|
|
1453
|
+
# @return [Wenmar::Paginator]
|
|
1454
|
+
def list_reports_tax_periods
|
|
1455
|
+
get("/reports/tax_periods")
|
|
1456
|
+
end
|
|
1457
|
+
|
|
1458
|
+
# Fetches all reports_tax_periods, up to 1000 by default.
|
|
1459
|
+
# @return [Array<Hash>]
|
|
1460
|
+
def get_all_reports_tax_periods
|
|
1461
|
+
paginator_to_a(list_reports_tax_periods, 1000)
|
|
1462
|
+
end
|
|
1463
|
+
|
|
1464
|
+
# Fetches list_reports_technician_productivity.
|
|
1465
|
+
def list_reports_technician_productivity
|
|
1466
|
+
get("/reports/technician_productivity")
|
|
1467
|
+
end
|
|
1468
|
+
|
|
1469
|
+
# Fetches list_reports_work_order_profitability.
|
|
1470
|
+
def list_reports_work_order_profitability
|
|
1471
|
+
get("/reports/work_order_profitability")
|
|
1472
|
+
end
|
|
1473
|
+
|
|
1474
|
+
# Lists list_service_categories resources (paginated).
|
|
1475
|
+
# @return [Wenmar::Paginator]
|
|
1476
|
+
def list_service_categories
|
|
1477
|
+
get("/service_categories")
|
|
1478
|
+
end
|
|
1479
|
+
|
|
1480
|
+
# Fetches all service_categories, up to 1000 by default.
|
|
1481
|
+
# @return [Array<Hash>]
|
|
1482
|
+
def get_all_service_categories
|
|
1483
|
+
paginator_to_a(list_service_categories, 1000)
|
|
1484
|
+
end
|
|
1485
|
+
|
|
1486
|
+
# Lists list_shop_discounts resources (paginated).
|
|
1487
|
+
# @return [Wenmar::Paginator]
|
|
1488
|
+
def list_shop_discounts
|
|
1489
|
+
get("/shop_discounts")
|
|
1490
|
+
end
|
|
1491
|
+
|
|
1492
|
+
# Fetches all shop_discounts, up to 1000 by default.
|
|
1493
|
+
# @return [Array<Hash>]
|
|
1494
|
+
def get_all_shop_discounts
|
|
1495
|
+
paginator_to_a(list_shop_discounts, 1000)
|
|
1496
|
+
end
|
|
1497
|
+
|
|
1498
|
+
# Lists list_shop_fees resources (paginated).
|
|
1499
|
+
# @return [Wenmar::Paginator]
|
|
1500
|
+
def list_shop_fees
|
|
1501
|
+
get("/shop_fees")
|
|
1502
|
+
end
|
|
1503
|
+
|
|
1504
|
+
# Fetches all shop_fees, up to 1000 by default.
|
|
1505
|
+
# @return [Array<Hash>]
|
|
1506
|
+
def get_all_shop_fees
|
|
1507
|
+
paginator_to_a(list_shop_fees, 1000)
|
|
1508
|
+
end
|
|
1509
|
+
|
|
1510
|
+
# Lists list_statements_payments resources (paginated).
|
|
1511
|
+
# @return [Wenmar::Paginator]
|
|
1512
|
+
def list_statements_payments(statement_id)
|
|
1513
|
+
get("/statements/#{statement_id}/payments")
|
|
1514
|
+
end
|
|
1515
|
+
|
|
1516
|
+
# Fetches all statements_payments, up to 1000 by default.
|
|
1517
|
+
# @return [Array<Hash>]
|
|
1518
|
+
def get_all_statements_payments(statement_id)
|
|
1519
|
+
paginator_to_a(list_statements_payments(statement_id), 1000)
|
|
1520
|
+
end
|
|
1521
|
+
|
|
1522
|
+
# Lists list_sub_statuses resources (paginated).
|
|
1523
|
+
# @return [Wenmar::Paginator]
|
|
1524
|
+
def list_sub_statuses
|
|
1525
|
+
get("/sub_statuses")
|
|
1526
|
+
end
|
|
1527
|
+
|
|
1528
|
+
# Fetches all sub_statuses, up to 1000 by default.
|
|
1529
|
+
# @return [Array<Hash>]
|
|
1530
|
+
def get_all_sub_statuses
|
|
1531
|
+
paginator_to_a(list_sub_statuses, 1000)
|
|
1532
|
+
end
|
|
1533
|
+
|
|
1534
|
+
# Lists list_sublet_packages resources (paginated).
|
|
1535
|
+
# @return [Wenmar::Paginator]
|
|
1536
|
+
def list_sublet_packages
|
|
1537
|
+
get("/sublet_packages")
|
|
1538
|
+
end
|
|
1539
|
+
|
|
1540
|
+
# Fetches all sublet_packages, up to 1000 by default.
|
|
1541
|
+
# @return [Array<Hash>]
|
|
1542
|
+
def get_all_sublet_packages
|
|
1543
|
+
paginator_to_a(list_sublet_packages, 1000)
|
|
1544
|
+
end
|
|
1545
|
+
|
|
1546
|
+
# Lists list_tire_events resources (paginated).
|
|
1547
|
+
# @return [Wenmar::Paginator]
|
|
1548
|
+
def list_tire_events
|
|
1549
|
+
get("/tire_events")
|
|
1550
|
+
end
|
|
1551
|
+
|
|
1552
|
+
# Fetches all tire_events, up to 1000 by default.
|
|
1553
|
+
# @return [Array<Hash>]
|
|
1554
|
+
def get_all_tire_events
|
|
1555
|
+
paginator_to_a(list_tire_events, 1000)
|
|
1556
|
+
end
|
|
1557
|
+
|
|
1558
|
+
# Lists list_tire_storage_slots resources (paginated).
|
|
1559
|
+
# @return [Wenmar::Paginator]
|
|
1560
|
+
def list_tire_storage_slots
|
|
1561
|
+
get("/tire_storage_slots")
|
|
1562
|
+
end
|
|
1563
|
+
|
|
1564
|
+
# Fetches all tire_storage_slots, up to 1000 by default.
|
|
1565
|
+
# @return [Array<Hash>]
|
|
1566
|
+
def get_all_tire_storage_slots
|
|
1567
|
+
paginator_to_a(list_tire_storage_slots, 1000)
|
|
1568
|
+
end
|
|
1569
|
+
|
|
1570
|
+
# Lists list_tires resources (paginated).
|
|
1571
|
+
# @return [Wenmar::Paginator]
|
|
1572
|
+
def list_tires
|
|
1573
|
+
get("/tires")
|
|
1574
|
+
end
|
|
1575
|
+
|
|
1576
|
+
# Fetches all tires, up to 1000 by default.
|
|
1577
|
+
# @return [Array<Hash>]
|
|
1578
|
+
def get_all_tires
|
|
1579
|
+
paginator_to_a(list_tires, 1000)
|
|
1580
|
+
end
|
|
1581
|
+
|
|
1582
|
+
# Lists list_users resources (paginated).
|
|
1583
|
+
# @return [Wenmar::Paginator]
|
|
1584
|
+
def list_users(page: nil, per_page: nil)
|
|
1585
|
+
params = {"page" => page, "per_page" => per_page}
|
|
1586
|
+
get("/users", params.compact)
|
|
1587
|
+
end
|
|
1588
|
+
|
|
1589
|
+
# Fetches all users, up to 1000 by default.
|
|
1590
|
+
# @return [Array<Hash>]
|
|
1591
|
+
def get_all_users(page: nil, per_page: nil)
|
|
1592
|
+
paginator_to_a(list_users(page: page, per_page: per_page), 1000)
|
|
1593
|
+
end
|
|
1594
|
+
|
|
1595
|
+
# Fetches list_users_qr_code.
|
|
1596
|
+
def list_users_qr_code(id)
|
|
1597
|
+
get("/users/#{id}/qr_code")
|
|
1598
|
+
end
|
|
1599
|
+
|
|
1600
|
+
# Lists list_vehicles resources (paginated).
|
|
1601
|
+
# @return [Wenmar::Paginator]
|
|
1602
|
+
def list_vehicles(customer_id: nil, page: nil, per_page: nil, q: nil, status: nil, type: nil)
|
|
1603
|
+
params = {"customer_id" => customer_id, "page" => page, "per_page" => per_page, "q" => q, "status" => status, "type" => type}
|
|
1604
|
+
get("/vehicles", params.compact)
|
|
1605
|
+
end
|
|
1606
|
+
|
|
1607
|
+
# Fetches all vehicles, up to 1000 by default.
|
|
1608
|
+
# @return [Array<Hash>]
|
|
1609
|
+
def get_all_vehicles(customer_id: nil, page: nil, per_page: nil, q: nil, status: nil, type: nil)
|
|
1610
|
+
paginator_to_a(list_vehicles(customer_id: customer_id, page: page, per_page: per_page, q: q, status: status, type: type), 1000)
|
|
1611
|
+
end
|
|
1612
|
+
|
|
1613
|
+
# Fetches list_vehicles_customer_vehicles.
|
|
1614
|
+
def list_vehicles_customer_vehicles(customer_id: nil)
|
|
1615
|
+
params = {"customer_id" => customer_id}
|
|
1616
|
+
get("/vehicles/customer_vehicles", params.compact)
|
|
1617
|
+
end
|
|
1618
|
+
|
|
1619
|
+
# Lists list_vehicles_work_orders resources (paginated).
|
|
1620
|
+
# @return [Wenmar::Paginator]
|
|
1621
|
+
def list_vehicles_work_orders(vehicle_id)
|
|
1622
|
+
get("/vehicles/#{vehicle_id}/work_orders")
|
|
1623
|
+
end
|
|
1624
|
+
|
|
1625
|
+
# Fetches all vehicles_work_orders, up to 1000 by default.
|
|
1626
|
+
# @return [Array<Hash>]
|
|
1627
|
+
def get_all_vehicles_work_orders(vehicle_id)
|
|
1628
|
+
paginator_to_a(list_vehicles_work_orders(vehicle_id), 1000)
|
|
1629
|
+
end
|
|
1630
|
+
|
|
1631
|
+
# Lists list_vendors resources (paginated).
|
|
1632
|
+
# @return [Wenmar::Paginator]
|
|
1633
|
+
def list_vendors
|
|
1634
|
+
get("/vendors")
|
|
1635
|
+
end
|
|
1636
|
+
|
|
1637
|
+
# Fetches all vendors, up to 1000 by default.
|
|
1638
|
+
# @return [Array<Hash>]
|
|
1639
|
+
def get_all_vendors
|
|
1640
|
+
paginator_to_a(list_vendors, 1000)
|
|
1641
|
+
end
|
|
1642
|
+
|
|
1643
|
+
# Lists list_vendors_purchase_orders resources (paginated).
|
|
1644
|
+
# @return [Wenmar::Paginator]
|
|
1645
|
+
def list_vendors_purchase_orders(vendor_id)
|
|
1646
|
+
get("/vendors/#{vendor_id}/purchase_orders")
|
|
1647
|
+
end
|
|
1648
|
+
|
|
1649
|
+
# Fetches all vendors_purchase_orders, up to 1000 by default.
|
|
1650
|
+
# @return [Array<Hash>]
|
|
1651
|
+
def get_all_vendors_purchase_orders(vendor_id)
|
|
1652
|
+
paginator_to_a(list_vendors_purchase_orders(vendor_id), 1000)
|
|
1653
|
+
end
|
|
1654
|
+
|
|
1655
|
+
# Lists list_work_order_services resources (paginated).
|
|
1656
|
+
# @return [Wenmar::Paginator]
|
|
1657
|
+
def list_work_order_services(work_order_id)
|
|
1658
|
+
get("/work_orders/#{work_order_id}/services")
|
|
1659
|
+
end
|
|
1660
|
+
|
|
1661
|
+
# Fetches all work_order_services, up to 1000 by default.
|
|
1662
|
+
# @return [Array<Hash>]
|
|
1663
|
+
def get_all_work_order_services(work_order_id)
|
|
1664
|
+
paginator_to_a(list_work_order_services(work_order_id), 1000)
|
|
1665
|
+
end
|
|
1666
|
+
|
|
1667
|
+
# Lists list_work_order_tags resources (paginated).
|
|
1668
|
+
# @return [Wenmar::Paginator]
|
|
1669
|
+
def list_work_order_tags
|
|
1670
|
+
get("/work_order_tags")
|
|
1671
|
+
end
|
|
1672
|
+
|
|
1673
|
+
# Fetches all work_order_tags, up to 1000 by default.
|
|
1674
|
+
# @return [Array<Hash>]
|
|
1675
|
+
def get_all_work_order_tags
|
|
1676
|
+
paginator_to_a(list_work_order_tags, 1000)
|
|
1677
|
+
end
|
|
1678
|
+
|
|
1679
|
+
# Lists list_work_orders resources (paginated).
|
|
1680
|
+
# @return [Wenmar::Paginator]
|
|
1681
|
+
def list_work_orders(per_page: nil)
|
|
1682
|
+
params = {"per_page" => per_page}
|
|
1683
|
+
get("/work_orders", params.compact)
|
|
1684
|
+
end
|
|
1685
|
+
|
|
1686
|
+
# Fetches all work_orders, up to 1000 by default.
|
|
1687
|
+
# @return [Array<Hash>]
|
|
1688
|
+
def get_all_work_orders(per_page: nil)
|
|
1689
|
+
paginator_to_a(list_work_orders(per_page: per_page), 1000)
|
|
1690
|
+
end
|
|
1691
|
+
|
|
1692
|
+
# Lists list_work_orders_activity resources (paginated).
|
|
1693
|
+
# @return [Wenmar::Paginator]
|
|
1694
|
+
def list_work_orders_activity(id, category: nil)
|
|
1695
|
+
params = {"category" => category}
|
|
1696
|
+
get("/work_orders/#{id}/activity", params.compact)
|
|
1697
|
+
end
|
|
1698
|
+
|
|
1699
|
+
# Fetches all work_orders_activity, up to 1000 by default.
|
|
1700
|
+
# @return [Array<Hash>]
|
|
1701
|
+
def get_all_work_orders_activity(id, category: nil)
|
|
1702
|
+
paginator_to_a(list_work_orders_activity(id, category: category), 1000)
|
|
1703
|
+
end
|
|
1704
|
+
|
|
1705
|
+
# Lists list_work_orders_appointments resources (paginated).
|
|
1706
|
+
# @return [Wenmar::Paginator]
|
|
1707
|
+
def list_work_orders_appointments(id)
|
|
1708
|
+
get("/work_orders/#{id}/appointments")
|
|
1709
|
+
end
|
|
1710
|
+
|
|
1711
|
+
# Fetches all work_orders_appointments, up to 1000 by default.
|
|
1712
|
+
# @return [Array<Hash>]
|
|
1713
|
+
def get_all_work_orders_appointments(id)
|
|
1714
|
+
paginator_to_a(list_work_orders_appointments(id), 1000)
|
|
1715
|
+
end
|
|
1716
|
+
|
|
1717
|
+
# Lists list_work_orders_authorization_logs resources (paginated).
|
|
1718
|
+
# @return [Wenmar::Paginator]
|
|
1719
|
+
def list_work_orders_authorization_logs(id)
|
|
1720
|
+
get("/work_orders/#{id}/authorization_logs")
|
|
1721
|
+
end
|
|
1722
|
+
|
|
1723
|
+
# Fetches all work_orders_authorization_logs, up to 1000 by default.
|
|
1724
|
+
# @return [Array<Hash>]
|
|
1725
|
+
def get_all_work_orders_authorization_logs(id)
|
|
1726
|
+
paginator_to_a(list_work_orders_authorization_logs(id), 1000)
|
|
1727
|
+
end
|
|
1728
|
+
|
|
1729
|
+
# Lists list_work_orders_concerns resources (paginated).
|
|
1730
|
+
# @return [Wenmar::Paginator]
|
|
1731
|
+
def list_work_orders_concerns(work_order_id)
|
|
1732
|
+
get("/work_orders/#{work_order_id}/concerns")
|
|
1733
|
+
end
|
|
1734
|
+
|
|
1735
|
+
# Fetches all work_orders_concerns, up to 1000 by default.
|
|
1736
|
+
# @return [Array<Hash>]
|
|
1737
|
+
def get_all_work_orders_concerns(work_order_id)
|
|
1738
|
+
paginator_to_a(list_work_orders_concerns(work_order_id), 1000)
|
|
1739
|
+
end
|
|
1740
|
+
|
|
1741
|
+
# Fetches list_work_orders_payment_link.
|
|
1742
|
+
def list_work_orders_payment_link(work_order_id)
|
|
1743
|
+
get("/work_orders/#{work_order_id}/payment_link")
|
|
1744
|
+
end
|
|
1745
|
+
|
|
1746
|
+
# Lists list_work_orders_receipts resources (paginated).
|
|
1747
|
+
# @return [Wenmar::Paginator]
|
|
1748
|
+
def list_work_orders_receipts(work_order_id)
|
|
1749
|
+
get("/work_orders/#{work_order_id}/receipts")
|
|
1750
|
+
end
|
|
1751
|
+
|
|
1752
|
+
# Fetches all work_orders_receipts, up to 1000 by default.
|
|
1753
|
+
# @return [Array<Hash>]
|
|
1754
|
+
def get_all_work_orders_receipts(work_order_id)
|
|
1755
|
+
paginator_to_a(list_work_orders_receipts(work_order_id), 1000)
|
|
1756
|
+
end
|
|
1757
|
+
|
|
1758
|
+
# Fetches list_work_orders_services_adjust_time.
|
|
1759
|
+
def list_work_orders_services_adjust_time(work_order_id, id)
|
|
1760
|
+
get("/work_orders/#{work_order_id}/services/#{id}/adjust_time")
|
|
1761
|
+
end
|
|
1762
|
+
|
|
1763
|
+
# Lists list_work_orders_services_comments resources (paginated).
|
|
1764
|
+
# @return [Wenmar::Paginator]
|
|
1765
|
+
def list_work_orders_services_comments(work_order_id, service_id)
|
|
1766
|
+
get("/work_orders/#{work_order_id}/services/#{service_id}/comments")
|
|
1767
|
+
end
|
|
1768
|
+
|
|
1769
|
+
# Fetches all work_orders_services_comments, up to 1000 by default.
|
|
1770
|
+
# @return [Array<Hash>]
|
|
1771
|
+
def get_all_work_orders_services_comments(work_order_id, service_id)
|
|
1772
|
+
paginator_to_a(list_work_orders_services_comments(work_order_id, service_id), 1000)
|
|
1773
|
+
end
|
|
1774
|
+
|
|
1775
|
+
# Lists list_work_orders_services_line_items resources (paginated).
|
|
1776
|
+
# @return [Wenmar::Paginator]
|
|
1777
|
+
def list_work_orders_services_line_items(work_order_id, service_id)
|
|
1778
|
+
get("/work_orders/#{work_order_id}/services/#{service_id}/line_items")
|
|
1779
|
+
end
|
|
1780
|
+
|
|
1781
|
+
# Fetches all work_orders_services_line_items, up to 1000 by default.
|
|
1782
|
+
# @return [Array<Hash>]
|
|
1783
|
+
def get_all_work_orders_services_line_items(work_order_id, service_id)
|
|
1784
|
+
paginator_to_a(list_work_orders_services_line_items(work_order_id, service_id), 1000)
|
|
1785
|
+
end
|
|
1786
|
+
|
|
1787
|
+
# Lists list_work_orders_sublet_orders resources (paginated).
|
|
1788
|
+
# @return [Wenmar::Paginator]
|
|
1789
|
+
def list_work_orders_sublet_orders(work_order_id)
|
|
1790
|
+
get("/work_orders/#{work_order_id}/sublet_orders")
|
|
1791
|
+
end
|
|
1792
|
+
|
|
1793
|
+
# Fetches all work_orders_sublet_orders, up to 1000 by default.
|
|
1794
|
+
# @return [Array<Hash>]
|
|
1795
|
+
def get_all_work_orders_sublet_orders(work_order_id)
|
|
1796
|
+
paginator_to_a(list_work_orders_sublet_orders(work_order_id), 1000)
|
|
1797
|
+
end
|
|
1798
|
+
|
|
1799
|
+
# Lists list_work_orders_tire_storage resources (paginated).
|
|
1800
|
+
# @return [Wenmar::Paginator]
|
|
1801
|
+
def list_work_orders_tire_storage(work_order_id)
|
|
1802
|
+
get("/work_orders/#{work_order_id}/tire_storage")
|
|
1803
|
+
end
|
|
1804
|
+
|
|
1805
|
+
# Fetches all work_orders_tire_storage, up to 1000 by default.
|
|
1806
|
+
# @return [Array<Hash>]
|
|
1807
|
+
def get_all_work_orders_tire_storage(work_order_id)
|
|
1808
|
+
paginator_to_a(list_work_orders_tire_storage(work_order_id), 1000)
|
|
1809
|
+
end
|
|
1810
|
+
|
|
1811
|
+
# Lists list_work_orders_vehicle_history resources (paginated).
|
|
1812
|
+
# @return [Wenmar::Paginator]
|
|
1813
|
+
def list_work_orders_vehicle_history(id)
|
|
1814
|
+
get("/work_orders/#{id}/vehicle_history")
|
|
1815
|
+
end
|
|
1816
|
+
|
|
1817
|
+
# Fetches all work_orders_vehicle_history, up to 1000 by default.
|
|
1818
|
+
# @return [Array<Hash>]
|
|
1819
|
+
def get_all_work_orders_vehicle_history(id)
|
|
1820
|
+
paginator_to_a(list_work_orders_vehicle_history(id), 1000)
|
|
1821
|
+
end
|
|
1822
|
+
|
|
1823
|
+
# Runs mark_all_inspection_report (POST /inspection_reports/{id}/mark_all).
|
|
1824
|
+
def mark_all_inspection_report(id, status:, group_name:)
|
|
1825
|
+
post("/inspection_reports/#{id}/mark_all", {status: status, group_name: group_name})
|
|
1826
|
+
end
|
|
1827
|
+
|
|
1828
|
+
# Runs merge_customer (POST /customers/{id}/merges).
|
|
1829
|
+
def merge_customer(id, source_customer_id:)
|
|
1830
|
+
post("/customers/#{id}/merges", {source_customer_id: source_customer_id})
|
|
1831
|
+
end
|
|
1832
|
+
|
|
1833
|
+
# Runs merge_vehicle (POST /vehicles/{id}/merges).
|
|
1834
|
+
def merge_vehicle(id, source_vehicle_id:)
|
|
1835
|
+
post("/vehicles/#{id}/merges", {source_vehicle_id: source_vehicle_id})
|
|
1836
|
+
end
|
|
1837
|
+
|
|
1838
|
+
# Runs post_work_order_to_account (POST /work_orders/{id}/post_to_account).
|
|
1839
|
+
def post_work_order_to_account(id)
|
|
1840
|
+
post("/work_orders/#{id}/post_to_account")
|
|
1841
|
+
end
|
|
1842
|
+
|
|
1843
|
+
# Fetches prefill_vehicle.
|
|
1844
|
+
def prefill_vehicle(make: nil, model: nil, vin: nil, year: nil)
|
|
1845
|
+
params = {"make" => make, "model" => model, "vin" => vin, "year" => year}
|
|
1846
|
+
get("/vehicles/prefill", params.compact)
|
|
1847
|
+
end
|
|
1848
|
+
|
|
1849
|
+
# Runs pull_work_order_service_line_item (PATCH /work_orders/{work_order_id}/services/{service_id}/line_items/{id}/pull).
|
|
1850
|
+
def pull_work_order_service_line_item(work_order_id, service_id, id)
|
|
1851
|
+
patch("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}/pull")
|
|
1852
|
+
end
|
|
1853
|
+
|
|
1854
|
+
# Runs reassign_inspection_report (PATCH /inspection_reports/{id}/reassign).
|
|
1855
|
+
def reassign_inspection_report(id, user_id:)
|
|
1856
|
+
patch("/inspection_reports/#{id}/reassign", {user_id: user_id})
|
|
1857
|
+
end
|
|
1858
|
+
|
|
1859
|
+
# Runs remove_default_inspection (PATCH /inspections/{id}/remove_default).
|
|
1860
|
+
def remove_default_inspection(id)
|
|
1861
|
+
patch("/inspections/#{id}/remove_default")
|
|
1862
|
+
end
|
|
1863
|
+
|
|
1864
|
+
# Runs reopen_inspection_report (PATCH /inspection_reports/{id}/reopen).
|
|
1865
|
+
def reopen_inspection_report(id)
|
|
1866
|
+
patch("/inspection_reports/#{id}/reopen")
|
|
1867
|
+
end
|
|
1868
|
+
|
|
1869
|
+
# Runs reopen_work_order (POST /work_orders/{id}/reopen).
|
|
1870
|
+
def reopen_work_order(id)
|
|
1871
|
+
post("/work_orders/#{id}/reopen")
|
|
1872
|
+
end
|
|
1873
|
+
|
|
1874
|
+
# Runs reset_inspection_report (PATCH /inspection_reports/{id}/reset).
|
|
1875
|
+
def reset_inspection_report(id)
|
|
1876
|
+
patch("/inspection_reports/#{id}/reset")
|
|
1877
|
+
end
|
|
1878
|
+
|
|
1879
|
+
# Runs restore_customer (PATCH /customers/{id}/restore).
|
|
1880
|
+
def restore_customer(id)
|
|
1881
|
+
patch("/customers/#{id}/restore")
|
|
1882
|
+
end
|
|
1883
|
+
|
|
1884
|
+
# Runs restore_inspection (PATCH /inspections/{id}/restore).
|
|
1885
|
+
def restore_inspection(id)
|
|
1886
|
+
patch("/inspections/#{id}/restore")
|
|
1887
|
+
end
|
|
1888
|
+
|
|
1889
|
+
# Runs restore_labor_rate (PATCH /labor_rates/{id}/restore).
|
|
1890
|
+
def restore_labor_rate(id)
|
|
1891
|
+
patch("/labor_rates/#{id}/restore")
|
|
1892
|
+
end
|
|
1893
|
+
|
|
1894
|
+
# Runs restore_package (PATCH /packages/{id}/restore).
|
|
1895
|
+
def restore_package(id)
|
|
1896
|
+
patch("/packages/#{id}/restore")
|
|
1897
|
+
end
|
|
1898
|
+
|
|
1899
|
+
# Runs restore_service_category (PATCH /service_categories/{id}/restore).
|
|
1900
|
+
def restore_service_category(id)
|
|
1901
|
+
patch("/service_categories/#{id}/restore")
|
|
1902
|
+
end
|
|
1903
|
+
|
|
1904
|
+
# Runs restore_vehicle (PATCH /vehicles/{id}/restore).
|
|
1905
|
+
def restore_vehicle(id)
|
|
1906
|
+
patch("/vehicles/#{id}/restore")
|
|
1907
|
+
end
|
|
1908
|
+
|
|
1909
|
+
# Runs restore_vendor (PATCH /vendors/{id}/restore).
|
|
1910
|
+
def restore_vendor(id)
|
|
1911
|
+
patch("/vendors/#{id}/restore")
|
|
1912
|
+
end
|
|
1913
|
+
|
|
1914
|
+
# Runs retry_inspection_report_recording (POST /inspection_reports/{id}/retry_recording).
|
|
1915
|
+
def retry_inspection_report_recording(id, recording_id: nil)
|
|
1916
|
+
params = {recording_id: recording_id}
|
|
1917
|
+
post("/inspection_reports/#{id}/retry_recording", params.compact)
|
|
1918
|
+
end
|
|
1919
|
+
|
|
1920
|
+
# Deletes reverse_work_order_payment_ar.
|
|
1921
|
+
def reverse_work_order_payment_ar(work_order_id)
|
|
1922
|
+
delete("/work_orders/#{work_order_id}/payments/reverse_ar")
|
|
1923
|
+
end
|
|
1924
|
+
|
|
1925
|
+
# Runs seed_defaults_service_categories (POST /service_categories/seed_defaults).
|
|
1926
|
+
def seed_defaults_service_categories
|
|
1927
|
+
post("/service_categories/seed_defaults")
|
|
1928
|
+
end
|
|
1929
|
+
|
|
1930
|
+
# Runs send_campaign (POST /campaigns/{id}/send_campaign).
|
|
1931
|
+
def send_campaign(id)
|
|
1932
|
+
post("/campaigns/#{id}/send_campaign")
|
|
1933
|
+
end
|
|
1934
|
+
|
|
1935
|
+
# Runs send_work_order_estimate (POST /work_orders/{id}/send_estimate).
|
|
1936
|
+
def send_work_order_estimate(id)
|
|
1937
|
+
post("/work_orders/#{id}/send_estimate")
|
|
1938
|
+
end
|
|
1939
|
+
|
|
1940
|
+
# Runs send_work_order_invoice_summary (POST /work_orders/{id}/send_invoice_summary).
|
|
1941
|
+
def send_work_order_invoice_summary(id)
|
|
1942
|
+
post("/work_orders/#{id}/send_invoice_summary")
|
|
1943
|
+
end
|
|
1944
|
+
|
|
1945
|
+
# Runs send_work_order_payment_to_ar (POST /work_orders/{work_order_id}/payments/send_to_ar).
|
|
1946
|
+
def send_work_order_payment_to_ar(work_order_id)
|
|
1947
|
+
post("/work_orders/#{work_order_id}/payments/send_to_ar")
|
|
1948
|
+
end
|
|
1949
|
+
|
|
1950
|
+
# Runs send_work_order_reminder (POST /work_orders/{id}/send_reminder).
|
|
1951
|
+
def send_work_order_reminder(id)
|
|
1952
|
+
post("/work_orders/#{id}/send_reminder")
|
|
1953
|
+
end
|
|
1954
|
+
|
|
1955
|
+
# Runs set_default_inspection (PATCH /inspections/{id}/set_default).
|
|
1956
|
+
def set_default_inspection(id)
|
|
1957
|
+
patch("/inspections/#{id}/set_default")
|
|
1958
|
+
end
|
|
1959
|
+
|
|
1960
|
+
# Fetches show_appointment.
|
|
1961
|
+
def show_appointment(id)
|
|
1962
|
+
get("/appointments/#{id}")
|
|
1963
|
+
end
|
|
1964
|
+
|
|
1965
|
+
# Fetches show_campaign.
|
|
1966
|
+
def show_campaign(id)
|
|
1967
|
+
get("/campaigns/#{id}")
|
|
1968
|
+
end
|
|
1969
|
+
|
|
1970
|
+
# Fetches show_cash_entry.
|
|
1971
|
+
def show_cash_entry(id)
|
|
1972
|
+
get("/cash_entries/#{id}")
|
|
1973
|
+
end
|
|
1974
|
+
|
|
1975
|
+
# Fetches show_conversation.
|
|
1976
|
+
def show_conversation(id)
|
|
1977
|
+
get("/conversations/#{id}")
|
|
1978
|
+
end
|
|
1979
|
+
|
|
1980
|
+
# Fetches show_counter_sale.
|
|
1981
|
+
def show_counter_sale(id)
|
|
1982
|
+
get("/counter_sales/#{id}")
|
|
1983
|
+
end
|
|
1984
|
+
|
|
1985
|
+
# Fetches show_customer.
|
|
1986
|
+
def show_customer(id)
|
|
1987
|
+
get("/customers/#{id}")
|
|
1988
|
+
end
|
|
1989
|
+
|
|
1990
|
+
# Fetches show_customer_tag.
|
|
1991
|
+
def show_customer_tag(id)
|
|
1992
|
+
get("/customer_tags/#{id}")
|
|
1993
|
+
end
|
|
1994
|
+
|
|
1995
|
+
# Fetches show_driver.
|
|
1996
|
+
def show_driver(customer_id, id)
|
|
1997
|
+
get("/customers/#{customer_id}/drivers/#{id}")
|
|
1998
|
+
end
|
|
1999
|
+
|
|
2000
|
+
# Fetches show_expense.
|
|
2001
|
+
def show_expense(id)
|
|
2002
|
+
get("/expenses/#{id}")
|
|
2003
|
+
end
|
|
2004
|
+
|
|
2005
|
+
# Fetches show_inspection.
|
|
2006
|
+
def show_inspection(id)
|
|
2007
|
+
get("/inspections/#{id}")
|
|
2008
|
+
end
|
|
2009
|
+
|
|
2010
|
+
# Fetches show_inspection_report.
|
|
2011
|
+
def show_inspection_report(id)
|
|
2012
|
+
get("/inspection_reports/#{id}")
|
|
2013
|
+
end
|
|
2014
|
+
|
|
2015
|
+
# Fetches show_inspection_report_group.
|
|
2016
|
+
def show_inspection_report_group(id, group_name: nil)
|
|
2017
|
+
params = {"group_name" => group_name}
|
|
2018
|
+
get("/inspection_reports/#{id}/group", params.compact)
|
|
2019
|
+
end
|
|
2020
|
+
|
|
2021
|
+
# Fetches show_inventory_level.
|
|
2022
|
+
def show_inventory_level(id)
|
|
2023
|
+
get("/inventory_levels/#{id}")
|
|
2024
|
+
end
|
|
2025
|
+
|
|
2026
|
+
# Fetches show_location.
|
|
2027
|
+
def show_location(id)
|
|
2028
|
+
get("/locations/#{id}")
|
|
2029
|
+
end
|
|
2030
|
+
|
|
2031
|
+
# Fetches show_message.
|
|
2032
|
+
def show_message(id)
|
|
2033
|
+
get("/messages/#{id}")
|
|
2034
|
+
end
|
|
2035
|
+
|
|
2036
|
+
# Fetches show_notification.
|
|
2037
|
+
def show_notification(id)
|
|
2038
|
+
get("/notifications/#{id}")
|
|
2039
|
+
end
|
|
2040
|
+
|
|
2041
|
+
# Fetches show_orders_purchase_order.
|
|
2042
|
+
def show_orders_purchase_order(id)
|
|
2043
|
+
get("/orders/purchase_orders/#{id}")
|
|
2044
|
+
end
|
|
2045
|
+
|
|
2046
|
+
# Fetches show_orders_return_order.
|
|
2047
|
+
def show_orders_return_order(id)
|
|
2048
|
+
get("/orders/return_orders/#{id}")
|
|
2049
|
+
end
|
|
2050
|
+
|
|
2051
|
+
# Fetches show_orders_sublet_order.
|
|
2052
|
+
def show_orders_sublet_order(id)
|
|
2053
|
+
get("/orders/sublet_orders/#{id}")
|
|
2054
|
+
end
|
|
2055
|
+
|
|
2056
|
+
# Fetches show_part.
|
|
2057
|
+
def show_part(id)
|
|
2058
|
+
get("/parts/#{id}")
|
|
2059
|
+
end
|
|
2060
|
+
|
|
2061
|
+
# Fetches show_payment.
|
|
2062
|
+
def show_payment(id)
|
|
2063
|
+
get("/payments/#{id}")
|
|
2064
|
+
end
|
|
2065
|
+
|
|
2066
|
+
# Fetches show_reports_cash_drawer_session.
|
|
2067
|
+
def show_reports_cash_drawer_session(id)
|
|
2068
|
+
get("/reports/cash_drawer_sessions/#{id}")
|
|
2069
|
+
end
|
|
2070
|
+
|
|
2071
|
+
# Fetches show_statement.
|
|
2072
|
+
def show_statement(id)
|
|
2073
|
+
get("/statements/#{id}")
|
|
2074
|
+
end
|
|
2075
|
+
|
|
2076
|
+
# Fetches show_tire.
|
|
2077
|
+
def show_tire(id)
|
|
2078
|
+
get("/tires/#{id}")
|
|
2079
|
+
end
|
|
2080
|
+
|
|
2081
|
+
# Fetches show_tire_event.
|
|
2082
|
+
def show_tire_event(id)
|
|
2083
|
+
get("/tire_events/#{id}")
|
|
2084
|
+
end
|
|
2085
|
+
|
|
2086
|
+
# Fetches show_tire_storage_slot.
|
|
2087
|
+
def show_tire_storage_slot(id)
|
|
2088
|
+
get("/tire_storage_slots/#{id}")
|
|
2089
|
+
end
|
|
2090
|
+
|
|
2091
|
+
# Fetches show_user.
|
|
2092
|
+
def show_user(id)
|
|
2093
|
+
get("/users/#{id}")
|
|
2094
|
+
end
|
|
2095
|
+
|
|
2096
|
+
# Fetches show_vehicle.
|
|
2097
|
+
def show_vehicle(id)
|
|
2098
|
+
get("/vehicles/#{id}")
|
|
2099
|
+
end
|
|
2100
|
+
|
|
2101
|
+
# Fetches show_vendor.
|
|
2102
|
+
def show_vendor(id)
|
|
2103
|
+
get("/vendors/#{id}")
|
|
2104
|
+
end
|
|
2105
|
+
|
|
2106
|
+
# Fetches show_work_order.
|
|
2107
|
+
def show_work_order(id)
|
|
2108
|
+
get("/work_orders/#{id}")
|
|
2109
|
+
end
|
|
2110
|
+
|
|
2111
|
+
# Lists show_work_order_declined_services resources (paginated).
|
|
2112
|
+
# @return [Wenmar::Paginator]
|
|
2113
|
+
def show_work_order_declined_services(id)
|
|
2114
|
+
get("/work_orders/#{id}/declined_services")
|
|
2115
|
+
end
|
|
2116
|
+
|
|
2117
|
+
# Fetches show_work_order_estimate.
|
|
2118
|
+
def show_work_order_estimate(work_order_id)
|
|
2119
|
+
get("/work_orders/#{work_order_id}/estimate")
|
|
2120
|
+
end
|
|
2121
|
+
|
|
2122
|
+
# Fetches show_work_order_inspection.
|
|
2123
|
+
def show_work_order_inspection(work_order_id)
|
|
2124
|
+
get("/work_orders/#{work_order_id}/inspection")
|
|
2125
|
+
end
|
|
2126
|
+
|
|
2127
|
+
# Fetches show_work_order_parts.
|
|
2128
|
+
def show_work_order_parts(work_order_id)
|
|
2129
|
+
get("/work_orders/#{work_order_id}/parts")
|
|
2130
|
+
end
|
|
2131
|
+
|
|
2132
|
+
# Fetches show_work_order_payments.
|
|
2133
|
+
def show_work_order_payments(work_order_id)
|
|
2134
|
+
get("/work_orders/#{work_order_id}/payments")
|
|
2135
|
+
end
|
|
2136
|
+
|
|
2137
|
+
# Lists show_work_order_service_history resources (paginated).
|
|
2138
|
+
# @return [Wenmar::Paginator]
|
|
2139
|
+
def show_work_order_service_history(id)
|
|
2140
|
+
get("/work_orders/#{id}/service_history")
|
|
2141
|
+
end
|
|
2142
|
+
|
|
2143
|
+
# Fetches show_work_order_wip.
|
|
2144
|
+
def show_work_order_wip(work_order_id)
|
|
2145
|
+
get("/work_orders/#{work_order_id}/wip")
|
|
2146
|
+
end
|
|
2147
|
+
|
|
2148
|
+
# Fetches show_work_orders_signature.
|
|
2149
|
+
def show_work_orders_signature(work_order_id, id)
|
|
2150
|
+
get("/work_orders/#{work_order_id}/signatures/#{id}")
|
|
2151
|
+
end
|
|
2152
|
+
|
|
2153
|
+
# Fetches show_work_orders_sublet_order.
|
|
2154
|
+
def show_work_orders_sublet_order(work_order_id, id)
|
|
2155
|
+
get("/work_orders/#{work_order_id}/sublet_orders/#{id}")
|
|
2156
|
+
end
|
|
2157
|
+
|
|
2158
|
+
# Fetches show_work_orders_tire_storage.
|
|
2159
|
+
def show_work_orders_tire_storage(work_order_id, id)
|
|
2160
|
+
get("/work_orders/#{work_order_id}/tire_storage/#{id}")
|
|
2161
|
+
end
|
|
2162
|
+
|
|
2163
|
+
# Runs start_work_order (POST /work_orders/{id}/start).
|
|
2164
|
+
def start_work_order(id)
|
|
2165
|
+
post("/work_orders/#{id}/start")
|
|
2166
|
+
end
|
|
2167
|
+
|
|
2168
|
+
# Runs transfer_vehicle (POST /vehicles/{id}/transfers).
|
|
2169
|
+
def transfer_vehicle(id, customer_id:, mode:)
|
|
2170
|
+
post("/vehicles/#{id}/transfers", {customer_id: customer_id, mode: mode})
|
|
2171
|
+
end
|
|
2172
|
+
|
|
2173
|
+
# Runs trash_customer (PATCH /customers/{id}/trash).
|
|
2174
|
+
def trash_customer(id)
|
|
2175
|
+
patch("/customers/#{id}/trash")
|
|
2176
|
+
end
|
|
2177
|
+
|
|
2178
|
+
# Runs trash_inspection (PATCH /inspections/{id}/trash).
|
|
2179
|
+
def trash_inspection(id)
|
|
2180
|
+
patch("/inspections/#{id}/trash")
|
|
2181
|
+
end
|
|
2182
|
+
|
|
2183
|
+
# Runs trash_labor_rate (PATCH /labor_rates/{id}/trash).
|
|
2184
|
+
def trash_labor_rate(id)
|
|
2185
|
+
patch("/labor_rates/#{id}/trash")
|
|
2186
|
+
end
|
|
2187
|
+
|
|
2188
|
+
# Runs trash_package (PATCH /packages/{id}/trash).
|
|
2189
|
+
def trash_package(id)
|
|
2190
|
+
patch("/packages/#{id}/trash")
|
|
2191
|
+
end
|
|
2192
|
+
|
|
2193
|
+
# Runs trash_service_category (PATCH /service_categories/{id}/trash).
|
|
2194
|
+
def trash_service_category(id)
|
|
2195
|
+
patch("/service_categories/#{id}/trash")
|
|
2196
|
+
end
|
|
2197
|
+
|
|
2198
|
+
# Runs trash_vehicle (PATCH /vehicles/{id}/trash).
|
|
2199
|
+
def trash_vehicle(id)
|
|
2200
|
+
patch("/vehicles/#{id}/trash")
|
|
2201
|
+
end
|
|
2202
|
+
|
|
2203
|
+
# Runs trash_vendor (PATCH /vendors/{id}/trash).
|
|
2204
|
+
def trash_vendor(id)
|
|
2205
|
+
patch("/vendors/#{id}/trash")
|
|
2206
|
+
end
|
|
2207
|
+
|
|
2208
|
+
# Runs undo_pull_work_order_service_line_item (PATCH /work_orders/{work_order_id}/services/{service_id}/line_items/{id}/undo_pull).
|
|
2209
|
+
def undo_pull_work_order_service_line_item(work_order_id, service_id, id)
|
|
2210
|
+
patch("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}/undo_pull")
|
|
2211
|
+
end
|
|
2212
|
+
|
|
2213
|
+
# Runs undo_return_work_order_service_line_item (PATCH /work_orders/{work_order_id}/services/{service_id}/line_items/{id}/undo_return).
|
|
2214
|
+
def undo_return_work_order_service_line_item(work_order_id, service_id, id)
|
|
2215
|
+
patch("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}/undo_return")
|
|
2216
|
+
end
|
|
2217
|
+
|
|
2218
|
+
# Runs update_account (PATCH /account).
|
|
2219
|
+
def update_account(account:)
|
|
2220
|
+
patch("/account", {account: account})
|
|
2221
|
+
end
|
|
2222
|
+
|
|
2223
|
+
# Runs update_appointment (PATCH /appointments/{id}).
|
|
2224
|
+
def update_appointment(id, appointment:)
|
|
2225
|
+
patch("/appointments/#{id}", {appointment: appointment})
|
|
2226
|
+
end
|
|
2227
|
+
|
|
2228
|
+
# Runs update_calendar_blocked_time (PATCH /calendar/blocked_times/{id}).
|
|
2229
|
+
def update_calendar_blocked_time(id, blocked_time:)
|
|
2230
|
+
patch("/calendar/blocked_times/#{id}", {blocked_time: blocked_time})
|
|
2231
|
+
end
|
|
2232
|
+
|
|
2233
|
+
# Runs update_conversation (PATCH /conversations/{id}).
|
|
2234
|
+
def update_conversation(id, status:)
|
|
2235
|
+
patch("/conversations/#{id}", {status: status})
|
|
2236
|
+
end
|
|
2237
|
+
|
|
2238
|
+
# Runs update_core_tax_rule (PATCH /core_tax_rules/{id}).
|
|
2239
|
+
def update_core_tax_rule(id, core_tax_rule:)
|
|
2240
|
+
patch("/core_tax_rules/#{id}", {core_tax_rule: core_tax_rule})
|
|
2241
|
+
end
|
|
2242
|
+
|
|
2243
|
+
# Runs update_counter_sale (PATCH /counter_sales/{id}).
|
|
2244
|
+
def update_counter_sale(id, counter_sale:)
|
|
2245
|
+
patch("/counter_sales/#{id}", {counter_sale: counter_sale})
|
|
2246
|
+
end
|
|
2247
|
+
|
|
2248
|
+
# Runs update_counter_sales_line_item (PATCH /counter_sales/{counter_sale_id}/line_items/{id}).
|
|
2249
|
+
def update_counter_sales_line_item(counter_sale_id, id, counter_sale_line_item:)
|
|
2250
|
+
patch("/counter_sales/#{counter_sale_id}/line_items/#{id}", {counter_sale_line_item: counter_sale_line_item})
|
|
2251
|
+
end
|
|
2252
|
+
|
|
2253
|
+
# Runs update_counter_sales_reopen (PATCH /counter_sales/{id}/reopen).
|
|
2254
|
+
def update_counter_sales_reopen(id)
|
|
2255
|
+
patch("/counter_sales/#{id}/reopen")
|
|
2256
|
+
end
|
|
2257
|
+
|
|
2258
|
+
# Runs update_current_location (PATCH /current_location).
|
|
2259
|
+
def update_current_location(location:)
|
|
2260
|
+
patch("/current_location", {location: location})
|
|
2261
|
+
end
|
|
2262
|
+
|
|
2263
|
+
# Runs update_customer (PATCH /customers/{id}).
|
|
2264
|
+
def update_customer(id, customer:)
|
|
2265
|
+
patch("/customers/#{id}", {customer: customer})
|
|
2266
|
+
end
|
|
2267
|
+
|
|
2268
|
+
# Runs update_customer_tag (PATCH /customer_tags/{id}).
|
|
2269
|
+
def update_customer_tag(id, name:)
|
|
2270
|
+
patch("/customer_tags/#{id}", {name: name})
|
|
2271
|
+
end
|
|
2272
|
+
|
|
2273
|
+
# Runs update_customer_tags_archive (PATCH /customer_tags/{id}/archive).
|
|
2274
|
+
def update_customer_tags_archive(id)
|
|
2275
|
+
patch("/customer_tags/#{id}/archive")
|
|
2276
|
+
end
|
|
2277
|
+
|
|
2278
|
+
# Runs update_customer_tags_restore (PATCH /customer_tags/{id}/restore).
|
|
2279
|
+
def update_customer_tags_restore(id)
|
|
2280
|
+
patch("/customer_tags/#{id}/restore")
|
|
2281
|
+
end
|
|
2282
|
+
|
|
2283
|
+
# Runs update_customer_tags_trash (PATCH /customer_tags/{id}/trash).
|
|
2284
|
+
def update_customer_tags_trash(id)
|
|
2285
|
+
patch("/customer_tags/#{id}/trash")
|
|
2286
|
+
end
|
|
2287
|
+
|
|
2288
|
+
# Runs update_driver (PATCH /customers/{customer_id}/drivers/{id}).
|
|
2289
|
+
def update_driver(customer_id, id, driver:)
|
|
2290
|
+
patch("/customers/#{customer_id}/drivers/#{id}", {driver: driver})
|
|
2291
|
+
end
|
|
2292
|
+
|
|
2293
|
+
# Runs update_expense (PATCH /expenses/{id}).
|
|
2294
|
+
def update_expense(id, expense:)
|
|
2295
|
+
patch("/expenses/#{id}", {expense: expense})
|
|
2296
|
+
end
|
|
2297
|
+
|
|
2298
|
+
# Runs update_inspection (PATCH /inspections/{id}).
|
|
2299
|
+
def update_inspection(id, inspection:)
|
|
2300
|
+
patch("/inspections/#{id}", {inspection: inspection})
|
|
2301
|
+
end
|
|
2302
|
+
|
|
2303
|
+
# Runs update_inspections_group (PATCH /inspections/{inspection_id}/groups/{id}).
|
|
2304
|
+
def update_inspections_group(inspection_id, id, inspection_group:)
|
|
2305
|
+
patch("/inspections/#{inspection_id}/groups/#{id}", {inspection_group: inspection_group})
|
|
2306
|
+
end
|
|
2307
|
+
|
|
2308
|
+
# Runs update_inspections_item (PATCH /inspections/{inspection_id}/items/{id}).
|
|
2309
|
+
def update_inspections_item(inspection_id, id, inspection_item:)
|
|
2310
|
+
patch("/inspections/#{inspection_id}/items/#{id}", {inspection_item: inspection_item})
|
|
2311
|
+
end
|
|
2312
|
+
|
|
2313
|
+
# Runs update_inspections_preset (PATCH /inspections/{inspection_id}/presets/{id}).
|
|
2314
|
+
def update_inspections_preset(inspection_id, id, inspection_preset:)
|
|
2315
|
+
patch("/inspections/#{inspection_id}/presets/#{id}", {inspection_preset: inspection_preset})
|
|
2316
|
+
end
|
|
2317
|
+
|
|
2318
|
+
# Runs update_inventory_level (PATCH /inventory_levels/{id}).
|
|
2319
|
+
def update_inventory_level(id, inventory_level:)
|
|
2320
|
+
patch("/inventory_levels/#{id}", {inventory_level: inventory_level})
|
|
2321
|
+
end
|
|
2322
|
+
|
|
2323
|
+
# Runs update_labor_matrix (PATCH /labor_matrices/{id}).
|
|
2324
|
+
def update_labor_matrix(id, labor_matrix:)
|
|
2325
|
+
patch("/labor_matrices/#{id}", {labor_matrix: labor_matrix})
|
|
2326
|
+
end
|
|
2327
|
+
|
|
2328
|
+
# Runs update_labor_template (PATCH /labor_templates/{id}).
|
|
2329
|
+
def update_labor_template(id, labor_template:)
|
|
2330
|
+
patch("/labor_templates/#{id}", {labor_template: labor_template})
|
|
2331
|
+
end
|
|
2332
|
+
|
|
2333
|
+
# Runs update_lead_source (PATCH /lead_sources/{id}).
|
|
2334
|
+
def update_lead_source(id, lead_source:)
|
|
2335
|
+
patch("/lead_sources/#{id}", {lead_source: lead_source})
|
|
2336
|
+
end
|
|
2337
|
+
|
|
2338
|
+
# Runs update_location (PATCH /locations/{id}).
|
|
2339
|
+
def update_location(id, location:)
|
|
2340
|
+
patch("/locations/#{id}", {location: location})
|
|
2341
|
+
end
|
|
2342
|
+
|
|
2343
|
+
# Runs update_locations_business_profile (PATCH /locations/{id}/business_profile).
|
|
2344
|
+
def update_locations_business_profile(id, location:)
|
|
2345
|
+
patch("/locations/#{id}/business_profile", {location: location})
|
|
2346
|
+
end
|
|
2347
|
+
|
|
2348
|
+
# Runs update_locations_close_requirements (PATCH /locations/{location_id}/close_requirements).
|
|
2349
|
+
def update_locations_close_requirements(location_id, close_requirements:)
|
|
2350
|
+
patch("/locations/#{location_id}/close_requirements", {close_requirements: close_requirements})
|
|
2351
|
+
end
|
|
2352
|
+
|
|
2353
|
+
# Runs update_locations_documents (PATCH /locations/{location_id}/documents).
|
|
2354
|
+
def update_locations_documents(location_id, location:)
|
|
2355
|
+
patch("/locations/#{location_id}/documents", {location: location})
|
|
2356
|
+
end
|
|
2357
|
+
|
|
2358
|
+
# Runs update_locations_lead_source_requirements (PATCH /locations/{location_id}/lead_source_requirements).
|
|
2359
|
+
def update_locations_lead_source_requirements(location_id, lead_source_requirements:)
|
|
2360
|
+
patch("/locations/#{location_id}/lead_source_requirements", {lead_source_requirements: lead_source_requirements})
|
|
2361
|
+
end
|
|
2362
|
+
|
|
2363
|
+
# Runs update_locations_operations (PATCH /locations/{id}/operations).
|
|
2364
|
+
def update_locations_operations(id, location:)
|
|
2365
|
+
patch("/locations/#{id}/operations", {location: location})
|
|
2366
|
+
end
|
|
2367
|
+
|
|
2368
|
+
# Runs update_locations_reminders (PATCH /locations/{location_id}/reminders).
|
|
2369
|
+
def update_locations_reminders(location_id, location:)
|
|
2370
|
+
patch("/locations/#{location_id}/reminders", {location: location})
|
|
2371
|
+
end
|
|
2372
|
+
|
|
2373
|
+
# Runs update_locations_schedule_config (PATCH /locations/{location_id}/schedule_config).
|
|
2374
|
+
def update_locations_schedule_config(location_id, schedule_config:)
|
|
2375
|
+
patch("/locations/#{location_id}/schedule_config", {schedule_config: schedule_config})
|
|
2376
|
+
end
|
|
2377
|
+
|
|
2378
|
+
# Runs update_me_notifications (PATCH /me/notifications).
|
|
2379
|
+
def update_me_notifications(user:)
|
|
2380
|
+
patch("/me/notifications", {user: user})
|
|
2381
|
+
end
|
|
2382
|
+
|
|
2383
|
+
# Runs update_me_preferences (PATCH /me/preferences).
|
|
2384
|
+
def update_me_preferences(user:)
|
|
2385
|
+
patch("/me/preferences", {user: user})
|
|
2386
|
+
end
|
|
2387
|
+
|
|
2388
|
+
# Runs update_me_profile (PATCH /me/profile).
|
|
2389
|
+
def update_me_profile(user:)
|
|
2390
|
+
patch("/me/profile", {user: user})
|
|
2391
|
+
end
|
|
2392
|
+
|
|
2393
|
+
# Runs update_notification (PATCH /notifications/{id}).
|
|
2394
|
+
def update_notification(id, read:)
|
|
2395
|
+
patch("/notifications/#{id}", {read: read})
|
|
2396
|
+
end
|
|
2397
|
+
|
|
2398
|
+
# Runs update_orders_purchase_order (PATCH /orders/purchase_orders/{id}).
|
|
2399
|
+
def update_orders_purchase_order(id, purchase_order:)
|
|
2400
|
+
patch("/orders/purchase_orders/#{id}", {purchase_order: purchase_order})
|
|
2401
|
+
end
|
|
2402
|
+
|
|
2403
|
+
# Runs update_orders_return_order (PATCH /orders/return_orders/{id}).
|
|
2404
|
+
def update_orders_return_order(id, return_order:)
|
|
2405
|
+
patch("/orders/return_orders/#{id}", {return_order: return_order})
|
|
2406
|
+
end
|
|
2407
|
+
|
|
2408
|
+
# Runs update_orders_sublet_orders_mark_payment_complete (PATCH /orders/sublet_orders/mark_payment_complete).
|
|
2409
|
+
def update_orders_sublet_orders_mark_payment_complete(sublet_order_ids:, payment_method:)
|
|
2410
|
+
patch("/orders/sublet_orders/mark_payment_complete", {sublet_order_ids: sublet_order_ids, payment_method: payment_method})
|
|
2411
|
+
end
|
|
2412
|
+
|
|
2413
|
+
# Runs update_package (PATCH /packages/{id}).
|
|
2414
|
+
def update_package(id)
|
|
2415
|
+
patch("/packages/#{id}")
|
|
2416
|
+
end
|
|
2417
|
+
|
|
2418
|
+
# Runs update_part (PATCH /parts/{id}).
|
|
2419
|
+
def update_part(id, part:)
|
|
2420
|
+
patch("/parts/#{id}", {part: part})
|
|
2421
|
+
end
|
|
2422
|
+
|
|
2423
|
+
# Runs update_parts_matrix (PATCH /parts_matrices/{id}).
|
|
2424
|
+
def update_parts_matrix(id, parts_matrix:)
|
|
2425
|
+
patch("/parts_matrices/#{id}", {parts_matrix: parts_matrix})
|
|
2426
|
+
end
|
|
2427
|
+
|
|
2428
|
+
# Runs update_permission_group (PATCH /users/permission_groups/{id}).
|
|
2429
|
+
def update_permission_group(id, permission_group:)
|
|
2430
|
+
patch("/users/permission_groups/#{id}", {permission_group: permission_group})
|
|
2431
|
+
end
|
|
2432
|
+
|
|
2433
|
+
# Runs update_reports_cash_drawer_sessions_confirm_close (PATCH /reports/cash_drawer_sessions/{id}/confirm_close).
|
|
2434
|
+
def update_reports_cash_drawer_sessions_confirm_close(id, cash_drawer_session:)
|
|
2435
|
+
patch("/reports/cash_drawer_sessions/#{id}/confirm_close", {cash_drawer_session: cash_drawer_session})
|
|
2436
|
+
end
|
|
2437
|
+
|
|
2438
|
+
# Runs update_reports_tax_period (PATCH /reports/tax_periods/{id}).
|
|
2439
|
+
def update_reports_tax_period(id, tax_period:)
|
|
2440
|
+
patch("/reports/tax_periods/#{id}", {tax_period: tax_period})
|
|
2441
|
+
end
|
|
2442
|
+
|
|
2443
|
+
# Runs update_service_category (PATCH /service_categories/{id}).
|
|
2444
|
+
def update_service_category(id, service_category:)
|
|
2445
|
+
patch("/service_categories/#{id}", {service_category: service_category})
|
|
2446
|
+
end
|
|
2447
|
+
|
|
2448
|
+
# Runs update_shop_discount (PATCH /shop_discounts/{id}).
|
|
2449
|
+
def update_shop_discount(id, shop_discount_config:)
|
|
2450
|
+
patch("/shop_discounts/#{id}", {shop_discount_config: shop_discount_config})
|
|
2451
|
+
end
|
|
2452
|
+
|
|
2453
|
+
# Runs update_shop_fee (PATCH /shop_fees/{id}).
|
|
2454
|
+
def update_shop_fee(id, shop_fee_config:)
|
|
2455
|
+
patch("/shop_fees/#{id}", {shop_fee_config: shop_fee_config})
|
|
2456
|
+
end
|
|
2457
|
+
|
|
2458
|
+
# Runs update_sub_status (PATCH /sub_statuses/{id}).
|
|
2459
|
+
def update_sub_status(id, sub_status_type:)
|
|
2460
|
+
patch("/sub_statuses/#{id}", {sub_status_type: sub_status_type})
|
|
2461
|
+
end
|
|
2462
|
+
|
|
2463
|
+
# Runs update_sublet_package (PATCH /sublet_packages/{id}).
|
|
2464
|
+
def update_sublet_package(id, sublet_package:)
|
|
2465
|
+
patch("/sublet_packages/#{id}", {sublet_package: sublet_package})
|
|
2466
|
+
end
|
|
2467
|
+
|
|
2468
|
+
# Runs update_sublet_packages_deactivate (PATCH /sublet_packages/{id}/deactivate).
|
|
2469
|
+
def update_sublet_packages_deactivate(id)
|
|
2470
|
+
patch("/sublet_packages/#{id}/deactivate")
|
|
2471
|
+
end
|
|
2472
|
+
|
|
2473
|
+
# Runs update_tire (PATCH /tires/{id}).
|
|
2474
|
+
def update_tire(id, tire:)
|
|
2475
|
+
patch("/tires/#{id}", {tire: tire})
|
|
2476
|
+
end
|
|
2477
|
+
|
|
2478
|
+
# Runs update_tire_storage_slot (PATCH /tire_storage_slots/{id}).
|
|
2479
|
+
def update_tire_storage_slot(id, tire_storage_slot:)
|
|
2480
|
+
patch("/tire_storage_slots/#{id}", {tire_storage_slot: tire_storage_slot})
|
|
2481
|
+
end
|
|
2482
|
+
|
|
2483
|
+
# Runs update_user (PATCH /users/{id}).
|
|
2484
|
+
def update_user(id, user:)
|
|
2485
|
+
patch("/users/#{id}", {user: user})
|
|
2486
|
+
end
|
|
2487
|
+
|
|
2488
|
+
# Runs update_vehicle (PATCH /vehicles/{id}).
|
|
2489
|
+
def update_vehicle(id, vehicle:)
|
|
2490
|
+
patch("/vehicles/#{id}", {vehicle: vehicle})
|
|
2491
|
+
end
|
|
2492
|
+
|
|
2493
|
+
# Runs update_vendor (PATCH /vendors/{id}).
|
|
2494
|
+
def update_vendor(id, vendor:)
|
|
2495
|
+
patch("/vendors/#{id}", {vendor: vendor})
|
|
2496
|
+
end
|
|
2497
|
+
|
|
2498
|
+
# Runs update_work_order (PATCH /work_orders/{id}).
|
|
2499
|
+
def update_work_order(id, work_order:)
|
|
2500
|
+
patch("/work_orders/#{id}", {work_order: work_order})
|
|
2501
|
+
end
|
|
2502
|
+
|
|
2503
|
+
# Runs update_work_order_tag (PATCH /work_order_tags/{id}).
|
|
2504
|
+
def update_work_order_tag(id, name:)
|
|
2505
|
+
patch("/work_order_tags/#{id}", {name: name})
|
|
2506
|
+
end
|
|
2507
|
+
|
|
2508
|
+
# Runs update_work_order_tags_archive (PATCH /work_order_tags/{id}/archive).
|
|
2509
|
+
def update_work_order_tags_archive(id)
|
|
2510
|
+
patch("/work_order_tags/#{id}/archive")
|
|
2511
|
+
end
|
|
2512
|
+
|
|
2513
|
+
# Runs update_work_orders_concern (PATCH /work_orders/{work_order_id}/concerns/{id}).
|
|
2514
|
+
def update_work_orders_concern(work_order_id, id, concern:)
|
|
2515
|
+
patch("/work_orders/#{work_order_id}/concerns/#{id}", {concern: concern})
|
|
2516
|
+
end
|
|
2517
|
+
|
|
2518
|
+
# Runs update_work_orders_courtesy_car_assignment (PATCH /work_orders/{id}/courtesy_car_assignment).
|
|
2519
|
+
def update_work_orders_courtesy_car_assignment(id, action_type:)
|
|
2520
|
+
patch("/work_orders/#{id}/courtesy_car_assignment", {action_type: action_type})
|
|
2521
|
+
end
|
|
2522
|
+
|
|
2523
|
+
# Runs update_work_orders_purchase_order (PATCH /work_orders/{work_order_id}/purchase_orders/{id}).
|
|
2524
|
+
def update_work_orders_purchase_order(work_order_id, id, purchase_order:)
|
|
2525
|
+
patch("/work_orders/#{work_order_id}/purchase_orders/#{id}", {purchase_order: purchase_order})
|
|
2526
|
+
end
|
|
2527
|
+
|
|
2528
|
+
# Runs update_work_orders_service (PATCH /work_orders/{work_order_id}/services/{id}).
|
|
2529
|
+
def update_work_orders_service(work_order_id, id, work_order_service:)
|
|
2530
|
+
patch("/work_orders/#{work_order_id}/services/#{id}", {work_order_service: work_order_service})
|
|
2531
|
+
end
|
|
2532
|
+
|
|
2533
|
+
# Runs update_work_orders_services_adjust_time (PATCH /work_orders/{work_order_id}/services/{id}/adjust_time).
|
|
2534
|
+
def update_work_orders_services_adjust_time(work_order_id, id, hours:, minutes:)
|
|
2535
|
+
patch("/work_orders/#{work_order_id}/services/#{id}/adjust_time", {hours: hours, minutes: minutes})
|
|
2536
|
+
end
|
|
2537
|
+
|
|
2538
|
+
# Runs update_work_orders_services_line_item (PATCH /work_orders/{work_order_id}/services/{service_id}/line_items/{id}).
|
|
2539
|
+
def update_work_orders_services_line_item(work_order_id, service_id, id, work_order_line_item:)
|
|
2540
|
+
patch("/work_orders/#{work_order_id}/services/#{service_id}/line_items/#{id}", {work_order_line_item: work_order_line_item})
|
|
2541
|
+
end
|
|
2542
|
+
|
|
2543
|
+
# Runs update_work_orders_services_pause (PATCH /work_orders/{work_order_id}/services/{id}/pause).
|
|
2544
|
+
def update_work_orders_services_pause(work_order_id, id)
|
|
2545
|
+
patch("/work_orders/#{work_order_id}/services/#{id}/pause")
|
|
2546
|
+
end
|
|
2547
|
+
|
|
2548
|
+
# Runs update_work_orders_services_publish (PATCH /work_orders/{work_order_id}/services/{id}/publish).
|
|
2549
|
+
def update_work_orders_services_publish(work_order_id, id)
|
|
2550
|
+
patch("/work_orders/#{work_order_id}/services/#{id}/publish")
|
|
2551
|
+
end
|
|
2552
|
+
|
|
2553
|
+
# Runs update_work_orders_services_reorder (PATCH /work_orders/{work_order_id}/services/reorder).
|
|
2554
|
+
def update_work_orders_services_reorder(work_order_id, service_ids:)
|
|
2555
|
+
patch("/work_orders/#{work_order_id}/services/reorder", {service_ids: service_ids})
|
|
2556
|
+
end
|
|
2557
|
+
|
|
2558
|
+
# Runs update_work_orders_services_revive (PATCH /work_orders/{work_order_id}/services/{id}/revive).
|
|
2559
|
+
def update_work_orders_services_revive(work_order_id, id)
|
|
2560
|
+
patch("/work_orders/#{work_order_id}/services/#{id}/revive")
|
|
2561
|
+
end
|
|
2562
|
+
|
|
2563
|
+
# Runs update_work_orders_services_sublet_order (PATCH /work_orders/{work_order_id}/services/{service_id}/sublet_orders/{id}).
|
|
2564
|
+
def update_work_orders_services_sublet_order(work_order_id, service_id, id, sublet_order:)
|
|
2565
|
+
patch("/work_orders/#{work_order_id}/services/#{service_id}/sublet_orders/#{id}", {sublet_order: sublet_order})
|
|
2566
|
+
end
|
|
2567
|
+
|
|
2568
|
+
# Runs update_work_orders_services_toggle_labor_completion (PATCH /work_orders/{work_order_id}/services/{id}/toggle_labor_completion).
|
|
2569
|
+
def update_work_orders_services_toggle_labor_completion(work_order_id, id, line_item_id:)
|
|
2570
|
+
patch("/work_orders/#{work_order_id}/services/#{id}/toggle_labor_completion", {line_item_id: line_item_id})
|
|
2571
|
+
end
|
|
2572
|
+
|
|
2573
|
+
# Runs update_work_orders_services_update_category (PATCH /work_orders/{work_order_id}/services/{id}/update_category).
|
|
2574
|
+
def update_work_orders_services_update_category(work_order_id, id, category_id:)
|
|
2575
|
+
patch("/work_orders/#{work_order_id}/services/#{id}/update_category", {category_id: category_id})
|
|
2576
|
+
end
|
|
2577
|
+
|
|
2578
|
+
# Runs update_work_orders_tire_storage (PATCH /work_orders/{work_order_id}/tire_storage/{id}).
|
|
2579
|
+
def update_work_orders_tire_storage(work_order_id, id, tire_storage_slot:)
|
|
2580
|
+
patch("/work_orders/#{work_order_id}/tire_storage/#{id}", {tire_storage_slot: tire_storage_slot})
|
|
2581
|
+
end
|
|
2582
|
+
|
|
2583
|
+
# Runs void_work_order (POST /work_orders/{id}/void).
|
|
2584
|
+
def void_work_order(id, closure_reason:)
|
|
2585
|
+
post("/work_orders/#{id}/void", {closure_reason: closure_reason})
|
|
2586
|
+
end
|
|
2587
|
+
end
|
|
2588
|
+
end
|