{ "summary": [ { "name": "script_engine", "title": "逻辑脚本表", "primary": ["id"], "catelog": "entity" } ], "fields": [ {"name": "id", "title": "主键ID", "type": "str", "length": 32, "nullable": "no"}, {"name": "world_id", "title": "所属世界", "type": "str", "length": 32, "nullable": "no"}, {"name": "scene_id", "title": "所属场景", "type": "str", "length": 32, "nullable": "yes"}, {"name": "entity_id", "title": "绑定实体", "type": "str", "length": 32, "nullable": "yes"}, {"name": "name", "title": "脚本名称", "type": "str", "length": 255, "nullable": "no"}, {"name": "code", "title": "脚本编码", "type": "str", "length": 64, "nullable": "no"}, {"name": "script_type", "title": "脚本类型", "type": "str", "length": 16, "nullable": "no", "default": "0"}, {"name": "trigger_event", "title": "触发事件", "type": "str", "length": 64, "nullable": "yes"}, {"name": "content", "title": "脚本内容", "type": "text", "nullable": "no"}, {"name": "status", "title": "状态", "type": "str", "length": 16, "nullable": "no", "default": "0"}, {"name": "created_at", "title": "创建时间", "type": "timestamp", "nullable": "no"}, {"name": "updated_at", "title": "更新时间", "type": "timestamp", "nullable": "yes"} ], "indexes": [ {"name": "idx_script_code", "idxtype": "unique", "idxfields": ["code"]}, {"name": "idx_script_world", "idxtype": "index", "idxfields": ["world_id"]}, {"name": "idx_script_entity", "idxtype": "index", "idxfields": ["entity_id"]} ], "codes": [ {"field": "world_id", "table": "world", "valuefield": "id", "textfield": "name"}, {"field": "scene_id", "table": "scene", "valuefield": "id", "textfield": "name"}, {"field": "entity_id", "table": "entity", "valuefield": "id", "textfield": "name"}, {"field": "script_type", "table": "appcodes_kv", "valuefield": "k", "textfield": "v", "cond": "parentid='script_type'"}, {"field": "status", "table": "appcodes_kv", "valuefield": "k", "textfield": "v", "cond": "parentid='script_status'"} ] }