feat: add thai text to notification
This commit is contained in:
parent
17b92b4012
commit
f583448e5f
4 changed files with 22 additions and 22 deletions
|
|
@ -231,8 +231,8 @@ export class QuotationPayment extends Controller {
|
|||
if (quotation.quotationStatus !== res.quotationStatus)
|
||||
await tx.notification.create({
|
||||
data: {
|
||||
title: "Quotation Status Updated",
|
||||
detail: res.code + " " + res.quotationStatus,
|
||||
title: "สถานะใบเสนอราคาเปลี่ยนแปลง / Quotation Status Updated",
|
||||
detail: "รหัส / code : " + res.code + " " + res.quotationStatus,
|
||||
receiverId: res.createdByUserId,
|
||||
},
|
||||
});
|
||||
|
|
|
|||
|
|
@ -642,8 +642,8 @@ export class QuotationController extends Controller {
|
|||
|
||||
await prisma.notification.create({
|
||||
data: {
|
||||
title: "New Quotation",
|
||||
detail: "New quotation: " + ret.code,
|
||||
title: "ใบเสนอราคาใหม่ / New Quotation",
|
||||
detail: "รหัส / code : " + ret.code,
|
||||
registeredBranchId: ret.registeredBranchId,
|
||||
groupReceiver: { create: [{ name: "accountant" }, { name: "head_of_accountant" }] },
|
||||
},
|
||||
|
|
@ -1176,8 +1176,8 @@ export class QuotationActionController extends Controller {
|
|||
.then(async (ret) => {
|
||||
await prisma.notification.create({
|
||||
data: {
|
||||
title: "New Request",
|
||||
detail: "New request: " + ret.requestData.map((v) => v.code).join(", "),
|
||||
title: "รายการคำขอใหม่ / New Request",
|
||||
detail: "รหัส / code : " + ret.requestData.map((v) => v.code).join(", "),
|
||||
registeredBranchId: ret.registeredBranchId,
|
||||
groupReceiver: { create: { name: "document_checker" } },
|
||||
},
|
||||
|
|
|
|||
|
|
@ -280,8 +280,8 @@ export class RequestDataActionController extends Controller {
|
|||
.then(async (res) => {
|
||||
await tx.notification.createMany({
|
||||
data: res.map((v) => ({
|
||||
title: "Quotation Status Updated",
|
||||
detail: v.code + " Canceled",
|
||||
title: "สถานะใบเสนอราคาเปลี่ยนแปลง / Quotation Status Updated",
|
||||
detail: "รหัส / code : " + v.code + " Canceled",
|
||||
receiverId: v.createdByUserId,
|
||||
})),
|
||||
});
|
||||
|
|
@ -428,8 +428,8 @@ export class RequestDataActionController extends Controller {
|
|||
.then(async (res) => {
|
||||
await tx.notification.createMany({
|
||||
data: res.map((v) => ({
|
||||
title: "Quotation Status Updated",
|
||||
detail: v.code + " Canceled",
|
||||
title: "สถานะใบเสนอราคาเปลี่ยนแปลง / Quotation Status Updated",
|
||||
detail: "รหัส / code : " + v.code + " Canceled",
|
||||
receiverId: v.createdByUserId,
|
||||
})),
|
||||
});
|
||||
|
|
@ -519,8 +519,8 @@ export class RequestDataActionController extends Controller {
|
|||
.then(async (res) => {
|
||||
await tx.notification.createMany({
|
||||
data: res.map((v) => ({
|
||||
title: "Quotation Status Updated",
|
||||
detail: v.code + " Completed",
|
||||
title: "สถานะใบเสนอราคาเปลี่ยนแปลง / Quotation Status Updated",
|
||||
detail: "รหัส / code : " + v.code + " Completed",
|
||||
receiverId: v.createdByUserId,
|
||||
})),
|
||||
});
|
||||
|
|
@ -856,8 +856,8 @@ export class RequestListController extends Controller {
|
|||
.then(async (res) => {
|
||||
await tx.notification.createMany({
|
||||
data: res.map((v) => ({
|
||||
title: "Quotation Status Updated",
|
||||
detail: v.code + " Canceled",
|
||||
title: "สถานะใบเสนอราคาเปลี่ยนแปลง / Quotation Status Updated",
|
||||
detail: "รหัส / code : " + v.code + " Canceled",
|
||||
receiverId: v.createdByUserId,
|
||||
})),
|
||||
});
|
||||
|
|
@ -948,8 +948,8 @@ export class RequestListController extends Controller {
|
|||
.then(async (res) => {
|
||||
await tx.notification.createMany({
|
||||
data: res.map((v) => ({
|
||||
title: "Quotation Status Updated",
|
||||
detail: v.code + " Completed",
|
||||
title: "สถานะใบเสนอราคาเปลี่ยนแปลง / Quotation Status Updated",
|
||||
detail: "รหัส / code : " + v.code + " Completed",
|
||||
receiverId: v.createdByUserId,
|
||||
})),
|
||||
});
|
||||
|
|
|
|||
|
|
@ -520,8 +520,8 @@ export class TaskController extends Controller {
|
|||
if (body.taskOrderStatus && record.taskOrderStatus !== body.taskOrderStatus) {
|
||||
await prisma.notification.create({
|
||||
data: {
|
||||
title: "Task Submitted",
|
||||
detail: "Task submitted in order: " + record.code,
|
||||
title: "มีการส่งงาน / Task Submitted",
|
||||
detail: "รหัสใบสั่งงาน / Order : " + record.code,
|
||||
receiverId: record.createdByUserId,
|
||||
},
|
||||
});
|
||||
|
|
@ -666,8 +666,8 @@ export class TaskActionController extends Controller {
|
|||
}),
|
||||
prisma.notification.create({
|
||||
data: {
|
||||
title: "Task Submitted",
|
||||
detail: "Task submitted in order: " + record.code,
|
||||
title: "มีการส่งงาน / Task Submitted",
|
||||
detail: "รหัสใบสั่งงาน / Order : " + record.code,
|
||||
receiverId: record.createdByUserId,
|
||||
},
|
||||
}),
|
||||
|
|
@ -824,8 +824,8 @@ export class TaskActionController extends Controller {
|
|||
.then(async (res) => {
|
||||
await tx.notification.createMany({
|
||||
data: res.map((v) => ({
|
||||
title: "Quotation Status Updated",
|
||||
detail: v.code + " Completed",
|
||||
title: "สถานะใบเสนอราคาเปลี่ยนแปลง / Quotation Status Updated",
|
||||
detail: "รหัส / code : " + v.code + " Completed",
|
||||
receiverId: v.createdByUserId,
|
||||
})),
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue