Skip to content

Commit f0af468

Browse files
committed
Add excluir347 field
1 parent 11fe837 commit f0af468

12 files changed

Lines changed: 189 additions & 14 deletions

Extension/Model/Cliente.php

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<?php
2+
/**
3+
* This file is part of FacturaScripts
4+
* Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
5+
*
6+
* This program is free software: you can redistribute it and/or modify
7+
* it under the terms of the GNU Lesser General Public License as
8+
* published by the Free Software Foundation, either version 3 of the
9+
* License, or (at your option) any later version.
10+
*
11+
* This program is distributed in the hope that it will be useful,
12+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14+
* GNU Lesser General Public License for more details.
15+
*
16+
* You should have received a copy of the GNU Lesser General Public License
17+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
18+
*/
19+
namespace FacturaScripts\Plugins\Modelo347\Extension\Model;
20+
21+
use Closure;
22+
23+
/**
24+
* Auxiliar class for special actions into the customer.
25+
* - Set excluir347 initial value.
26+
*
27+
* @author Jose Antonio Cuello Principal <yopli2000@gmail.com>
28+
*
29+
* @property bool excluir347
30+
*/
31+
class Cliente
32+
{
33+
public function clear(): Closure
34+
{
35+
return function () {
36+
$this->excluir347 = false;
37+
};
38+
}
39+
}

Extension/Model/FacturaCliente.php

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
<?php
2+
/**
3+
* This file is part of FacturaScripts
4+
* Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
5+
*
6+
* This program is free software: you can redistribute it and/or modify
7+
* it under the terms of the GNU Lesser General Public License as
8+
* published by the Free Software Foundation, either version 3 of the
9+
* License, or (at your option) any later version.
10+
*
11+
* This program is distributed in the hope that it will be useful,
12+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14+
* GNU Lesser General Public License for more details.
15+
*
16+
* You should have received a copy of the GNU Lesser General Public License
17+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
18+
*/
19+
namespace FacturaScripts\Plugins\Modelo347\Extension\Model;
20+
21+
use Closure;
22+
23+
/**
24+
* Auxiliar class for special actions into the business document.
25+
* - setSubject: Set Modelo347 attributes values from the subject of the document.
26+
*
27+
* @author Jose Antonio Cuello Principal <yopli2000@gmail.com>
28+
*
29+
* @property bool excluir347
30+
*/
31+
class FacturaCliente
32+
{
33+
public function clear(): Closure
34+
{
35+
return function () {
36+
$this->excluir347 = false;
37+
};
38+
}
39+
40+
public function setSubject(): Closure
41+
{
42+
return function ($subject) {
43+
if (property_exists($subject, 'excluir347')) {
44+
$this->excluir347 = $subject->excluir347;
45+
}
46+
};
47+
}
48+
}
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
<?php
2+
/**
3+
* This file is part of FacturaScripts
4+
* Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
5+
*
6+
* This program is free software: you can redistribute it and/or modify
7+
* it under the terms of the GNU Lesser General Public License as
8+
* published by the Free Software Foundation, either version 3 of the
9+
* License, or (at your option) any later version.
10+
*
11+
* This program is distributed in the hope that it will be useful,
12+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14+
* GNU Lesser General Public License for more details.
15+
*
16+
* You should have received a copy of the GNU Lesser General Public License
17+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
18+
*/
19+
namespace FacturaScripts\Plugins\Modelo347\Extension\Model;
20+
21+
use Closure;
22+
23+
/**
24+
* Auxiliar class for special actions into the business document.
25+
* - setSubject: Set Modelo347 attributes values from the subject of the document.
26+
*
27+
* @author Jose Antonio Cuello Principal <yopli2000@gmail.com>
28+
*
29+
* @property bool excluir347
30+
*/
31+
class FacturaProveedor
32+
{
33+
public function clear(): Closure
34+
{
35+
return function () {
36+
$this->excluir347 = false;
37+
};
38+
}
39+
40+
public function setSubject(): Closure
41+
{
42+
return function ($subject) {
43+
if (property_exists($subject, 'excluir347')) {
44+
$this->excluir347 = $subject->excluir347;
45+
}
46+
};
47+
}
48+
}

