Code Monkey home page Code Monkey logo

Comments (2)

an-tao avatar an-tao commented on May 18, 2024

@bigfish3000 一个Model对象只代表一行数据,你可以通过接口获得或者修改它的内容(本地的),model源文件不应被修改,相关数据库操作由Mapper对象或者DbClient对象完成,至于业务相关的逻辑,应该由专门的业务类实现,继承不是个好主意,毕竟耦合比较深,我认为组合更好,用model对象构造你的业务类对象并被后者持有。
你说的数据操作模型,我不太清楚指什么,如果是业务无关的通用接口,可以整合到model或者Mapper里的,你可以提Issue,由Drogon来实现。

from drogon.

bigfish3000 avatar bigfish3000 commented on May 18, 2024

不错,不错,我继续研究。。。文档,文档。。。

from drogon.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.