3604-route_agencyTerm #893
No reviewers
Labels
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: verdnatura/salix#893
Loading…
Reference in New Issue
No description provided.
Delete Branch "3604-route_agencyTerm"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@ -0,0 +1,2 @@
INSERT INTO salix.ACL (id, model, property, accessType, permission, principalType, principalId)
move to /10430-ash
@ -0,0 +1,2 @@
INSERT INTO salix.ACL (model,property,accessType,principalId)
move to /10430-ash
@ -0,0 +1,10 @@
CREATE TABLE `vn`.`agencyTermConfig` (
move to /10430-ash
@ -221,2 +221,3 @@
"You don't have privileges to create pay back": "No tienes permisos para crear un abono",
"The item is required": "El artículo es requerido"
"The item is required": "El artículo es requerido",
"reference duplicated": "reference duplicated"
Reference is duplicated // Duplicated reference
this is still wrong
@ -0,0 +1,99 @@
module.exports = Self => {
Self.remoteMethod('createInvoiceIn', {
description: 'create a invoce in from one or more agency terms',
Creates an invoiceIn from one or more agency terms
@ -0,0 +81,4 @@
transactionTypeSageFk: transactionTypeSage.value
}, myOptions);
// await Self.rawSql(`CALL invoiceInDueDay_calculate(?)`, [newInvoiceIn.id], myOptions);
:(
@ -0,0 +89,4 @@
UPDATE vn.route SET invoiceInFk = ? WHERE id = ?
`, [newInvoiceIn.id, route.id], myOptions);
}
Maybe you want the endpoint to return the created invoiceIn.
@ -0,0 +30,4 @@
if (typeof options == 'object')
Object.assign(myOptions, options);
let stmts = [];
const
@ -0,0 +31,4 @@
Object.assign(myOptions, options);
let stmts = [];
let stmt;
stmt is initialized once and assigned once, perhaps you want to create a constant directly on definition
@ -0,0 +65,4 @@
stmt.merge(conn.makeSuffix(filter));
let agencyTerm = stmts.push(stmt) - 1;
const
@ -0,0 +66,4 @@
stmt.merge(conn.makeSuffix(filter));
let agencyTerm = stmts.push(stmt) - 1;
let sql = ParameterizedSQL.join(stmts, ';');
const
@ -0,0 +67,4 @@
let agencyTerm = stmts.push(stmt) - 1;
let sql = ParameterizedSQL.join(stmts, ';');
let result = await conn.executeStmt(sql, myOptions);
const
@ -0,0 +1,49 @@
const models = require('vn-loopback/server/server').models;
xdescribe('AgencyTerm createInvoiceIn()', () => {
if a test is excluded a reference to the issue create must be stated with a comment above it.
or maybe this is a mistake.
@ -0,0 +15,4 @@
}
];
it('should make a invoice in', async() => {
an invoiceIn
@ -0,0 +28,4 @@
const oldInvoiceInDueDay = await models.InvoiceInDueDay.findById(invoiceInDueDayId, null, options);
const oldInvoiceInTax = await models.InvoiceInTax.findById(invoiceInTaxId, null, options);
// await models.AgencyTerm.createInvoiceIn(rows, dms, options);
:(
@ -0,0 +34,4 @@
const [newInvoiceInDueDay] = await models.InvoiceInDueDay.rawSql('SELECT MAX(id) id FROM invoiceInDueDay', null, options);
const [newInvoiceInTax] = await models.InvoiceInTax.rawSql('SELECT MAX(id) id FROM invoiceInTax', null, options);
conso;
conso was left alone
@ -0,0 +3,4 @@
describe('AgencyTerm filter()', () => {
const authUserId = 9;
it('should all return the tickets matching the filter', async() => {
should return all the tickets...
@ -0,0 +62,4 @@
describe('setDefaultParams()', () => {
it('should perform a GET query and define the dms property on controller', () => {
const params2 = {filter: {
paramsTwo or myParams, or testParams
never use numbers for variable definitions
@ -0,0 +65,4 @@
const params2 = {filter: {
where: {code: 'invoiceIn'}
}};
let serializedParams = $httpParamSerializer(params2);
const
@ -0,0 +39,4 @@
};
}
exprBuilder(param, value) {
The following approach requires less code for same functionality
@ -0,0 +45,4 @@
});
describe('preview()', () => {
it('should show the dialog summary', () => {
should show the summary dialog
@ -0,0 +63,4 @@
});
describe('createInvoiceIn()', () => {
it('should throw an error if are checked more than one autonomous', () => {
should throw an error if more than one autonomous are checked
@ -0,0 +74,4 @@
expect(controller.vnApp.showError).toHaveBeenCalled();
});
it('should call the function go() on $state to go to the file managment', () => {
management
@ -0,0 +1,7 @@
picture: Foto
the word picture should be capitalised.
Also some of the translations don't seem to be used at all. please double check their use on your templates.
@ -0,0 +1,48 @@
const models = require('vn-loopback/server/server').models;
// Include test when the database export is done
// Include after #3638 export database
@ -0,0 +1,5 @@
Agency route: Agencia ruta
Agency Agreement: Agencia acuerdo
Acuerdo de agencia? Acuerdo agencia?
LGTM