diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-08-06 12:57:11 +0200 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-08-06 12:57:11 +0200 |
commit | 576be3536a4a9432f4127fbad912d32e0ca7b53c (patch) | |
tree | a367c8ada1d5d887549ab636b9de38882c2a5965 | |
parent | Gregy's settings page + TheBrayns new icons (diff) | |
download | pyload-576be3536a4a9432f4127fbad912d32e0ca7b53c.tar.xz |
webif plugin config preparations
-rw-r--r-- | module/config/default.conf | 4 | ||||
-rw-r--r-- | module/web/pyload/views.py | 6 | ||||
-rwxr-xr-x | pyLoadCli.py | 2 | ||||
-rwxr-xr-x | pyLoadCore.py | 2 |
4 files changed, 6 insertions, 8 deletions
diff --git a/module/config/default.conf b/module/config/default.conf index 4d0d588df..b1c0c648e 100644 --- a/module/config/default.conf +++ b/module/config/default.conf @@ -16,10 +16,6 @@ webinterface - "Webinterface": ip host : "IP" = 0.0.0.0
int port : "Port" = 8001
str template : "Template" = default
-xdcc - "xdcc":
- str nick : "Nickname" = pyload
- str ident : "Ident" = pyloadident
- str realname : "Realname" = pyloadreal
log - "Log":
bool file_log : "File Log" = True
str log_folder : "Folder" = Logs
diff --git a/module/web/pyload/views.py b/module/web/pyload/views.py index b93ed603e..0c04962fa 100644 --- a/module/web/pyload/views.py +++ b/module/web/pyload/views.py @@ -8,6 +8,7 @@ from os.path import isdir from os.path import isfile from os.path import join from urllib import unquote +from itertools import chain from django.conf import settings from django.contrib.auth.decorators import login_required @@ -214,6 +215,7 @@ def collector(request): @check_server def config(request): conf = settings.PYLOAD.get_config() + plugin = settings.PYLOAD.get_plugin_config() if request.META.get('REQUEST_METHOD', "GET") == "POST": @@ -245,11 +247,11 @@ def config(request): return render_to_response(join(settings.TEMPLATE, 'settings.html'), RequestContext(request, {'conf': {}, 'errors': messages}, [status_proc])) - for section in conf.itervalues(): + for section in chain(conf.itervalues(), plugin.itervalues()): for key, option in section.iteritems(): if key == "desc": continue if ";" in option["type"]: option["list"] = option["type"].split(";") - return render_to_response(join(settings.TEMPLATE, 'settings.html'), RequestContext(request, {'conf': conf, 'messages': []}, [status_proc])) + return render_to_response(join(settings.TEMPLATE, 'settings.html'), RequestContext(request, {'conf': conf, 'plugin': plugin, 'messages': []}, [status_proc])) diff --git a/pyLoadCli.py b/pyLoadCli.py index b08a56f28..5105599cd 100755 --- a/pyLoadCli.py +++ b/pyLoadCli.py @@ -486,7 +486,7 @@ if __name__ == "__main__": ssl = "" shortOptions = 'lu:a:p:s:h' - longOptions = ['local', "username=", "address=", "port=", "ssl=", "help", "linklist=", "pw="] + longOptions = ['local', "username=", "address=", "port=", "ssl=", "help", "linklist=", "pw=", "configdir="] try: opts, extraparams = getopt(sys.argv[1:], shortOptions, longOptions) diff --git a/pyLoadCore.py b/pyLoadCore.py index 1d7d31469..74cb10d23 100755 --- a/pyLoadCore.py +++ b/pyLoadCore.py @@ -77,7 +77,7 @@ class Core(object): if len(argv) > 1: try: - options, args = getopt(argv[1:], 'vca:hdusC:', ["version", "clear", "add=", "help", "debug", "user", "setup", "configdir="]) + options, args = getopt(argv[1:], 'vca:hdus:', ["version", "clear", "add=", "help", "debug", "user", "setup", "configdir="]) for option, argument in options: if option in ("-v", "--version"): |