Switch to unified view

a/webui.py b/webui.py
...
...
110
            rc[s][k] = v
110
            rc[s][k] = v
111
    # get useful things from recoll.conf
111
    # get useful things from recoll.conf
112
    config['dirs'] = shlex.split(rc['main']['topdirs'])
112
    config['dirs'] = shlex.split(rc['main']['topdirs'])
113
    # get config from cookies or defaults
113
    # get config from cookies or defaults
114
    for k, v in DEFAULTS.items():
114
    for k, v in DEFAULTS.items():
115
        try:
116
            value = type(v)(bottle.request.get_cookie(k))
115
        value = select([bottle.request.get_cookie(k), v])
117
        except:
118
            value = v
119
        config[k] = value
116
        config[k] = type(v)(value)
120
    # get mountpoints
117
    # get mountpoints
121
    config['mounts'] = {}
118
    config['mounts'] = {}
122
    for d in config['dirs']:
119
    for d in config['dirs']:
123
        name = 'mount_%s' % urllib.quote(d,'')
120
        name = 'mount_%s' % urllib.quote(d,'')
124
        config['mounts'][d] = select([bottle.request.get_cookie(name), 'file://%s' % d], [None, ''])
121
        config['mounts'][d] = select([bottle.request.get_cookie(name), 'file://%s' % d], [None, ''])