12345678910111213141516171819202122 |
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- """
- demeter database
- name:device_camera.py
- author:rabin
- """
- from __load__ import *
- class Device_camera(Model):
- __table__ = 'device_camera'
- __comment__ = '摄像机管理'
- id = Fields(type='uuid', primaryKey=True, comment='摄像机ID', uuid='farm_id')
- farm_id = Fields(type='int', default='setting.farm', comment='园区ID', match='not')
- name = Fields(type='varchar(50)', comment='摄像机名')
- hardware_id = Fields(type='bigint', comment='硬件id')
- gateway_id = Fields(type='uuid', comment='网关id')
- type_id = Fields(type='int', comment='摄像机类型')
- pic = Fields(type='varchar(255)', comment='摄像机当前照片')
- status = Fields(type='boolean', default='False', comment='摄像机连接状态')
- state = Fields(type='boolean', default='True', comment='数据存在状态')
- cdate = Fields(type='int', default='time', comment='创建时间')
|