update : 21.05.2025 13:32:34,21
This commit is contained in:
parent
781cb51fee
commit
c66fe3881a
@ -85,7 +85,7 @@
|
||||
<div class="user-block">
|
||||
<img class="img-circle " src="{% static 'img/platform.png' %}?ver={% settings_value 'APP_VER' %}" alt="user image">
|
||||
<span class="username"><a href="#">Система</a></span>
|
||||
<span class="description">Shared publicly - 7:30 PM today</span>
|
||||
<span class="description"></span>
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<table class="table text-nowrap table-borderless" >
|
||||
@ -114,7 +114,7 @@
|
||||
<div class="user-block">
|
||||
<img class="img-circle " src="{% static 'img/cpu.png' %}?ver={% settings_value 'APP_VER' %}" alt="user image">
|
||||
<span class="username"><a href="#">ЦП</a></span>
|
||||
<span class="description">Shared publicly - 7:30 PM today</span>
|
||||
<span class="description"></span>
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<table class="table text-nowrap table-borderless" >
|
||||
@ -143,7 +143,7 @@
|
||||
<div class="user-block">
|
||||
<img class="img-circle " src="{% static 'img/memory.png' %}?ver={% settings_value 'APP_VER' %}" alt="user image">
|
||||
<span class="username"><a href="#">Память</a></span>
|
||||
<span class="description">Shared publicly - 7:30 PM today</span>
|
||||
<span class="description"></span>
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<table class="table text-nowrap table-borderless" >
|
||||
@ -172,7 +172,7 @@
|
||||
<div class="user-block">
|
||||
<img class="img-circle " src="{% static 'img/hdd.png' %}?ver={% settings_value 'APP_VER' %}" alt="user image">
|
||||
<span class="username"><a href="#">Диски</a></span>
|
||||
<span class="description">Shared publicly - 7:30 PM today</span>
|
||||
<span class="description"></span>
|
||||
</div>
|
||||
{% for disk in disks %}
|
||||
<div class="col-4">
|
||||
|
||||
@ -23,6 +23,23 @@ from sabron.util import logging
|
||||
|
||||
def get_platform_info():
|
||||
try:
|
||||
platform_version = {
|
||||
'платформа': 'Не определено',
|
||||
'версия': 'Не определено',
|
||||
'релиз': 'Не определено',
|
||||
'система': 'Не определено',
|
||||
'архитектура': 'Не определено',
|
||||
'cpu_name': 'Не определено',
|
||||
'cpu_usage': 'Не определено',
|
||||
'cpu_freq': 'Не определено',
|
||||
'cpu_count': 'Не определено',
|
||||
'cpu_count_logical': 'Не определено',
|
||||
'memory_total': 'Не определено',
|
||||
'memory_used': 'Не определено',
|
||||
'memory_available': 'Не определено',
|
||||
'memory_percent': 'Не определено',
|
||||
'disks':[],
|
||||
}
|
||||
memory = psutil.virtual_memory()
|
||||
m_disk=[]
|
||||
for value in psutil.disk_partitions():
|
||||
@ -61,13 +78,6 @@ def get_platform_info():
|
||||
}
|
||||
return platform_version
|
||||
except Exception as err:
|
||||
platform_version = {
|
||||
'платформа': 'Не определено',
|
||||
'версия': 'Не определено',
|
||||
'релиз': 'Не определено',
|
||||
'система': 'Не определено',
|
||||
'архитектура': 'Не определено',
|
||||
}
|
||||
logging.error(traceback.format_exc())
|
||||
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user