# This is an auto-generated Django model module.
# You'll have to do the following manually to clean this up:
#   * Rearrange models' order
#   * Make sure each model has one field with primary_key=True
#   * Make sure each ForeignKey and OneToOneField has `on_delete` set to the desired behavior
#   * Remove `managed = False` lines if you wish to allow Django to create, modify, and delete the table
# Feel free to rename the models, but don't rename db_table values or field names.
from django.db import models


class Dataname(models.Model):
    iid = models.AutoField(primary_key=True)
    main_iid = models.IntegerField(blank=True, null=True)
    title_theme = models.CharField(max_length=100, blank=True, null=True)
    upfile_path = models.CharField(max_length=10, blank=True, null=True)
    admin = models.CharField(max_length=255, blank=True, null=True)
    link_type = models.IntegerField(blank=True, null=True)
    out_html = models.CharField(max_length=255, blank=True, null=True)
    contents = models.TextField(blank=True, null=True)
    out_link = models.CharField(max_length=255, blank=True, null=True)
    modekind = models.IntegerField(blank=True, null=True)
    update_date = models.DateTimeField(blank=True, null=True)
    c_title = models.TextField(blank=True, null=True)
    ltitle = models.CharField(max_length=50, blank=True, null=True)
    rtitle = models.CharField(max_length=50, blank=True, null=True)
    orders = models.IntegerField(blank=True, null=True)
    newfun_id = models.IntegerField(blank=True, null=True)
    showyn = models.CharField(max_length=1, blank=True, null=True)
    idpath = models.CharField(max_length=200, blank=True, null=True)
    userid = models.CharField(max_length=20, blank=True, null=True)
    publicid = models.IntegerField(blank=True, null=True)
    titlepic = models.CharField(max_length=30, blank=True, null=True)
    webkind = models.CharField(max_length=4, blank=True, null=True)
    mobilemenu = models.IntegerField(blank=True, null=True)
    topmenu = models.TextField(blank=True, null=True)
    btitle = models.CharField(max_length=50, blank=True, null=True)
    onsub = models.IntegerField(blank=True, null=True)
    mag = models.IntegerField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'dataname'


class Doctor(models.Model):
    cname = models.CharField(max_length=50, blank=True, null=True)
    mobile = models.CharField(max_length=50, blank=True, null=True)
    job = models.CharField(max_length=50, blank=True, null=True)
    sid = models.IntegerField(blank=True, null=True)
    adduser = models.CharField(max_length=50, blank=True, null=True)
    adddate = models.DateTimeField(blank=True, null=True)
    editdate = models.DateTimeField(blank=True, null=True)
    edituser = models.CharField(max_length=50, blank=True, null=True)
    typs = models.IntegerField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'doctor'


class Editrec(models.Model):
    iid = models.AutoField(primary_key=True)
    editrec = models.CharField(max_length=10, blank=True, null=True)
    edituser = models.CharField(max_length=10, blank=True, null=True)
    editusernm = models.CharField(max_length=50, blank=True, null=True)
    editdate = models.DateTimeField(blank=True, null=True)
    action = models.CharField(max_length=50, blank=True, null=True)
    edititem = models.CharField(max_length=50, blank=True, null=True)
    aid = models.IntegerField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'editrec'


class F00(models.Model):
    user_id = models.CharField(max_length=20)
    user_name = models.CharField(max_length=30, blank=True, null=True)
    passwd = models.CharField(max_length=50, blank=True, null=True)
    levels = models.IntegerField(blank=True, null=True)
    password = models.CharField(max_length=25, blank=True, null=True)
    email = models.CharField(max_length=100, blank=True, null=True)
    position2 = models.IntegerField(blank=True, null=True)
    editdate = models.DateTimeField(blank=True, null=True)
    edituser = models.CharField(max_length=20, blank=True, null=True)
    mobilephone = models.CharField(max_length=50, blank=True, null=True)
    usertimes = models.IntegerField(blank=True, null=True)
    stopuse = models.CharField(max_length=1, blank=True, null=True)
    checkdate = models.DateTimeField(blank=True, null=True)
    leavedate = models.DateTimeField(blank=True, null=True)
    allowiid = models.TextField(blank=True, null=True)
    adduser = models.CharField(max_length=50, blank=True, null=True)
    adddate = models.DateTimeField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'f00'


