import { FieldInfo } from 'model-util-base'
import { ConditionUtil, ConditionUtilImpl, FieldUtil, TableUtilImpl, IdType, JoinTable, SubTable } from 'model-util'
import { Container, Singleton } from 'typescript-ioc' 
import { PayAccount } from '../models/index' 
/**
 * @author auto generate
 * @version 1.0
 * @date 2020-10-16 11:27
 */
interface PayAccountCU extends ConditionUtil<PayAccountCU>{
    ID:FieldUtil<PayAccountCU>;
    CODE:FieldUtil<PayAccountCU>;
    NAME:FieldUtil<PayAccountCU>;
    ACT_TYPE:FieldUtil<PayAccountCU>;
    PAY_METHOD:FieldUtil<PayAccountCU>;
    ACT_CONFIG:FieldUtil<PayAccountCU>;
    REMARK:FieldUtil<PayAccountCU>;
    STATE:FieldUtil<PayAccountCU>;
    CREATE_TIME:FieldUtil<PayAccountCU>;
    UPDATE_TIME:FieldUtil<PayAccountCU>;
    CURRENCY_CODE:FieldUtil<PayAccountCU>;
    LOGO_URL:FieldUtil<PayAccountCU>;
}

class PayAccountCUImpl extends ConditionUtilImpl<PayAccountCUImpl> implements PayAccountCU{ 
    newInstance(): PayAccountCUImpl {
        return new PayAccountCUImpl();
    } 
    get ID(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('ID','id','', this);
    }
    get CODE(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('CODE','code','账户代码', this);
    }
    get NAME(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('NAME','name','账户名称', this);
    }
    get ACT_TYPE(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('ACT_TYPE','actType','支付账户类型：10:境外第三方支付', this);
    }
    get PAY_METHOD(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('PAY_METHOD','payMethod','支付方式：101:信用卡支付', this);
    }
    get ACT_CONFIG(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('ACT_CONFIG','actConfig','账户配置信息-JSON', this);
    }
    get REMARK(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('REMARK','remark','备注', this);
    }
    get STATE(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('STATE','state','状态：0-正常，1-删除', this);
    }
    get CREATE_TIME(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('CREATE_TIME','createTime','创建时间', this);
    }
    get UPDATE_TIME(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('UPDATE_TIME','updateTime','更新时间', this);
    }
    get CURRENCY_CODE(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('CURRENCY_CODE','currencyCode','交易币种', this);
    }
    get LOGO_URL(): FieldUtil<PayAccountCU>{  
        return new FieldUtil('LOGO_URL','logoUrl','图标url', this);
    }
}

@Singleton 
class PayAccountMU extends TableUtilImpl<PayAccountCU,PayAccount>{ 
    tableName  = 'pay_account';
    tableFields  = ['id','code','name','act_type','pay_method','act_config','remark','state','create_time','update_time','currency_code','logo_url'];
    modelFields  = ['id','code','name','actType','payMethod','actConfig','remark','state','createTime','updateTime','currencyCode','logoUrl'];
    modelIdFields  = ['id'];
    tableIdFields  = ['id'];
    idType = IdType.CUSTOM;
    joinTables = [];
    subTables = [];

    createConditionUtil(): PayAccountCU {
        return new PayAccountCUImpl();
    }   

    static get ID(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('ID','id','', new PayAccountCUImpl());
    }
    static get CODE(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('CODE','code','账户代码', new PayAccountCUImpl());
    }
    static get NAME(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('NAME','name','账户名称', new PayAccountCUImpl());
    }
    static get ACT_TYPE(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('ACT_TYPE','actType','支付账户类型：10:境外第三方支付', new PayAccountCUImpl());
    }
    static get PAY_METHOD(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('PAY_METHOD','payMethod','支付方式：101:信用卡支付', new PayAccountCUImpl());
    }
    static get ACT_CONFIG(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('ACT_CONFIG','actConfig','账户配置信息-JSON', new PayAccountCUImpl());
    }
    static get REMARK(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('REMARK','remark','备注', new PayAccountCUImpl());
    }
    static get STATE(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('STATE','state','状态：0-正常，1-删除', new PayAccountCUImpl());
    }
    static get CREATE_TIME(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('CREATE_TIME','createTime','创建时间', new PayAccountCUImpl());
    }
    static get UPDATE_TIME(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('UPDATE_TIME','updateTime','更新时间', new PayAccountCUImpl());
    }
    static get CURRENCY_CODE(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('CURRENCY_CODE','currencyCode','交易币种', new PayAccountCUImpl());
    }
    static get LOGO_URL(): FieldUtil<PayAccountCU>{ 
        return new FieldUtil('LOGO_URL','logoUrl','图标url', new PayAccountCUImpl());
    }

    get ID(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.ID;
    }
    get CODE(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.CODE;
    }
    get NAME(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.NAME;
    }
    get ACT_TYPE(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.ACT_TYPE;
    }
    get PAY_METHOD(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.PAY_METHOD;
    }
    get ACT_CONFIG(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.ACT_CONFIG;
    }
    get REMARK(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.REMARK;
    }
    get STATE(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.STATE;
    }
    get CREATE_TIME(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.CREATE_TIME;
    }
    get UPDATE_TIME(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.UPDATE_TIME;
    }
    get CURRENCY_CODE(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.CURRENCY_CODE;
    }
    get LOGO_URL(): FieldUtil<PayAccountCU>{ 
        return PayAccountMU.LOGO_URL;
    }
}
export {PayAccountMU, PayAccountCU}
