Completed
Push — master ( 1af8b6...90bc50 )
by Laurent
03:35
created

InventoryArticles   A

Complexity

Total Complexity 15

Size/Duplication

Total Lines 231
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 15
c 0
b 0
f 0
lcom 0
cbo 0
dl 0
loc 231
rs 10

15 Methods

Rating   Name   Duplication   Size   Complexity  
A getId() 0 4 1
A setInventory() 0 6 1
A getInventory() 0 4 1
A setArticle() 0 6 1
A getArticle() 0 4 1
A setRealstock() 0 6 1
A getRealstock() 0 4 1
A setPrice() 0 6 1
A getPrice() 0 4 1
A setQuantity() 0 6 1
A getQuantity() 0 4 1
A setUnitStorage() 0 6 1
A getUnitStorage() 0 4 1
A setZoneStorage() 0 6 1
A getZoneStorage() 0 4 1
1
<?php
2
3
/**
4
 * Entité InventoryArticles.
5
 *
6
 * PHP Version 5
7
 *
8
 * @author    Quétier Laurent <[email protected]>
9
 * @copyright 2014 Dev-Int GLSR
10
 * @license   http://opensource.org/licenses/gpl-license.php GNU Public License
11
 *
12
 * @version GIT: <git_id>
13
 *
14
 * @link https://github.com/Dev-Int/glsr
15
 */
16
namespace AppBundle\Entity\Stocks;
17
18
use Doctrine\ORM\Mapping as ORM;
19
20
/**
21
 * InventoryArticles
22
 *
23
 * @ORM\Table(name="gs_inventory_articles")
24
 * @ORM\Entity(repositoryClass="AppBundle\Repository\Stocks\InventoryArticlesRepository")
25
 */
26
class InventoryArticles
27
{
28
    /**
29
     * @var integer
30
     *
31
     * @ORM\Column(name="id", type="integer")
32
     * @ORM\Id
33
     * @ORM\GeneratedValue(strategy="AUTO")
34
     */
35
    private $id;
36
37
    /**
38
     * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Stocks\Inventory", inversedBy="articles")
39
     * @ORM\JoinColumn(nullable=false)
40
     */
41
    private $inventory;
42
43
    /**
44
     * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Settings\Article")
45
     * @ORM\JoinColumn(nullable=false)
46
     */
47
    private $article;
48
49
    /**
50
     * @var decimal Quantité en stock
51
     *
52
     * @ORM\Column(name="quantity", type="decimal", precision=7, scale=3)
53
     */
54
    private $quantity;
55
56
    /**
57
     * @var string
58
     *
59
     * @ORM\Column(name="realstock", type="decimal", precision=7, scale=3, options={"default" = 0})
60
     */
61
    private $realstock;
62
63
    /**
64
     * @var string|\AppBundle\Entity\Settings\Diverse\UnitStorage Unité de stockage
65
     *
66
     * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Settings\Diverse\UnitStorage")
67
     * @ORM\JoinColumn(nullable=false)
68
     */
69
    private $unitStorage;
70
71
    /**
72
     * @var string
73
     *
74
     * @ORM\Column(name="price", type="decimal", precision=7, scale=3, nullable=true)
75
     */
76
    private $price;
77
78
    /**
79
     * @var string $zoneStorage Zone de stockage
80
     *
81
     * @ORM\Column(name="zoneStorage", type="string", length=255, nullable=true)
82
     */
83
    private $zoneStorage;
84
85
86
    /**
87
     * Get id
88
     *
89
     * @return integer
90
     */
91
    public function getId()
92
    {
93
        return $this->id;
94
    }
95
96
    /**
97
     * Set inventory
98
     *
99
     * @param \AppBundle\Entity\Stocks\Inventory $inventory
100
     * @return InventoryArticles
101
     */
102
    public function setInventory(\AppBundle\Entity\Stocks\Inventory $inventory)
103
    {
104
        $this->inventory = $inventory;
105
106
        return $this;
107
    }
108
109
    /**
110
     * Get inventory
111
     *
112
     * @return \AppBundle\Entity\Stocks\Inventory
113
     */
114
    public function getInventory()
115
    {
116
        return $this->inventory;
117
    }
118
119
    /**
120
     * Set article
121
     *
122
     * @param \AppBundle\Entity\Settings\Article $article
123
     * @return InventoryArticles
124
     */
125
    public function setArticle(\AppBundle\Entity\Settings\Article $article)
126
    {
127
        $this->article = $article;
128
129
        return $this;
130
    }
131
132
    /**
133
     * Get article
134
     *
135
     * @return \AppBundle\Entity\Settings\Article
136
     */
137
    public function getArticle()
138
    {
139
        return $this->article;
140
    }
141
142
    /**
143
     * Set realstock
144
     *
145
     * @param string $realstock
146
     * @return InventoryArticles
147
     */
148
    public function setRealstock($realstock)
149
    {
150
        $this->realstock = $realstock;
151
152
        return $this;
153
    }
154
155
    /**
156
     * Get realstock
157
     *
158
     * @return string
159
     */
160
    public function getRealstock()
161
    {
162
        return $this->realstock;
163
    }
164
165
    /**
166
     * Set Price
167
     *
168
     * @param string $price
169
     * @return InventoryArticles
170
     */
171
    public function setPrice($price)
172
    {
173
        $this->price = $price;
174
175
        return $this;
176
    }
177
178
    /**
179
     * Get Price
180
     *
181
     * @return string
182
     */
183
    public function getPrice()
184
    {
185
        return $this->price;
186
    }
187
188
    /**
189
     * Set quantity
190
     *
191
     * @param decimal $quantity
192
     * @return InventoryArticles
193
     */
194
    public function setQuantity($quantity)
195
    {
196
        $this->quantity = $quantity;
197
198
        return $this;
199
    }
200
201
    /**
202
     * Get quantity
203
     *
204
     * @return decimal
205
     */
206
    public function getQuantity()
207
    {
208
        return $this->quantity;
209
    }
210
211
    /**
212
     * Set unitStorage
213
     *
214
     * @param null|\AppBundle\Entity\Settings\Diverse\UnitStorage $unitStorage
215
     * @return InventoryArticles
216
     */
217
    public function setUnitStorage(\AppBundle\Entity\Settings\Diverse\UnitStorage $unitStorage = null)
218
    {
219
        $this->unitStorage = $unitStorage;
220
221
        return $this;
222
    }
223
224
    /**
225
     * Get unitStorage
226
     *
227
     * @return string|\AppBundle\Entity\Settings\Diverse\UnitStorage
228
     */
229
    public function getUnitStorage()
230
    {
231
        return $this->unitStorage;
232
    }
233
234
    /**
235
     * Set zoneStorage
236
     *
237
     * @param string $zoneStorage
238
     * @return InventoryArticles
239
     */
240
    public function setZoneStorage($zoneStorage = null)
241
    {
242
        $this->zoneStorage = $zoneStorage;
243
244
        return $this;
245
    }
246
247
    /**
248
     * Get zoneStorage
249
     *
250
     * @return string
251
     */
252
    public function getZoneStorage()
253
    {
254
        return $this->zoneStorage;
255
    }
256
}
257