import { FieldInfo } from 'model-util-base'
import { ConditionUtil, ConditionUtilImpl, FieldUtil, TableUtilImpl, IdType, JoinTable, SubTable } from 'model-util'
import { Container, Singleton } from 'typescript-ioc' 
import { CrSendCouponRecord } from '../models/index' 
/**
 * @author auto generate
 * @version 1.0
 * @date 2021-05-16 14:39
 */
interface CrSendCouponRecordCU extends ConditionUtil<CrSendCouponRecordCU>{
    UUID:FieldUtil<CrSendCouponRecordCU>;
    USER_ID:FieldUtil<CrSendCouponRecordCU>;
    CCC_ID:FieldUtil<CrSendCouponRecordCU>;
    COUPON_INFO:FieldUtil<CrSendCouponRecordCU>;
    SEND_TIME:FieldUtil<CrSendCouponRecordCU>;
    SEND_STATUS:FieldUtil<CrSendCouponRecordCU>;
    RETRY_TIMES:FieldUtil<CrSendCouponRecordCU>;
    DEL_FLAG:FieldUtil<CrSendCouponRecordCU>;
    CREATE_TIME:FieldUtil<CrSendCouponRecordCU>;
    UPDATE_TIME:FieldUtil<CrSendCouponRecordCU>;
    AD_INFO_ID:FieldUtil<CrSendCouponRecordCU>;
    ACTION_TYPE:FieldUtil<CrSendCouponRecordCU>;
}

class CrSendCouponRecordCUImpl extends ConditionUtilImpl<CrSendCouponRecordCUImpl> implements CrSendCouponRecordCU{ 
    newInstance(): CrSendCouponRecordCUImpl {
        return new CrSendCouponRecordCUImpl();
    } 
    get UUID(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('uuid','uuid','', this);
    }
    get USER_ID(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('user_id','userId','', this);
    }
    get CCC_ID(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('ccc_id','cccId','', this);
    }
    get COUPON_INFO(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('coupon_info','couponInfo','', this);
    }
    get SEND_TIME(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('send_time','sendTime','', this);
    }
    get SEND_STATUS(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('send_status','sendStatus','', this);
    }
    get RETRY_TIMES(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('retry_times','retryTimes','', this);
    }
    get DEL_FLAG(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('del_flag','delFlag','', this);
    }
    get CREATE_TIME(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('create_time','createTime','', this);
    }
    get UPDATE_TIME(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('update_time','updateTime','', this);
    }
    get AD_INFO_ID(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('ad_info_id','adInfoId','', this);
    }
    get ACTION_TYPE(): FieldUtil<CrSendCouponRecordCU>{  
        return new FieldUtil('action_type','actionType','', this);
    }
}

@Singleton 
class CrSendCouponRecordMU extends TableUtilImpl<CrSendCouponRecordCU,CrSendCouponRecord>{ 
    tableName  = 'cr_send_coupon_record';
    tableFields  = ['uuid','user_id','ccc_id','coupon_info','send_time','send_status','retry_times','del_flag','create_time','update_time','ad_info_id','action_type'];
    modelFields  = ['uuid','userId','cccId','couponInfo','sendTime','sendStatus','retryTimes','delFlag','createTime','updateTime','adInfoId','actionType'];
    modelIdFields  = ['uuid'];
    tableIdFields  = ['uuid'];
    idType = IdType.CUSTOM;
    joinTables = [];
    subTables = [];

    createConditionUtil(): CrSendCouponRecordCU {
        return new CrSendCouponRecordCUImpl();
    }   

    static get UUID(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('uuid','uuid','', new CrSendCouponRecordCUImpl());
    }
    static get USER_ID(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('user_id','userId','', new CrSendCouponRecordCUImpl());
    }
    static get CCC_ID(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('ccc_id','cccId','', new CrSendCouponRecordCUImpl());
    }
    static get COUPON_INFO(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('coupon_info','couponInfo','', new CrSendCouponRecordCUImpl());
    }
    static get SEND_TIME(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('send_time','sendTime','', new CrSendCouponRecordCUImpl());
    }
    static get SEND_STATUS(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('send_status','sendStatus','', new CrSendCouponRecordCUImpl());
    }
    static get RETRY_TIMES(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('retry_times','retryTimes','', new CrSendCouponRecordCUImpl());
    }
    static get DEL_FLAG(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('del_flag','delFlag','', new CrSendCouponRecordCUImpl());
    }
    static get CREATE_TIME(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('create_time','createTime','', new CrSendCouponRecordCUImpl());
    }
    static get UPDATE_TIME(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('update_time','updateTime','', new CrSendCouponRecordCUImpl());
    }
    static get AD_INFO_ID(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('ad_info_id','adInfoId','', new CrSendCouponRecordCUImpl());
    }
    static get ACTION_TYPE(): FieldUtil<CrSendCouponRecordCU>{ 
        return new FieldUtil('action_type','actionType','', new CrSendCouponRecordCUImpl());
    }

    get UUID(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.UUID;
    }
    get USER_ID(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.USER_ID;
    }
    get CCC_ID(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.CCC_ID;
    }
    get COUPON_INFO(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.COUPON_INFO;
    }
    get SEND_TIME(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.SEND_TIME;
    }
    get SEND_STATUS(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.SEND_STATUS;
    }
    get RETRY_TIMES(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.RETRY_TIMES;
    }
    get DEL_FLAG(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.DEL_FLAG;
    }
    get CREATE_TIME(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.CREATE_TIME;
    }
    get UPDATE_TIME(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.UPDATE_TIME;
    }
    get AD_INFO_ID(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.AD_INFO_ID;
    }
    get ACTION_TYPE(): FieldUtil<CrSendCouponRecordCU>{ 
        return CrSendCouponRecordMU.ACTION_TYPE;
    }
}
export {CrSendCouponRecordMU, CrSendCouponRecordCU}
