From 755d743b164aadae8120c7ea6b6ab03cf804ee85 Mon Sep 17 00:00:00 2001 From: TermiNexus Date: Thu, 13 Aug 2026 08:22:21 +0800 Subject: [PATCH] =?UTF-8?q?fix(app):=20Install/Uninstall=20=E5=85=AC?= =?UTF-8?q?=E5=8F=B8=E6=9D=83=E9=99=90=E6=A0=A1=E9=AA=8C=20c.hex=20?= =?UTF-8?q?=E6=94=B9=20c.hex()=E2=80=94=E2=80=94UUIDObj=20=E6=97=A0=20hex?= =?UTF-8?q?=20=E5=B1=9E=E6=80=A7=E5=AF=BC=E8=87=B4=E6=9D=83=E9=99=90?= =?UTF-8?q?=E8=AF=AF=E5=88=A4=EF=BC=88403/500=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- TempLate/GERP/index.html | 4 ++-- gvsds/apps/gerp/views/app.py | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/TempLate/GERP/index.html b/TempLate/GERP/index.html index a26dec18..6abb691c 100644 --- a/TempLate/GERP/index.html +++ b/TempLate/GERP/index.html @@ -5,7 +5,7 @@ GERP 管理系统 - + @@ -14,7 +14,7 @@ - +
diff --git a/gvsds/apps/gerp/views/app.py b/gvsds/apps/gerp/views/app.py index 24312e37..44e19c51 100644 --- a/gvsds/apps/gerp/views/app.py +++ b/gvsds/apps/gerp/views/app.py @@ -199,9 +199,9 @@ class AppInstallView(ELTAuthenticatedAPIView): manageable, scope = AppManager.GetManageableCompanies(request) if not manageable: return Response({'code': 403, 'msg': '无权安装应用:您没有可管理的公司'}, status=403) - manageable_set = {c.hex for c in manageable} + manageable_set = {c.hex() for c in manageable} company_bytes = _ParseUUIDList(request.data.get('CompanyUUIDs')) - invalid = [c.hex for c in company_bytes if c.hex not in manageable_set] + invalid = [c.hex() for c in company_bytes if c.hex() not in manageable_set] if invalid: return Response({'code': 403, 'msg': '无权为以下公司安装(不在您的管理范围)'}, status=403) ok, err, count = AppManager.InstallCompanyApps( @@ -247,9 +247,9 @@ class AppUninstallView(ELTAuthenticatedAPIView): manageable, scope = AppManager.GetManageableCompanies(request) if not manageable: return Response({'code': 403, 'msg': '无权停用应用:您没有可管理的公司'}, status=403) - manageable_set = {c.hex for c in manageable} + manageable_set = {c.hex() for c in manageable} company_bytes = _ParseUUIDList(request.data.get('CompanyUUIDs')) - invalid = [c.hex for c in company_bytes if c.hex not in manageable_set] + invalid = [c.hex() for c in company_bytes if c.hex() not in manageable_set] if invalid: return Response({'code': 403, 'msg': '无权为以下公司停用(不在您的管理范围)'}, status=403) ok, err = AppManager.UninstallCompanyApps(company_uuids, app_uuid)