Nessun oggetto della modifica
Nessun oggetto della modifica
Riga 9: Riga 9:
   <button class="dashboard-toggle" onclick="toggleDashboardBox('test-tools')">🧪 Strumenti di Test</button>
   <button class="dashboard-toggle" onclick="toggleDashboardBox('test-tools')">🧪 Strumenti di Test</button>
   <button class="dashboard-toggle" onclick="toggleDashboardBox('activity-log')">📘 Registro Attività</button>
   <button class="dashboard-toggle" onclick="toggleDashboardBox('activity-log')">📘 Registro Attività</button>
   <button class="dashboard-toggle" onclick="uploadToOpenAI()">📤 Carica in OpenAI</button>
   <button class="dashboard-toggle" onclick="uploadToOpenAI()">📄 Carica in OpenAI</button>
</div>
</div>


----
<!-- 📁 Importa file dal server (semplificata) -->
<!-- 📁 Importa file (semplificata) -->
<div id="serverFileSimpleImportContainer"></div>
<div id="import-simple" style="display:none; padding:1rem; border:1px solid #ccc; border-radius:8px; background:#f9f9f9;">
  <h4>📁 Importa file dal server (semplificata)</h4>
 
  <label for="baseDirSelect"><b>Directory di origine:</b></label><br>
  <select id="baseDirSelect" style="width:100%; margin-bottom:0.5rem;">
    <option value="/var/www/html/masticationpedia-staging/">📁 staging/</option>
    <option value="/var/www/html/masticationpedia-staging/oauth/">📁 oauth/</option>
    <option value="/var/www/html/masticationpedia-staging/dashboard/">📁 dashboard/</option>
    <option value="/var/www/html/masticationpedia-staging/dashboard/api/">📁 dashboard/api/</option>
  </select><br>
 
  <label for="fileNameInput"><b>Nome file da copiare:</b></label><br>
  <input type="text" id="fileNameInput" placeholder="es: linkedin-login.php" style="width:100%; margin-bottom:0.5rem;"><br>
 
  <label for="destinationPath"><b>Cartella di destinazione nel progetto:</b></label><br>
  <input type="text" id="destinationPath" value="SSO_Linkedin_Login/" style="width:100%; margin-bottom:0.5rem;"><br>
 
  <button onclick="importServerFileFromPresetDir()" style="background:#007bff; color:white; border:none; padding:0.4rem 1rem; border-radius:5px; font-weight:bold;">📥 Copia e Registra</button>
</div>
 
 
 
----
 
 
 
 
 
 
 


<!-- 📦 Connessione API -->
<!-- 📦 Connessione API -->
Riga 49: Riga 19:
   <strong>Connessione API:</strong><br><br>
   <strong>Connessione API:</strong><br><br>
   <input id="api-key" placeholder="🔑 Inserisci API Key" style="width:100%; margin-bottom:0.5rem;"><br>
   <input id="api-key" placeholder="🔑 Inserisci API Key" style="width:100%; margin-bottom:0.5rem;"><br>
  <!-- ✅ Hidden input per il model, richiesto da CommonDashboard.js -->
   <input type="hidden" id="gptModel" value="gpt-4o">
   <input type="hidden" id="gptModel" value="gpt-4o">
   <select id="model-select" style="width:100%; margin-bottom:0.5rem;">
   <select id="model-select" style="width:100%; margin-bottom:0.5rem;">
     <option value="gpt-4">gpt-4</option>
     <option value="gpt-4">gpt-4</option>
Riga 58: Riga 25:
     <option value="gpt-4o-2024-05-13" selected></option>
     <option value="gpt-4o-2024-05-13" selected></option>
   </select><br>
   </select><br>
   <textarea id="test-prompt" rows="3" style="width:100%; margin-bottom:0.5rem;">Dimmi una curiosità sulla mandibola</textarea><br>
   <textarea id="test-prompt" rows="3" style="width:100%; margin-bottom:0.5rem;">Dimmi una curiosità sulla mandibola</textarea><br>
   <button onclick="testAPIConnection()">▶️ Testa connessione</button>
   <button onclick="testAPIConnection()">▶️ Testa connessione</button>
   <pre id="api-result" style="background:#f0f0f0; padding:1rem; border:1px solid #ccc; margin-top:1rem; white-space:pre-wrap;"></pre>
   <pre id="api-result" style="background:#f0f0f0; padding:1rem; border:1px solid #ccc; margin-top:1rem; white-space:pre-wrap;"></pre>
</div>
</div>
Riga 70: Riga 35:
   <button onclick="openProjectDialog()" style="margin-bottom:1rem; background:#007bff; color:white; border:none; padding:0.5rem 1rem; border-radius:5px; font-weight:bold;">➕ Nuovo Progetto</button>
   <button onclick="openProjectDialog()" style="margin-bottom:1rem; background:#007bff; color:white; border:none; padding:0.5rem 1rem; border-radius:5px; font-weight:bold;">➕ Nuovo Progetto</button>


