ref #5914 rename table
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Alex Moreno 2023-11-14 15:45:52 +01:00
parent fd142b9f23
commit 88ec0f24c3
14 changed files with 40 additions and 40 deletions

View File

@ -74,7 +74,7 @@ BEGIN
clientFk, clientFk,
dued, dued,
companyFk, companyFk,
cplusInvoiceType477Fk siiTypeInvoiceOutFk
) )
SELECT SELECT
1, 1,

View File

@ -96,7 +96,7 @@ BEGIN
clientFk, clientFk,
dued, dued,
companyFk, companyFk,
cplusInvoiceType477Fk siiTypeInvoiceOutFk
) )
SELECT SELECT
1, 1,

View File

@ -96,7 +96,7 @@ BEGIN
clientFk, clientFk,
dued, dued,
companyFk, companyFk,
cplusInvoiceType477Fk siiTypeInvoiceOutFk
) )
SELECT SELECT
1, 1,

View File

@ -1,6 +1,6 @@
INSERT INTO `salix`.`ACL` (model, property, accessType, permission, principalType, principalId) INSERT INTO `salix`.`ACL` (model, property, accessType, permission, principalType, principalId)
VALUES VALUES
('CplusRectificationType', '*', 'READ', 'ALLOW', 'ROLE', 'administrative'), ('CplusRectificationType', '*', 'READ', 'ALLOW', 'ROLE', 'administrative'),
('CplusInvoiceType477', '*', 'READ', 'ALLOW', 'ROLE', 'administrative'), ('SiiTypeInvoiceOut', '*', 'READ', 'ALLOW', 'ROLE', 'administrative'),
('InvoiceCorrectionType', '*', 'READ', 'ALLOW', 'ROLE', 'administrative'), ('InvoiceCorrectionType', '*', 'READ', 'ALLOW', 'ROLE', 'administrative'),
('InvoiceOut', 'transferInvoice', 'WRITE', 'ALLOW', 'ROLE', 'administrative'); ('InvoiceOut', 'transferInvoice', 'WRITE', 'ALLOW', 'ROLE', 'administrative');

View File

@ -275,13 +275,13 @@ INSERT INTO `cplusInvoiceType472` VALUES (1,'F1 - Factura'),(2,'F2 - Factura sim
UNLOCK TABLES; UNLOCK TABLES;
-- --
-- Dumping data for table `cplusInvoiceType477` -- Dumping data for table `siiTypeInvoiceOut`
-- --
LOCK TABLES `cplusInvoiceType477` WRITE; LOCK TABLES `siiTypeInvoiceOut` WRITE;
/*!40000 ALTER TABLE `cplusInvoiceType477` DISABLE KEYS */; /*!40000 ALTER TABLE `siiTypeInvoiceOut` DISABLE KEYS */;
INSERT INTO `cplusInvoiceType477` VALUES (1,'F1 - Factura'),(2,'F2 - Factura simplificada (ticket)'),(3,'F3 - Factura emitida en sustitución de facturas simplificadas facturadas y declaradas'),(4,'F4 - Asiento resumen de facturas'),(5,'R1 - Factura rectificativa (Art. 80.1, 80.2 y error fundado en derecho)'),(6,'R2 - Factura rectificativa (Art. 80.3)'),(7,'R3 - Factura rectificativa (Art. 80.4)'),(8,'R4 - Factura rectificativa (Resto)'),(9,'R5 - Factura rectificativa en facturas simplificadas'); INSERT INTO `siiTypeInvoiceOut` VALUES (1,'F1 - Factura'),(2,'F2 - Factura simplificada (ticket)'),(3,'F3 - Factura emitida en sustitución de facturas simplificadas facturadas y declaradas'),(4,'F4 - Asiento resumen de facturas'),(5,'R1 - Factura rectificativa (Art. 80.1, 80.2 y error fundado en derecho)'),(6,'R2 - Factura rectificativa (Art. 80.3)'),(7,'R3 - Factura rectificativa (Art. 80.4)'),(8,'R4 - Factura rectificativa (Resto)'),(9,'R5 - Factura rectificativa en facturas simplificadas');
/*!40000 ALTER TABLE `cplusInvoiceType477` ENABLE KEYS */; /*!40000 ALTER TABLE `siiTypeInvoiceOut` ENABLE KEYS */;
UNLOCK TABLES; UNLOCK TABLES;
-- --

View File

@ -25993,13 +25993,13 @@ CREATE TABLE `cplusInvoiceType472` (
/*!40101 SET character_set_client = @saved_cs_client */; /*!40101 SET character_set_client = @saved_cs_client */;
-- --
-- Table structure for table `cplusInvoiceType477` -- Table structure for table `siiTypeInvoiceOut`
-- --
DROP TABLE IF EXISTS `cplusInvoiceType477`; DROP TABLE IF EXISTS `siiTypeInvoiceOut`;
/*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */; /*!40101 SET character_set_client = utf8 */;
CREATE TABLE `cplusInvoiceType477` ( CREATE TABLE `siiTypeInvoiceOut` (
`id` int(10) unsigned NOT NULL, `id` int(10) unsigned NOT NULL,
`description` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL, `description` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL,
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
@ -29450,16 +29450,16 @@ CREATE TABLE `invoiceCorrection` (
`correctingFk` int(10) unsigned NOT NULL COMMENT 'Factura rectificativa', `correctingFk` int(10) unsigned NOT NULL COMMENT 'Factura rectificativa',
`correctedFk` int(10) unsigned NOT NULL COMMENT 'Factura rectificada', `correctedFk` int(10) unsigned NOT NULL COMMENT 'Factura rectificada',
`cplusRectificationTypeFk` int(10) unsigned NOT NULL, `cplusRectificationTypeFk` int(10) unsigned NOT NULL,
`cplusInvoiceType477Fk` int(10) unsigned NOT NULL, `siiTypeInvoiceOutFk` int(10) unsigned NOT NULL,
`invoiceCorrectionTypeFk` int(11) NOT NULL DEFAULT 3, `invoiceCorrectionTypeFk` int(11) NOT NULL DEFAULT 3,
PRIMARY KEY (`correctingFk`), PRIMARY KEY (`correctingFk`),
KEY `correctedFk_idx` (`correctedFk`), KEY `correctedFk_idx` (`correctedFk`),
KEY `invoiceCorrection_ibfk_1_idx` (`cplusRectificationTypeFk`), KEY `invoiceCorrection_ibfk_1_idx` (`cplusRectificationTypeFk`),
KEY `cplusInvoiceTyoeFk_idx` (`cplusInvoiceType477Fk`), KEY `cplusInvoiceTyoeFk_idx` (`siiTypeInvoiceOutFk`),
KEY `invoiceCorrectionTypeFk_idx` (`invoiceCorrectionTypeFk`), KEY `invoiceCorrectionTypeFk_idx` (`invoiceCorrectionTypeFk`),
CONSTRAINT `corrected_fk` FOREIGN KEY (`correctedFk`) REFERENCES `invoiceOut` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, CONSTRAINT `corrected_fk` FOREIGN KEY (`correctedFk`) REFERENCES `invoiceOut` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `correcting_fk` FOREIGN KEY (`correctingFk`) REFERENCES `invoiceOut` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, CONSTRAINT `correcting_fk` FOREIGN KEY (`correctingFk`) REFERENCES `invoiceOut` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `cplusInvoiceTyoeFk` FOREIGN KEY (`cplusInvoiceType477Fk`) REFERENCES `cplusInvoiceType477` (`id`) ON UPDATE CASCADE, CONSTRAINT `cplusInvoiceTyoeFk` FOREIGN KEY (`siiTypeInvoiceOutFk`) REFERENCES `siiTypeInvoiceOut` (`id`) ON UPDATE CASCADE,
CONSTRAINT `invoiceCorrectionType_Fk33` FOREIGN KEY (`invoiceCorrectionTypeFk`) REFERENCES `invoiceCorrectionType` (`id`) ON UPDATE CASCADE, CONSTRAINT `invoiceCorrectionType_Fk33` FOREIGN KEY (`invoiceCorrectionTypeFk`) REFERENCES `invoiceCorrectionType` (`id`) ON UPDATE CASCADE,
CONSTRAINT `invoiceCorrection_ibfk_1` FOREIGN KEY (`cplusRectificationTypeFk`) REFERENCES `cplusRectificationType` (`id`) ON UPDATE CASCADE CONSTRAINT `invoiceCorrection_ibfk_1` FOREIGN KEY (`cplusRectificationTypeFk`) REFERENCES `cplusRectificationType` (`id`) ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci COMMENT='Relacion entre las facturas rectificativas y las rectificadas.'; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci COMMENT='Relacion entre las facturas rectificativas y las rectificadas.';
@ -30130,7 +30130,7 @@ CREATE TABLE `invoiceOut` (
`companyFk` int(10) unsigned NOT NULL DEFAULT 442, `companyFk` int(10) unsigned NOT NULL DEFAULT 442,
`hasPdf` tinyint(3) unsigned NOT NULL DEFAULT 0, `hasPdf` tinyint(3) unsigned NOT NULL DEFAULT 0,
`booked` date DEFAULT NULL, `booked` date DEFAULT NULL,
`cplusInvoiceType477Fk` int(10) unsigned NOT NULL DEFAULT 1, `siiTypeInvoiceOutFk` int(10) unsigned NOT NULL DEFAULT 1,
`cplusTaxBreakFk` int(10) unsigned NOT NULL DEFAULT 1, `cplusTaxBreakFk` int(10) unsigned NOT NULL DEFAULT 1,
`cplusSubjectOpFk` int(10) unsigned NOT NULL DEFAULT 1, `cplusSubjectOpFk` int(10) unsigned NOT NULL DEFAULT 1,
`cplusTrascendency477Fk` int(10) unsigned NOT NULL DEFAULT 1, `cplusTrascendency477Fk` int(10) unsigned NOT NULL DEFAULT 1,
@ -30140,13 +30140,13 @@ CREATE TABLE `invoiceOut` (
KEY `Id_Cliente` (`clientFk`), KEY `Id_Cliente` (`clientFk`),
KEY `empresa_id` (`companyFk`), KEY `empresa_id` (`companyFk`),
KEY `Fecha` (`issued`), KEY `Fecha` (`issued`),
KEY `Facturas_ibfk_2_idx` (`cplusInvoiceType477Fk`), KEY `Facturas_ibfk_2_idx` (`siiTypeInvoiceOutFk`),
KEY `Facturas_ibfk_3_idx` (`cplusSubjectOpFk`), KEY `Facturas_ibfk_3_idx` (`cplusSubjectOpFk`),
KEY `Facturas_ibfk_4_idx` (`cplusTaxBreakFk`), KEY `Facturas_ibfk_4_idx` (`cplusTaxBreakFk`),
KEY `Facturas_ibfk_5_idx` (`cplusTrascendency477Fk`), KEY `Facturas_ibfk_5_idx` (`cplusTrascendency477Fk`),
KEY `Facturas_idx_Vencimiento` (`dued`), KEY `Facturas_idx_Vencimiento` (`dued`),
KEY `invoiceOut_serial` (`serial`), KEY `invoiceOut_serial` (`serial`),
CONSTRAINT `invoiceOut_ibfk_2` FOREIGN KEY (`cplusInvoiceType477Fk`) REFERENCES `cplusInvoiceType477` (`id`) ON UPDATE CASCADE, CONSTRAINT `invoiceOut_ibfk_2` FOREIGN KEY (`siiTypeInvoiceOutFk`) REFERENCES `siiTypeInvoiceOut` (`id`) ON UPDATE CASCADE,
CONSTRAINT `invoiceOut_ibfk_3` FOREIGN KEY (`cplusSubjectOpFk`) REFERENCES `cplusSubjectOp` (`id`) ON UPDATE CASCADE, CONSTRAINT `invoiceOut_ibfk_3` FOREIGN KEY (`cplusSubjectOpFk`) REFERENCES `cplusSubjectOp` (`id`) ON UPDATE CASCADE,
CONSTRAINT `invoiceOut_ibfk_4` FOREIGN KEY (`cplusTaxBreakFk`) REFERENCES `cplusTaxBreak` (`id`) ON UPDATE CASCADE, CONSTRAINT `invoiceOut_ibfk_4` FOREIGN KEY (`cplusTaxBreakFk`) REFERENCES `cplusTaxBreak` (`id`) ON UPDATE CASCADE,
CONSTRAINT `invoiceOut_serial` FOREIGN KEY (`serial`) REFERENCES `invoiceOutSerial` (`code`), CONSTRAINT `invoiceOut_serial` FOREIGN KEY (`serial`) REFERENCES `invoiceOutSerial` (`code`),
@ -30308,7 +30308,7 @@ CREATE TABLE `invoiceOutSerial` (
`isTaxed` tinyint(1) NOT NULL DEFAULT 1, `isTaxed` tinyint(1) NOT NULL DEFAULT 1,
`taxAreaFk` varchar(15) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL DEFAULT 'NATIONAL', `taxAreaFk` varchar(15) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL DEFAULT 'NATIONAL',
`isCEE` tinyint(1) NOT NULL DEFAULT 0, `isCEE` tinyint(1) NOT NULL DEFAULT 0,
`cplusInvoiceType477Fk` int(10) unsigned DEFAULT 1, `siiTypeInvoiceOutFk` int(10) unsigned DEFAULT 1,
`footNotes` longtext DEFAULT NULL, `footNotes` longtext DEFAULT NULL,
`isRefEditable` tinyint(4) NOT NULL DEFAULT 0, `isRefEditable` tinyint(4) NOT NULL DEFAULT 0,
`type` enum('global','quick') DEFAULT NULL, `type` enum('global','quick') DEFAULT NULL,
@ -58288,7 +58288,7 @@ BEGIN
io.cplusTrascendency477Fk AS TIPOCLAVE, io.cplusTrascendency477Fk AS TIPOCLAVE,
io.cplusTaxBreakFk AS TIPOEXENCI, io.cplusTaxBreakFk AS TIPOEXENCI,
io.cplusSubjectOpFk AS TIPONOSUJE, io.cplusSubjectOpFk AS TIPONOSUJE,
io.cplusInvoiceType477Fk AS TIPOFACT, io.siiTypeInvoiceOutFk AS TIPOFACT,
ic.cplusRectificationTypeFk AS TIPORECTIF, ic.cplusRectificationTypeFk AS TIPORECTIF,
io.companyFk, io.companyFk,
RIGHT(io.ref, LENGTH(io.ref) - 1) AS invoiceNum, RIGHT(io.ref, LENGTH(io.ref) - 1) AS invoiceNum,
@ -58868,7 +58868,7 @@ BEGIN
clientFk, clientFk,
dued, dued,
companyFk, companyFk,
cplusInvoiceType477Fk siiTypeInvoiceOutFk
) )
SELECT SELECT
1, 1,

View File

@ -46,7 +46,7 @@ TABLES=(
bookingPlanner bookingPlanner
businessType businessType
cplusInvoiceType472 cplusInvoiceType472
cplusInvoiceType477 siiTypeInvoiceOut
cplusRectificationType cplusRectificationType
cplusSubjectOp cplusSubjectOp
cplusTaxBreak cplusTaxBreak

View File

@ -27,7 +27,7 @@ describe('InvoiceOut tranferInvoice()', () => {
ref: 'T4444444', ref: 'T4444444',
newClientFk: 1, newClientFk: 1,
cplusRectificationId: 1, cplusRectificationId: 1,
cplusInvoiceType477Id: 1, siiTypeInvoiceOutId: 1,
invoiceCorrectionTypeId: 1 invoiceCorrectionTypeId: 1
}; };
ctx.args = args; ctx.args = args;
@ -52,7 +52,7 @@ describe('InvoiceOut tranferInvoice()', () => {
ref: 'T1111111', ref: 'T1111111',
newClientFk: 1101, newClientFk: 1101,
cplusRectificationId: 1, cplusRectificationId: 1,
cplusInvoiceType477Id: 1, siiTypeInvoiceOutId: 1,
invoiceCorrectionTypeId: 1 invoiceCorrectionTypeId: 1
}; };
ctx.args = args; ctx.args = args;

View File

@ -27,7 +27,7 @@ module.exports = Self => {
required: true required: true
}, },
{ {
arg: 'cplusInvoiceType477Id', arg: 'siiTypeInvoiceOutId',
type: 'number', type: 'number',
required: true required: true
}, },
@ -93,7 +93,7 @@ module.exports = Self => {
correctingFk: invoiceId, correctingFk: invoiceId,
correctedFk: args.id, correctedFk: args.id,
cplusRectificationTypeFk: args.cplusRectificationId, cplusRectificationTypeFk: args.cplusRectificationId,
cplusInvoiceType477Fk: args.cplusInvoiceType477Id, siiTypeInvoiceOutFk: args.siiTypeInvoiceOutId,
invoiceCorrectionTypeFk: args.invoiceCorrectionTypeId invoiceCorrectionTypeFk: args.invoiceCorrectionTypeId
}, myOptions); }, myOptions);

View File

@ -41,7 +41,7 @@
"InvoiceCorrection": { "InvoiceCorrection": {
"dataSource": "vn" "dataSource": "vn"
}, },
"CplusInvoiceType477": { "SiiTypeInvoiceOut": {
"dataSource": "vn" "dataSource": "vn"
} }
} }

View File

@ -1,9 +1,9 @@
{ {
"name": "CplusInvoiceType477", "name": "SiiTypeInvoiceOut",
"base": "VnModel", "base": "VnModel",
"options": { "options": {
"mysql": { "mysql": {
"table": "cplusInvoiceType477" "table": "siiTypeInvoiceOut"
} }
}, },
"properties": { "properties": {
@ -16,4 +16,4 @@
"type": "string" "type": "string"
} }
} }
} }

