Format pump schema

This commit is contained in:
WQY\qiong
2022-10-21 22:11:48 +08:00
parent 30e6813c0c
commit 9254427915

View File

@@ -3,13 +3,13 @@ from .s0_base import *
def get_pump_schema(name: str) -> dict[str, dict[str, Any]]:
return { 'id' : {'type': 'str' , 'optional': False , 'readonly': True },
'node1' : {'type': 'str' , 'optional': False , 'readonly': False},
'node2' : {'type': 'str' , 'optional': False , 'readonly': False},
'power' : {'type': 'float' , 'optional': True , 'readonly': False},
'head' : {'type': 'str' , 'optional': True , 'readonly': False},
'speed' : {'type': 'float' , 'optional': True , 'readonly': False},
'pattern' : {'type': 'str' , 'optional': True , 'readonly': False} }
return { 'id' : {'type': 'str' , 'optional': False , 'readonly': True },
'node1' : {'type': 'str' , 'optional': False , 'readonly': False},
'node2' : {'type': 'str' , 'optional': False , 'readonly': False},
'power' : {'type': 'float' , 'optional': True , 'readonly': False},
'head' : {'type': 'str' , 'optional': True , 'readonly': False},
'speed' : {'type': 'float' , 'optional': True , 'readonly': False},
'pattern' : {'type': 'str' , 'optional': True , 'readonly': False} }
def get_pump(name: str, id: str) -> dict[str, Any]: