@@ -6,12 +6,12 @@ |
||
6 | 6 | */ |
7 | 7 | |
8 | 8 | ?> |
9 | -<?php $this->block()->start( 'jqadm_content' ); ?> |
|
9 | +<?php $this->block()->start('jqadm_content'); ?> |
|
10 | 10 | |
11 | 11 | <div class="dashboard"> |
12 | -<?php echo $this->get( 'listBody' ); ?> |
|
12 | +<?php echo $this->get('listBody'); ?> |
|
13 | 13 | </div> |
14 | 14 | |
15 | 15 | <?php $this->block()->stop(); ?> |
16 | 16 | |
17 | -<?php echo $this->render( $this->config( 'admin/jqadm/template/page', 'common/page-default.php' ) ); ?> |
|
17 | +<?php echo $this->render($this->config('admin/jqadm/template/page', 'common/page-default.php')); ?> |
@@ -9,5 +9,5 @@ |
||
9 | 9 | |
10 | 10 | ?> |
11 | 11 | <div class="dashboard-order"> |
12 | -<?php echo $this->get( 'orderBody' ); ?> |
|
12 | +<?php echo $this->get('orderBody'); ?> |
|
13 | 13 | </div> |
@@ -11,9 +11,9 @@ |
||
11 | 11 | |
12 | 12 | <div class="order-paymentstatus card panel panel-small"> |
13 | 13 | <div id="order-paymentstatus-head" class="header card-header"> |
14 | - <?php echo $enc->html( $this->translate( 'admin', 'Orders by payment status' ) ); ?> |
|
14 | + <?php echo $enc->html($this->translate('admin', 'Orders by payment status')); ?> |
|
15 | 15 | </div> |
16 | 16 | <div id="order-paymentstatus-data" class="content card-block"> |
17 | 17 | </div> |
18 | 18 | </div> |
19 | -<?php echo $this->get( 'orderpaymentstatusBody' ); ?> |
|
19 | +<?php echo $this->get('orderpaymentstatusBody'); ?> |
@@ -19,42 +19,42 @@ |
||
19 | 19 | { |
20 | 20 | $this->templatePaths = \TestHelperJqadm::getTemplatePaths(); |
21 | 21 | $this->context = \TestHelperJqadm::getContext(); |
22 | - $this->context->setView( \TestHelperJqadm::getView() ); |
|
22 | + $this->context->setView(\TestHelperJqadm::getView()); |
|
23 | 23 | } |
24 | 24 | |
25 | 25 | |
26 | 26 | public function testCreateClient() |
27 | 27 | { |
28 | - $client = \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient( $this->context, $this->templatePaths ); |
|
29 | - $this->assertInstanceOf( '\\Aimeos\\Admin\\JQAdm\\Iface', $client ); |
|
28 | + $client = \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient($this->context, $this->templatePaths); |
|
29 | + $this->assertInstanceOf('\\Aimeos\\Admin\\JQAdm\\Iface', $client); |
|
30 | 30 | } |
31 | 31 | |
32 | 32 | |
33 | 33 | public function testCreateClientName() |
34 | 34 | { |
35 | - $client = \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient( $this->context, $this->templatePaths, 'Standard' ); |
|
36 | - $this->assertInstanceOf( '\\Aimeos\\Admin\\JQAdm\\Iface', $client ); |
|
35 | + $client = \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient($this->context, $this->templatePaths, 'Standard'); |
|
36 | + $this->assertInstanceOf('\\Aimeos\\Admin\\JQAdm\\Iface', $client); |
|
37 | 37 | } |
38 | 38 | |
39 | 39 | |
40 | 40 | public function testCreateClientNameEmpty() |
41 | 41 | { |
42 | - $this->setExpectedException( '\\Aimeos\\Admin\\JQAdm\\Exception' ); |
|
43 | - \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient( $this->context, $this->templatePaths, '' ); |
|
42 | + $this->setExpectedException('\\Aimeos\\Admin\\JQAdm\\Exception'); |
|
43 | + \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient($this->context, $this->templatePaths, ''); |
|
44 | 44 | } |
45 | 45 | |
46 | 46 | |
47 | 47 | public function testCreateClientNameInvalid() |
48 | 48 | { |
49 | - $this->setExpectedException( '\\Aimeos\\Admin\\JQAdm\\Exception' ); |
|
50 | - \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient( $this->context, $this->templatePaths, '%dash' ); |
|
49 | + $this->setExpectedException('\\Aimeos\\Admin\\JQAdm\\Exception'); |
|
50 | + \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient($this->context, $this->templatePaths, '%dash'); |
|
51 | 51 | } |
52 | 52 | |
53 | 53 | |
54 | 54 | public function testCreateClientNameNotFound() |
55 | 55 | { |
56 | - $this->setExpectedException( '\\Aimeos\\Admin\\JQAdm\\Exception' ); |
|
57 | - \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient( $this->context, $this->templatePaths, 'test' ); |
|
56 | + $this->setExpectedException('\\Aimeos\\Admin\\JQAdm\\Exception'); |
|
57 | + \Aimeos\Admin\JQAdm\Dashboard\Factory::createClient($this->context, $this->templatePaths, 'test'); |
|
58 | 58 | } |
59 | 59 | |
60 | 60 | } |
@@ -22,48 +22,48 @@ discard block |
||
22 | 22 | $this->context = \TestHelperJqadm::getContext(); |
23 | 23 | $templatePaths = \TestHelperJqadm::getTemplatePaths(); |
24 | 24 | |
25 | - $this->object = new \Aimeos\Admin\JQAdm\Dashboard\Order\Standard( $this->context, $templatePaths ); |
|
26 | - $this->object->setView( $this->view ); |
|
25 | + $this->object = new \Aimeos\Admin\JQAdm\Dashboard\Order\Standard($this->context, $templatePaths); |
|
26 | + $this->object->setView($this->view); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | |
30 | 30 | protected function tearDown() |
31 | 31 | { |
32 | - unset( $this->object ); |
|
32 | + unset($this->object); |
|
33 | 33 | } |
34 | 34 | |
35 | 35 | |
36 | 36 | public function testCreate() |
37 | 37 | { |
38 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
38 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
39 | 39 | $this->object->create(); |
40 | 40 | } |
41 | 41 | |
42 | 42 | |
43 | 43 | public function testCopy() |
44 | 44 | { |
45 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
45 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
46 | 46 | $this->object->copy(); |
47 | 47 | } |
48 | 48 | |
49 | 49 | |
50 | 50 | public function testDelete() |
51 | 51 | { |
52 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
52 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
53 | 53 | $this->object->delete(); |
54 | 54 | } |
55 | 55 | |
56 | 56 | |
57 | 57 | public function testGet() |
58 | 58 | { |
59 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
59 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
60 | 60 | $this->object->get(); |
61 | 61 | } |
62 | 62 | |
63 | 63 | |
64 | 64 | public function testSave() |
65 | 65 | { |
66 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
66 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
67 | 67 | $this->object->save(); |
68 | 68 | } |
69 | 69 | |
@@ -72,13 +72,13 @@ discard block |
||
72 | 72 | { |
73 | 73 | $result = $this->object->search(); |
74 | 74 | |
75 | - $this->assertContains( '<div class="dashboard-order">', $result ); |
|
75 | + $this->assertContains('<div class="dashboard-order">', $result); |
|
76 | 76 | } |
77 | 77 | |
78 | 78 | |
79 | 79 | public function testGetSubClient() |
80 | 80 | { |
81 | - $result = $this->object->getSubClient( 'paymentstatus' ); |
|
82 | - $this->assertInstanceOf( '\Aimeos\Admin\JQAdm\Iface', $result ); |
|
81 | + $result = $this->object->getSubClient('paymentstatus'); |
|
82 | + $this->assertInstanceOf('\Aimeos\Admin\JQAdm\Iface', $result); |
|
83 | 83 | } |
84 | 84 | } |
@@ -22,48 +22,48 @@ discard block |
||
22 | 22 | $this->context = \TestHelperJqadm::getContext(); |
23 | 23 | $templatePaths = \TestHelperJqadm::getTemplatePaths(); |
24 | 24 | |
25 | - $this->object = new \Aimeos\Admin\JQAdm\Dashboard\Order\Paymentstatus\Standard( $this->context, $templatePaths ); |
|
26 | - $this->object->setView( $this->view ); |
|
25 | + $this->object = new \Aimeos\Admin\JQAdm\Dashboard\Order\Paymentstatus\Standard($this->context, $templatePaths); |
|
26 | + $this->object->setView($this->view); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | |
30 | 30 | protected function tearDown() |
31 | 31 | { |
32 | - unset( $this->object ); |
|
32 | + unset($this->object); |
|
33 | 33 | } |
34 | 34 | |
35 | 35 | |
36 | 36 | public function testCreate() |
37 | 37 | { |
38 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
38 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
39 | 39 | $this->object->create(); |
40 | 40 | } |
41 | 41 | |
42 | 42 | |
43 | 43 | public function testCopy() |
44 | 44 | { |
45 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
45 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
46 | 46 | $this->object->copy(); |
47 | 47 | } |
48 | 48 | |
49 | 49 | |
50 | 50 | public function testDelete() |
51 | 51 | { |
52 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
52 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
53 | 53 | $this->object->delete(); |
54 | 54 | } |
55 | 55 | |
56 | 56 | |
57 | 57 | public function testGet() |
58 | 58 | { |
59 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
59 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
60 | 60 | $this->object->get(); |
61 | 61 | } |
62 | 62 | |
63 | 63 | |
64 | 64 | public function testSave() |
65 | 65 | { |
66 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
66 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
67 | 67 | $this->object->save(); |
68 | 68 | } |
69 | 69 | |
@@ -72,21 +72,21 @@ discard block |
||
72 | 72 | { |
73 | 73 | $result = $this->object->search(); |
74 | 74 | |
75 | - $this->assertContains( '<div class="order-paymentstatus', $result ); |
|
75 | + $this->assertContains('<div class="order-paymentstatus', $result); |
|
76 | 76 | } |
77 | 77 | |
78 | 78 | |
79 | 79 | public function testSearchException() |
80 | 80 | { |
81 | - $object = $this->getMockBuilder( '\Aimeos\Admin\JQAdm\Dashboard\Standard' ) |
|
82 | - ->setConstructorArgs( array( $this->context, \TestHelperJqadm::getTemplatePaths() ) ) |
|
83 | - ->setMethods( array( 'getSubClients' ) ) |
|
81 | + $object = $this->getMockBuilder('\Aimeos\Admin\JQAdm\Dashboard\Standard') |
|
82 | + ->setConstructorArgs(array($this->context, \TestHelperJqadm::getTemplatePaths())) |
|
83 | + ->setMethods(array('getSubClients')) |
|
84 | 84 | ->getMock(); |
85 | 85 | |
86 | - $object->expects( $this->once() )->method( 'getSubClients' ) |
|
87 | - ->will( $this->throwException( new \Exception() ) ); |
|
86 | + $object->expects($this->once())->method('getSubClients') |
|
87 | + ->will($this->throwException(new \Exception())); |
|
88 | 88 | |
89 | - $object->setView( $this->getViewNoRender() ); |
|
89 | + $object->setView($this->getViewNoRender()); |
|
90 | 90 | |
91 | 91 | $object->search(); |
92 | 92 | } |
@@ -94,15 +94,15 @@ discard block |
||
94 | 94 | |
95 | 95 | public function testSearchMShopException() |
96 | 96 | { |
97 | - $object = $this->getMockBuilder( '\Aimeos\Admin\JQAdm\Dashboard\Standard' ) |
|
98 | - ->setConstructorArgs( array( $this->context, \TestHelperJqadm::getTemplatePaths() ) ) |
|
99 | - ->setMethods( array( 'getSubClients' ) ) |
|
97 | + $object = $this->getMockBuilder('\Aimeos\Admin\JQAdm\Dashboard\Standard') |
|
98 | + ->setConstructorArgs(array($this->context, \TestHelperJqadm::getTemplatePaths())) |
|
99 | + ->setMethods(array('getSubClients')) |
|
100 | 100 | ->getMock(); |
101 | 101 | |
102 | - $object->expects( $this->once() )->method( 'getSubClients' ) |
|
103 | - ->will( $this->throwException( new \Aimeos\MShop\Exception() ) ); |
|
102 | + $object->expects($this->once())->method('getSubClients') |
|
103 | + ->will($this->throwException(new \Aimeos\MShop\Exception())); |
|
104 | 104 | |
105 | - $object->setView( $this->getViewNoRender() ); |
|
105 | + $object->setView($this->getViewNoRender()); |
|
106 | 106 | |
107 | 107 | $object->search(); |
108 | 108 | } |
@@ -110,16 +110,16 @@ discard block |
||
110 | 110 | |
111 | 111 | public function testGetSubClient() |
112 | 112 | { |
113 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
114 | - $this->object->getSubClient( 'invalid' ); |
|
113 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
114 | + $this->object->getSubClient('invalid'); |
|
115 | 115 | } |
116 | 116 | |
117 | 117 | |
118 | 118 | protected function getViewNoRender() |
119 | 119 | { |
120 | - return $this->getMockBuilder( '\Aimeos\MW\View\Standard' ) |
|
121 | - ->setConstructorArgs( array( array() ) ) |
|
122 | - ->setMethods( array( 'render', 'config' ) ) |
|
120 | + return $this->getMockBuilder('\Aimeos\MW\View\Standard') |
|
121 | + ->setConstructorArgs(array(array())) |
|
122 | + ->setMethods(array('render', 'config')) |
|
123 | 123 | ->getMock(); |
124 | 124 | } |
125 | 125 | } |
@@ -22,48 +22,48 @@ discard block |
||
22 | 22 | $this->context = \TestHelperJqadm::getContext(); |
23 | 23 | $templatePaths = \TestHelperJqadm::getTemplatePaths(); |
24 | 24 | |
25 | - $this->object = new \Aimeos\Admin\JQAdm\Dashboard\Order\Latest\Standard( $this->context, $templatePaths ); |
|
26 | - $this->object->setView( $this->view ); |
|
25 | + $this->object = new \Aimeos\Admin\JQAdm\Dashboard\Order\Latest\Standard($this->context, $templatePaths); |
|
26 | + $this->object->setView($this->view); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | |
30 | 30 | protected function tearDown() |
31 | 31 | { |
32 | - unset( $this->object ); |
|
32 | + unset($this->object); |
|
33 | 33 | } |
34 | 34 | |
35 | 35 | |
36 | 36 | public function testCreate() |
37 | 37 | { |
38 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
38 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
39 | 39 | $this->object->create(); |
40 | 40 | } |
41 | 41 | |
42 | 42 | |
43 | 43 | public function testCopy() |
44 | 44 | { |
45 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
45 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
46 | 46 | $this->object->copy(); |
47 | 47 | } |
48 | 48 | |
49 | 49 | |
50 | 50 | public function testDelete() |
51 | 51 | { |
52 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
52 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
53 | 53 | $this->object->delete(); |
54 | 54 | } |
55 | 55 | |
56 | 56 | |
57 | 57 | public function testGet() |
58 | 58 | { |
59 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
59 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
60 | 60 | $this->object->get(); |
61 | 61 | } |
62 | 62 | |
63 | 63 | |
64 | 64 | public function testSave() |
65 | 65 | { |
66 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
66 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
67 | 67 | $this->object->save(); |
68 | 68 | } |
69 | 69 | |
@@ -72,21 +72,21 @@ discard block |
||
72 | 72 | { |
73 | 73 | $result = $this->object->search(); |
74 | 74 | |
75 | - $this->assertContains( '<div class="order-latest', $result ); |
|
75 | + $this->assertContains('<div class="order-latest', $result); |
|
76 | 76 | } |
77 | 77 | |
78 | 78 | |
79 | 79 | public function testSearchException() |
80 | 80 | { |
81 | - $object = $this->getMockBuilder( '\Aimeos\Admin\JQAdm\Dashboard\Standard' ) |
|
82 | - ->setConstructorArgs( array( $this->context, \TestHelperJqadm::getTemplatePaths() ) ) |
|
83 | - ->setMethods( array( 'getSubClients' ) ) |
|
81 | + $object = $this->getMockBuilder('\Aimeos\Admin\JQAdm\Dashboard\Standard') |
|
82 | + ->setConstructorArgs(array($this->context, \TestHelperJqadm::getTemplatePaths())) |
|
83 | + ->setMethods(array('getSubClients')) |
|
84 | 84 | ->getMock(); |
85 | 85 | |
86 | - $object->expects( $this->once() )->method( 'getSubClients' ) |
|
87 | - ->will( $this->throwException( new \Exception() ) ); |
|
86 | + $object->expects($this->once())->method('getSubClients') |
|
87 | + ->will($this->throwException(new \Exception())); |
|
88 | 88 | |
89 | - $object->setView( $this->getViewNoRender() ); |
|
89 | + $object->setView($this->getViewNoRender()); |
|
90 | 90 | |
91 | 91 | $object->search(); |
92 | 92 | } |
@@ -94,15 +94,15 @@ discard block |
||
94 | 94 | |
95 | 95 | public function testSearchMShopException() |
96 | 96 | { |
97 | - $object = $this->getMockBuilder( '\Aimeos\Admin\JQAdm\Dashboard\Standard' ) |
|
98 | - ->setConstructorArgs( array( $this->context, \TestHelperJqadm::getTemplatePaths() ) ) |
|
99 | - ->setMethods( array( 'getSubClients' ) ) |
|
97 | + $object = $this->getMockBuilder('\Aimeos\Admin\JQAdm\Dashboard\Standard') |
|
98 | + ->setConstructorArgs(array($this->context, \TestHelperJqadm::getTemplatePaths())) |
|
99 | + ->setMethods(array('getSubClients')) |
|
100 | 100 | ->getMock(); |
101 | 101 | |
102 | - $object->expects( $this->once() )->method( 'getSubClients' ) |
|
103 | - ->will( $this->throwException( new \Aimeos\MShop\Exception() ) ); |
|
102 | + $object->expects($this->once())->method('getSubClients') |
|
103 | + ->will($this->throwException(new \Aimeos\MShop\Exception())); |
|
104 | 104 | |
105 | - $object->setView( $this->getViewNoRender() ); |
|
105 | + $object->setView($this->getViewNoRender()); |
|
106 | 106 | |
107 | 107 | $object->search(); |
108 | 108 | } |
@@ -110,16 +110,16 @@ discard block |
||
110 | 110 | |
111 | 111 | public function testGetSubClient() |
112 | 112 | { |
113 | - $this->setExpectedException( '\Aimeos\Admin\JQAdm\Exception' ); |
|
114 | - $this->object->getSubClient( 'invalid' ); |
|
113 | + $this->setExpectedException('\Aimeos\Admin\JQAdm\Exception'); |
|
114 | + $this->object->getSubClient('invalid'); |
|
115 | 115 | } |
116 | 116 | |
117 | 117 | |
118 | 118 | protected function getViewNoRender() |
119 | 119 | { |
120 | - return $this->getMockBuilder( '\Aimeos\MW\View\Standard' ) |
|
121 | - ->setConstructorArgs( array( array() ) ) |
|
122 | - ->setMethods( array( 'render', 'config' ) ) |
|
120 | + return $this->getMockBuilder('\Aimeos\MW\View\Standard') |
|
121 | + ->setConstructorArgs(array(array())) |
|
122 | + ->setMethods(array('render', 'config')) |
|
123 | 123 | ->getMock(); |
124 | 124 | } |
125 | 125 | } |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | * @category Developer |
56 | 56 | */ |
57 | 57 | private $subPartPath = 'admin/jqadm/dashboard/standard/subparts'; |
58 | - private $subPartNames = array( 'order' ); |
|
58 | + private $subPartNames = array('order'); |
|
59 | 59 | |
60 | 60 | |
61 | 61 | /** |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | public function copy() |
67 | 67 | { |
68 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be copied' ); |
|
68 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be copied'); |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | */ |
77 | 77 | public function create() |
78 | 78 | { |
79 | - throw new \Aimeos\Admin\JQAdm\Exception( 'New resources can not be created' ); |
|
79 | + throw new \Aimeos\Admin\JQAdm\Exception('New resources can not be created'); |
|
80 | 80 | } |
81 | 81 | |
82 | 82 | |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | */ |
88 | 88 | public function delete() |
89 | 89 | { |
90 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be deleted' ); |
|
90 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be deleted'); |
|
91 | 91 | } |
92 | 92 | |
93 | 93 | |
@@ -98,7 +98,7 @@ discard block |
||
98 | 98 | */ |
99 | 99 | public function get() |
100 | 100 | { |
101 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be retrieved' ); |
|
101 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be retrieved'); |
|
102 | 102 | } |
103 | 103 | |
104 | 104 | |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | */ |
110 | 110 | public function save() |
111 | 111 | { |
112 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be modified' ); |
|
112 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be modified'); |
|
113 | 113 | } |
114 | 114 | |
115 | 115 | |
@@ -127,25 +127,25 @@ discard block |
||
127 | 127 | { |
128 | 128 | $view->listBody = ''; |
129 | 129 | |
130 | - foreach( $this->getSubClients() as $client ) { |
|
130 | + foreach ($this->getSubClients() as $client) { |
|
131 | 131 | $view->listBody .= $client->search(); |
132 | 132 | } |
133 | 133 | } |
134 | - catch( \Aimeos\MShop\Exception $e ) |
|
134 | + catch (\Aimeos\MShop\Exception $e) |
|
135 | 135 | { |
136 | - $error = array( 'dashboard' => $context->getI18n()->dt( 'mshop', $e->getMessage() ) ); |
|
137 | - $view->errors = $view->get( 'errors', array() ) + $error; |
|
136 | + $error = array('dashboard' => $context->getI18n()->dt('mshop', $e->getMessage())); |
|
137 | + $view->errors = $view->get('errors', array()) + $error; |
|
138 | 138 | } |
139 | - catch( \Exception $e ) |
|
139 | + catch (\Exception $e) |
|
140 | 140 | { |
141 | - $error = array( 'dashboard' => $e->getMessage() ); |
|
142 | - $view->errors = $view->get( 'errors', array() ) + $error; |
|
141 | + $error = array('dashboard' => $e->getMessage()); |
|
142 | + $view->errors = $view->get('errors', array()) + $error; |
|
143 | 143 | } |
144 | 144 | |
145 | 145 | $tplconf = 'admin/jqadm/dashboard/template-list'; |
146 | 146 | $default = 'dashboard/list-default.php'; |
147 | 147 | |
148 | - return $view->render( $view->config( $tplconf, $default ) ); |
|
148 | + return $view->render($view->config($tplconf, $default)); |
|
149 | 149 | } |
150 | 150 | |
151 | 151 | |
@@ -156,7 +156,7 @@ discard block |
||
156 | 156 | * @param string|null $name Name of the sub-client (Default if null) |
157 | 157 | * @return \Aimeos\Admin\JQAdm\Iface Sub-client object |
158 | 158 | */ |
159 | - public function getSubClient( $type, $name = null ) |
|
159 | + public function getSubClient($type, $name = null) |
|
160 | 160 | { |
161 | 161 | /** admin/jqadm/dashboard/decorators/excludes |
162 | 162 | * Excludes decorators added by the "common" option from the dashboard JQAdm client |
@@ -231,7 +231,7 @@ discard block |
||
231 | 231 | * @see admin/jqadm/dashboard/decorators/excludes |
232 | 232 | * @see admin/jqadm/dashboard/decorators/global |
233 | 233 | */ |
234 | - return $this->createSubClient( 'dashboard/' . $type, $name ); |
|
234 | + return $this->createSubClient('dashboard/' . $type, $name); |
|
235 | 235 | } |
236 | 236 | |
237 | 237 | |
@@ -242,7 +242,7 @@ discard block |
||
242 | 242 | */ |
243 | 243 | protected function getSubClientNames() |
244 | 244 | { |
245 | - $result = $this->getContext()->getConfig()->get( $this->subPartPath, $this->subPartNames ); |
|
245 | + $result = $this->getContext()->getConfig()->get($this->subPartPath, $this->subPartNames); |
|
246 | 246 | return $result; |
247 | 247 | } |
248 | 248 | } |
@@ -151,14 +151,12 @@ |
||
151 | 151 | |
152 | 152 | $manager->commit(); |
153 | 153 | return; |
154 | - } |
|
155 | - catch( \Aimeos\MShop\Exception $e ) |
|
154 | + } catch( \Aimeos\MShop\Exception $e ) |
|
156 | 155 | { |
157 | 156 | $error = array( 'product-item-category' => $context->getI18n()->dt( 'mshop', $e->getMessage() ) ); |
158 | 157 | $view->errors = $view->get( 'errors', array() ) + $error; |
159 | 158 | $manager->rollback(); |
160 | - } |
|
161 | - catch( \Exception $e ) |
|
159 | + } catch( \Exception $e ) |
|
162 | 160 | { |
163 | 161 | $context->getLogger()->log( $e->getMessage() . ' - ' . $e->getTraceAsString() ); |
164 | 162 | $error = array( 'product-item-category' => $e->getMessage() ); |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | public function copy() |
67 | 67 | { |
68 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be copied' ); |
|
68 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be copied'); |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | */ |
77 | 77 | public function create() |
78 | 78 | { |
79 | - throw new \Aimeos\Admin\JQAdm\Exception( 'New resources can not be created' ); |
|
79 | + throw new \Aimeos\Admin\JQAdm\Exception('New resources can not be created'); |
|
80 | 80 | } |
81 | 81 | |
82 | 82 | |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | */ |
88 | 88 | public function delete() |
89 | 89 | { |
90 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be deleted' ); |
|
90 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be deleted'); |
|
91 | 91 | } |
92 | 92 | |
93 | 93 | |
@@ -98,7 +98,7 @@ discard block |
||
98 | 98 | */ |
99 | 99 | public function get() |
100 | 100 | { |
101 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be retrieved' ); |
|
101 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be retrieved'); |
|
102 | 102 | } |
103 | 103 | |
104 | 104 | |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | */ |
110 | 110 | public function save() |
111 | 111 | { |
112 | - throw new \Aimeos\Admin\JQAdm\Exception( 'The resource can not be modified' ); |
|
112 | + throw new \Aimeos\Admin\JQAdm\Exception('The resource can not be modified'); |
|
113 | 113 | } |
114 | 114 | |
115 | 115 | |
@@ -127,25 +127,25 @@ discard block |
||
127 | 127 | { |
128 | 128 | $view->orderpaymentstatusBody = ''; |
129 | 129 | |
130 | - foreach( $this->getSubClients() as $client ) { |
|
130 | + foreach ($this->getSubClients() as $client) { |
|
131 | 131 | $view->orderpaymentstatusBody .= $client->search(); |
132 | 132 | } |
133 | 133 | } |
134 | - catch( \Aimeos\MShop\Exception $e ) |
|
134 | + catch (\Aimeos\MShop\Exception $e) |
|
135 | 135 | { |
136 | - $error = array( 'order-paymentstatus' => $context->getI18n()->dt( 'mshop', $e->getMessage() ) ); |
|
137 | - $view->errors = $view->get( 'errors', array() ) + $error; |
|
136 | + $error = array('order-paymentstatus' => $context->getI18n()->dt('mshop', $e->getMessage())); |
|
137 | + $view->errors = $view->get('errors', array()) + $error; |
|
138 | 138 | } |
139 | - catch( \Exception $e ) |
|
139 | + catch (\Exception $e) |
|
140 | 140 | { |
141 | - $error = array( 'order-paymentstatus' => $e->getMessage() ); |
|
142 | - $view->errors = $view->get( 'errors', array() ) + $error; |
|
141 | + $error = array('order-paymentstatus' => $e->getMessage()); |
|
142 | + $view->errors = $view->get('errors', array()) + $error; |
|
143 | 143 | } |
144 | 144 | |
145 | 145 | $tplconf = 'admin/jqadm/dashboard/order/paymentstatus/template-item'; |
146 | 146 | $default = 'dashboard/item-order-paymentstatus-default.php'; |
147 | 147 | |
148 | - return $view->render( $view->config( $tplconf, $default ) ); |
|
148 | + return $view->render($view->config($tplconf, $default)); |
|
149 | 149 | } |
150 | 150 | |
151 | 151 | |
@@ -156,7 +156,7 @@ discard block |
||
156 | 156 | * @param string|null $name Name of the sub-client (Default if null) |
157 | 157 | * @return \Aimeos\Admin\JQAdm\Iface Sub-client object |
158 | 158 | */ |
159 | - public function getSubClient( $type, $name = null ) |
|
159 | + public function getSubClient($type, $name = null) |
|
160 | 160 | { |
161 | 161 | /** admin/jqadm/dashboard/order/paymentstatus/decorators/excludes |
162 | 162 | * Excludes decorators added by the "common" option from the dashboard JQAdm client |
@@ -231,7 +231,7 @@ discard block |
||
231 | 231 | * @see admin/jqadm/dashboard/order/paymentstatus/decorators/excludes |
232 | 232 | * @see admin/jqadm/dashboard/order/paymentstatus/decorators/global |
233 | 233 | */ |
234 | - return $this->createSubClient( 'dashboard/order/paymentstatus/' . $type, $name ); |
|
234 | + return $this->createSubClient('dashboard/order/paymentstatus/' . $type, $name); |
|
235 | 235 | } |
236 | 236 | |
237 | 237 | |
@@ -242,6 +242,6 @@ discard block |
||
242 | 242 | */ |
243 | 243 | protected function getSubClientNames() |
244 | 244 | { |
245 | - return $this->getContext()->getConfig()->get( $this->subPartPath, $this->subPartNames ); |
|
245 | + return $this->getContext()->getConfig()->get($this->subPartPath, $this->subPartNames); |
|
246 | 246 | } |
247 | 247 | } |
@@ -151,14 +151,12 @@ |
||
151 | 151 | |
152 | 152 | $manager->commit(); |
153 | 153 | return; |
154 | - } |
|
155 | - catch( \Aimeos\MShop\Exception $e ) |
|
154 | + } catch( \Aimeos\MShop\Exception $e ) |
|
156 | 155 | { |
157 | 156 | $error = array( 'product-item-category' => $context->getI18n()->dt( 'mshop', $e->getMessage() ) ); |
158 | 157 | $view->errors = $view->get( 'errors', array() ) + $error; |
159 | 158 | $manager->rollback(); |
160 | - } |
|
161 | - catch( \Exception $e ) |
|
159 | + } catch( \Exception $e ) |
|
162 | 160 | { |
163 | 161 | $context->getLogger()->log( $e->getMessage() . ' - ' . $e->getTraceAsString() ); |
164 | 162 | $error = array( 'product-item-category' => $e->getMessage() ); |