admin/jqadm/src/Admin/JQAdm/Order/Standard.php
public function export()
	{
		$view = $this->getView();
		$context = $this->getContext();

		try
		{
			$params = $this->storeSearchParams( $view->param(), 'order' );
			$msg = ['sitecode' => $context->getLocale()->getSite()->getCode()];

			if( isset( $params['filter'] ) ) {
				$msg['filter'] = $this->getCriteriaConditions( $params['filter'] );
			}

			if( isset( $params['sort'] ) ) {
				$msg['sort'] = $this->getCriteriaSortations( $params['sort'] );
			}

			$mq = $context->getMessageQueueManager()->get( 'mq-admin' )->getQueue( 'order-export' );
			$mq->add( json_encode( $msg ) );

			$msg = $context->getI18n()->dt( 'admin', 'Your export will be available in a few minutes for download' );
			$view->info = $view->get( 'info', [] ) + ['order-item' => $msg];
		}
		catch( \Aimeos\MShop\Exception $e )
		{
			$error = array( 'order-item' => $context->getI18n()->dt( 'mshop', $e->getMessage() ) );
			$view->errors = $view->get( 'errors', [] ) + $error;
			$this->logException( $e );
		}
		catch( \Exception $e )
		{
			$error = array( 'order-item' => $e->getMessage() . ', ' . $e->getFile() . ':' . $e->getLine() );
			$view->errors = $view->get( 'errors', [] ) + $error;
			$this->logException( $e );
		}

		return $this->search();
	}
public function export()
	{
		$view = $this->getView();
		$context = $this->getContext();

		try
		{
			$params = $this->storeSearchParams( $view->param(), 'order' );
			$msg = ['sitecode' => $context->getLocale()->getSite()->getCode()];

			if( isset( $params['filter'] ) ) {
				$msg['filter'] = $this->getCriteriaConditions( $params['filter'] );
			}

			if( isset( $params['sort'] ) ) {
				$msg['sort'] = $this->getCriteriaSortations( $params['sort'] );
			}

			$mq = $context->getMessageQueueManager()->get( 'mq-admin' )->getQueue( 'order-export' );
			$mq->add( json_encode( $msg ) );

			$msg = $context->getI18n()->dt( 'admin', 'Your export will be available in a few minutes for download' );
			$view->info = $view->get( 'info', [] ) + ['order-item' => $msg];
		}
		catch( \Aimeos\MShop\Exception $e )
		{
			$error = array( 'order-item' => $context->getI18n()->dt( 'mshop', $e->getMessage() ) );
			$view->errors = $view->get( 'errors', [] ) + $error;
			$this->logException( $e );
		}
		catch( \Exception $e )
		{
			$error = array( 'order-item' => $e->getMessage() . ', ' . $e->getFile() . ':' . $e->getLine() );
			$view->errors = $view->get( 'errors', [] ) + $error;
			$this->logException( $e );
		}

		return $this->search();
	}
public function export ( ) { $ view = $ this -> getView ( ) ; $ context = $ this -> getContext ( ) ; try { $ params = $ this -> storeSearchParams ( $ view -> param ( ) , 'order' ) ; $ msg = [ 'sitecode' => $ context -> getLocale ( ) -> getSite ( ) -> getCode ( ) ] ; if ( isset ( $ params [ 'filter' ] ) ) { $ msg [ 'filter' ] = $ this -> getCriteriaConditions ( $ params [ 'filter' ] ) ; } if ( isset ( $ params [ 'sort' ] ) ) { $ msg [ 'sort' ] = $ this -> getCriteriaSortations ( $ params [ 'sort' ] ) ; } $ mq = $ context -> getMessageQueueManager ( ) -> get ( 'mq-admin' ) -> getQueue ( 'order-export' ) ; $ mq -> add ( json_encode ( $ msg ) ) ; $ msg = $ context -> getI18n ( ) -> dt ( 'admin' , 'Your export will be available in a few minutes for download' ) ; $ view -> info = $ view -> get ( 'info' , [ ] ) + [ 'order-item' => $ msg ] ; } catch ( \ Aimeos \ MShop \ Exception $ e ) { $ error = array ( 'order-item' => $ context -> getI18n ( ) -> dt ( 'mshop' , $ e -> getMessage ( ) ) ) ; $ view -> errors = $ view -> get ( 'errors' , [ ] ) + $ error ; $ this -> logException ( $ e ) ; } catch ( \ Exception $ e ) { $ error = array ( 'order-item' => $ e -> getMessage ( ) . ', ' . $ e -> getFile ( ) . ':' . $ e -> getLine ( ) ) ; $ view -> errors = $ view -> get ( 'errors' , [ ] ) + $ error ; $ this -> logException ( $ e ) ; } return $ this -> search ( ) ; }
Exports a resource

@return string Admin output to display
Exports a resource