Extension/Model/Proveedor.php

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<?php
2+
/**
3+
* This file is part of FacturaScripts
4+
* Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
5+
*
6+
* This program is free software: you can redistribute it and/or modify
7+
* it under the terms of the GNU Lesser General Public License as
8+
* published by the Free Software Foundation, either version 3 of the
9+
* License, or (at your option) any later version.
10+
*
11+
* This program is distributed in the hope that it will be useful,
12+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14+
* GNU Lesser General Public License for more details.
15+
*
16+
* You should have received a copy of the GNU Lesser General Public License
17+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
18+
*/
19+
namespace FacturaScripts\Plugins\Modelo347\Extension\Model;
20+
21+
use Closure;
22+
23+
/**
24+
* Auxiliar class for special actions into the supplier.
25+
* - Set excluir347 initial value.
26+
*
27+
* @author Jose Antonio Cuello Principal <yopli2000@gmail.com>
28+
*
29+
* @property bool excluir347
30+
*/
31+
class Proveedor
32+
{
33+
public function clear(): Closure
34+
{
35+
return function () {
36+
$this->excluir347 = false;
37+
};
38+
}
39+
}

Extension/Table/clientes.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
This file is part of Modelo347 plugin for FacturaScripts
4-
Copyright (C) 2020-2023 Carlos Garcia Gomez <carlos@facturascripts.com>
4+
Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
55
66
This program is free software: you can redistribute it and/or modify
77
it under the terms of the GNU Lesser General Public License as

Extension/Table/facturascli.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
This file is part of Modelo347 plugin for FacturaScripts
4-
Copyright (C) 2020-2023 Carlos Garcia Gomez <carlos@facturascripts.com>
4+
Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
55
66
This program is free software: you can redistribute it and/or modify
77
it under the terms of the GNU Lesser General Public License as

Extension/Table/facturasprov.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
This file is part of Modelo347 plugin for FacturaScripts
4-
Copyright (C) 2020-2023 Carlos Garcia Gomez <carlos@facturascripts.com>
4+
Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
55
66
This program is free software: you can redistribute it and/or modify
77
it under the terms of the GNU Lesser General Public License as

Extension/Table/proveedores.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
This file is part of Modelo347 plugin for FacturaScripts
4-
Copyright (C) 2020-2023 Carlos Garcia Gomez <carlos@facturascripts.com>
4+
Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
55
66
This program is free software: you can redistribute it and/or modify
77
it under the terms of the GNU Lesser General Public License as
@@ -17,7 +17,6 @@
1717
along with this program. If not, see <http://www.gnu.org/licenses/>.
1818
1919
Document : proveedores.xml
20-
Author : Jose Antonio Cuello <yopli2000@gmail.com>
2120
Author : Dainier Rojas Jimenez <danredjim@gmail.com>
2221
Description:
2322
Add fields to basic structure of proveedores table.

Extension/XMLView/EditCliente.xml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
* This file is part of FacturaScripts
4-
* Copyright (C) 2017-2024 Carlos Garcia Gomez <carlos@facturascripts.com>
4+
* Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
55
*
66
* This program is free software: you can redistribute it and/or modify
77
* it under the terms of the GNU Lesser General Public License as
@@ -16,7 +16,6 @@
1616
* You should have received a copy of the GNU Lesser General Public License
1717
* along with this program. If not, see <http://www.gnu.org/licenses/>.
1818
*
19-
* @author Artex Trading sa <jcuello@artextrading.com>
2019
* @author Dainier Rojas Jiménez <danredjim.com>
2120
-->
2221
<view>
@@ -25,7 +24,7 @@
2524
<column name="exclude-347" order="205" numcolumns="2">
2625
<widget type="select" fieldname="excluir347" translate="true" required="true">
2726
<values title="no">0</values>
28-
<values title="yes">1</values>
27+
<values title="yes">1</values>
2928
</widget>
3029
</column>
3130
</group>

Extension/XMLView/EditProveedor.xml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
* This file is part of FacturaScripts
4-
* Copyright (C) 2017-2023 Carlos Garcia Gomez <carlos@facturascripts.com>
4+
* Copyright (C) 2017-2025 Carlos Garcia Gomez <carlos@facturascripts.com>
55
*
66
* This program is free software: you can redistribute it and/or modify
77
* it under the terms of the GNU Lesser General Public License as
@@ -16,16 +16,15 @@
1616
* You should have received a copy of the GNU Lesser General Public License
1717
* along with this program. If not, see <http://www.gnu.org/licenses/>.
1818
*
19-
* @author Artex Trading sa <jcuello@artextrading.com>
2019
* @author Dainier Rojas Jiménez <danredjim.com>
2120
-->
2221
<view>
2322
<columns>
2423
<group name="comercial" title="commercial-terms" numcolumns="12">
2524
<column name="exclude-347" order="205" numcolumns="2">
26-
<widget type="select" fieldname="excluir347" translate="true" required="true">
25+
<widget type="select" fieldname="excluir347" translate="true" required="true">
2726
<values title="no">0</values>
28-
<values title="yes">1</values>
27+
<values title="yes">1</values>
2928
</widget>
3029
</column>
3130
</group>

0 commit comments

Comments
 (0)