<div id="newProjectDialog" style="display:none; padding:1rem; border:1px solid #ccc; margin-top:1rem;">
  <div id="newProjectDialog" style="display:none; padding:1rem; border:1px solid #ccc; margin-top:1rem;">
  <h4>➕ Crea Nuovo Progetto</h4>
    <h4>➕ Crea Nuovo Progetto</h4>
  <input id="newProjectTitle" placeholder="Titolo progetto" style="width:100%; margin-bottom:0.5rem;" />
    <input id="newProjectTitle" placeholder="Titolo progetto" style="width:100%; margin-bottom:0.5rem;" />
  <input id="newProjectNotes" placeholder="Note (opzionale)" style="width:100%; margin-bottom:0.5rem;" />
    <input id="newProjectNotes" placeholder="Note (opzionale)" style="width:100%; margin-bottom:0.5rem;" />
  <button onclick="addNewProject()">💾 Salva</button>
    <button onclick="addNewProject()">📅 Salva</button>
  <button onclick="closeProjectDialog()">❌ Chiudi</button>
    <button onclick="closeProjectDialog()">❌ Chiudi</button>
</div>
  </div>
 
 
 


   <table id="projectTable" style="width:100%; border-collapse: collapse; font-size: 0.95rem;">
   <table id="projectTable" style="width:100%; border-collapse: collapse; font-size: 0.95rem;">
     <thead>
     <thead>
       <tr style="background:#eaeaea;">
       <tr style="background:#eaeaea;">
         <th>🧱 Modulo</th><th>📊 Stato</th><th>📅 Data</th><th>🔍 Note</th>
         <th>🧱 Modulo</th><th>📊 Stato</th><th>🗓️ Data</th><th>🔍 Note</th>
       </tr>
       </tr>
     </thead>
     </thead>
Riga 97: Riga 59:
   </table>
   </table>


<!-- 🧠 Risposta GPT Analisi Progetto -->
  <div style="margin-top: 1rem;">
<div style="margin-top: 1rem;">
    <label for="response"><strong>🧠 Risposta GPT – Analisi progetto:</strong></label><br>
  <label for="response"><strong>🧠 Risposta GPT – Analisi progetto:</strong></label><br>
    <textarea id="response" rows="8" style="width: 100%; margin-top: 6px; margin-bottom: 15px; padding: 8px; font-family: monospace; background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 6px;" placeholder="Qui apparirà la risposta generata da GPT sull’analisi del progetto..."></textarea>
  <textarea id="response" rows="8" style="width: 100%; margin-top: 6px; margin-bottom: 15px; padding: 8px; font-family: monospace; background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 6px;" placeholder="Qui apparirà la risposta generata da GPT sull’analisi del progetto..."></textarea>
  </div>
</div>
 
 
</div>
</div>


Riga 111: Riga 70:
   <textarea id="promptArea" style="width:100%; height:200px; font-family:monospace;"></textarea><br>
   <textarea id="promptArea" style="width:100%; height:200px; font-family:monospace;"></textarea><br>
   <button onclick="loadPrompt()">📂 Carica prompt.txt</button>
   <button onclick="loadPrompt()">📂 Carica prompt.txt</button>
   <button onclick="savePrompt()">💾 Salva prompt.txt</button>
   <button onclick="savePrompt()">📅 Salva prompt.txt</button>
</div>
</div>


Riga 124: Riga 83:
   </select>
   </select>
   <input type="text" id="newProjectTitle" value="SSO_LinkedIn" placeholder="Project">
   <input type="text" id="newProjectTitle" value="SSO_LinkedIn" placeholder="Project">
   <button onclick="salvaFileDaTextarea()" style="background:#28a745; color:white; border:none; padding:0.4rem 1rem; border-radius:5px; font-weight:bold;">💾 Salva nel progetto</button>
   <button onclick="salvaFileDaTextarea()" style="background:#28a745; color:white; border:none; padding:0.4rem 1rem; border-radius:5px; font-weight:bold;">📅 Salva nel progetto</button>
</div>
</div>


<!-- 📂 Caricamento File GPT -->
<!-- 📁 Caricamento File GPT -->
<div style="margin-top:2rem;">
<div style="margin-top:2rem;">
   <h3>📂 Carica File GPT</h3>
   <h3>📁 Carica File GPT</h3>
   <label>📁 Project: <input type="text" id="gpt-load-project" value="SSO_LinkedIn" /></label>
   <label>📁 Project: <input type="text" id="gpt-load-project" value="SSO_LinkedIn" /></label>
   <label>📂 Subfolder: <input type="text" id="gpt-load-subfolder" value="php" /></label>
   <label>📂 Subfolder: <input type="text" id="gpt-load-subfolder" value="php" /></label>
   <label>📄 Filename: <input type="text" id="gpt-load-filename" placeholder="es: testGPT.php" /></label>
   <label>📄 Filename: <input type="text" id="gpt-load-filename" placeholder="es: testGPT.php" /></label>
   <button onclick="caricaFileGPT()">📂 Carica file</button>
   <button onclick="caricaFileGPT()">📁 Carica file</button>
</div>
</div>



Versione delle 11:59, 4 ago 2025

🔧 Dashboard Operativa – Masticationpedia

Centro di comando per progetti, API, file e backup

📄 Prompt attuale:


📥 Risposta GPT da salvare:


📁 Carica File GPT