Passed
Push — master ( a43e58...4ea7aa )
by Giancarlos
08:09
created

Invoice::setAnticipos()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 5
ccs 3
cts 3
cp 1
rs 9.4285
cc 1
eloc 3
nc 1
nop 1
crap 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: Giansalex
5
 * Date: 15/07/2017
6
 * Time: 21:05
7
 */
8
9
namespace Greenter\Model\Sale;
10
11
use Greenter\Xml\Validator\InvoiceValidator;
12
use Symfony\Component\Validator\Constraints as Assert;
13
14
/**
15
 * Class Invoice
16
 * @package Greenter\Model\Sale
17
 */
18
class Invoice extends BaseSale
19
{
20
    use InvoiceValidator;
21
22
    /**
23
     * Tipo operacion (Catálogo 17).
24
     * @var string
25
     */
26
    private $tipoOperacion;
27
28
    /**
29
     * @var float
30
     */
31
    private $mtoOperGratuitas;
32
33
    /**
34
     * @var float
35
     */
36
    private $sumDsctoGlobal;
37
38
    /**
39
     * @var float
40
     */
41
    private $mtoDescuentos;
42
43
    /**
44
     * @var float
45
     */
46
    private $totalAnticipos;
47
48
    /**
49
     * @Assert\Valid()
50
     *
51
     * @var SalePerception
52
     */
53
    private $perception;
54
55
    /**
56
     * Orden de Compra relacionado.
57
     *
58
     * @var string
59
     */
60
    private $compra;
61
62
    /**
63
     * Guias de Remision relacionado (caso de uso en venta itinerante).
64
     *
65
     * @Assert\Valid()
66
     *
67
     * @var Document[]
68
     */
69
    private $guias;
70
71
    /**
72
     * @Assert\Valid()
73
     *
74
     * @var Prepayment[]
75
     */
76
    private $anticipos;
77
78
    /**
79
     * @Assert\Valid()
80
     *
81
     * @var Detraction
82
     */
83
    private $detraccion;
84
85
    /**
86
     * Utilizado cuando se trata de una Factura Guia.
87
     *
88
     * @Assert\Valid()
89
     *
90
     * @var EmbededDespatch
91
     */
92
    private $guiaEmbebida;
93
94
    /**
95
     * @return string
96
     */
97 12
    public function getTipoOperacion()
98
    {
99 12
        return $this->tipoOperacion;
100
    }
101
102
    /**
103
     * @param string $tipoOperacion
104
     * @return Invoice
105
     */
106 12
    public function setTipoOperacion($tipoOperacion)
107
    {
108 12
        $this->tipoOperacion = $tipoOperacion;
109 12
        return $this;
110
    }
111
112
    /**
113
     * @return float
114
     */
115 12
    public function getSumDsctoGlobal()
116
    {
117 12
        return $this->sumDsctoGlobal;
118
    }
119
120
    /**
121
     * @param float $sumDsctoGlobal
122
     * @return Invoice
123
     */
124 12
    public function setSumDsctoGlobal($sumDsctoGlobal)
125
    {
126 12
        $this->sumDsctoGlobal = $sumDsctoGlobal;
127 12
        return $this;
128
    }
129
130
    /**
131
     * @return float
132
     */
133 12
    public function getMtoDescuentos()
134
    {
135 12
        return $this->mtoDescuentos;
136
    }
137
138
    /**
139
     * @param float $mtoDescuentos
140
     * @return Invoice
141
     */
142 12
    public function setMtoDescuentos($mtoDescuentos)
143
    {
144 12
        $this->mtoDescuentos = $mtoDescuentos;
145 12
        return $this;
146
    }
147
148
    /**
149
     * @return float
150
     */
151 12
    public function getMtoOperGratuitas()
152
    {
153 12
        return $this->mtoOperGratuitas;
154
    }
155
156
    /**
157
     * @param float $mtoOperGratuitas
158
     * @return Invoice
159
     */
160 12
    public function setMtoOperGratuitas($mtoOperGratuitas)
161
    {
162 12
        $this->mtoOperGratuitas = $mtoOperGratuitas;
163 12
        return $this;
164
    }
165
166
    /**
167
     * @return mixed
168
     */
169 12
    public function getTotalAnticipos()
170
    {
171 12
        return $this->totalAnticipos;
172
    }
173
174
    /**
175
     * @param mixed $totalAnticipos
176
     * @return Invoice
177
     */
178 12
    public function setTotalAnticipos($totalAnticipos)
179
    {
180 12
        $this->totalAnticipos = $totalAnticipos;
181 12
        return $this;
182
    }
183
184
    /**
185
     * @return SalePerception
186
     */
187 12
    public function getPerception()
188
    {
189 12
        return $this->perception;
190
    }
191
192
    /**
193
     * @param SalePerception $perception
194
     * @return Invoice
195
     */
196 12
    public function setPerception($perception)
197
    {
198 12
        $this->perception = $perception;
199 12
        return $this;
200
    }
201
202
    /**
203
     * @return string
204
     */
205 12
    public function getCompra()
206
    {
207 12
        return $this->compra;
208
    }
209
210
    /**
211
     * @param string $compra
212
     * @return Invoice
213
     */
214 12
    public function setCompra($compra)
215
    {
216 12
        $this->compra = $compra;
217 12
        return $this;
218
    }
219
220
    /**
221
     * @return Document[]
222
     */
223 12
    public function getGuias()
224
    {
225 12
        return $this->guias;
226
    }
227
228
    /**
229
     * @param Document[] $guias
230
     * @return Invoice
231
     */
232 12
    public function setGuias($guias)
233
    {
234 12
        $this->guias = $guias;
235 12
        return $this;
236
    }
237
238
    /**
239
     * @return Prepayment[]
240
     */
241 12
    public function getAnticipos()
242
    {
243 12
        return $this->anticipos;
244
    }
245
246
    /**
247
     * @param Prepayment[] $anticipos
248
     * @return Invoice
249
     */
250 12
    public function setAnticipos($anticipos)
251
    {
252 12
        $this->anticipos = $anticipos;
253 12
        return $this;
254
    }
255
256
    /**
257
     * @return Detraction
258
     */
259 12
    public function getDetraccion()
260
    {
261 12
        return $this->detraccion;
262
    }
263
264
    /**
265
     * @param Detraction $detraccion
266
     * @return Invoice
267
     */
268 12
    public function setDetraccion($detraccion)
269
    {
270 12
        $this->detraccion = $detraccion;
271 12
        return $this;
272
    }
273
274
    /**
275
     * @return EmbededDespatch
276
     */
277 12
    public function getGuiaEmbebida()
278
    {
279 12
        return $this->guiaEmbebida;
280
    }
281
282
    /**
283
     * @param EmbededDespatch $guiaEmbebida
284
     * @return Invoice
285
     */
286 12
    public function setGuiaEmbebida($guiaEmbebida)
287
    {
288 12
        $this->guiaEmbebida = $guiaEmbebida;
289 12
        return $this;
290
    }
291
}