demo_facility_level0.py 472 Bytes
Newer Older
Wei Shoulin's avatar
demo  
Wei Shoulin committed
1
2
3
4
5
from csst_dfs_api.facility.level0 import Level0DataApi

api = Level0DataApi()

# find
Wei Shoulin's avatar
Wei Shoulin committed
6
recs = api.find(obs_id = '17', obs_type = 'sci', limit = 0, prc_status = -1)
Wei Shoulin's avatar
demo  
Wei Shoulin committed
7
8
9
print('find:', recs)

# get
Wei Shoulin's avatar
Wei Shoulin committed
10
rec = api.get(level0_id = '100')
Wei Shoulin's avatar
demo  
Wei Shoulin committed
11
12
13
print('get:', rec)

# update_proc_status
Wei Shoulin's avatar
Wei Shoulin committed
14
rec = api.update_proc_status(level0_id = '100', status = 6)
Wei Shoulin's avatar
demo  
Wei Shoulin committed
15
16
17
print('update_proc_status:', rec)

# update_qc0_status
Wei Shoulin's avatar
Wei Shoulin committed
18
rec = api.update_qc0_status(level0_id = '100', status = 7)
Wei Shoulin's avatar
demo  
Wei Shoulin committed
19
print('update_qc0_status:', rec)