Set poll sources disabled by default with better interval options
- Poll sources now created with enabled=False by default - Admin must manually enable sources after adding them - Replace numeric interval input with dropdown: 15min to 24hr options - Default interval is 1 hour - Fix avatar upload form with proper multipart/form-data encoding 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
4
app.py
4
app.py
@@ -1360,13 +1360,13 @@ def admin_polling_add():
|
||||
flash(f'Source {platform}:{source_id} already exists', 'warning')
|
||||
return redirect(url_for('admin_polling'))
|
||||
|
||||
# Create new source
|
||||
# Create new source (disabled by default)
|
||||
source = PollSource(
|
||||
platform=platform,
|
||||
source_id=source_id,
|
||||
display_name=display_name,
|
||||
poll_interval_minutes=poll_interval,
|
||||
enabled=True,
|
||||
enabled=False,
|
||||
created_by=current_user.id
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user