mirror of
https://github.com/IceWhaleTech/CasaOS.git
synced 2025-06-16 05:55:33 +00:00
Dev (#275)
* 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](https://github.com/IceWhaleTech/CasaOS/issues/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](https://github.com/IceWhaleTech/CasaOS/issues/214)) ### Fixed - [System] Fixed the problem that sync data cannot submit the device ID ([#68](https://github.com/IceWhaleTech/CasaOS/issues/68)) - [Files] Fixed the code editor center alignment display problem.([#210](https://github.com/IceWhaleTech/CasaOS/issues/210)) - [Files] Fixed the problem of wrong name when downloading files.([#240](https://github.com/IceWhaleTech/CasaOS/issues/240)) - [System] Fixed the network display as a negative number problem.([#224](https://github.com/IceWhaleTech/CasaOS/issues/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
This commit is contained in:
parent
9d47874ae3
commit
c33af66c6e
@ -18,7 +18,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|
||||||
## [0.3.2-pre] - 2022-06-08
|
## [0.3.2] - 2022-06-10
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
|
2
main.go
2
main.go
@ -100,7 +100,7 @@ func main() {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Println(err)
|
fmt.Println(err)
|
||||||
}
|
}
|
||||||
err = cron2.AddFunc("0/3 * * * * *", func() {
|
err = cron2.AddFunc("0/5 * * * * *", func() {
|
||||||
if service.ClientCount > 0 {
|
if service.ClientCount > 0 {
|
||||||
// route.SendNetINfoBySocket()
|
// route.SendNetINfoBySocket()
|
||||||
// route.SendCPUBySocket()
|
// route.SendCPUBySocket()
|
||||||
|
@ -199,7 +199,6 @@ func GetDownloadFile(c *gin.Context) {
|
|||||||
defer ar.Close()
|
defer ar.Close()
|
||||||
commonDir := file.CommonPrefix(filepath.Separator, list...)
|
commonDir := file.CommonPrefix(filepath.Separator, list...)
|
||||||
|
|
||||||
|
|
||||||
currentPath := filepath.Base(commonDir)
|
currentPath := filepath.Base(commonDir)
|
||||||
|
|
||||||
name := "_" + currentPath
|
name := "_" + currentPath
|
||||||
@ -278,17 +277,20 @@ func DirPath(c *gin.Context) {
|
|||||||
|
|
||||||
//Hide the files or folders in operation
|
//Hide the files or folders in operation
|
||||||
fileQueue := make(map[string]string)
|
fileQueue := make(map[string]string)
|
||||||
for _, v := range service.OpStrArr {
|
if len(service.OpStrArr) > 0 {
|
||||||
v, ok := service.FileQueue.Load(v)
|
for _, v := range service.OpStrArr {
|
||||||
if !ok {
|
v, ok := service.FileQueue.Load(v)
|
||||||
continue
|
if !ok {
|
||||||
}
|
continue
|
||||||
vt := v.(model.FileOperate)
|
}
|
||||||
for _, i := range vt.Item {
|
vt := v.(model.FileOperate)
|
||||||
lastPath := i.From[strings.LastIndex(i.From, "/")+1:]
|
for _, i := range vt.Item {
|
||||||
fileQueue[vt.To+"/"+lastPath] = i.From
|
lastPath := i.From[strings.LastIndex(i.From, "/")+1:]
|
||||||
|
fileQueue[vt.To+"/"+lastPath] = i.From
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pathList := []model.Path{}
|
pathList := []model.Path{}
|
||||||
for i := 0; i < len(info); i++ {
|
for i := 0; i < len(info); i++ {
|
||||||
if _, ok := fileQueue[info[i].Path]; !ok {
|
if _, ok := fileQueue[info[i].Path]; !ok {
|
||||||
|
@ -67,7 +67,7 @@ func (d *diskService) SmartCTL(path string) model.SmartctlA {
|
|||||||
loger.Error("Failed to unmarshal json", zap.Any("err", err))
|
loger.Error("Failed to unmarshal json", zap.Any("err", err))
|
||||||
}
|
}
|
||||||
if !reflect.DeepEqual(m, model.SmartctlA{}) {
|
if !reflect.DeepEqual(m, model.SmartctlA{}) {
|
||||||
Cache.Add(key, m, time.Second*10)
|
Cache.Add(key, m, time.Hour*24)
|
||||||
}
|
}
|
||||||
return m
|
return m
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user