wip(semantic):数据模型语义化

This commit is contained in:
zhengxinonly
2021-09-06 02:17:36 +08:00
parent 27f5d78c35
commit 00053da117
31 changed files with 189 additions and 183 deletions
+2 -2
View File
@@ -1,7 +1,7 @@
from flask import render_template, request
from applications.common.utils.rights import authorize
from applications.models import Dept
from applications.models import CompanyDepartment
from applications.view import index_bp
@@ -21,5 +21,5 @@ def add():
@authorize("admin:dept:edit", log=True)
def edit():
dept_id = request.args.get("deptId", type=int)
dept = Dept.query.get(dept_id)
dept = CompanyDepartment.query.get(dept_id)
return render_template('department/edit.html', dept=dept)