# coding: utf-8
from sqlalchemy import Column, DECIMAL, Date, DateTime, String
from sqlalchemy.dialects.mysql import INTEGER

from config.mysql import Base


class ZxIeSettlement(Base):
    __tablename__ = 'zx_ie_settlement'

    pk_ie_settlement = Column(INTEGER(11), primary_key=True, comment='结算清单信息抽取主键')
    pk_phhd = Column(INTEGER(11), nullable=False, unique=True, comment='报销案子主键')
    name = Column(String(30), comment='患者姓名')
    admission_date_str = Column(String(255), comment='入院日期字符串')
    admission_date = Column(Date, comment='入院日期')
    discharge_date_str = Column(String(255), comment='出院日期字符串')
    discharge_date = Column(Date, comment='出院日期')
    medical_expenses_str = Column(String(255), comment='费用总额字符串')
    medical_expenses = Column(DECIMAL(18, 2), comment='费用总额')
    personal_cash_payment_str = Column(String(255), comment='个人现金支付字符串')
    personal_cash_payment = Column(DECIMAL(18, 2), comment='个人现金支付')
    personal_account_payment_str = Column(String(255), comment='个人账户支付字符串')
    personal_account_payment = Column(DECIMAL(18, 2), comment='个人账户支付')
    personal_funded_amount_str = Column(String(255), comment='自费金额字符串')
    personal_funded_amount = Column(DECIMAL(18, 2), comment='自费金额')
    medical_insurance_type = Column(String(255), comment='医保类型')
    create_time = Column(DateTime, comment='创建时间')
    creator = Column(String(255), comment='创建人')
    update_time = Column(DateTime, comment='修改时间')
    updater = Column(String(255), comment='修改人')
