import { FieldInfo } from 'model-util-base'
import { ConditionUtil, ConditionUtilImpl, FieldUtil, TableUtilImpl, IdType, JoinTable, SubTable } from 'model-util'
import { Container, Singleton } from 'typescript-ioc' 
import { TapdReviewApp } from '../models/index' 
/**
 * @author auto generate
 * @version 1.0
 * @date 2021-08-17 17:55
 */
interface TapdReviewAppCU extends ConditionUtil<TapdReviewAppCU>{
    ID:FieldUtil<TapdReviewAppCU>;
    APP_NAME:FieldUtil<TapdReviewAppCU>;
    APP_TYPE:FieldUtil<TapdReviewAppCU>;
    VERSION:FieldUtil<TapdReviewAppCU>;
    DESCRIPTION:FieldUtil<TapdReviewAppCU>;
    TAPD_ID:FieldUtil<TapdReviewAppCU>;
}

class TapdReviewAppCUImpl extends ConditionUtilImpl<TapdReviewAppCUImpl> implements TapdReviewAppCU{ 
    newInstance(): TapdReviewAppCUImpl {
        return new TapdReviewAppCUImpl();
    } 
    get ID(): FieldUtil<TapdReviewAppCU>{  
        return new FieldUtil('id','id','', this);
    }
    get APP_NAME(): FieldUtil<TapdReviewAppCU>{  
        return new FieldUtil('app_name','appName','应用名称', this);
    }
    get APP_TYPE(): FieldUtil<TapdReviewAppCU>{  
        return new FieldUtil('app_type','appType','应用类型：0-deamon应用；1-web应用；2-前端；', this);
    }
    get VERSION(): FieldUtil<TapdReviewAppCU>{  
        return new FieldUtil('version','version','发布版本', this);
    }
    get DESCRIPTION(): FieldUtil<TapdReviewAppCU>{  
        return new FieldUtil('description','description','', this);
    }
    get TAPD_ID(): FieldUtil<TapdReviewAppCU>{  
        return new FieldUtil('tapd_id','tapdId','', this);
    }
}

@Singleton 
class TapdReviewAppMU extends TableUtilImpl<TapdReviewAppCU,TapdReviewApp>{ 
    tableName  = 'tapd_review_app';
    tableFields  = ['id','app_name','app_type','version','description','tapd_id'];
    modelFields  = ['id','appName','appType','version','description','tapdId'];
    modelIdFields  = ['id'];
    tableIdFields  = ['id'];
    idType = IdType.CUSTOM;
    joinTables = [];
    subTables = [];

    createConditionUtil(): TapdReviewAppCU {
        return new TapdReviewAppCUImpl();
    }   

    static get ID(): FieldUtil<TapdReviewAppCU>{ 
        return new FieldUtil('id','id','', new TapdReviewAppCUImpl());
    }
    static get APP_NAME(): FieldUtil<TapdReviewAppCU>{ 
        return new FieldUtil('app_name','appName','应用名称', new TapdReviewAppCUImpl());
    }
    static get APP_TYPE(): FieldUtil<TapdReviewAppCU>{ 
        return new FieldUtil('app_type','appType','应用类型：0-deamon应用；1-web应用；2-前端；', new TapdReviewAppCUImpl());
    }
    static get VERSION(): FieldUtil<TapdReviewAppCU>{ 
        return new FieldUtil('version','version','发布版本', new TapdReviewAppCUImpl());
    }
    static get DESCRIPTION(): FieldUtil<TapdReviewAppCU>{ 
        return new FieldUtil('description','description','', new TapdReviewAppCUImpl());
    }
    static get TAPD_ID(): FieldUtil<TapdReviewAppCU>{ 
        return new FieldUtil('tapd_id','tapdId','', new TapdReviewAppCUImpl());
    }

    get ID(): FieldUtil<TapdReviewAppCU>{ 
        return TapdReviewAppMU.ID;
    }
    get APP_NAME(): FieldUtil<TapdReviewAppCU>{ 
        return TapdReviewAppMU.APP_NAME;
    }
    get APP_TYPE(): FieldUtil<TapdReviewAppCU>{ 
        return TapdReviewAppMU.APP_TYPE;
    }
    get VERSION(): FieldUtil<TapdReviewAppCU>{ 
        return TapdReviewAppMU.VERSION;
    }
    get DESCRIPTION(): FieldUtil<TapdReviewAppCU>{ 
        return TapdReviewAppMU.DESCRIPTION;
    }
    get TAPD_ID(): FieldUtil<TapdReviewAppCU>{ 
        return TapdReviewAppMU.TAPD_ID;
    }
}
export {TapdReviewAppMU, TapdReviewAppCU}
