コード例 #1
0
ファイル: Observer.php プロジェクト: shabbirvividads/magento2
 /**
  * Refresh sales shipment report statistics for last day
  *
  * @return $this
  */
 public function aggregateSalesReportShipmentData()
 {
     $this->_localeResolver->emulate(0);
     $currentDate = new \DateTime();
     $date = $currentDate->modify('-25 hours');
     $this->_shippingFactory->create()->aggregate($date);
     $this->_localeResolver->revert();
     return $this;
 }
コード例 #2
0
ファイル: Observer.php プロジェクト: aiesh/magento2
 /**
  * Refresh sales shipment report statistics for last day
  *
  * @return $this
  */
 public function aggregateSalesReportShipmentData()
 {
     $this->_localeResolver->emulate(0);
     $currentDate = $this->_coreLocale->date();
     $date = $currentDate->subHour(25);
     $this->_shippingFactory->create()->aggregate($date);
     $this->_localeResolver->revert();
     return $this;
 }