class Marquee(models.Model):
    roomid = models.CharField(max_length=10, blank=True, null=True)
    marqueetext = models.TextField(blank=True, null=True)
    edituser = models.CharField(max_length=50, blank=True, null=True)
    editdate = models.DateTimeField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'marquee'


class Meeting(models.Model):
    iid = models.AutoField(primary_key=True)
    week = models.CharField(max_length=50, blank=True, null=True)
    title = models.CharField(max_length=200, blank=True, null=True)
    people = models.TextField(blank=True, null=True)
    sdate = models.DateTimeField(blank=True, null=True)
    stime = models.CharField(max_length=100, blank=True, null=True)
    edate = models.DateTimeField(blank=True, null=True)
    memo = models.TextField(blank=True, null=True)
    filenamea = models.CharField(max_length=200, blank=True, null=True)
    place = models.CharField(max_length=255, blank=True, null=True)
    sid = models.CharField(max_length=255, blank=True, null=True)
    build_date = models.DateTimeField(blank=True, null=True)
    stime1 = models.CharField(max_length=50, blank=True, null=True)
    stime2 = models.CharField(max_length=50, blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'meeting'


class Mem(models.Model):
    iid = models.AutoField(primary_key=True)
    sid = models.IntegerField(blank=True, null=True)
    mno = models.CharField(max_length=10, blank=True, null=True)
    eid = models.CharField(max_length=10, blank=True, null=True)
    cnm = models.CharField(max_length=50, blank=True, null=True)
    enm = models.CharField(max_length=50, blank=True, null=True)
    birthday = models.DateTimeField(blank=True, null=True)
    sex = models.CharField(max_length=1, blank=True, null=True)
    addr1 = models.CharField(max_length=255, blank=True, null=True)
    ondate = models.DateTimeField(blank=True, null=True)
    inter = models.IntegerField(blank=True, null=True)
    out_date = models.TextField(blank=True, null=True)
    mobile = models.CharField(max_length=50, blank=True, null=True)
    phone = models.CharField(max_length=50, blank=True, null=True)
    update_date = models.DateTimeField(blank=True, null=True)
    update_userid = models.CharField(max_length=50, blank=True, null=True)
    remarks = models.TextField(blank=True, null=True)
    maindiagnose = models.CharField(db_column='mainDiagnose', max_length=50, blank=True, null=True)  # Field name made lowercase.
    maindoctor = models.CharField(db_column='mainDoctor', max_length=10, blank=True, null=True)  # Field name made lowercase.
    treatmentroom = models.CharField(db_column='treatmentRoom', max_length=20, blank=True, null=True)  # Field name made lowercase.
    hospitalizedstatus = models.IntegerField(db_column='hospitalizedStatus', blank=True, null=True)  # Field name made lowercase.
    shift = models.CharField(db_column='Shift', max_length=1, blank=True, null=True)  # Field name made lowercase.
    undone = models.CharField(max_length=1, blank=True, null=True)
    detailmaindigonse = models.TextField(db_column='detailMainDigonse', blank=True, null=True)  # Field name made lowercase.
    treatmentcount = models.IntegerField(db_column='TreatmentCount', blank=True, null=True)  # Field name made lowercase.
    fallrisktime = models.DateTimeField(db_column='fallRiskTime', blank=True, null=True)  # Field name made lowercase.
    fallrisk = models.IntegerField(db_column='fallRisk', blank=True, null=True)  # Field name made lowercase.
    makewill = models.IntegerField(db_column='makeWill', blank=True, null=True)  # Field name made lowercase.
    willtime = models.DateTimeField(db_column='willTime', blank=True, null=True)  # Field name made lowercase.

    class Meta:
        managed = False
        db_table = 'mem'


class Patient(models.Model):
    record_no = models.CharField(max_length=100, blank=True, null=True)
    name = models.CharField(max_length=50, blank=True, null=True)
    enname = models.CharField(max_length=255, blank=True, null=True)
    roc_id = models.CharField(max_length=10, blank=True, null=True)
    sex = models.CharField(max_length=2, blank=True, null=True)
    birthday = models.CharField(max_length=10, blank=True, null=True)
    family_name = models.CharField(max_length=10, blank=True, null=True)
    home_phone_number = models.CharField(max_length=50, blank=True, null=True)
    mobile_phone = models.CharField(max_length=50, blank=True, null=True)
    contact_home_number = models.CharField(max_length=50, blank=True, null=True)
    contact_phone_number = models.CharField(max_length=100, blank=True, null=True)
    edituser = models.CharField(max_length=50, blank=True, null=True)
    editdate = models.DateTimeField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'patient'


class PatientAppointment(models.Model):
    appointment_date = models.DateTimeField(blank=True, null=True)
    appointment_hour = models.CharField(max_length=2, blank=True, null=True)
    appointment_minutes = models.CharField(max_length=2, blank=True, null=True)
    create_datetime = models.DateTimeField(blank=True, null=True)
    endstatus = models.CharField(db_column='endStatus', max_length=10, blank=True, null=True)  # Field name made lowercase.
    finished_times = models.IntegerField(blank=True, null=True)
    main_diagnose = models.TextField(blank=True, null=True)
    main_doctor = models.CharField(max_length=50, blank=True, null=True)
    rt_doctor = models.CharField(db_column='RT_doctor', max_length=50, blank=True, null=True)  # Field name made lowercase.
    mobile_phone_number = models.CharField(max_length=10, blank=True, null=True)
    record_no = models.CharField(max_length=100, blank=True, null=True)
    shift = models.CharField(max_length=1, blank=True, null=True)
    tip_note = models.TextField(blank=True, null=True)
    treatment_room = models.CharField(max_length=50, blank=True, null=True)
    treatment_times = models.IntegerField(blank=True, null=True)
    dropsize = models.CharField(db_column='dropSize', max_length=2, blank=True, null=True)  # Field name made lowercase.
    fallrisk = models.CharField(db_column='fallRisk', max_length=1, blank=True, null=True)  # Field name made lowercase.
    fallrisktime = models.DateTimeField(db_column='fallRiskTime', blank=True, null=True)  # Field name made lowercase.
    makewill = models.CharField(db_column='makeWill', max_length=1, blank=True, null=True)  # Field name made lowercase.
    willtime = models.DateTimeField(db_column='willTime', blank=True, null=True)  # Field name made lowercase.
    editdate = models.DateTimeField(blank=True, null=True)
    edituser = models.CharField(max_length=10, blank=True, null=True)
    comments = models.TextField(blank=True, null=True)
    note = models.TextField(blank=True, null=True)
    endallschudle = models.CharField(db_column='endAllSchudle', max_length=50, blank=True, null=True)  # Field name made lowercase.
    cre = models.CharField(max_length=50, blank=True, null=True)
    locationappointment = models.TextField(db_column='locationAppointment', blank=True, null=True)  # Field name made lowercase.
    hospitalized_status = models.CharField(max_length=50, blank=True, null=True)
    mrid = models.IntegerField(blank=True, null=True)
    planstatus = models.IntegerField(db_column='Planstatus', blank=True, null=True)  # Field name made lowercase.
    plandate = models.DateTimeField(db_column='Plandate', blank=True, null=True)  # Field name made lowercase.
    onlineok = models.IntegerField(db_column='ONLINEOK', blank=True, null=True)  # Field name made lowercase.
    ide = models.CharField(db_column='IDE', max_length=50, blank=True, null=True)  # Field name made lowercase.
    goals = models.CharField(max_length=50, blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'patient_appointment'


class PatientAppointmentSchedule(models.Model):
    appointment_date = models.DateTimeField(blank=True, null=True)
    appointment_hour = models.CharField(max_length=2, blank=True, null=True)
    appointment_minutes = models.CharField(max_length=2, blank=True, null=True)
    calling = models.CharField(max_length=1, blank=True, null=True)
    calling_right = models.CharField(max_length=1, blank=True, null=True)
    checkin_datetime = models.DateTimeField(blank=True, null=True)
    checkin_late = models.BooleanField(blank=True, null=True)
    checkin_status = models.CharField(max_length=5, blank=True, null=True)
    comments = models.CharField(max_length=500, blank=True, null=True)
    complex_segments = models.CharField(max_length=2, blank=True, null=True)
    hospitalized_status = models.CharField(max_length=100, blank=True, null=True)
    mapping_appointment = models.IntegerField(blank=True, null=True)
    mapping_patient = models.IntegerField(blank=True, null=True)
    queue_datetime = models.DateTimeField(blank=True, null=True)
    queue_status = models.CharField(max_length=5, blank=True, null=True)
    record_no = models.CharField(max_length=100, blank=True, null=True)
    room_calling = models.CharField(max_length=1, blank=True, null=True)
    schedule_status = models.CharField(max_length=1, blank=True, null=True)
    second_time = models.CharField(max_length=1, blank=True, null=True)
    shift = models.CharField(max_length=1, blank=True, null=True)
    simple_segments = models.CharField(max_length=2, blank=True, null=True)
    treatment_complete_datetime = models.DateTimeField(blank=True, null=True)
    treatment_count = models.IntegerField(blank=True, null=True)
    treatment_room = models.CharField(max_length=50, blank=True, null=True)
    treatment_start_datetime = models.DateTimeField(blank=True, null=True)
    treatment_status = models.CharField(max_length=10, blank=True, null=True)
    finish_calling = models.CharField(max_length=1, blank=True, null=True)
    finish_calling_right = models.CharField(max_length=1, blank=True, null=True)
    fallrisk = models.CharField(db_column='fallRisk', max_length=1, blank=True, null=True)  # Field name made lowercase.
    fallrisktime = models.DateTimeField(db_column='fallRiskTime', blank=True, null=True)  # Field name made lowercase.
    makewill = models.CharField(db_column='makeWill', max_length=1, blank=True, null=True)  # Field name made lowercase.
    willtime = models.DateTimeField(db_column='willTime', blank=True, null=True)  # Field name made lowercase.
    editdate = models.DateTimeField(blank=True, null=True)
    edituser = models.CharField(max_length=10, blank=True, null=True)
    main_doctor = models.CharField(max_length=50, blank=True, null=True)
    rt_doctor = models.CharField(db_column='RT_doctor', max_length=50, blank=True, null=True)  # Field name made lowercase.
    main_diagnose = models.TextField(blank=True, null=True)
    smsstatus = models.CharField(db_column='smsStatus', max_length=1, blank=True, null=True)  # Field name made lowercase.
    smsmsg = models.CharField(db_column='smsMsg', max_length=50, blank=True, null=True)  # Field name made lowercase.
    ctnm = models.CharField(db_column='CTnm', max_length=50, blank=True, null=True)  # Field name made lowercase.
    onlinestatus = models.IntegerField(db_column='Onlinestatus', blank=True, null=True)  # Field name made lowercase.
    okdate = models.DateTimeField(blank=True, null=True)
    onlineokdate = models.DateTimeField(db_column='ONLINEOKDATE', blank=True, null=True)  # Field name made lowercase.
    okstatus = models.IntegerField(blank=True, null=True)
    period = models.IntegerField(blank=True, null=True)
    onlineok = models.CharField(db_column='ONLINEOK', max_length=1, blank=True, null=True)  # Field name made lowercase.

    class Meta:
        managed = False
        db_table = 'patient_appointment_schedule'


class Sms(models.Model):
    smsway = models.CharField(db_column='smsWay', max_length=50, blank=True, null=True)  # Field name made lowercase.
    smsdate = models.DateTimeField(db_column='smsDate', blank=True, null=True)  # Field name made lowercase.
    hour = models.CharField(max_length=2, blank=True, null=True)
    minute = models.CharField(max_length=2, blank=True, null=True)
    cname = models.CharField(max_length=50, blank=True, null=True)
    smscontent = models.TextField(db_column='smsContent', blank=True, null=True)  # Field name made lowercase.
    userid = models.CharField(db_column='userId', max_length=50, blank=True, null=True)  # Field name made lowercase.
    history = models.CharField(db_column='History', max_length=50, blank=True, null=True)  # Field name made lowercase.
    getlogs = models.CharField(db_column='getLogs', max_length=50, blank=True, null=True)  # Field name made lowercase.
    roomid = models.CharField(max_length=10, blank=True, null=True)
    mobile = models.CharField(max_length=50, blank=True, null=True)
    smsresult = models.CharField(db_column='smsResult', max_length=100, blank=True, null=True)  # Field name made lowercase.
    adddate = models.DateTimeField(blank=True, null=True)
    adduser = models.CharField(max_length=50, blank=True, null=True)
    types = models.CharField(max_length=1, blank=True, null=True)
    smsstatus = models.CharField(db_column='smsStatus', max_length=100, blank=True, null=True)  # Field name made lowercase.
    targetuser = models.CharField(db_column='targetUser', max_length=1, blank=True, null=True)  # Field name made lowercase.
    senddate = models.DateTimeField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'sms'


class Smslog(models.Model):
    username = models.CharField(db_column='UserName', max_length=50, blank=True, null=True)  # Field name made lowercase.
    smsdatetime = models.DateTimeField(db_column='smsDateTime', blank=True, null=True)  # Field name made lowercase.
    createdatetime = models.DateTimeField(db_column='CreateDateTime', blank=True, null=True)  # Field name made lowercase.
    smscontent = models.TextField(db_column='smsContent', blank=True, null=True)  # Field name made lowercase.
    sendstatus = models.CharField(db_column='sendStatus', max_length=100, blank=True, null=True)  # Field name made lowercase.
    statuscode = models.CharField(db_column='statusCode', max_length=50, blank=True, null=True)  # Field name made lowercase.
    smsid = models.IntegerField(blank=True, null=True)
    msgseq = models.CharField(db_column='msgSeq', max_length=10, blank=True, null=True)  # Field name made lowercase.
    smsnum = models.CharField(max_length=10, blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'smsLog'


class Smshistory(models.Model):
    id = models.AutoField(primary_key=True)
    smsbody = models.TextField(db_column='Smsbody', blank=True, null=True)  # Field name made lowercase.
    smstitle = models.CharField(max_length=50, blank=True, null=True)
    type = models.CharField(max_length=1, blank=True, null=True)
    roomid = models.CharField(max_length=50, blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'smshistory'


class TreatmentRoom(models.Model):
    id = models.CharField(primary_key=True, max_length=50)
    room_name = models.CharField(max_length=50, blank=True, null=True)
    room_show_name = models.CharField(max_length=50, blank=True, null=True)
    room_status = models.CharField(max_length=1, blank=True, null=True)
    editdate = models.DateTimeField(blank=True, null=True)
    edituser = models.CharField(max_length=50, blank=True, null=True)
    tv_status = models.CharField(max_length=1, blank=True, null=True)
    capacity = models.IntegerField(blank=True, null=True)
    isshow = models.IntegerField(blank=True, null=True)

    class Meta:
        managed = False
        db_table = 'treatment_room'
