shish 6 lat temu
rodzic
commit
2d6fe1e0ce

+ 7 - 0
app/business/controllers/MerchantController.php

@@ -57,4 +57,11 @@ class MerchantController extends BaseController
 		util::ok('提交成功');
 	}
 
+	//常用链接
+	public function actionCommonUrl()
+	{
+		$list = MerchantService::getCommonUrl();
+		util::success($list);
+	}
+
 }

+ 8 - 4
biz/merchant/classes/MerchantClass.php

@@ -8,9 +8,13 @@ use biz\base\classes\BaseClass;
 class MerchantClass extends BaseClass
 {
 	
-	//merchant敏感字段,一般情况过渡不输出
-	public static $sensitive = [];
-	
 	public static $baseFile = '\biz\merchant\models\Merchant';
-	
+
+	//常用链接
+	public static $commonUrl = [
+		['id' => 0, 'url' => '/mall/index?account=12358', 'sign' => 'mall', 'name' => '商城'],
+		['id' => 1, 'url' => '/mall/index?account=12358', 'sign' => 'mall', 'name' => '申请会员'],
+		['id' => 2, 'url' => '/mall/index?account=12358', 'sign' => 'mall', 'name' => '点我付款'],
+	];
+
 }

+ 11 - 3
biz/merchant/services/MerchantService.php

@@ -4,6 +4,7 @@ namespace biz\merchant\services;
 
 use biz\auth\services\AuthService;
 use biz\base\services\BaseService;
+use biz\merchant\classes\MerchantClass;
 use biz\saas\services\SetAuthService;
 use Yii;
 
@@ -52,15 +53,22 @@ class MerchantService extends BaseService
 		foreach ($deleteExtend as $delExtend) {
 			unset($extend[$delExtend]);
 		}
-
+		
 		//设置计算方式
 		$freight = $extend['freight'];
 		$freightList = explode('_', $freight);
 		$extend['freightFirst'] = isset($freightList[0]) && is_numeric($freightList[0]) ? $freightList[0] : 5;
 		$extend['freightAdd'] = isset($freightList[1]) && is_numeric($freightList[1]) ? $freightList[1] : 2;
-
+		
 		$merchant['extend'] = $extend;
 		return $merchant;
 	}
-	
+
+	//常用链接 shish 2019.12.19
+	public static function getCommonUrl()
+	{
+		$list = MerchantClass::$commonUrl;
+		return $list;
+	}
+
 }