feat: Enhance note creation and project cancellation with user information and translations
This commit is contained in:
@@ -125,9 +125,12 @@ export function createProjectTask(data) {
|
||||
|
||||
// Add system note for task creation
|
||||
if (result.lastInsertRowid) {
|
||||
const language = getUserLanguage();
|
||||
const priority = data.priority || "normal";
|
||||
const status = data.status || "pending";
|
||||
const logMessage = `Task "${taskName}" created with priority: ${priority}, status: ${status}`;
|
||||
const translatedPriority = translatePriority(priority, language);
|
||||
const translatedStatus = translateStatus(status, language);
|
||||
const logMessage = `${serverT("Task created", language)} "${taskName}" ${serverT("with priority", language)}: ${translatedPriority}, ${serverT("status", language)}: ${translatedStatus}`;
|
||||
addNoteToTask(result.lastInsertRowid, logMessage, true, data.created_by);
|
||||
}
|
||||
|
||||
|
||||
@@ -11,6 +11,10 @@ const serverTranslations = {
|
||||
"Date started": "Data rozpoczęcia",
|
||||
"None": "Brak",
|
||||
"Task updated": "Zadanie zaktualizowane",
|
||||
"Task created": "Zadanie utworzone",
|
||||
"with priority": "z priorytetem",
|
||||
"status": "status",
|
||||
"Project cancelled on": "Projekt został wycofany w dniu",
|
||||
"pending": "oczekujące",
|
||||
"in_progress": "w trakcie",
|
||||
"completed": "ukończone",
|
||||
@@ -31,6 +35,10 @@ const serverTranslations = {
|
||||
"Date started": "Date started",
|
||||
"None": "None",
|
||||
"Task updated": "Task updated",
|
||||
"Task created": "Task created",
|
||||
"with priority": "with priority",
|
||||
"status": "status",
|
||||
"Project cancelled on": "Project cancelled on",
|
||||
"pending": "pending",
|
||||
"in_progress": "in_progress",
|
||||
"completed": "completed",
|
||||
|
||||
Reference in New Issue
Block a user