Example #1
0
 public function get($params)
 {
     $objMdlSeller = app::get('sysshop')->model('seller');
     $data = $objMdlSeller->getRow('*', ['seller_id' => $params['seller_id'], 'shop_id' => $params['shop_id']]);
     if ($data) {
         $data['login_account'] = shopAuth::getSellerName($params['seller_id']);
     }
     return $data;
 }
Example #2
0
 /**
  * @brief 审核页面
  *
  * @param $enterapplyId
  *
  * @return html
  */
 public function doExamine($enterapplyId)
 {
     $objMdlEnterapply = app::get('sysshop')->model('enterapply');
     $list = $objMdlEnterapply->getRow('*', array('enterapply_id' => $enterapplyId));
     $shop = unserialize($list['shop']);
     $checkBrand = array('shop_type' => $list['shop_type'], 'shop' => array('shop_brand' => $shop['shop_brand']));
     $list['seller_name'] = shopAuth::getSellerName($list['seller_id']);
     $list['shoptype'] = $this->shoptype[$list['shop_type']];
     $cat = app::get('sysshop')->rpcCall('category.cat.get.info', array('cat_id' => $shop['shop_cat']))[$shop['shop_cat']];
     if ($shop['shop_brand']) {
         $brand = app::get('sysshop')->rpcCall('category.brand.get.list', array('brand_id' => $shop['shop_brand']))[$shop['shop_brand']];
     }
     if ($list['new_brand']) {
         $brand = app::get('sysshop')->rpcCall('category.brand.get.list', array('brand_name' => $list['new_brand']));
         if ($brand) {
             $brand = reset($brand);
         }
     }
     try {
         $checkB = kernel::single('sysshop_data_enterapply')->checkBrand($checkBrand, $msg);
     } catch (\LogicException $e) {
         echo $brand['brand_name'] . $e->getMessage();
         exit;
     }
     if (!$checkB) {
         $pagedata['checkbrand'] = $msg;
     }
     $shop['brand_name'] = $brand['brand_name'];
     $shop['shop_cat'] = $cat['cat_name'];
     $shopinfo = unserialize($list['shop_info']);
     $shopinfo['corporate_identity_img'] = base_storager::modifier($shopinfo['corporate_identity_img'], 's');
     $shopinfo['tissue_code_img'] = base_storager::modifier($shopinfo['tissue_code_img'], 's');
     $shopinfo['tax_code_img'] = base_storager::modifier($shopinfo['tax_code_img'], 's');
     $shopinfo['shopuser_identity_img'] = base_storager::modifier($shopinfo['shopuser_identity_img'], 's');
     $shopinfo['license_img'] = base_storager::modifier($shopinfo['license_img'], 's');
     $shopinfo['brand_warranty'] = base_storager::modifier($shopinfo['brand_warranty'], 's');
     $pagedata['shop'] = $shop;
     $pagedata['shop_info'] = $shopinfo;
     $pagedata['itemdata'] = $list;
     return $this->page('sysshop/admin/enterapply/examine.html', $pagedata);
 }