Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
data_report
/
data-report
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit dec4f00d
authored
Sep 22, 2026
by
周立明
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
全国经营总产值不传bizs
1 parent
50e5bf4d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
4 deletions
data-process/build_store_effect_board.py
data-process/indicator_client.py
data-process/build_store_effect_board.py
View file @
dec4f00
...
...
@@ -1175,7 +1175,7 @@ FIELD_NOTES = [
(
'全国经营门店总数'
,
'来源于saas+门店预算分解表sheet1+sheet2,所有门店明细按门店名称去重计算总数'
),
(
'经管预算目标'
,
'来源于saas+门店预算分解表sheet1+sheet2,所有明细的"预估产值(预算目标)"之和'
),
(
'全国经营总预算'
,
'来源于saas+门店预算分解表sheet1+sheet2,所有明细的"预估产值(纠偏)"之和'
),
(
'全国经营总产值'
,
'指标系统 A0018(含二手车业务),
不传bizs全量求和、不做门店匹配;2026-08=97,681,597.64
'
),
(
'全国经营总产值'
,
'指标系统 A0018(含二手车业务),
biz=None 不传bizs查全量、不做门店匹配;2026-08 全量(不传bizs)实测=98,255,112.51(注:97,681,597.64 为历史快照,数据随业务回写变动)
'
),
(
'全国直营门店总数'
,
'来源于saas+门店预算分解表sheet1+sheet2,所有驻店类型=直营 的门店明细去重计算总数'
),
(
'全国直营总人数'
,
'人力成本表:AF列检核=TRUE、过滤岗位=离职,按工号去重【人力表加密无法读取,当前0】'
),
(
'全国直营营销人数'
,
'人力成本表:检核=TRUE、岗位=门店销售,按工号去重【人力表加密无法读取,当前0】'
),
...
...
data-process/indicator_client.py
View file @
dec4f00
...
...
@@ -63,7 +63,8 @@ class IndicatorClient:
- end_date: str 'YYYY-MM-DD'
- biz: int 单值(1=延保 2=轻改 3=权益) 或 list/tuple(如 [1,3] 多业务线);
多值会序列化为逗号字符串 bizs="1,3"(与 itemCodes 风格一致);
单值仍走原 "biz" 键,向后兼容现有调用方。
单值序列化为 bizs="N"(API 仅认 bizs 键,不再有 "biz" 单数形式);
None 表示不限定业务线 → 不传 bizs 键、查全量(A0018 全国经营总产值用此)。
- item_codes: list[str] 指标编码列表,如 ['A036', 'A075']
- rate_codes: set[str] 率类指标编码,API 返回小数会 *100;None 则用 RATE_CODES 默认
...
...
@@ -83,8 +84,10 @@ class IndicatorClient:
"exts"
:
"merchantIds"
,
"itemCodes"
:
","
.
join
(
item_codes
),
}
# 统一用 bizs 参数(API 不支持 biz 单数形式),单值也序列化为逗号字符串
if
isinstance
(
biz
,
(
list
,
tuple
,
set
)):
# biz=None 表示查全量:不要传 bizs 键,否则 API 把 "None" 当无效业务线过滤返回空
if
biz
is
None
:
pass
# 不传 bizs → 返回全业务线全量
elif
isinstance
(
biz
,
(
list
,
tuple
,
set
)):
payload
[
"bizs"
]
=
","
.
join
(
str
(
b
)
for
b
in
biz
)
else
:
payload
[
"bizs"
]
=
str
(
biz
)
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment