docs: establish marqdo-lint architecture and examples

This commit is contained in:
cflmy committed 2026-11-23 16:47:53 +08:00
1 parent 326c9bb119
commit 68b14db095
19 files changed
+1338

No files matched your search

+32
View File
@@ -0,0 +1,32 @@
# @knowledge 库存示例
## @exec 检查库存并累计可用量
只在仓库启用时统计库存;对每个未统计条目进行累计。
位置从零下标开始,返回最小计量单位的总量。
`params(仓库启用: Bool, 数量列表: List)`
**总量 = 0**
**位置 = 0**
1. `if 仓库启用`:仅在启用状态下统计库存。
- `while 位置 < 长度(数量列表)`:按位置依次统计,到达列表末尾时终止。
**总量 = 总量 + 数量列表[位置]**
**位置 = 位置 + 1**
`end`
2. `else`:仓库未启用时,总量保持为零。
不执行任何库存统计。
`end`
返回累计总量;本函数不会修改库存来源。
*return 总量*