-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix bug * updata UI * 0.3.2 ### Added - [Files] Files can now be selected multiple files and downloaded, deleted, moved, etc. - [Apps] Support to modify the application opening address.([#204](#204)) ### Changed - [Apps] Hide the display of non-essential environment variables in the application. - [System] Network, disk, cpu, memory, etc. information is modified to be pushed via socket. - [System] Optimize opening speed.([#214](#214)) ### Fixed - [System] Fixed the problem that sync data cannot submit the device ID ([#68](#68)) - [Files] Fixed the code editor center alignment display problem.([#210](#210)) - [Files] Fixed the problem of wrong name when downloading files.([#240](#240)) - [System] Fixed the network display as a negative number problem.([#224](#224)) * Modify log help class * Fix some bugs in 0.3.2 * Solve the operation file queue problem * Exclude web folders * update UI * add cancel file operate * Update UI * Merge sockets to transfer data * Conflict Resolution * Update send data interval * Update UI * fixed bug - Fix the problem of application opening failure on non-80 ports - Modify port failure problem - Modify environment variables disappearing problem
- Loading branch information
Showing
16 changed files
with
165 additions
and
170 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule UI
updated
6 files
+2 −2 | .env.dev | |
+5 −6 | src/components/settings/PortPanel.vue | |
+3 −3 | src/main.js | |
+14 −33 | src/service/info.js | |
+3 −3 | src/views/Home.vue | |
+1 −1 | src/widgets/Cpu.vue |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,20 +21,10 @@ Handshake = socket.casaos.io | |
Token = | ||
USBAutoMount = | ||
|
||
[user] | ||
UserName = | ||
PWD = | ||
Email = [email protected] | ||
Description = description | ||
Initialized = false | ||
Avatar = | ||
NickName = | ||
PublicKey = | ||
|
||
[system] | ||
ConfigStr = | ||
WidgetList = | ||
Analyse = | ||
|
||
|
||
[file] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
* @Author: LinkLeong [email protected] | ||
* @Date: 2021-09-30 18:18:14 | ||
* @LastEditors: LinkLeong | ||
* @LastEditTime: 2022-05-27 18:07:13 | ||
* @LastEditTime: 2022-06-13 15:20:56 | ||
* @FilePath: /CasaOS/route/v1/zima_info.go | ||
* @Description: | ||
* @Website: https://www.casaos.io | ||
|
@@ -12,87 +12,13 @@ package v1 | |
|
||
import ( | ||
"net/http" | ||
"strings" | ||
"time" | ||
"unsafe" | ||
|
||
"github.com/IceWhaleTech/CasaOS/model" | ||
oasis_err2 "github.com/IceWhaleTech/CasaOS/pkg/utils/oasis_err" | ||
"github.com/IceWhaleTech/CasaOS/service" | ||
"github.com/gin-gonic/gin" | ||
) | ||
|
||
// @Summary 获取cpu信息 | ||
// @Produce application/json | ||
// @Accept application/json | ||
// @Tags zima | ||
// @Security ApiKeyAuth | ||
// @Success 200 {string} string "ok" | ||
// @Router /zima/getcpuinfo [get] | ||
func CupInfo(c *gin.Context) { | ||
//检查参数是否正确 | ||
cpu := service.MyService.System().GetCpuPercent() | ||
num := service.MyService.System().GetCpuCoreNum() | ||
data := make(map[string]interface{}) | ||
data["percent"] = cpu | ||
data["num"] = num | ||
c.JSON(http.StatusOK, model.Result{Success: oasis_err2.SUCCESS, Message: oasis_err2.GetMsg(oasis_err2.SUCCESS), Data: data}) | ||
|
||
} | ||
|
||
// @Summary 获取内存信息 | ||
// @Produce application/json | ||
// @Accept application/json | ||
// @Tags zima | ||
// @Security ApiKeyAuth | ||
// @Success 200 {string} string "ok" | ||
// @Router /zima/getmeminfo [get] | ||
func MemInfo(c *gin.Context) { | ||
|
||
//检查参数是否正确 | ||
mem := service.MyService.System().GetMemInfo() | ||
c.JSON(http.StatusOK, model.Result{Success: oasis_err2.SUCCESS, Message: oasis_err2.GetMsg(oasis_err2.SUCCESS), Data: mem}) | ||
|
||
} | ||
|
||
// @Summary 获取硬盘信息 | ||
// @Produce application/json | ||
// @Accept application/json | ||
// @Tags zima | ||
// @Security ApiKeyAuth | ||
// @Success 200 {string} string "ok" | ||
// @Router /zima/getdiskinfo [get] | ||
func DiskInfo(c *gin.Context) { | ||
disk := service.MyService.ZiMa().GetDiskInfo() | ||
c.JSON(http.StatusOK, model.Result{Success: oasis_err2.SUCCESS, Message: oasis_err2.GetMsg(oasis_err2.SUCCESS), Data: disk}) | ||
} | ||
|
||
// @Summary 获取网络信息 | ||
// @Produce application/json | ||
// @Accept application/json | ||
// @Tags zima | ||
// @Security ApiKeyAuth | ||
// @Success 200 {string} string "ok" | ||
// @Router /zima/getnetinfo [get] | ||
func NetInfo(c *gin.Context) { | ||
netList := service.MyService.System().GetNetInfo() | ||
|
||
newNet := []model.IOCountersStat{} | ||
for _, n := range netList { | ||
for _, netCardName := range service.MyService.System().GetNet(true) { | ||
if n.Name == netCardName { | ||
item := *(*model.IOCountersStat)(unsafe.Pointer(&n)) | ||
item.State = strings.TrimSpace(service.MyService.ZiMa().GetNetState(n.Name)) | ||
item.Time = time.Now().Unix() | ||
newNet = append(newNet, item) | ||
break | ||
} | ||
} | ||
} | ||
|
||
c.JSON(http.StatusOK, model.Result{Success: oasis_err2.SUCCESS, Message: oasis_err2.GetMsg(oasis_err2.SUCCESS), Data: newNet}) | ||
} | ||
|
||
// @Summary 获取信息系统信息 | ||
// @Produce application/json | ||
// @Accept application/json | ||
|
Oops, something went wrong.