<?php
/**
* Created by PhpStorm.
* User: kang
* Date: 2021/3/15
* Time: 14:05
*/
namespace JinDouYun\Controller\Oem;

use Mall\Framework\Core\ErrorCode;
use Mall\Framework\Core\StatusCode;

use JinDouYun\Controller\BaseController;

use JinDouYun\Model\Oem\MOem;

class Oem extends BaseController
{
    private $objMOem;
    
    public function __construct($isCheckAcl = true, $isMustLogin = true)
    {
        parent::__construct($isCheckAcl, $isMustLogin);
        
        $this->objMOem = new MOem($this->onlineEnterpriseId, $this->onlineUserId);
    }
    
    /**
     * 获取指定logo贴标
     */
    public function getOemInfo()
    {
        $oemId  = $this->request->param('request_id');
        if ( !$oemId ) {
            $this->sendOutput('参数错误', ErrorCode::$paramError );
        }
        $result = $this->objMOem->getOemInfo($oemId);
        if($result->isSuccess()){
            $this->sendOutput($result->getData());
        }else{
            $this->sendOutput($result->getData(), $result->getErrorCode());
        }
    }
}