How to enforce account based separation in Django

前端 未结 5 779
一向
一向 2020-12-30 18:16

I have a Django app which has a single-account model. We are converting this to be multi-account, so almost every model will have a ForeignKey(Account).

5条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-30 18:38

    Is there some huge reason why you can't just write a function that automatically inserts the session account into the query and takes all your other parameters as arguments?

提交回复
热议问题