diff --git a/applications/view/system/dept.py b/applications/view/system/dept.py index 91941d8..20e4a09 100644 --- a/applications/view/system/dept.py +++ b/applications/view/system/dept.py @@ -108,7 +108,8 @@ def dis_enable(): @authorize("system:dept:edit", log=True) def update(): json = request.get_json(force=True) - id = json.get("deptId"), + #id = json.get("deptId"), + id = str_escape(json.get("deptId")) data = { "dept_name": validate.str_escape(json.get("deptName")), "sort": validate.str_escape(json.get("sort")), diff --git a/docs/install.md b/docs/install.md index a617ac5..c4b2002 100644 --- a/docs/install.md +++ b/docs/install.md @@ -44,7 +44,7 @@ source ./test_env/bin/activate ```shell # 使用 pip 安装必要模块(对于 master 分支) -pip install -r requirement\requirement.txt +pip install -r requirements.txt # 使用 pip 安装必要模块(对于 mini 分支) pip install -r requirement.txt @@ -76,10 +76,10 @@ flask admin init #### 运行项目 ```shell -# linux +# windows run.bat -# windows +# linux ./run.sh ``` diff --git a/templates/system/dept/main.html b/templates/system/dept/main.html index 5f4fec7..2e66065 100644 --- a/templates/system/dept/main.html +++ b/templates/system/dept/main.html @@ -199,7 +199,8 @@ title: '修改', shade: 0.1, area: ['450px', '500px'], - content: MODULE_PATH + 'edit?deptId=' + obj.data['deptId'] + //content: MODULE_PATH + 'edit?deptId=' + obj.data['deptId'] + content: MODULE_PATH + 'edit?deptId=' + obj.data['id'] }) } diff --git a/templates/system/power/add.html b/templates/system/power/add.html index be4c1d8..9460fb3 100644 --- a/templates/system/power/add.html +++ b/templates/system/power/add.html @@ -63,7 +63,7 @@
-
diff --git a/templates/system/power/edit.html b/templates/system/power/edit.html index ad5db4c..aa7c695 100644 --- a/templates/system/power/edit.html +++ b/templates/system/power/edit.html @@ -75,7 +75,7 @@
-
diff --git a/templates/system/user/edit.html b/templates/system/user/edit.html index 32f8542..8fbea3a 100644 --- a/templates/system/user/edit.html +++ b/templates/system/user/edit.html @@ -71,48 +71,48 @@ {% include 'system/common/footer.html' %} \ No newline at end of file diff --git a/templates/system/user/profile.html b/templates/system/user/profile.html index 62550bf..9480420 100644 --- a/templates/system/user/profile.html +++ b/templates/system/user/profile.html @@ -65,7 +65,7 @@ formData.append('fileToken', timeStamp) $.ajax({ method: 'post', - url: '/admin/file/upload', //用于文件上传的服务器端请求地址 + url: '/system/file/upload', //用于文件上传的服务器端请求地址 data: formData, processData: false, contentType: false,