修改香港澳门台湾快递定价

This commit is contained in:
wangjinlei
2026-04-20 15:33:59 +08:00
parent d2a6c3ff30
commit f1fad67f76

View File

@@ -3,6 +3,7 @@
namespace app\api\controller;
use think\Db;
use think\Validate;
class PromotionFactory extends Base
{
@@ -132,6 +133,23 @@ class PromotionFactory extends Base
return jsonSuccess(['promotion_factory_id' => $id]);
}
public function getCountForPromotionEmailIds(){
$data = $this->request->post();
$rule = new Validate([
"ids"=>"require"
]);
if(!$rule->check($data)){
return jsonError($rule->getError());
}
$ids = explode(",",$data["ids"]);
$emails = Db::name("journal_email")->whereIn("j_email_id",$ids)->select();
$count = 0;
foreach ($emails as $item){
$count += $item["daily_limit"];
}
return jsonSuccess(['limit_count'=>$count]);
}
/**
* 编辑工厂
*/