gtools

package
v0.0.0-...-a30bb73 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2023 License: MIT Imports: 48 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SymbolIntervals = []SymbolInterval{}

Functions

func SavePngFromClipboard

func SavePngFromClipboard() (bool, string)

Types

type App

type App struct {
	Ctx       context.Context
	Log       *logrus.Logger
	Db        *xorm.Engine
	LogFile   string
	DBFile    string
	ConfigMap map[string]map[string]string
	AliOSS    *oss.Client
	Exchange  *gvmbot.Exchange
	Launcher  *launcher.Launcher
}

App 结构体

func NewApp

func NewApp() *App

NewApp 创建一个新的 App 应用程序结构体

func (*App) AddAlertItem

func (a *App) AddAlertItem(item taskmodel.Task) *util.Resp

创建警报

func (*App) AddCmdItem

func (a *App) AddCmdItem(item internal.CmdItem) *util.Resp

func (*App) AddMdDirPath

func (a *App) AddMdDirPath(item internal.MdPath) *util.Resp

添加md文件夹列表

func (*App) AddMdFile

func (a *App) AddMdFile() *util.Resp

添加文件

func (*App) AddSymbolInterval

func (a *App) AddSymbolInterval(symbol string, interval string) RespDate

func (*App) AddTodoItem

func (a *App) AddTodoItem(item internal.TodoItem) *util.Resp

func (*App) AppSetting

func (a *App) AppSetting() *util.Resp

func (*App) BaiDuTrans

func (a *App) BaiDuTrans(query string) *util.Resp

func (*App) BaiduOCR

func (a *App) BaiduOCR(ocrType int8) *util.Resp

func (*App) CleanWebKitCache

func (a *App) CleanWebKitCache() *util.Resp

清理Mac上的Webkit缓存

func (*App) CloseAlert

func (a *App) CloseAlert(id string) *util.Resp

func (*App) CmdHandler

func (a *App) CmdHandler(item internal.CmdItem) *util.Resp

func (*App) CreateNoteFile

func (a *App) CreateNoteFile(dirName string) RespDate

创建笔记文件

func (*App) CreateNotebook

func (a *App) CreateNotebook(dirName string) RespDate

创建笔记本文件夹

func (*App) DelAlertItem

func (a *App) DelAlertItem(id string) *util.Resp

func (*App) DelAlertItemById

func (a *App) DelAlertItemById(item internal.AlertItem) *util.Resp

func (*App) DelCmdItem

func (a *App) DelCmdItem(item internal.CmdItem) *util.Resp

func (*App) DelMdDir

func (a *App) DelMdDir(item internal.MdPath) *util.Resp

删除md文件夹列表

func (*App) DelTodoItem

func (a *App) DelTodoItem(item internal.TodoItem) *util.Resp

func (*App) DelTodoItemById

func (a *App) DelTodoItemById(item internal.TodoItem) *util.Resp

func (*App) DownToLocal

func (a *App) DownToLocal() RespDate

同步到本地

func (*App) ExportHTML

func (a *App) ExportHTML(fpath, content string) *util.Resp

func (*App) GetAlertItem

func (a *App) GetAlertItem(id string) *util.Resp

func (*App) GetAlertList

func (a *App) GetAlertList() *util.Resp

获取全部

func (*App) GetBdOCRToken

func (a *App) GetBdOCRToken() (bool, string)

func (*App) GetCmdItemList

func (a *App) GetCmdItemList() *util.Resp

func (*App) GetConfigMap

func (a *App) GetConfigMap() map[string]map[string]string

获取系统配置

func (*App) GetConfigOnounted

func (a *App) GetConfigOnounted() *util.Resp

页面加载是获取系统配置

func (*App) GetDirs

func (a *App) GetDirs() RespDate

遍历目录

func (*App) GetJGTestDir

func (a *App) GetJGTestDir() RespDate

读取坚果云笔记本

func (*App) GetJGTestDirFile

func (a *App) GetJGTestDirFile(dirName string) RespDate

读取坚果云笔记本文件夹下的笔记

func (*App) GetMdContent

func (a *App) GetMdContent(path string) *util.Resp

获取md文档的全部内容

