# -*- coding: utf-8 -*-
# Generated by Django 1.11.29 on 2020-08-13 16:51
from __future__ import unicode_literals

from django.db import migrations, models
import django.db.models.deletion
import mysite.admin.abstract_cloud_model


class Migration(migrations.Migration):

    dependencies = [
        ('personnel', '0015_auto_20200729_1719'),
        ('iclock', '0018_auto_20200813_1632'),
    ]

    operations = [
        migrations.CreateModel(
            name='Unregister',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('emp_code', models.CharField(max_length=20, null=True, verbose_name='transaction_field_employeeCode')),
                ('punch_time', models.DateTimeField(verbose_name='transaction_field_punchTime')),
                ('punch_state', models.CharField(choices=[('0', 'transaction_punchState_checkIn'), ('1', 'transaction_punchState_checkOut'), ('2', 'transaction_punchState_breakOut'), ('3', 'transaction_punchState_breakIn'), ('4', 'transaction_punchState_overtimeIn'), ('5', 'transaction_punchState_overtimeOut')], default='0', max_length=5, verbose_name='transaction_field_punchState')),
                ('verify_type', models.IntegerField(choices=[(0, 'terminal_verifyOption_automatic'), (1, 'terminal_verifyOption_fingerprint'), (2, 'terminal_verifyOption_badge'), (3, 'terminal_verifyOption_password'), (4, 'terminal_verifyOption_card'), (5, 'terminal_verifyOption_fingerprintOrPassword'), (6, 'terminal_verifyOption_fingerprintOrCard'), (7, 'terminal_verifyOption_passwordOrCard'), (8, 'terminal_verifyOption_badgeAndFingerprint'), (9, 'terminal_verifyOption_fingerprintAndPassword'), (10, 'terminal_verifyOption_fingerprintAndCard'), (11, 'terminal_verifyOption_passwordAndCard'), (12, 'terminal_verifyOption_fingerprintAndPasswordAndCard'), (13, 'terminal_verifyOption_badgeAndFingerprintAndPassword'), (14, 'terminal_verifyOption_fingerprintAndCardOrFingerprintAndBadge'), (15, 'terminal_verifyOption_face'), (16, 'terminal_verifyOption_faceAndFingerprint'), (17, 'terminal_verifyOption_faceAndPassword'), (18, 'terminal_verifyOption_faceAndCard'), (19, 'terminal_verifyOption_faceAndFingerprintAndCard'), (20, 'terminal_verifyOption_faceAndFingerprintAndPassword'), (21, 'terminal_verifyOption_fingerVein'), (22, 'terminal_verifyOption_fingerVeinAndPassword'), (23, 'terminal_verifyOption_fingerVeinAndCard'), (24, 'terminal_verifyOption_fingerVeinAndPasswordAndCard'), (25, 'terminal_verifyOption_palm'), (26, 'terminal_verifyOption_palmAndCard'), (27, 'terminal_verifyOption_palmAndFace'), (28, 'terminal_verifyOption_palmAndFingerprint'), (29, 'terminal_verifyOption_palmAndFingerprintAndFace'), (101, 'terminal_verifyOption_gps'), (102, 'terminal_verifyOption_aiCamera'), (200, 'terminal_verifyOption_other')], default=0, verbose_name='transaction_field_verifyType')),
                ('work_code', models.CharField(blank=True, max_length=20, null=True, verbose_name='transaction_field_workCode')),
                ('terminal_sn', models.CharField(blank=True, default='', max_length=50, null=True, verbose_name='transaction_field_terminalSN')),
                ('terminal_alias', models.CharField(blank=True, max_length=50, null=True, verbose_name='transaction_terminal_alias')),
                ('area_alias', models.CharField(blank=True, max_length=120, null=True, verbose_name='transaction_field_areaAlias')),
                ('longitude', models.FloatField(blank=True, null=True, verbose_name='transaction_field_longitude')),
                ('latitude', models.FloatField(blank=True, null=True, verbose_name='transaction_field_latitude')),
                ('gps_location', models.TextField(blank=True, default='', null=True, verbose_name='transaction_field_gpsLocation')),
                ('mobile', models.CharField(blank=True, max_length=50, null=True, verbose_name='transaction_field_mobile')),
                ('source', models.SmallIntegerField(blank=True, choices=[(1, 'dataSources_option_terminal'), (2, 'dataSources_option_manualLog'), (3, 'dataSources_option_mobile'), (4, 'pen driver')], default=1, null=True, verbose_name='transaction_field_source')),
                ('purpose', models.SmallIntegerField(blank=True, default=1, editable=False, null=True, verbose_name='transaction_field_purpose')),
                ('crc', models.CharField(blank=True, max_length=100, null=True, verbose_name='transaction_field_crcCode')),
                ('is_attendance', models.SmallIntegerField(blank=True, default=1, null=True, verbose_name='transaction_field_isAttendance')),
                ('reserved', models.CharField(blank=True, max_length=100, null=True, verbose_name='transaction_field_reserved')),
                ('upload_time', models.DateTimeField(blank=True, null=True, verbose_name='transaction_field_uploadTime')),
                ('sync_status', models.SmallIntegerField(blank=True, default=0, null=True, verbose_name='transaction_field_synchronizedStatus')),
                ('sync_time', models.DateTimeField(blank=True, null=True, verbose_name='transaction_field_synchronized_time')),
                ('temperature', models.DecimalField(blank=True, decimal_places=2, max_digits=4, null=True, verbose_name='Temperature')),
                ('mask_flag', models.IntegerField(blank=True, choices=[(0, 'No'), (1, 'Yes')], null=True, verbose_name='Mask Flag')),
                ('company', models.ForeignKey(blank=True, default=mysite.admin.abstract_cloud_model.get_current_company, null=True, on_delete=django.db.models.deletion.CASCADE, to='personnel.Company')),
                ('emp', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='personnel.Employee', verbose_name='transaction_field_employee')),
                ('terminal', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='iclock.Terminal', verbose_name='transaction_field_terminal')),
            ],
            options={
                'verbose_name': 'iclock_model_unregister',
                'verbose_name_plural': 'iclock_model_unregister',
                'default_permissions': ('view',),
            },
        ),
        migrations.AlterUniqueTogether(
            name='unregister',
            unique_together=set([('punch_time', 'company', 'terminal_sn')]),
        ),
    ]