View File

@ -18,11 +18,11 @@
"cplusRectificationTypeFk": { "cplusRectificationTypeFk": {
"type": "number" "type": "number"
}, },
"cplusInvoiceType477Fk": { "siiTypeInvoiceOutFk": {
"type": "number" "type": "number"
}, },
"invoiceCorrectionTypeFk": { "invoiceCorrectionTypeFk": {
"type": "number" "type": "number"
} }
} }
} }

View File

@ -6,8 +6,8 @@
</vn-crud-model> </vn-crud-model>
<vn-crud-model <vn-crud-model
auto-load="true" auto-load="true"
url="CplusInvoiceType477s" url="SiiTypeInvoiceOuts"
data="cplusInvoiceType477"> data="siiTypeInvoiceOut">
</vn-crud-model> </vn-crud-model>
<vn-crud-model <vn-crud-model
auto-load="true" auto-load="true"
@ -24,7 +24,7 @@
<vn-item <vn-item
vn-acl="administrative" vn-acl="administrative"
vn-acl-action="remove" vn-acl-action="remove"
ng-click="transferInvoice.show()" ng-click="transferInvoice.show()"
translate> translate>
Transfer invoice to... Transfer invoice to...
</vn-item> </vn-item>
@ -223,15 +223,15 @@
<vn-autocomplete <vn-autocomplete
vn-one vn-one
vn-id="cplusInvoiceType" vn-id="cplusInvoiceType"
data="cplusInvoiceType477" data="siiTypeInvoiceOut"
show-field="description" show-field="description"
value-field="id" value-field="id"
required="true" required="true"
ng-model="$ctrl.cplusInvoiceType477" ng-model="$ctrl.siiTypeInvoiceOut"
search-function="{or: [{id: $search}, {description: {like: '%'+ $search +'%'}}]}" search-function="{or: [{id: $search}, {description: {like: '%'+ $search +'%'}}]}"
label="Class"> label="Class">
</vn-autocomplete> </vn-autocomplete>
<vn-autocomplete <vn-autocomplete
vn-one vn-one
vn-id="invoiceCorrectionType" vn-id="invoiceCorrectionType"
data="invoiceCorrectionTypes" data="invoiceCorrectionTypes"
@ -247,4 +247,4 @@
<tpl-buttons> <tpl-buttons>
<button response="accept" translate>Transfer client</button> <button response="accept" translate>Transfer client</button>
</tpl-buttons> </tpl-buttons>
</vn-dialog> </vn-dialog>

View File

@ -132,7 +132,7 @@ class Controller extends Section {
ref: this.invoiceOut.ref, ref: this.invoiceOut.ref,
newClientFk: this.invoiceOut.client.id, newClientFk: this.invoiceOut.client.id,
cplusRectificationId: this.cplusRectificationType, cplusRectificationId: this.cplusRectificationType,
cplusInvoiceType477Id: this.cplusInvoiceType477, siiTypeInvoiceOutId: this.siiTypeInvoiceOut,
invoiceCorrectionTypeId: this.invoiceCorrectionType invoiceCorrectionTypeId: this.invoiceCorrectionType
}; };
this.$http.post(`InvoiceOuts/transferInvoice`, params).then(res => { this.$http.post(`InvoiceOuts/transferInvoice`, params).then(res => {