allow all archives to be disabled, take two
This commit is contained in:
parent
5d70306979
commit
cd260d34da
@ -15,10 +15,12 @@ Redirect =
|
||||
o.file[boardID] = data unless boardID of o.file or boardID not in files
|
||||
|
||||
for boardID, record of Conf['selectedArchives']
|
||||
for type, id of record when (archive = archives[id])
|
||||
boards = if type is 'file' then archive.files else archive.boards
|
||||
continue unless boardID in boards
|
||||
o[type][boardID] = archive
|
||||
for type, id of record
|
||||
if id is 'disabled'
|
||||
delete o[type][boardID]
|
||||
else if archive = archives[id]
|
||||
boards = if type is 'file' then archive.files else archive.boards
|
||||
o[type][boardID] = archive if boardID in boards
|
||||
|
||||
Redirect.data = o
|
||||
|
||||
|
||||
@ -329,8 +329,7 @@ Settings =
|
||||
o.file[i].push name if boardID in files
|
||||
for boardID, o of archBoards
|
||||
for item in ['thread', 'post', 'file']
|
||||
if o[item][0].length is 0 and o[item][1].length isnt 0
|
||||
o[item][0].push 'disabled'
|
||||
o[item][0].push 'disabled'
|
||||
o[item] = o[item][0].concat(o[item][1])
|
||||
|
||||
rows = []
|
||||
|
||||
@ -10,7 +10,6 @@
|
||||
</thead>
|
||||
<tbody></tbody>
|
||||
</table>
|
||||
<span class=note>Disabled selections indicate that only one archive is available for that board and redirection type.</span>
|
||||
</fieldset>
|
||||
|
||||
<fieldset>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user