-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #148 from magmodules/release/1.8.0
Release/1.8.0
- Loading branch information
Showing
57 changed files
with
2,568 additions
and
1,063 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?php | ||
/** | ||
* Copyright © Magmodules.eu. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
declare(strict_types=1); | ||
|
||
namespace Magmodules\Channable\Api\Config\System; | ||
|
||
use Magento\Framework\Exception\NoSuchEntityException; | ||
|
||
/** | ||
* Returns config group interface | ||
*/ | ||
interface ReturnsInterface | ||
{ | ||
public const XML_PATH_RETURNS_ENABLE = 'magmodules_channable_marketplace/returns/enable'; | ||
|
||
/** | ||
* Check whether returns are enabled | ||
* | ||
* @param int|null $storeId | ||
* | ||
* @return bool | ||
*/ | ||
public function isReturnsEnabled(int $storeId = null): bool; | ||
|
||
/** | ||
* Returns webhook url builder | ||
* | ||
* @param int $storeId | ||
* | ||
* @return string | ||
* @throws NoSuchEntityException | ||
*/ | ||
public function getReturnsWebhookUrl(int $storeId): string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,223 @@ | ||
<?php | ||
/** | ||
* Copyright © Magmodules.eu. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
declare(strict_types=1); | ||
|
||
namespace Magmodules\Channable\Api\Returns\Data; | ||
|
||
use Magento\Framework\Api\ExtensibleDataInterface; | ||
|
||
/** | ||
* Interface for Channable Returns | ||
* @api | ||
*/ | ||
interface DataInterface extends ExtensibleDataInterface | ||
{ | ||
|
||
public const ID = 'id'; | ||
public const STORE_ID = 'store_id'; | ||
public const ORDER_ID = 'order_id'; | ||
public const CHANNEL_NAME = 'channel_name'; | ||
public const CHANNEL_ID = 'channel_id'; | ||
public const CHANNABLE_ID = 'channable_id'; | ||
public const MAGENTO_ORDER_ID = 'magento_order_id'; | ||
public const MAGENTO_INCREMENT_ID = 'magento_increment_id'; | ||
public const ITEM = 'item'; | ||
public const CUSTOMER_NAME = 'customer_name'; | ||
public const CUSTOMER = 'customer'; | ||
public const ADDRESS = 'address'; | ||
public const REASON = 'reason'; | ||
public const COMMENT = 'comment'; | ||
public const STATUS = 'status'; | ||
public const CREATED_AT = 'created_at'; | ||
public const UPDATED_AT = 'updated_at'; | ||
|
||
/** | ||
* @return int | ||
*/ | ||
public function getId(): int; | ||
|
||
/** | ||
* @param mixed $value | ||
* @return $this | ||
*/ | ||
public function setId($value): self; | ||
|
||
/** | ||
* @return int | ||
*/ | ||
public function getStoreId(): int; | ||
|
||
/** | ||
* @param int $storeId | ||
* @return $this | ||
*/ | ||
public function setStoreId(int $storeId): self; | ||
|
||
/** | ||
* @return int | ||
*/ | ||
public function getOrderId(): int; | ||
|
||
/** | ||
* @param int $orderId | ||
* @return $this | ||
*/ | ||
public function setOrderId(int $orderId): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getChannelName(): string; | ||
|
||
/** | ||
* @param string $channelName | ||
* @return $this | ||
*/ | ||
public function setChannelName(string $channelName): self; | ||
|
||
/** | ||
* @return int | ||
*/ | ||
public function getChannelId(): int; | ||
|
||
/** | ||
* @param int $channelId | ||
* @return $this | ||
*/ | ||
public function setChannelId(int $channelId): self; | ||
|
||
/** | ||
* @return int | ||
*/ | ||
public function getChannableId(): int; | ||
|
||
/** | ||
* @param int $channableId | ||
* @return $this | ||
*/ | ||
public function setChannableId(int $channableId): self; | ||
|
||
/** | ||
* @return int | ||
*/ | ||
public function getMagentoOrderId(): int; | ||
|
||
/** | ||
* @param int $magentoOrderId | ||
* @return $this | ||
*/ | ||
public function setMagentoOrderId(int $magentoOrderId): self; | ||
|
||
/** | ||
* @return int | ||
*/ | ||
public function getMagentoIncrementId(): int; | ||
|
||
/** | ||
* @param int $magentoIncrementId | ||
* @return $this | ||
*/ | ||
public function setMagentoIncrementId(int $magentoIncrementId): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getItem(): string; | ||
|
||
/** | ||
* @param string $item | ||
* @return $this | ||
*/ | ||
public function setItem(string $item): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getCustomerName(): string; | ||
|
||
/** | ||
* @param string $customerName | ||
* @return $this | ||
*/ | ||
public function setCustomerName(string $customerName): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getCustomer(): string; | ||
|
||
/** | ||
* @param string $customer | ||
* @return $this | ||
*/ | ||
public function setCustomer(string $customer): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getAddress(): string; | ||
|
||
/** | ||
* @param string $address | ||
* @return $this | ||
*/ | ||
public function setAddress(string $address): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getReason(): string; | ||
|
||
/** | ||
* @param string $reason | ||
* @return $this | ||
*/ | ||
public function setReason(string $reason): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getComment(): string; | ||
|
||
/** | ||
* @param string $comment | ||
* @return $this | ||
*/ | ||
public function setComment(string $comment): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getStatus(): string; | ||
|
||
/** | ||
* @param string $status | ||
* @return $this | ||
*/ | ||
public function setStatus(string $status): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getCreatedAt(): string; | ||
|
||
/** | ||
* @param string $createdAt | ||
* @return $this | ||
*/ | ||
public function setCreatedAt(string $createdAt): self; | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getUpdatedAt(): string; | ||
|
||
/** | ||
* @param string $updatedAt | ||
* @return $this | ||
*/ | ||
public function setUpdatedAt(string $updatedAt): self; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?php | ||
/** | ||
* Copyright © Magmodules.eu. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
declare(strict_types=1); | ||
|
||
namespace Magmodules\Channable\Api\Returns\Data; | ||
|
||
use Magento\Framework\Api\SearchResultsInterface as FrameworkSearchResultsInterface; | ||
use Magmodules\Channable\Api\Returns\Data\DataInterface as ChannableReturnsData; | ||
|
||
/** | ||
* Interface for Channable Item search results. | ||
* @api | ||
*/ | ||
interface SearchResultsInterface extends FrameworkSearchResultsInterface | ||
{ | ||
|
||
/** | ||
* Gets Code Items. | ||
* | ||
* @return ChannableReturnsData[] | ||
*/ | ||
public function getItems(): array; | ||
|
||
/** | ||
* Sets Code Items. | ||
* | ||
* @param ChannableReturnsData[] $items | ||
* | ||
* @return $this | ||
*/ | ||
public function setItems(array $items): self; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
<?php | ||
/** | ||
* Copyright © Magmodules.eu. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
declare(strict_types=1); | ||
|
||
namespace Magmodules\Channable\Api\Returns; | ||
|
||
use Magento\Framework\Api\SearchCriteriaInterface; | ||
use Magento\Framework\App\RequestInterface; | ||
use Magento\Framework\Exception\LocalizedException; | ||
use Magento\Framework\Exception\NoSuchEntityException; | ||
use Magmodules\Channable\Api\Returns\Data\DataInterface as ChannableReturnsData; | ||
use Magmodules\Channable\Api\Returns\Data\SearchResultsInterface; | ||
|
||
/** | ||
* Interface Repository | ||
*/ | ||
interface RepositoryInterface | ||
{ | ||
|
||
/** | ||
* Loads a specified Return | ||
* | ||
* @param int $id | ||
* | ||
* @return ChannableReturnsData | ||
* @throws LocalizedException | ||
*/ | ||
public function get(int $id): ChannableReturnsData; | ||
|
||
/** | ||
* Return Channable Returns object | ||
* | ||
* @return ChannableReturnsData | ||
*/ | ||
public function create(); | ||
|
||
/** | ||
* Retrieves an Channable Returns matching the specified criteria. | ||
* | ||
* @param SearchCriteriaInterface $searchCriteria | ||
* | ||
* @return SearchResultsInterface | ||
* @throws LocalizedException | ||
*/ | ||
public function getList($searchCriteria); | ||
|
||
/** | ||
* Register entity to delete | ||
* | ||
* @param ChannableReturnsData $entity | ||
* | ||
* @return bool true on success | ||
* @throws LocalizedException | ||
*/ | ||
public function delete(ChannableReturnsData $entity): bool; | ||
|
||
/** | ||
* Deletes an Channable Returns entity by ID | ||
* | ||
* @param int $id | ||
* | ||
* @return bool true on success | ||
* @throws NoSuchEntityException | ||
* @throws LocalizedException | ||
*/ | ||
public function deleteById($id); | ||
|
||
/** | ||
* Perform persist operations for one entity | ||
* | ||
* @param ChannableReturnsData $entity | ||
* | ||
* @return ChannableReturnsData | ||
* @throws LocalizedException | ||
*/ | ||
public function save( | ||
ChannableReturnsData $entity | ||
): ChannableReturnsData; | ||
} |
Oops, something went wrong.