diff options
author | mkaay <mkaay@mkaay.de> | 2010-08-05 00:31:36 +0200 |
---|---|---|
committer | mkaay <mkaay@mkaay.de> | 2010-08-05 00:31:36 +0200 |
commit | f08de5a2f377134fcbfe95cc28b5030f3d834da5 (patch) | |
tree | b588f136c31e5feb8e8b92809fc81c6e563a3b82 | |
parent | gregy's great webif patch for chrome (diff) | |
download | pyload-f08de5a2f377134fcbfe95cc28b5030f3d834da5.tar.xz |
fix for gui
-rw-r--r-- | module/FileDatabase.py | 4 | ||||
-rwxr-xr-x | pyLoadCore.py | 5 |
2 files changed, 4 insertions, 5 deletions
diff --git a/module/FileDatabase.py b/module/FileDatabase.py index 18c371ae8..fe1bb9f8f 100644 --- a/module/FileDatabase.py +++ b/module/FileDatabase.py @@ -337,14 +337,14 @@ class FileHandler: self.core.pullManager.addEvent(e) @change - def pushPackageToQueue(self, id): + def setPackageLocation(self, id, queue): """push package to queue""" pack = self.db.getPackage(id) e = RemoveEvent("pack", id, "collector" if not pack.queue else "queue") self.core.pullManager.addEvent(e) - pack.queue = 1 + pack.queue = queue self.db.updatePackage(pack) e = InsertEvent("pack", id, -1, "collector" if not pack.queue else "queue") diff --git a/pyLoadCore.py b/pyLoadCore.py index 40b87ab76..4e0e8cb08 100755 --- a/pyLoadCore.py +++ b/pyLoadCore.py @@ -521,7 +521,7 @@ class ServerMethods(): pass def push_package_to_queue(self, id): - self.core.files.pushPackageToQueue(id) + self.core.files.setPackageLocation(id, 1) def restart_package(self, packid): self.core.files.restartPackage(int(packid)) @@ -568,8 +568,7 @@ class ServerMethods(): def pull_out_package(self, pid): """put package back to collector""" - #@TODO implement - pass + self.core.files.setPackageLocation(pid, 0) def is_captcha_waiting(self): self.core.lastClientConnected = time.time() |