fix: wrong employee code on change branch
This commit is contained in:
parent
900876ed1b
commit
aa7ba6d3ae
1 changed files with 1 additions and 1 deletions
|
|
@ -547,7 +547,7 @@ export class EmployeeController extends Controller {
|
||||||
},
|
},
|
||||||
update: { value: { increment: 1 } },
|
update: { value: { increment: 1 } },
|
||||||
});
|
});
|
||||||
code = `${customerBranch.id}-${`${new Date().getFullYear()}`.slice(-2).padStart(2, "0")}${`${last.value}`.padStart(7, "0")}`;
|
code = `${customerBranch.code}-${`${new Date().getFullYear()}`.slice(-2).padStart(2, "0")}${`${last.value}`.padStart(7, "0")}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
return await prisma.employee.update({
|
return await prisma.employee.update({
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue