12345678910111213141516171819 |
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- """
- demeter database
- name:device_set.py
- author:rabin
- """
- from __load__ import *
- class Device_set(Base):
- __table__ = 'device_set'
- __comment__ = '设备设置'
- id = Fields(type='uuid', primaryKey=True, comment='设备设置ID', uuid='farm_id')
- farm_id = Fields(type='int', default='setting.farm', comment='园区ID', match='not')
- device_id = Fields(type='int', comment='设备id')
- max = Fields(type='smallint', comment='最大上限')
- min = Fields(type='smallint', comment='最小下限')
- state = Fields(type='boolean', default='True', comment='数据存在状态')
- cdate = Fields(type='int', default='time', comment='创建时间')
|