Completed
Branch 2.0.0 (a6ce5f)
by Chubarov
06:30 queued 03:11
created
example.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@
 block discarded – undo
55 55
 //dd($test);
56 56
 
57 57
 // 8.  Example delete
58
-$test = $test->action('delete:xml', function ($creator){
58
+$test = $test->action('delete:xml', function($creator) {
59 59
     $creator->guid('');
60 60
 })->get();
61 61
 dd($test);
62 62
\ No newline at end of file
Please login to merge, or discard this patch.
src/Handlers/XmlHandler.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -84,12 +84,12 @@  discard block
 block discarded – undo
84 84
         $this->response      = simplexml_load_string($response);
85 85
         $copyXml             = $this->response;
86 86
 
87
-        if ( $this->response === false || $this->checkIntegrity($this->response) === false )
87
+        if ($this->response === false || $this->checkIntegrity($this->response) === false)
88 88
         {
89 89
             return [];
90 90
         }
91 91
 
92
-            $array_vars_list    = get_object_vars($copyXml);
92
+            $array_vars_list = get_object_vars($copyXml);
93 93
 
94 94
             if (key_exists('content', $array_vars_list)) {
95 95
                 return $this->arrayOne();
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
      */
108 108
     public function checkIntegrity($response)
109 109
     {
110
-        if ( empty($response->message) )
110
+        if (empty($response->message))
111 111
         {
112 112
             return true;
113 113
         }
@@ -154,12 +154,12 @@  discard block
 block discarded – undo
154 154
      */
155 155
     private function workspace()
156 156
     {
157
-        if ( !empty($this->response->message->collection->title) ) {
157
+        if (!empty($this->response->message->collection->title)) {
158 158
             throw new \Exception("responce BPM API : ".
159
-                $this->response->innererror->message.". ENG :".  $this->response->message);
159
+                $this->response->innererror->message.". ENG :".$this->response->message);
160 160
         }
161 161
         foreach ($this->response->workspace->collection as $item) {
162
-            $this->validText[] = get_object_vars($item->children(  $this->namespaces['NamespaceAtom'] ))['title'];
162
+            $this->validText[] = get_object_vars($item->children($this->namespaces['NamespaceAtom']))['title'];
163 163
         }
164 164
         return $this;
165 165
     }
@@ -172,8 +172,8 @@  discard block
 block discarded – undo
172 172
     private function arrayMany()
173 173
     {
174 174
         try {
175
-            foreach ($this->response->children( $this->namespaces['NamespaceAtom'] )->entry as $item ) {
176
-                $this->validText[] =   $item->content->children( $this->namespaces['NamespaceMetadata'] )
175
+            foreach ($this->response->children($this->namespaces['NamespaceAtom'])->entry as $item) {
176
+                $this->validText[] = $item->content->children($this->namespaces['NamespaceMetadata'])
177 177
                     ->children($this->namespaces['NamespaceDataServices']);
178 178
             }
179 179
             return $this;
@@ -187,9 +187,9 @@  discard block
 block discarded – undo
187 187
      */
188 188
     private function arrayOne()
189 189
     {
190
-        $this->validText = $this->response->children( $this->namespaces['NamespaceAtom'] )->content
191
-            ->children( $this->namespaces['NamespaceMetadata'] )
192
-            ->children( $this->namespaces['NamespaceDataServices'] );
190
+        $this->validText = $this->response->children($this->namespaces['NamespaceAtom'])->content
191
+            ->children($this->namespaces['NamespaceMetadata'])
192
+            ->children($this->namespaces['NamespaceDataServices']);
193 193
         return $this;
194 194
     }
195 195
 
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
         $xmlns_dcd->appendChild($valued);
227 227
 
228 228
         //----------  properties  ----------//
229
-        $properties   = $dom->createElement('m:properties');
229
+        $properties = $dom->createElement('m:properties');
230 230
         $content->appendChild($properties);
231 231
 
232 232
         foreach ($data as $nameField => $valueField) {
Please login to merge, or discard this patch.
src/Actions/Read.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -65,8 +65,8 @@  discard block
 block discarded – undo
65 65
      */
66 66
     public function filterConstructor($strRequest)
67 67
     {
68
-        $ParameterQuery =  '$filter=';
69
-        $ParameterQuery.=  $strRequest;
68
+        $ParameterQuery = '$filter=';
69
+        $ParameterQuery .= $strRequest;
70 70
         $this->concatenationUrlCurl($ParameterQuery);
71 71
         return $this;
72 72
     }
@@ -83,13 +83,13 @@  discard block
 block discarded – undo
83 83
     public function orderBy($whatSort, $param = 'asc')
84 84
     {
85 85
         $ParameterQuery = '$orderby=';
86
-        $ParameterQuery.=  ucfirst($whatSort);
86
+        $ParameterQuery .= ucfirst($whatSort);
87 87
 
88
-        if ( empty($param) === false ) {
88
+        if (empty($param) === false) {
89 89
             if ($param != 'desc' && $param != 'asc') {
90 90
                 throw new \Exception('no valid orderby parameters');
91 91
             }
92
-            $ParameterQuery.=  " ".$param;
92
+            $ParameterQuery .= " ".$param;
93 93
         }
94 94
          $this->concatenationUrlCurl($ParameterQuery);
95 95
 
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
      */
121 121
     public function amount($amountMax = null)
122 122
     {
123
-        Assert::that($amountMax,'You must specify a numeric parameter for the amount of the method')->integer();
123
+        Assert::that($amountMax, 'You must specify a numeric parameter for the amount of the method')->integer();
124 124
         $ParameterQuery = '$top='.$amountMax;
125 125
         $this->concatenationUrlCurl($ParameterQuery);
126 126
         return $this;
@@ -132,12 +132,12 @@  discard block
 block discarded – undo
132 132
     private function query()
133 133
     {
134 134
         $parameters = str_replace(' ', '%20', $this->url);
135
-        $url        = $this->kernel->getCollection() . $parameters;
135
+        $url        = $this->kernel->getCollection().$parameters;
136 136
         $client     = app()->make(ClientInterface::class);
137
-        $urlHome    = config($this->kernel->getPrefixConfig() . '.UrlHome');
137
+        $urlHome    = config($this->kernel->getPrefixConfig().'.UrlHome');
138 138
 
139 139
         try {
140
-            $response = $client->request($this->HTTP_TYPE, $urlHome . $url,
140
+            $response = $client->request($this->HTTP_TYPE, $urlHome.$url,
141 141
                 [
142 142
                     'headers' => [
143 143
                         'HTTP/1.0',
Please login to merge, or discard this patch.
src/Actions/Update.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -55,12 +55,12 @@
 block discarded – undo
55 55
     {
56 56
         $parameters = str_replace(' ', '%20', $this->url);
57 57
 
58
-        $url        = $this->kernel->getCollection() . $parameters;
58
+        $url        = $this->kernel->getCollection().$parameters;
59 59
         $client     = app()->make(ClientInterface::class);
60
-        $urlHome    = config($this->kernel->getPrefixConfig() . '.UrlHome');
60
+        $urlHome    = config($this->kernel->getPrefixConfig().'.UrlHome');
61 61
 
62 62
         try {
63
-            $response = $client->request($this->HTTP_TYPE, $urlHome . $url,
63
+            $response = $client->request($this->HTTP_TYPE, $urlHome.$url,
64 64
                 [
65 65
                     'headers' => [
66 66
                         'HTTP/1.0',
Please login to merge, or discard this patch.
src/Actions/Delete.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -55,12 +55,12 @@
 block discarded – undo
55 55
     {
56 56
         $parameters = str_replace(' ', '%20', $this->url);
57 57
 
58
-        $url        = $this->kernel->getCollection() . $parameters;
58
+        $url        = $this->kernel->getCollection().$parameters;
59 59
         $client     = app()->make(ClientInterface::class);
60
-        $urlHome    = config($this->kernel->getPrefixConfig() . '.UrlHome');
60
+        $urlHome    = config($this->kernel->getPrefixConfig().'.UrlHome');
61 61
 
62 62
         try {
63
-            $response = $client->request($this->HTTP_TYPE, $urlHome . $url,
63
+            $response = $client->request($this->HTTP_TYPE, $urlHome.$url,
64 64
                 [
65 65
                     'headers' => [
66 66
                         'HTTP/1.0',
Please login to merge, or discard this patch.
src/Assistants/ConstructorUrl.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
      */
17 17
     protected function concatenationUrlCurl($newParameters)
18 18
     {
19
-        if ($this->url  == '?') {
19
+        if ($this->url == '?') {
20 20
             $this->url .= $newParameters;
21 21
         } elseif ($this->url == '') {
22 22
             $this->url .= $newParameters;
@@ -36,10 +36,10 @@  discard block
 block discarded – undo
36 36
         $this->checkGuId($guid);
37 37
         $this->url      = '';
38 38
         $ParameterQuery = '(guid';
39
-        $ParameterQuery.= "'";
40
-        $ParameterQuery.= $guid;
41
-        $ParameterQuery.= "'";
42
-        $ParameterQuery.=')';
39
+        $ParameterQuery .= "'";
40
+        $ParameterQuery .= $guid;
41
+        $ParameterQuery .= "'";
42
+        $ParameterQuery .= ')';
43 43
 
44 44
         return $this->concatenationUrlCurl($ParameterQuery);
45 45
     }
Please login to merge, or discard this patch.