fix: wrong cond
This commit is contained in:
parent
c302eafb83
commit
c9d92c43f9
1 changed files with 1 additions and 1 deletions
|
|
@ -518,7 +518,7 @@ export class EmployeeController extends Controller {
|
|||
const record = await prisma.$transaction(async (tx) => {
|
||||
let code: string | undefined;
|
||||
|
||||
if (customerBranch && customerBranch.id !== customerBranchId) {
|
||||
if (customerBranch && customerBranch.id !== employee.customerBranchId) {
|
||||
const last = await tx.runningNo.upsert({
|
||||
where: {
|
||||
key: `EMPLOYEE_${customerBranch.customer.code}-${customerBranch.branchNo.toString().padStart(2, "0")}-${new Date().getFullYear().toString().slice(-2).padStart(2, "0")}`,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue