fix(url): la ulr termina con / no es necesario añadir el texto
gitea/salix/pipeline/head There was a failure building this commit Details

This commit is contained in:
Pablo Natek 2023-10-16 18:38:33 +02:00
parent 033c02750b
commit afe4c676fc
3 changed files with 6 additions and 7 deletions

View File

@ -69,7 +69,7 @@ module.exports = Self => {
const message = $t('Claim pickup order sent', { const message = $t('Claim pickup order sent', {
claimId: args.id, claimId: args.id,
clientName: claim.client().name, clientName: claim.client().name,
claimUrl: `${url}/claim/${args.id}/summary`, claimUrl: `${url}claim/${args.id}/summary`,
}); });
console.log(message); console.log(message);
const salesPersonId = claim.client().salesPersonFk; const salesPersonId = claim.client().salesPersonFk;

View File

@ -99,8 +99,8 @@ module.exports = Self => {
const message = $t('Created claim', { const message = $t('Created claim', {
claimId: newClaim.id, claimId: newClaim.id,
ticketId: ticketId, ticketId: ticketId,
ticketUrl: `${url}/ticket/${ticketId}/sale`, ticketUrl: `${url}ticket/${ticketId}/sale`,
claimUrl: `${url}/claim/${newClaim.id}/summary`, claimUrl: `${url}claim/${newClaim.id}/summary`,
changes: changesMade changes: changesMade
}); });
await models.Chat.sendCheckingPresence(ctx, salesPerson.id, message); await models.Chat.sendCheckingPresence(ctx, salesPerson.id, message);

View File

@ -121,22 +121,21 @@ module.exports = Self => {
const message = $t(`Claim state has changed to ${state}`, { const message = $t(`Claim state has changed to ${state}`, {
claimId: claim.id, claimId: claim.id,
clientName: claim.client().name, clientName: claim.client().name,
claimUrl: `${url}/claim/${claim.id}/summary` claimUrl: `${url}claim/${claim.id}/summary`
}); });
await models.Chat.sendCheckingPresence(ctx, workerId, message); await models.Chat.sendCheckingPresence(ctx, workerId, message);
} }
async function notifyPickUp(ctx, workerId, claim) { async function notifyPickUp(ctx, workerId, claim) {
const models = Self.app.models; const models = Self.app.models;
const url = await models.Application.getUrl(); const url = await models.Application.getUrl('lilium');
const $t = ctx.req.__; // $translate const $t = ctx.req.__; // $translate
const message = $t('Claim will be picked', { const message = $t('Claim will be picked', {
claimId: claim.id, claimId: claim.id,
clientName: claim.client().name, clientName: claim.client().name,
claimUrl: `${url}/claim/${claim.id}/summary` claimUrl: `${url}claim/${claim.id}/summary`
}); });
console.log(message);
await models.Chat.sendCheckingPresence(ctx, workerId, message); await models.Chat.sendCheckingPresence(ctx, workerId, message);
} }
}; };