[Update] 使用xterm.js替换原来的term.js

This commit is contained in:
ibuler
2018-05-10 12:19:37 +08:00
parent 0a9af98729
commit 7de6af89ad
15 changed files with 7446 additions and 55 deletions

View File

@@ -70,9 +70,16 @@ class CeleryTaskLogApi(generics.RetrieveAPIView):
end = False
queryset = CeleryTask.objects.all()
def get_object(self):
return CeleryTask(
id="4cae9ad8-1116-45e7-b019-9b1856696fd7",
log_path="2018-05-10/ca77e6db-9ac6-4970-80d1-eecdbcc3fcc5.log",
status="finished"
)
def get(self, request, *args, **kwargs):
mark = request.query_params.get("mark") or str(uuid.uuid4())
task = super().get_object()
task = self.get_object()
log_path = task.full_log_path
if not log_path or not os.path.isfile(log_path):