mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-12 11:20:27 +08:00
实现基本的图表管理
This commit is contained in:
21
web/views/@default/servers/metrics/charts/index.js
Normal file
21
web/views/@default/servers/metrics/charts/index.js
Normal file
@@ -0,0 +1,21 @@
|
||||
Tea.context(function () {
|
||||
this.createChart = function () {
|
||||
teaweb.popup(Tea.url(".createPopup?itemId=" + this.item.id), {
|
||||
callback: function () {
|
||||
teaweb.successRefresh("保存成功")
|
||||
},
|
||||
height: "27em"
|
||||
})
|
||||
}
|
||||
|
||||
this.deleteChart = function (chartId) {
|
||||
let that = this
|
||||
teaweb.confirm("确定要删除这个图表吗?", function () {
|
||||
that.$post(".delete")
|
||||
.params({ chartId: chartId })
|
||||
.success(function () {
|
||||
teaweb.successRefresh("保存成功")
|
||||
})
|
||||
})
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user