Files
crm.clientright.ru/test_syntax_check.html
Fedor 75d3f7942b feat: Обновлены все URL Nextcloud с office.klientprav.tech на office.clientright.ru
Обновленные файлы:
- crm_extensions/nextcloud_api.php (2 места)
- modules/Documents/actions/NcPrepareEdit.php
- crm_extensions/nextcloud_editor/js/nextcloud-editor.js
- crm_extensions/file_storage/api/get_edit_urls.php
- crm_extensions/file_storage/api/simple_edit.php
- crm_extensions/README.md
- NEXTCLOUD_EDIT_BUTTON_IMPLEMENTATION.md
- crm_extensions/docs/NEXTCLOUD_EDITOR.md
- test_syntax_check.html
- crm_extensions/tests/test_edit_button.html

Все ссылки теперь указывают на новый сервер office.clientright.ru
Backup файлы и тестовые директории не изменены
2025-10-20 17:17:34 +03:00

49 lines
2.1 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="ru">
<head>
<meta charset="UTF-8">
<title>🔧 Проверка синтаксиса JavaScript</title>
</head>
<body>
<h1>🔧 Проверка синтаксиса JavaScript</h1>
<button onclick="testEditButton('123', 'test.docx')" style="background: green; color: white; padding: 15px;">
Тест кнопки редактирования
</button>
<div id="log" style="background: #f0f0f0; padding: 15px; margin: 20px 0; font-family: monospace;"></div>
<script>
function addLog(message) {
document.getElementById('log').innerHTML += '[' + new Date().toLocaleTimeString() + '] ' + message + '<br>';
}
// Копируем функцию из Header.tpl для проверки синтаксиса
function testEditButton(recordId, fileName) {
console.log("🚀 Nextcloud Editor:", recordId, fileName);
// Простая версия для начала
var editUrl = "https://office.clientright.ru/apps/files/?dir=/CRM_Active_Files";
var editorWindow = window.open(editUrl, "nextcloud_editor", "width=1200,height=800");
if (editorWindow) {
alert("✅ Открываю Nextcloud для файла: " + fileName + "\n\nПерейдите в папку CRM_Active_Files и найдите ваш файл для редактирования.");
} else {
alert("❌ Всплывающие окна заблокированы. Откройте Nextcloud вручную:\n" + editUrl);
}
}
addLog('✅ JavaScript загружен без ошибок');
addLog('✅ Функция testEditButton определена');
// Проверяем синтаксис
try {
eval('testEditButton("test", "test.txt")');
addLog('✅ Синтаксис функции корректный');
} catch (e) {
addLog('❌ Ошибка синтаксиса: ' + e.message);
}
</script>
</body>
</html>