diff --git a/.dev-module-state.json b/.dev-module-state.json new file mode 100644 index 0000000..55a39e2 --- /dev/null +++ b/.dev-module-state.json @@ -0,0 +1,5 @@ +{ + "srvmonitor": true, + "itassets": true, + "networkview": true +} \ No newline at end of file diff --git a/.dev-pids b/.dev-pids index 79099e7..bf49aab 100644 --- a/.dev-pids +++ b/.dev-pids @@ -1,5 +1,5 @@ -77016 -77018 -77020 -77022 -77024 +18392 +18395 +18398 +18401 +18405 diff --git a/digiserver-v2/app/templates/players/add_player.html b/digiserver-v2/app/templates/players/add_player.html index 391103a..2b5342a 100644 --- a/digiserver-v2/app/templates/players/add_player.html +++ b/digiserver-v2/app/templates/players/add_player.html @@ -7,54 +7,82 @@ .form-group { margin-bottom: 1rem; } .form-group label { font-weight: bold; display: block; margin-bottom: 0.5rem; } body.dark-mode .form-group label { color: #e2e8f0; } - + .form-control { width: 100%; padding: 0.5rem; border: 1px solid #ddd; border-radius: 4px; + box-sizing: border-box; } body.dark-mode .form-control { background: #1a202c; border-color: #4a5568; color: #e2e8f0; } body.dark-mode .form-control:focus { border-color: #7c3aed; outline: none; } - + .form-help { color: #6c757d; font-size: 0.875rem; } body.dark-mode .form-help { color: #718096; } - + .section-header { margin-top: 2rem; padding-bottom: 0.5rem; border-bottom: 2px solid; } - .section-header.blue { border-color: #007bff; } - body.dark-mode .section-header.blue { border-color: #667eea; } + .section-header.blue { border-color: #007bff; } + body.dark-mode .section-header.blue { border-color: #667eea; } .section-header.green { border-color: #28a745; } body.dark-mode .section-header.green { border-color: #48bb78; } .section-header.yellow { border-color: #ffc107; } body.dark-mode .section-header.yellow { border-color: #ecc94b; } .section-header.purple { border-color: #9b59b6; } body.dark-mode .section-header.purple { border-color: #b794f6; } - + body.dark-mode h1, body.dark-mode h3, body.dark-mode h4 { color: #e2e8f0; } body.dark-mode p { color: #a0aec0; } - + .info-box { background-color: #e7f3ff; border-left: 4px solid #007bff; padding: 1rem; margin: 2rem 0; } - body.dark-mode .info-box { - background-color: #1a365d; border-left-color: #667eea; - } + body.dark-mode .info-box { background-color: #1a365d; border-left-color: #667eea; } .info-box h4 { margin-top: 0; color: #007bff; } body.dark-mode .info-box h4 { color: #667eea; } - .info-box code { - background: #f4f4f4; padding: 2px 6px; border-radius: 3px; - } - body.dark-mode .info-box code { - background: #2d3748; color: #e2e8f0; - } + .info-box code { background: #f4f4f4; padding: 2px 6px; border-radius: 3px; } + body.dark-mode .info-box code { background: #2d3748; color: #e2e8f0; } body.dark-mode small { color: #718096; } - - .ssh-section { - background-color: #f8f9fa; padding: 1.5rem; border-radius: 4px; margin-bottom: 2rem; + + /* Mode chooser cards */ + .mode-chooser { + display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-bottom: 2rem; } - body.dark-mode .ssh-section { background-color: #2d3748; } - + @media (max-width: 700px) { .mode-chooser { grid-template-columns: 1fr; } } + + .mode-card { + border: 2px solid #ddd; border-radius: 8px; padding: 1.5rem; + cursor: pointer; transition: border-color 0.2s, box-shadow 0.2s; + background: #fff; text-align: center; + } + body.dark-mode .mode-card { background: #2d3748; border-color: #4a5568; } + + .mode-card:hover { border-color: #007bff; box-shadow: 0 4px 12px rgba(0,123,255,0.15); } + body.dark-mode .mode-card:hover { border-color: #667eea; } + + .mode-card.active { border-color: #007bff; box-shadow: 0 4px 12px rgba(0,123,255,0.2); } + body.dark-mode .mode-card.active { border-color: #667eea; box-shadow: 0 4px 12px rgba(102,126,234,0.25); } + + .mode-card.active-deploy { border-color: #28a745; box-shadow: 0 4px 12px rgba(40,167,69,0.2); } + body.dark-mode .mode-card.active-deploy { border-color: #48bb78; } + + .mode-icon { font-size: 2.5rem; margin-bottom: 0.5rem; } + .mode-title { font-size: 1.15rem; font-weight: bold; margin-bottom: 0.4rem; } + body.dark-mode .mode-title { color: #e2e8f0; } + .mode-desc { font-size: 0.875rem; color: #6c757d; } + body.dark-mode .mode-desc { color: #a0aec0; } + + /* Panel visibility */ + .mode-panel { display: none; } + .mode-panel.active { display: block; } + + /* SSH section */ + .ssh-section { + background-color: #f8f9fa; padding: 1.5rem; border-radius: 6px; margin-bottom: 2rem; + } + body.dark-mode .ssh-section { background-color: #1e2a38; } + .connection-status { padding: 1rem; border-radius: 4px; margin-top: 1rem; display: none; } @@ -64,141 +92,273 @@ .connection-status.error { background-color: #f8d7da; border: 1px solid #f5c6cb; color: #721c24; display: block; } - body.dark-mode .connection-status.success { - background-color: #22543d; border-color: #2f855a; color: #9ae6b4; - } - body.dark-mode .connection-status.error { - background-color: #742a2a; border-color: #c53030; color: #fc8181; - } - - .player-form-section { display: none; } - .player-form-section.active { display: block; } - + body.dark-mode .connection-status.success { background-color: #22543d; border-color: #2f855a; color: #9ae6b4; } + body.dark-mode .connection-status.error { background-color: #742a2a; border-color: #c53030; color: #fc8181; } + + /* Deploy-form hidden until SSH verified */ + .deploy-player-form { display: none; } + .deploy-player-form.active { display: block; } + .btn { padding: 0.5rem 1rem; margin-right: 0.5rem; margin-bottom: 0.5rem; border: none; border-radius: 4px; cursor: pointer; font-size: 0.9rem; + text-decoration: none; display: inline-block; } .btn:disabled { opacity: 0.5; cursor: not-allowed; } - - .btn-primary { background-color: #007bff; color: white; } + .btn-primary { background-color: #007bff; color: white; } .btn-primary:hover:not(:disabled) { background-color: #0056b3; } - .btn-success { background-color: #28a745; color: white; } + .btn-success { background-color: #28a745; color: white; } .btn-success:hover:not(:disabled) { background-color: #218838; } .btn-secondary { background-color: #6c757d; color: white; } .btn-secondary:hover:not(:disabled) { background-color: #5a6268; } - + .loading-spinner { display: inline-block; width: 1rem; height: 1rem; - border: 2px solid rgba(255, 255, 255, 0.3); border-radius: 50%; + border: 2px solid rgba(255,255,255,0.3); border-radius: 50%; border-top-color: white; animation: spin 1s linear infinite; margin-right: 0.5rem; } @keyframes spin { to { transform: rotate(360deg); } } - - .row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; } - .row.full { grid-template-columns: 1fr; } - @media (max-width: 768px) { .row { grid-template-columns: 1fr; } } - - .hidden-field { display: none; } + + .row2col { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; } + @media (max-width: 768px) { .row2col { grid-template-columns: 1fr; } } -
- Create a new digital signage player with automatic code deployment via SSH +
+ Choose how you want to add the player to the system.
-app_config.json on the device yourself.
+ First, test SSH connection to the target host for player deployment
- -+ Test SSH connectivity to the target Linux host before proceeding. +
+ ++ Create a new digital signage player with automatic code deployment via SSH +
+ +First, test SSH connection to the target host for player deployment
+ +