func (*App) GetMdDirList

func (a *App) GetMdDirList() *util.Resp

获取文件夹列表

func (*App) GetMdFileList

func (a *App) GetMdFileList(dirPath string) *util.Resp

获取文件夹下所有的md文件

func (*App) GetTodoItem

func (a *App) GetTodoItem(id int) *util.Resp

func (*App) GetTodoList

func (a *App) GetTodoList() *util.Resp

func (*App) InitExchange

func (a *App) InitExchange()

func (*App) InitLauncher

func (a *App) InitLauncher()

func (*App) Kline

func (a *App) Kline()

读取坚果云笔记本

func (*App) NewMd

func (a *App) NewMd(path string, content string) *util.Resp

新建md文档

func (*App) OnBeforeClose

func (a *App) OnBeforeClose(ctx context.Context) bool

OnBeforeClose

func (*App) OnDOMReady

func (a *App) OnDOMReady(ctx context.Context)

OnDOMReady

func (*App) OnStartup

func (a *App) OnStartup(ctx context.Context)

startup 在应用程序启动时调用。 上下文被保存 所以我们可以调用 runtime 方法

func (*App) OpenHtmlSaveWindow

func (a *App) OpenHtmlSaveWindow() *util.Resp

func (*App) OpenMdFolderWindow

func (a *App) OpenMdFolderWindow() *util.Resp

func (*App) OpenMdSaveFileWindow

func (a *App) OpenMdSaveFileWindow() *util.Resp

func (*App) ReadNoteFile

func (a *App) ReadNoteFile(dirName, fileName string) RespDate

读取文件

func (*App) RemoveNote

func (a *App) RemoveNote(dirName, fileName string) RespDate

删除笔记

func (*App) RunAlert

func (a *App) RunAlert(id string) *util.Resp

启动一个任务

func (*App) RunTestCode

func (a *App) RunTestCode(alert internal.AlertItem)

func (*App) RunTestFile

func (a *App) RunTestFile(alert internal.AlertItem)

func (*App) SaveImgPath

func (a *App) SaveImgPath()

func (*App) SaveMdContent

func (a *App) SaveMdContent(path string, content string) *util.Resp

保存md文件内容

func (*App) SaveNote

func (a *App) SaveNote(dirName, noteName, noteTitle, noteContent string) RespDate

保存文章(笔记)

func (*App) SetAlertStatus

func (a *App) SetAlertStatus(id int, status bool) *util.Resp

func (*App) SyncToCloud

func (a *App) SyncToCloud() RespDate

同步到云端

func (*App) TxTrans

func (a *App) TxTrans()

func (*App) UpdateAlertItem

func (a *App) UpdateAlertItem(item internal.AlertItem) *util.Resp

func (*App) UpdateConfigByType

func (a *App) UpdateConfigByType(param updatParam) *util.Resp

func (*App) UpdateConfigItem

func (a *App) UpdateConfigItem(item internal.ConfigItem) *util.Resp

func (*App) UpdateTodoItem

func (a *App) UpdateTodoItem(item internal.TodoItem) *util.Resp

func (*App) UploadScreenshot

func (a *App) UploadScreenshot() *util.Resp

type BdTransResult

type BdTransResult struct {
	From        string      `json:"from"`
	To          string      `json:"to"`
	TransResult []transItem `json:"trans_result"`
}

type GvmBotTest

type GvmBotTest struct {
	GvmOptions
	// contains filtered or unexported fields
}

type GvmOptions

type GvmOptions struct {
	Exchange string `json:"exchange" form:"exchange"`
	Symbol   string `json:"symbol" form:"symbol"`
	Interval string `json:"interval" form:"interval"`
	Sname    string `json:"sname" form:"sname"`
	Code     string `json:"code" form:"code"`
}

/策略现场

type MdInfo

type MdInfo struct {
	Fname string `json:"fname"`
	Fpath string `json:"fpath"`
}

type RespDate

type RespDate struct {
	Code int         `json:"code"`
	Data interface{} `json:"data"`
	Msg  string      `json:"msg"`
}

type SymbolInterval

type SymbolInterval struct {
	Symbol   string
	Interval string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL