File tree Expand file tree Collapse file tree 2 files changed +4
-8
lines changed Expand file tree Collapse file tree 2 files changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -229,14 +229,10 @@ def content(id):
229229 elif '-files-upload-box' in x [1 ][0 ]:
230230 print ('skipping' )
231231 elif '-file-checkbox-' in x [1 ][0 ]:
232- content [int (x [1 ][0 ].split ('-file-checkbox-' )[0 ])]['value' ] = []
232+ if 'value' not in content [int (x [1 ][0 ].split ('-file-checkbox-' )[0 ])]:
233+ content [int (x [1 ][0 ].split ('-file-checkbox-' )[0 ])]['value' ] = []
233234 if x [1 ][1 ] == 'on' :
234- if "value" in content [int (x [1 ][0 ].split ('-file-checkbox-' )[0 ])]:
235- content [int (x [1 ][0 ].split ('-file-checkbox-' )[0 ])
236- ]['value' ].append (x [1 ][0 ].split ('-file-checkbox-' )[1 ])
237- else :
238- content [int (x [1 ][0 ].split ('-file-checkbox-' )[0 ])
239- ]['value' ] = [x [1 ][0 ].split ('-file-checkbox-' )[1 ]]
235+ content [int (x [1 ][0 ].split ('-file-checkbox-' )[0 ])]['value' ].append (x [1 ][0 ].split ('-file-checkbox-' )[1 ])
240236 elif content [int (x [1 ][0 ])]["type" ] == 'String Array' :
241237 content [int (x [1 ][0 ])]['value' ] = x [1 ][1 ].split (',' )
242238 else :
Original file line number Diff line number Diff line change @@ -169,7 +169,7 @@ <h2 class="text-2xl font-bold">Edit Content</h2>
169169 < small > (Deselect files to delete them.)</ small >
170170 < div id ="{{item[0]}}-checkbox " class ="mt-2 ">
171171 {% for checkbox in item[1]['value'] %}
172- < a target ="_blank " href ="/file/{{checkbox}} ">
172+ < a target ="_blank " style =" display: block; " class =" mb-2 " href ="/file/{{checkbox}} ">
173173 < input
174174 type ="checkbox "
175175 id ="{{item[0]}}-file-checkbox-{{checkbox}} "
You can’t perform that action at this time.
0 commit comments