img fix
parent
acf86a2d64
commit
d82106e506
|
|
@ -878,6 +878,7 @@
|
||||||
const install = allInstalls.find(i => i.id === installId);
|
const install = allInstalls.find(i => i.id === installId);
|
||||||
if (install) {
|
if (install) {
|
||||||
data['protocol'] = install.protocol;
|
data['protocol'] = install.protocol;
|
||||||
|
data['note'] = install.note; // Сохраняем текущую заметку
|
||||||
}
|
}
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: `${API_URL}/install/${installId}`,
|
url: `${API_URL}/install/${installId}`,
|
||||||
|
|
@ -917,13 +918,18 @@
|
||||||
console.error('Install not found:', installId);
|
console.error('Install not found:', installId);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
// Передаем все текущие данные записи, чтобы ничего не очистилось
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: `${API_URL}/install/${installId}`,
|
url: `${API_URL}/install/${installId}`,
|
||||||
type: 'PUT',
|
type: 'PUT',
|
||||||
contentType: 'application/json',
|
contentType: 'application/json',
|
||||||
data: JSON.stringify({
|
data: JSON.stringify({
|
||||||
|
rust_id: install.rust_id,
|
||||||
|
computer_name: install.computer_name,
|
||||||
|
install_time: install.install_time,
|
||||||
folder_id: folderId,
|
folder_id: folderId,
|
||||||
protocol: install.protocol
|
protocol: install.protocol,
|
||||||
|
note: install.note // Явно передаем заметку
|
||||||
}),
|
}),
|
||||||
success: function () {
|
success: function () {
|
||||||
console.log('Move successful');
|
console.log('Move successful');
|
||||||
|
|
@ -1033,8 +1039,12 @@
|
||||||
type: 'PUT',
|
type: 'PUT',
|
||||||
contentType: 'application/json',
|
contentType: 'application/json',
|
||||||
data: JSON.stringify({
|
data: JSON.stringify({
|
||||||
note: note,
|
rust_id: install.rust_id,
|
||||||
protocol: install.protocol // Сохраняем текущий protocol
|
computer_name: install.computer_name,
|
||||||
|
install_time: install.install_time,
|
||||||
|
folder_id: install.folder_id,
|
||||||
|
protocol: install.protocol,
|
||||||
|
note: note
|
||||||
}),
|
}),
|
||||||
success: function () {
|
success: function () {
|
||||||
console.log('Note saved successfully');
|
console.log('Note saved successfully');
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue