style: format common setting

This commit is contained in:
hu.sima
2023-08-10 15:30:01 +08:00
parent 927ed393d3
commit 790204ea28
8 changed files with 83 additions and 116 deletions

View File

@@ -100,7 +100,7 @@ class DepartmentSortView(APIView):
def put(self):
"""
修改部门排序,只能在同一个上级内排序
only can sort in the same parent
"""
department_list = request.json.get('department_list', None)
if department_list is None:

View File

@@ -150,12 +150,10 @@ class EmployeeViewExportExcel(APIView):
url_prefix = (f'{prefix}/export_all',)
def get(self):
# 规定了静态文件的存储位置
excel_filename = 'all_employee_info.xlsx'
excel_path = current_app.config['UPLOAD_DIRECTORY_FULL']
excel_path_with_filename = os.path.join(excel_path, excel_filename)
# 根据parameter查表自连接通过上级id获取上级名字列
block_status = int(request.args.get('block_status', -1))
data_list = EmployeeCRUD.get_export_employee_list(block_status)