import { FieldInfo } from 'model-util-base'
import { ConditionUtil, ConditionUtilImpl, FieldUtil, TableUtilImpl, IdType, JoinTable, SubTable } from 'model-util'
import { Container, Singleton } from 'typescript-ioc' 
import { BusLotPayConfig } from '../models/index' 
/**
 * @author auto generate
 * @version 1.0
 * @date 2021-06-24 10:37
 */
interface BusLotPayConfigCU extends ConditionUtil<BusLotPayConfigCU>{
    LOT_ID:FieldUtil<BusLotPayConfigCU>;
    PC_CONFIG_ID:FieldUtil<BusLotPayConfigCU>;
    REMARK:FieldUtil<BusLotPayConfigCU>;
    CREATE_TIME:FieldUtil<BusLotPayConfigCU>;
    UPDATE_TIME:FieldUtil<BusLotPayConfigCU>;
}

class BusLotPayConfigCUImpl extends ConditionUtilImpl<BusLotPayConfigCUImpl> implements BusLotPayConfigCU{ 
    newInstance(): BusLotPayConfigCUImpl {
        return new BusLotPayConfigCUImpl();
    } 
    get LOT_ID(): FieldUtil<BusLotPayConfigCU>{  
        return new FieldUtil('LOT_ID','lotId','车场ID', this);
    }
    get PC_CONFIG_ID(): FieldUtil<BusLotPayConfigCU>{  
        return new FieldUtil('PC_CONFIG_ID','pcConfigId','PC_CONFIG_ID', this);
    }
    get REMARK(): FieldUtil<BusLotPayConfigCU>{  
        return new FieldUtil('REMARK','remark','备注', this);
    }
    get CREATE_TIME(): FieldUtil<BusLotPayConfigCU>{  
        return new FieldUtil('CREATE_TIME','createTime','创建时间', this);
    }
    get UPDATE_TIME(): FieldUtil<BusLotPayConfigCU>{  
        return new FieldUtil('UPDATE_TIME','updateTime','更新时间', this);
    }
}

@Singleton 
class BusLotPayConfigMU extends TableUtilImpl<BusLotPayConfigCU,BusLotPayConfig>{ 
    tableName  = 'bus_lot_pay_config';
    tableFields  = ['LOT_ID','PC_CONFIG_ID','REMARK','CREATE_TIME','UPDATE_TIME'];
    modelFields  = ['lotId','pcConfigId','remark','createTime','updateTime'];
    modelIdFields  = ['lotId'];
    tableIdFields  = ['LOT_ID'];
    idType = IdType.CUSTOM;
    joinTables = [];
    subTables = [];

    createConditionUtil(): BusLotPayConfigCU {
        return new BusLotPayConfigCUImpl();
    }   

    static get LOT_ID(): FieldUtil<BusLotPayConfigCU>{ 
        return new FieldUtil('LOT_ID','lotId','车场ID', new BusLotPayConfigCUImpl());
    }
    static get PC_CONFIG_ID(): FieldUtil<BusLotPayConfigCU>{ 
        return new FieldUtil('PC_CONFIG_ID','pcConfigId','PC_CONFIG_ID', new BusLotPayConfigCUImpl());
    }
    static get REMARK(): FieldUtil<BusLotPayConfigCU>{ 
        return new FieldUtil('REMARK','remark','备注', new BusLotPayConfigCUImpl());
    }
    static get CREATE_TIME(): FieldUtil<BusLotPayConfigCU>{ 
        return new FieldUtil('CREATE_TIME','createTime','创建时间', new BusLotPayConfigCUImpl());
    }
    static get UPDATE_TIME(): FieldUtil<BusLotPayConfigCU>{ 
        return new FieldUtil('UPDATE_TIME','updateTime','更新时间', new BusLotPayConfigCUImpl());
    }

    get LOT_ID(): FieldUtil<BusLotPayConfigCU>{ 
        return BusLotPayConfigMU.LOT_ID;
    }
    get PC_CONFIG_ID(): FieldUtil<BusLotPayConfigCU>{ 
        return BusLotPayConfigMU.PC_CONFIG_ID;
    }
    get REMARK(): FieldUtil<BusLotPayConfigCU>{ 
        return BusLotPayConfigMU.REMARK;
    }
    get CREATE_TIME(): FieldUtil<BusLotPayConfigCU>{ 
        return BusLotPayConfigMU.CREATE_TIME;
    }
    get UPDATE_TIME(): FieldUtil<BusLotPayConfigCU>{ 
        return BusLotPayConfigMU.UPDATE_TIME;
    }
}
export {BusLotPayConfigMU, BusLotPayConfigCU}
