import { FieldInfo } from 'model-util-base'
import { ConditionUtil, ConditionUtilImpl, FieldUtil, TableUtilImpl, IdType, JoinTable, SubTable } from 'model-util'
import { Container, Singleton } from 'typescript-ioc' 
import { QuickExpendServer } from '../models/index' 
/**
 * @author auto generate
 * @version 1.0
 * @date 2021-06-01 15:23
 */
interface QuickExpendServerCU extends ConditionUtil<QuickExpendServerCU>{
    AREA_NAME:FieldUtil<QuickExpendServerCU>;
    ECS_TEMPLATE:FieldUtil<QuickExpendServerCU>;
    APP_TYPE:FieldUtil<QuickExpendServerCU>;
}

class QuickExpendServerCUImpl extends ConditionUtilImpl<QuickExpendServerCUImpl> implements QuickExpendServerCU{ 
    newInstance(): QuickExpendServerCUImpl {
        return new QuickExpendServerCUImpl();
    } 
    get AREA_NAME(): FieldUtil<QuickExpendServerCU>{  
        return new FieldUtil('area_name','areaName','', this);
    }
    get ECS_TEMPLATE(): FieldUtil<QuickExpendServerCU>{  
        return new FieldUtil('ecs_template','ecsTemplate','', this);
    }
    get APP_TYPE(): FieldUtil<QuickExpendServerCU>{  
        return new FieldUtil('app_type','appType','', this);
    }
}

@Singleton 
class QuickExpendServerMU extends TableUtilImpl<QuickExpendServerCU,QuickExpendServer>{ 
    tableName  = 'quick_expend_server';
    tableFields  = ['area_name','ecs_template','app_type'];
    modelFields  = ['areaName','ecsTemplate','appType'];
    modelIdFields  = [''];
    tableIdFields  = [''];
    idType = IdType.CUSTOM;
    joinTables = [];
    subTables = [];

    createConditionUtil(): QuickExpendServerCU {
        return new QuickExpendServerCUImpl();
    }   

    static get AREA_NAME(): FieldUtil<QuickExpendServerCU>{ 
        return new FieldUtil('area_name','areaName','', new QuickExpendServerCUImpl());
    }
    static get ECS_TEMPLATE(): FieldUtil<QuickExpendServerCU>{ 
        return new FieldUtil('ecs_template','ecsTemplate','', new QuickExpendServerCUImpl());
    }
    static get APP_TYPE(): FieldUtil<QuickExpendServerCU>{ 
        return new FieldUtil('app_type','appType','', new QuickExpendServerCUImpl());
    }

    get AREA_NAME(): FieldUtil<QuickExpendServerCU>{ 
        return QuickExpendServerMU.AREA_NAME;
    }
    get ECS_TEMPLATE(): FieldUtil<QuickExpendServerCU>{ 
        return QuickExpendServerMU.ECS_TEMPLATE;
    }
    get APP_TYPE(): FieldUtil<QuickExpendServerCU>{ 
        return QuickExpendServerMU.APP_TYPE;
    }
}
export {QuickExpendServerMU, QuickExpendServerCU}
