import { Http,Util,Errorlog } from '@/utils';
import ControlService from '@/widgets/control-service';
import SecurityMainMenuModel from './security-main-menu-appmenu-model';


/**
 * SecurityMainMenu 部件服务对象
 *
 * @export
 * @class SecurityMainMenuService
 */
export default class SecurityMainMenuService extends ControlService {

    /**
     * 设置从数据模式
     *
     * @type {boolean}
     * @memberof SecurityMainMenuService
     */
    public setTempMode(){
        this.isTempMode = false;
    }

    /**
     * Creates an instance of SecurityMainMenuService.
     * 
     * @param {*} [opts={}]
     * @memberof SecurityMainMenuService
     */
    constructor(opts: any = {}) {
        super(opts);
        this.model = new SecurityMainMenuModel();
    }

    /**
     * 获取数据
     *
     * @returns {Promise<any>}
     * @memberof SecurityMainMenu
     */
    @Errorlog
    public get(params: any = {}): Promise<any> {
        return Http.getInstance().get('v7/security-main-menuappmenu', params);
    }

}