feat: 初步添加光芯的批次分析函数
This commit is contained in:
parent
dae8d50d2c
commit
cdb4e65159
|
@ -0,0 +1,7 @@
|
|||
def main(batch: str):
|
||||
return None, None
|
||||
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
pass
|
|
@ -23,8 +23,9 @@ def get_alldata_with_batch_and_store(batch: str, need_update_time=True):
|
|||
last_time, data = get_alldata_with_batch(batch)
|
||||
elif BASE_PROJECT_CODE == "gxerp":
|
||||
need_update = True
|
||||
last_time, data = get_alldata_with_batch_gx(batch)
|
||||
|
||||
from apps.wpm.scripts.batch_gxerp import main
|
||||
last_time, data = main(batch)
|
||||
|
||||
if need_update and last_time and data:
|
||||
bobj, _ = BatchSt.objects.get_or_create(batch=batch, defaults={
|
||||
"last_time": last_time
|
||||
|
@ -34,11 +35,6 @@ def get_alldata_with_batch_and_store(batch: str, need_update_time=True):
|
|||
bobj.data = json.loads(json.dumps(data, cls=MyJSONEncoder))
|
||||
bobj.save()
|
||||
|
||||
def get_alldata_with_batch_gx(batch: str):
|
||||
"""
|
||||
光芯获取batch的统计数据
|
||||
"""
|
||||
return None, None
|
||||
|
||||
def get_alldata_with_batch(batch: str):
|
||||
"""
|
||||
|
|
Loading…
Reference in New Issue