from django.utils.decorators import method_decorator 1、在post 或 get方法 添加 @method_decorator(装饰器) 2、给类添加装饰器 @method_decorator(装饰器, name="") 这里的name等于get 或 post
Django CBV方法装饰器
猜你喜欢
转载自www.cnblogs.com/wt7018/p/11284238.html
今日推荐
周排行