mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
fix(notify): optimization of message template
This commit is contained in:
@@ -13,8 +13,8 @@
|
||||
,外网地址为{{ $d.public_dns }}:{{ $d.public_connect_port }}
|
||||
{{- end -}}
|
||||
|
||||
{{- if and $d.address_type $d.address -}}
|
||||
,服务地址为{{ $d.address_type }}{{ $d.address }}
|
||||
{{- if $d.address -}}
|
||||
,服务地址为{{ $d.address }}
|
||||
{{- end -}}
|
||||
|
||||
{{- if $d.ips -}}
|
||||
@@ -29,8 +29,8 @@
|
||||
,IP地址为{{ $d.ip_addr }}
|
||||
{{- end -}}
|
||||
|
||||
{{- if $d.account -}}
|
||||
,初始帐号为{{ $d.account }}
|
||||
{{- if $d.login_account -}}
|
||||
,初始帐号为{{ $d.login_account }}
|
||||
{{- end -}}
|
||||
|
||||
{{- if $d.password -}}
|
||||
@@ -56,7 +56,7 @@
|
||||
{{- else -}}
|
||||
SSH
|
||||
{{- end -}}
|
||||
或控制面板控制台访问虚拟机。
|
||||
或前往控制台访问虚拟机。
|
||||
{{- end -}}
|
||||
|
||||
{{- if has .resource_type $consoleServiceType -}}
|
||||
|
||||
@@ -9,8 +9,8 @@ Your {{ if $d.brand -}} {{ $d.brand }} {{ end -}} {{ .resource_type_display }} {
|
||||
, the internet address is {{ $d.public_dns }}:{{ $d.public_connect_port }}
|
||||
{{- end -}}
|
||||
|
||||
{{- if and $d.address_type $d.address -}}
|
||||
, the service address is {{ $d.address_type }}{{ $d.address }}
|
||||
{{- if $d.address -}}
|
||||
, the service address is {{ $d.address }}
|
||||
{{- end -}}
|
||||
|
||||
{{- if $d.ips -}}
|
||||
@@ -46,7 +46,7 @@ Your {{ if $d.brand -}} {{ $d.brand }} {{ end -}} {{ .resource_type_display }} {
|
||||
{{- end -}}
|
||||
|
||||
{{- if eq .resource_type "server" -}}
|
||||
, and please use {{ if $d.windows -}} Remote Desktop Connector (RDC) {{ else -}} SSH {{ end -}} or the control panel console to access the VM.
|
||||
, and please use {{ if $d.windows -}} Remote Desktop Connector (RDC) {{ else -}} SSH {{ end -}} or go to the console to access the VM.
|
||||
{{- end -}}
|
||||
|
||||
{{- if has .resource_type $consoleServiceType -}}
|
||||
|
||||
@@ -925,7 +925,7 @@ func (self *SGuest) EventNotify(ctx context.Context, userCred mcclient.TokenCred
|
||||
}
|
||||
loginAccount := meta[api.VM_METADATA_LOGIN_ACCOUNT]
|
||||
if len(loginAccount) > 0 {
|
||||
details.Add(jsonutils.NewString(loginAccount), "account")
|
||||
details.Add(jsonutils.NewString(loginAccount), "login_account")
|
||||
}
|
||||
keypair := self.getKeypairName()
|
||||
if len(keypair) > 0 {
|
||||
|
||||
@@ -429,6 +429,11 @@ func init() {
|
||||
"baremetal",
|
||||
"裸金属",
|
||||
},
|
||||
sI18nElme{
|
||||
api.TOPIC_RESOURCE_SNAPSHOTPOLICY,
|
||||
"snapshot policy",
|
||||
"快照策略",
|
||||
},
|
||||
sI18nElme{
|
||||
string(api.ActionCreate),
|
||||
"created",
|
||||
|
||||
Reference in New Issue
Block a user