Code Duplication    Length = 9-9 lines in 3 locations

src/Intraface/modules/invoice/Reminder.php 1 location

@@ 29-37 (lines=9) @@
26
        }
27
    }
28
29
    function getDBQuery()
30
    {
31
        if ($this->dbquery) {
32
            return $this->dbquery;
33
        }
34
        $this->dbquery = new Intraface_DBQuery($this->kernel, "invoice_reminder", "intranet_id = ".$this->kernel->intranet->get("id")." AND active = 1");
35
        $this->dbquery->useErrorObject($this->error);
36
        return $this->dbquery;
37
    }
38
39
    function getItems($type = null)
40
    {

src/Intraface/modules/invoice/ReminderGateway.php 1 location

@@ 15-23 (lines=9) @@
12
        $this->error = new Intraface_Error;
13
    }
14
15
    function getDBQuery()
16
    {
17
        if ($this->dbquery) {
18
            return $this->dbquery;
19
        }
20
        $this->dbquery = new Intraface_DBQuery($this->kernel, "invoice_reminder", "intranet_id = ".$this->kernel->intranet->get("id")." AND active = 1");
21
        $this->dbquery->useErrorObject($this->error);
22
        return $this->dbquery;
23
    }
24
25
    function findById($id)
26
    {

src/Intraface/modules/invoice/PaymentGateway.php 1 location

@@ 51-59 (lines=9) @@
48
    {
49
    }
50
51
    function getDBQuery()
52
    {
53
        if (is_object($this->dbquery)) {
54
            return $this->dbquery;
55
        }
56
        $this->dbquery = new Intraface_DBQuery($this->kernel, "invoice_payment", "intranet_id = ".$this->kernel->intranet->get("id"));
57
        $this->dbquery->useErrorObject($this->error);
58
        return $this->dbquery;
59
    }
60
61
    function findAll()
62
    {