ffl_core.api.store_overview¶
Source: apps/ffl_core/ffl_core/api/store_overview.py · 1 endpoint(s)
Generated by
make api-docs— do not edit by hand.
get_overview¶
POST /api/method/ffl_core.api.store_overview.get_overview
Auth (derived from code): Roles: System Manager / Sales User / Sales Manager / Stock User / Stock Manager / Accounts User
Everything the Gun Shop Overview page shows, one block per key.
A block this user may not see is null (the page leaves it out); a block that failed is
{"error": text} and an Error Log, and the others still load. Counts and report rows are
shared by every user for up to a minute.
| arg | type | required | default | description |
|---|---|---|---|---|
with_records |
— | no | 1 |
0 leaves out All records (the page asks for it once, not on every refresh). |
fresh_ad |
— | no | 0 |
1 recounts the A&D block now instead of reading the minute-old shared count (the block's refresh button). |
Returns: {today, now, sales: {days: [{date, net_sales, transactions, ticket_net}] (8 days, oldest first, today last; transactions and ticket_net leave returns out), report}, open_4473: {rows: [{invoice, customer_name, guns: [{serial, item_name}], nics_status, form_4473_status, started}], records, can_open}, pickups: {total, rows: [{customer, item_name, serial, source_name, days_in_store}]}, stock: {total, consignment, transfers}, drawer: {opening, expected, cash_in, cash_out, open_shifts, counted}, ad: {off} or {off, acquired, disposed, retrying, needs_person, synced_at, can_review, records?: [{doctype, name, error, terminal}]}, arriving: {total, orders: [{name, distributor, status, outstanding, received, expected}]}, records (only with with_records): [{title, items: [{label, link_type, link_to, is_query_report?, ref_doctype?}]}], links: {pos, new_order, receive, add_customer, cash_drawer, pickups}}.
apps/ffl_core/ffl_core/api/store_overview.py:431