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