ttpos-bom

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

ttpos-bom

ttpos-bom

先读
ttpos-shared
。本版不提供 BOM 导出和导入模板下载,被问到直接说没有。
First read
ttpos-shared
. This version does not provide BOM export or import template downloads; if asked, say they are unavailable.

能回答的问题

Questions This Can Answer

问题命令
某道菜的配方
ttpos bom module list --keyword <名称>
哪些商品配了 BOM
ttpos bom product list
一张成本卡
ttpos bom card get <uuid>
QuestionCommand
Recipe for a dish
ttpos bom module list --keyword <name>
Which products have a BOM
ttpos bom product list
A cost card
ttpos bom card get <uuid>

选哪条命令

Which Command to Use

想查命令
配方模块列表(全量,无分页)
ttpos bom module list --keyword <关键字>
配方模块详情
ttpos bom module get <uuid>
单品是否配了 BOM
ttpos bom product list
套餐、加料是否配了 BOM
ttpos bom product list --tab 1
(套餐)、
--tab 2
(加料)
单品、加料、套餐组项的行级 BOM
ttpos bom product get --owner-type 2|3|4 --owner-uuid <uuid>
套餐 BOM 汇总
ttpos bom combo get <uuid>
订单 BOM(整个商户一份)
ttpos bom order get
规格商品成本卡
ttpos bom card get <uuid>
查询上限:
bom product list
每页最多 100 条。
What You Want to Look UpCommand
Recipe module list (complete, no pagination)
ttpos bom module list --keyword <keyword>
Recipe module details
ttpos bom module get <uuid>
Whether an individual product has a BOM
ttpos bom product list
Whether a combo or add-on has a BOM
ttpos bom product list --tab 1
(combos),
--tab 2
(add-ons)
Line-level BOM for an individual product, add-on, or combo group item
ttpos bom product get --owner-type 2|3|4 --owner-uuid <uuid>
Combo BOM summary
ttpos bom combo get <uuid>
Order BOM (one per merchant)
ttpos bom order get
Spec-product cost card
ttpos bom card get <uuid>
Query limit:
bom product list
returns at most 100 records per page.

参数陷阱

Parameter Pitfalls

  • bom product list
    不传
    --tab
    只返回单品。
    查套餐、加料时不传不会报错,只会得到无关结果。
  • bom module list
    没有
    --page
    /
    --size
    。
  • bom product get
    的
    --owner-type
    (
    2
    规格,
    3
    加料,
    4
    套餐组项)和
    --owner-uuid
    都必填,缺了 exit 2。取值不合法时由服务端报错,是 exit 1。
  • 五个
    get
    只输出 JSON。
  • bom product list
    only returns individual products when
    --tab
    is omitted.
    When looking up combos or add-ons, omitting this option does not produce an error; it only returns unrelated results.
  • bom module list
    does not support
    --page
    /
    --size
    .
  • Both
    --owner-type
    (
    2
    specification,
    3
    add-on,
    4
    combo group item) and
    --owner-uuid
    are required for
    bom product get
    ; omitting either results in exit 2. Invalid values are reported by the server and result in exit 1.
  • The five
    get
    commands only output JSON.

读输出

Reading the Output

  • 本域的布尔字段都是原生
    true/false
    :
    has_nested
    is_editable
    headquarter
    configured
    all_configured
    。这只适用于本域。
  • bom module list
    的名称读
    locale_name
    ,
    name
    是未解析的原文。表格「主行数」=
    material_count
    +
    module_count
    ,不含
    alternative_count
    (备选行)和
    ref_count
    (被多少上层引用)。
  • bom product list
    的记录 id 是
    owner_uuid
    ,是否配置看
    configured
    。
  • bom order get
    :
    owner_type
    、
    owner_uuid
    恒为 0,没有业务含义,不要使用。
    有效数据在
    shared_lines
    dine_in_lines
    takeaway_lines
    leaf_preview
    。
  • bom combo get
    :
    items[]
    每项同时有
    product_uuid
    和
    owner_uuid
    ,含义不同,不要混用。
  • bom card get
    :
    materials[]
    里 material、unit、unit_list 的 uuid 都是 number,不要转 double。
退出码见
ttpos help exit-codes
。
  • Boolean fields in this domain use native
    true/false
    :
    has_nested
    is_editable
    headquarter
    configured
    all_configured
    . This applies only to this domain.
  • For
    bom module list
    , read the name from
    locale_name
    ;
    name
    contains unresolved source text. The table's "Main row count" equals
    material_count
    +
    module_count
    and excludes
    alternative_count
    (alternative rows) and
    ref_count
    (the number of parent references).
  • The record ID in
    bom product list
    is
    owner_uuid
    ; use
    configured
    to determine whether it is configured.
  • bom order get
    :
    owner_type
    and
    owner_uuid
    are always 0 and have no business meaning, so do not use them.
    Valid data is in
    shared_lines
    dine_in_lines
    takeaway_lines
    leaf_preview
    .
  • bom combo get
    : each item in
    items[]
    has both
    product_uuid
    and
    owner_uuid
    . They have different meanings and must not be used interchangeably.
  • bom card get
    : the UUIDs for material, unit, and unit_list in
    materials[]
    are numbers; do not convert them to double.
See
ttpos help exit-codes
for exit codes.