StockItemReserve::getAmount()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 4
Ratio 100 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 0
dl 4
loc 4
ccs 2
cts 2
cp 1
crap 1
rs 10
c 0
b 0
f 0
1
<?php
2
3
4
namespace Stockbase\Integration\Model;
5
6
use Magento\Framework\Model\AbstractModel;
7
8
/**
9
 * Class StockItemReserve
10
 */
11 View Code Duplication
class StockItemReserve extends AbstractModel
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
12
{
13
    /**
14
     * @return mixed
15
     */
16 1
    public function getEan()
17
    {
18 1
        return $this->getData('ean');
19
    }
20
21
    /**
22
     * @param string $ean
23
     */
24 1
    public function setEan($ean)
25
    {
26 1
        $this->setData('ean', $ean);
27 1
    }
28
29
    /**
30
     * @return mixed
31
     */
32 1
    public function getAmount()
33
    {
34 1
        return $this->getData('amount');
35
    }
36
37
    /**
38
     * @param string $amount
39
     */
40 1
    public function setAmount($amount)
41
    {
42 1
        $this->setData('amount', $amount);
43 1
    }
44
45
    /**
46
     * @return mixed
47
     */
48 1
    public function getMagentoStockAmount()
49
    {
50 1
        return $this->getData('magento_stock_amount');
51
    }
52
53
    /**
54
     * @param string $magentoStockAmount
55
     */
56 1
    public function setMagentoStockAmount($magentoStockAmount)
57
    {
58 1
        $this->setData('magento_stock_amount', $magentoStockAmount);
59 1
    }
60
61
    /**
62
     * @return mixed
63
     */
64 1
    public function getQuoteItemId()
65
    {
66 1
        return $this->getData('quote_item_id');
67
    }
68
69
    /**
70
     * @param string $quoteItemId
71
     */
72 1
    public function setQuoteItemId($quoteItemId)
73
    {
74 1
        $this->setData('quote_item_id', $quoteItemId);
75 1
    }
76
77
    /**
78
     * @return mixed
79
     */
80 1
    public function getProductId()
81
    {
82 1
        return $this->getData('product_id');
83
    }
84
85
    /**
86
     * @param string $productId
87
     */
88 1
    public function setProductId($productId)
89
    {
90 1
        $this->setData('product_id', $productId);
91 1
    }
92
93
    /**
94
     * @return mixed
95
     */
96 1
    public function getOrderItemId()
97
    {
98 1
        return $this->getData('order_item_id');
99
    }
100
101
    /**
102
     * @param string $orderItemId
103
     */
104 1
    public function setOrderItemId($orderItemId)
105
    {
106 1
        $this->setData('order_item_id', $orderItemId);
107 1
    }
108
109
    /**
110
     * @return mixed
111
     */
112 1
    public function getCreatedAt()
113
    {
114 1
        return $this->getData('created_at');
115
    }
116
117
    /**
118
     * @param string $createdAt
119
     */
120 1
    public function setCreatedAt($createdAt)
121
    {
122 1
        $this->setData('created_at', $createdAt);
123 1
    }
124
125 7
    protected function _construct()
126
    {
127 7
        $this->_init(\Stockbase\Integration\Model\ResourceModel\StockItemReserve::class);
128 7
    }
129
}
130