$storesNameArr[$cityStore->adress_amo] = $cityStore->id;
}
+ $checkarr = Sales::find()->where(['>=', 'date', date('Y-m-d H:i:s', strtotime('-30 days', time()))])->limit(1750)->asArray()->all();
+ $sale = [];
+ $check_sale_cnt = [];
+ $check_vozvrat_cnt = [];
+
+ foreach($checkarr as $checkr) {
+ /* @var $checkr Sales */
+ if (!in_array($checkr["order_id"], $check_sale_cnt)) {
+ $check_sale_cnt[$checkr["order_id"]] = 0;
+ }
+ if (!in_array($checkr["order_id"], $check_vozvrat_cnt)) {
+ $check_vozvrat_cnt[$checkr["order_id"]] = 0;
+ }
+ if (!in_array($checkr["order_id"], $sale)) {
+ $sale[$checkr["order_id"]] = '';
+ }
+ }
return $this->controller->render('delivery', compact('yesses', 'lid_id', 'delivery_date', 'status_ar2'));
}