1 | <?php |
||
20 | class Standard |
||
21 | extends \Aimeos\Controller\Frontend\Base |
||
22 | implements Iface, \Aimeos\Controller\Frontend\Common\Iface |
||
23 | { |
||
24 | /** |
||
25 | * Adds and returns a new customer item object |
||
26 | * |
||
27 | * @param array $values Values added to the newly created customer item like "customer.birthday" |
||
28 | * @return \Aimeos\MShop\Customer\Item\Iface Customer item |
||
29 | * @since 2017.04 |
||
30 | */ |
||
31 | public function addItem( array $values ) |
||
65 | |||
66 | |||
67 | /** |
||
68 | * Creates a new customer item object pre-filled with the given values but not yet stored |
||
69 | * |
||
70 | * @return \Aimeos\MShop\Customer\Item\Iface Customer item |
||
71 | */ |
||
72 | public function createItem( array $values = [] ) |
||
83 | |||
84 | |||
85 | /** |
||
86 | * Deletes a customer item that belongs to the current authenticated user |
||
87 | * |
||
88 | * @param string $id Unique customer ID |
||
89 | * @since 2017.04 |
||
90 | */ |
||
91 | public function deleteItem( $id ) |
||
98 | |||
99 | |||
100 | /** |
||
101 | * Updates the customer item identified by its ID |
||
102 | * |
||
103 | * @param string $id Unique customer ID |
||
104 | * @param array $values Values added to the customer item like "customer.birthday" or "customer.city" |
||
105 | * @return \Aimeos\MShop\Customer\Item\Iface Customer item |
||
106 | * @since 2017.04 |
||
107 | */ |
||
108 | public function editItem( $id, array $values ) |
||
120 | |||
121 | |||
122 | /** |
||
123 | * Returns the customer item for the given customer ID |
||
124 | * |
||
125 | * @param string|null $id Unique customer ID or null for current customer item |
||
126 | * @param string[] $domains Domain names of items that are associated with the customers and that should be fetched too |
||
127 | * @return \Aimeos\MShop\Customer\Item\Iface Customer item including the referenced domains items |
||
128 | * @since 2017.04 |
||
129 | */ |
||
130 | public function getItem( $id = null, array $domains = [] ) |
||
142 | |||
143 | |||
144 | /** |
||
145 | * Returns the customer item for the given customer code (usually e-mail address) |
||
146 | * |
||
147 | * This method doesn't check if the customer item belongs to the logged in user! |
||
148 | * |
||
149 | * @param string $code Unique customer code |
||
150 | * @param string[] $domains Domain names of items that are associated with the customers and that should be fetched too |
||
151 | * @return \Aimeos\MShop\Customer\Item\Iface Customer item including the referenced domains items |
||
152 | * @since 2017.04 |
||
153 | */ |
||
154 | public function findItem( $code, array $domains = [] ) |
||
158 | |||
159 | |||
160 | /** |
||
161 | * Stores a modified customer item |
||
162 | * |
||
163 | * @param \Aimeos\MShop\Customer\Item\Iface $item Customer item |
||
164 | * @return \Aimeos\MShop\Customer\Item\Address\Iface Customer address item including the generated ID |
||
165 | */ |
||
166 | public function saveItem( \Aimeos\MShop\Customer\Item\Iface $item ) |
||
170 | |||
171 | |||
172 | /** |
||
173 | * Creates and returns a new item object |
||
174 | * |
||
175 | * @param array $values Values added to the newly created customer item like "customer.birthday" |
||
176 | * @return \Aimeos\MShop\Customer\Item\Address\Iface Customer address item |
||
177 | * @since 2017.04 |
||
178 | */ |
||
179 | public function addAddressItem( array $values ) |
||
191 | |||
192 | |||
193 | /** |
||
194 | * Creates a new customer address item object pre-filled with the given values but not yet stored |
||
195 | * |
||
196 | * @return \Aimeos\MShop\Customer\Item\Address\Iface Customer address item |
||
197 | */ |
||
198 | public function createAddressItem( array $values = [] ) |
||
211 | |||
212 | |||
213 | /** |
||
214 | * Deletes a customer item that belongs to the current authenticated user |
||
215 | * |
||
216 | * @param string $id Unique customer address ID |
||
217 | * @since 2017.04 |
||
218 | */ |
||
219 | public function deleteAddressItem( $id ) |
||
227 | |||
228 | |||
229 | /** |
||
230 | * Saves a modified customer item object |
||
231 | * |
||
232 | * @param string $id Unique customer address ID |
||
233 | * @param array $values Values added to the customer item like "customer.address.city" |
||
234 | * @return \Aimeos\MShop\Customer\Item\Address\Iface Customer address item |
||
235 | * @since 2017.04 |
||
236 | */ |
||
237 | public function editAddressItem( $id, array $values ) |
||
249 | |||
250 | |||
251 | /** |
||
252 | * Returns the customer item for the given customer ID |
||
253 | * |
||
254 | * @param string $id Unique customer address ID |
||
255 | * @return \Aimeos\MShop\Customer\Item\Address\Iface Customer address item |
||
256 | * @since 2017.04 |
||
257 | */ |
||
258 | public function getAddressItem( $id ) |
||
267 | |||
268 | |||
269 | /** |
||
270 | * Stores a modified customer address item |
||
271 | * |
||
272 | * @param \Aimeos\MShop\Customer\Item\Address\Iface $item Customer address item |
||
273 | * @return \Aimeos\MShop\Customer\Item\Address\Iface Customer address item including the generated ID |
||
274 | */ |
||
275 | public function saveAddressItem( \Aimeos\MShop\Customer\Item\Address\Iface $item ) |
||
279 | |||
280 | |||
281 | /** |
||
282 | * Creates and returns a new list item object |
||
283 | * |
||
284 | * @param array $values Values added to the newly created customer item like "customer.lists.refid" |
||
285 | * @return \Aimeos\MShop\Common\Item\Lists\Iface Customer lists item |
||
286 | * @since 2017.06 |
||
287 | */ |
||
288 | public function addListItem( array $values ) |
||
315 | |||
316 | |||
317 | /** |
||
318 | * Returns a new customer lists filter criteria object |
||
319 | * |
||
320 | * @return \Aimeos\MW\Criteria\Iface New filter object |
||
321 | * @since 2017.06 |
||
322 | */ |
||
323 | public function createListsFilter() |
||
333 | |||
334 | |||
335 | /** |
||
336 | * Deletes a customer item that belongs to the current authenticated user |
||
337 | * |
||
338 | * @param string $id Unique customer address ID |
||
339 | * @since 2017.06 |
||
340 | */ |
||
341 | public function deleteListItem( $id ) |
||
349 | |||
350 | |||
351 | /** |
||
352 | * Saves a modified customer lists item object |
||
353 | * |
||
354 | * @param string $id Unique customer lists ID |
||
355 | * @param array $values Values added to the customer lists item like "customer.lists.refid" |
||
356 | * @return \Aimeos\MShop\Common\Item\Lists\Iface Customer lists item |
||
357 | * @since 2017.06 |
||
358 | */ |
||
359 | public function editListItem( $id, array $values ) |
||
387 | |||
388 | |||
389 | /** |
||
390 | * Returns the customer item for the given customer ID |
||
391 | * |
||
392 | * @param string $id Unique customer address ID |
||
393 | * @return \Aimeos\MShop\Customer\Item\Address\Iface Customer address item |
||
394 | * @since 2017.06 |
||
395 | */ |
||
396 | public function getListItem( $id ) |
||
405 | |||
406 | |||
407 | /** |
||
408 | * Returns the customer lists items filtered by the given criteria |
||
409 | * |
||
410 | * @param \Aimeos\MW\Criteria\Iface $filter Criteria object which contains the filter conditions |
||
411 | * @param integer &$total Parameter where the total number of found attributes will be stored in |
||
412 | * @return \Aimeos\MShop\Common\Item\Lists\Iface[] Customer list items |
||
413 | * @since 2017.06 |
||
414 | */ |
||
415 | public function searchListItems( \Aimeos\MW\Criteria\Iface $filter, &$total = null ) |
||
421 | |||
422 | |||
423 | /** |
||
424 | * Adds the default values for customer items if not yet available |
||
425 | * |
||
426 | * @param string[] $values Associative list of customer keys (e.g. "customer.label") and their values |
||
427 | * @return string[] Associative list of customer key/value pairs with default values set |
||
428 | */ |
||
429 | protected function addItemDefaults( array $values ) |
||
464 | |||
465 | |||
466 | /** |
||
467 | * Checks if the current user is allowed to retrieve the customer data for the given ID |
||
468 | * |
||
469 | * @param string $id Unique customer ID |
||
470 | * @throws \Aimeos\Controller\Frontend\Customer\Exception If access isn't allowed |
||
471 | */ |
||
472 | protected function checkUser( $id ) |
||
480 | } |
||
481 |
This check looks for function or method calls that always return null and whose return value is assigned to a variable.
The method
getObject()
can return nothing but null, so it makes no sense to assign that value to a variable.The reason is most likely that a function or method is imcomplete or has been reduced for debug purposes.