* [bug#56919] Adjust host view page.

This commit is contained in:
liyang
2024-11-13 08:32:15 +08:00
committed by 曹延义
parent 1373679f6f
commit 7f6afd21c6
3 changed files with 8 additions and 16 deletions
-2
View File
@@ -3,8 +3,6 @@ ALTER TABLE `zt_host` DROP COLUMN `hardwareType`;
ALTER TABLE `zt_host` DROP COLUMN `cpuBrand`;
ALTER TABLE `zt_host` DROP COLUMN `cpuModel`;
ALTER TABLE `zt_host` DROP COLUMN `provider`;
ALTER TABLE `zt_host` ADD `CD` varchar(32) NOT NULL DEFAULT 'manual' AFTER `name`;
ALTER TABLE `zt_host` ADD `sshPort` mediumint NOT NULL DEFAULT 0 AFTER `ssh`;
ALTER TABLE `zt_deploystep` DROP COLUMN `begin`;
ALTER TABLE `zt_deploystep` DROP COLUMN `end`;
-6
View File
@@ -2698,20 +2698,14 @@ CREATE TABLE `zt_host` (
`vsoft` varchar(30) NOT NULL DEFAULT '',
`heartbeat` datetime NULL,
`zap` varchar(10) NOT NULL DEFAULT '',
`provider` varchar(255) NOT NULL DEFAULT '',
`vnc` int(11) NOT NULL DEFAULT '0',
`ztf` int(11) NOT NULL DEFAULT '0',
`zd` int(11) NOT NULL DEFAULT '0',
`ssh` int(11) NOT NULL DEFAULT '0',
`sshPort` mediumint NOT NULL DEFAULT '0',
`parent` int(11) unsigned NOT NULL DEFAULT '0',
`image` int(11) unsigned NOT NULL DEFAULT '0',
`admin` smallint(5) unsigned NOT NULL DEFAULT '0',
`serverRoom` mediumint(8) unsigned NOT NULL DEFAULT '0',
`serverModel` varchar(256) NOT NULL DEFAULT '',
`hardwareType` varchar(64) NOT NULL DEFAULT '',
`cpuBrand` varchar(128) NOT NULL DEFAULT '',
`cpuModel` varchar(128) NOT NULL DEFAULT '',
`cpuNumber` varchar(16) NOT NULL DEFAULT '',
`cpuCores` varchar(30) NOT NULL DEFAULT '',
`intranet` varchar(128) NOT NULL DEFAULT '',
+8 -8
View File
@@ -32,8 +32,8 @@ detailBody
setClass('table table-fixed canvas host-view-table'),
h::tr
(
h::th($lang->host->CD),
h::td($host->CD),
isset($host->CD) ? h::th($lang->host->CD) : null,
isset($host->CD) ? h::td($host->CD) : null,
h::th($lang->host->name),
h::td($host->name)
),
@@ -44,12 +44,12 @@ detailBody
h::th($lang->host->serverRoom),
h::td(zget($rooms, $host->serverRoom, ""))
),
$host->CD == 'spug' ? h::tr
zget($host, 'CD') == 'spug' ? h::tr
(
h::th($lang->host->admin),
h::td(zget($host, 'admin')),
) : null,
$host->CD == 'spug' ? h::tr
zget($host, 'CD') == 'spug' ? h::tr
(
h::th($lang->host->password),
h::td($lang->host->defaultPWD),
@@ -77,12 +77,12 @@ detailBody
),
h::tr
(
$host->CD != 'spug' ? h::th($lang->host->osName) : null,
$host->CD != 'spug' ? h::td($host->osName) : null,
zget($host, 'CD') != 'spug' ? h::th($lang->host->osName) : null,
zget($host, 'CD') != 'spug' ? h::td($host->osName) : null,
h::th($lang->host->osVersion),
h::td($host->CD != 'spug' ? zget($lang->host->{$host->osName.'List'}, $host->osVersion) : $host->osName)
h::td(zget($host, 'CD') != 'spug' ? zget($lang->host->{$host->osName.'List'}, $host->osVersion) : $host->osName)
),
$host->CD != 'spug' ? h::tr
zget($host, 'CD') != 'spug' ? h::tr
(
h::th($lang->host->status),
h::td($lang->host->statusList[$host->status]),