[关闭]
@Wahson 2017-07-09T23:13:47.000000Z 字数 1322 阅读 936

梁华生--工作周报(2017-07-09)

周报


本周回顾

  • 前端
    • 元数据应用--员工管理模块开发完成
    • 使用react重构 <h2-grid /><h2-widget />
    • grid layout应用到<h2-domain-query /><h2-form />
    • 元数据下沉idl初步设计

下周计划

  • 元数据idl设计
  • 元数据数据库定义
  • 元数据查询接口设计与开发
  • 元数据组件文档整理

idl表达元数据初稿:

  1. DemoService {
  2. struct QueryRequest {
  3. @props( ref = "metadb.staffs.field1" ) int field1,
  4. @props( ref = "metadb.staffs.field2" ) optional string field2,
  5. }
  6. struct QueryResponse {
  7. @props( ref = "metadb.staffs.field3", editable=false ) int field3,
  8. @props( ref = "metadb.staffs.field4", editable=false ) optional string field4,
  9. }
  10. @query
  11. QueryResponse query(request: QueryRequest, pageRequest: PageRequest)
  12. @action( id="demo-delete", scope="field", name="删除", operType=1, modelSrc="" )
  13. void delete(id: Int)
  14. @action( id="demo-add", scope="domain", name="添加", operType=2 )
  15. void add(request: DemoRequest)
  16. }
  17. // 说明
  18. 1. scope: action的范围,domain | field
  19. 2. @propsref指定字段配置所在的数据库位置,可以配置添加或者覆盖属性值。
  20. 3. @action:自动根据接口入参和出参,添加formMetaformMeta中的fields定义来源于入参出参中实体的field定义。
  21. // ----------
  22. // 元数据查询接口定义
  23. MetadataService {
  24. DomainMeta getDomainMeta(domainName:string,version:String)
  25. FieldMeta getFieldMeta(domainName:String,fieldName:String)
  26. ActionMeta getActionMeta(domainName:String, actionName:String)
  27. FormMeta getFormMeta(domainName:String,actionName: String)
  28. }
  29. // 考虑: 一个domain有多个service,如何处理 ???

员工管理代码地址:http://git.oa.isuwang.com/isuwang-com/kuaisuadmin/tree/metadata/src/main/webapp/metadata
isuwang-meta地址:http://git.oa.isuwang.com/lianghuasheng/isuwang-meta

添加新批注
在作者公开此批注前,只有你和作者可见。
回复批注