# Generated by Django 3.2.19 on 2023-06-25 18:45
from django.db import migrations, models

from NEMO.migrations_utils import create_news_for_version


class Migration(migrations.Migration):

    dependencies = [
        ('NEMO', '0045_version_4_5_5'),
    ]

    def new_version_news(apps, schema_editor):
        create_news_for_version(apps, "4.6.0", "")

    operations = [
        migrations.RunPython(new_version_news),
        migrations.AddField(
            model_name='userpreferences',
            name='tool_freed_time_notifications',
            field=models.ManyToManyField(blank=True, help_text='Tools to receive notification when reservation time is freed.', to='NEMO.Tool'),
        ),
        migrations.AddField(
            model_name='userpreferences',
            name='tool_freed_time_notifications_max_future_days',
            field=models.PositiveIntegerField(default=7, help_text='Maximum number of days in the future to receive a notification for.'),
        ),
        migrations.AddField(
            model_name='userpreferences',
            name='tool_freed_time_notifications_min_time',
            field=models.PositiveIntegerField(default=120, help_text='Minimum amount of minutes freed to receive a notification.'),
        ),
        migrations.AddField(
            model_name='tool',
            name='_qualifications_never_expire',
            field=models.BooleanField(db_column='qualifications_never_expire', default=False, help_text='Check this box if qualifications for this tool should never expire (even if the tool qualification expiration feature is enabled).'),
        ),
        migrations.AddField(
            model_name='userpreferences',
            name='tool_adjustment_notifications',
            field=models.ManyToManyField(blank=True, help_text='Tools to see/receive adjustment notifications for. If empty all notifications will be received.', related_name='_NEMO_userpreferences_tool_adjustment_notifications_+', to='NEMO.Tool'),
        ),
        migrations.AlterField(
            model_name='user',
            name='is_facility_manager',
            field=models.BooleanField(default=False, help_text='Designates this user as facility manager. Facility managers receive updates on all reported problems in the facility and also review access and adjustment requests.', verbose_name='facility manager'),
        ),
        migrations.AddField(
            model_name='userpreferences',
            name='tool_task_notifications',
            field=models.ManyToManyField(blank=True, help_text='Tools to see maintenance records and receive task notifications for. If empty all notifications will be received.', related_name='_NEMO_userpreferences_tool_task_notifications_+', to='NEMO.Tool'),
        ),
        migrations.AddField(
            model_name='consumablewithdraw',
            name='tool_usage',
            field=models.BooleanField(default=False, help_text='Whether this withdraw is from tool usage'),
        ),
    ]
