<template>
  <wrapper
    fill
    margin
    padding
    background
  >
    <div class="l-grid--info mini">
      <button
        class="o-button"
        @click="onAlarmStratConfig"
      >
        告警策略
      </button>
      <button
        class="o-button"
        @click="onAutoRestartConfig"
      >
        设备定时重启
      </button>
      <alarm-strat-config-dialog ref="alarmStratConfigDialog" />
      <auto-restart-config-dialog ref="autoRestartConfigDialog" />
    </div>
  </wrapper>
</template>

<script>
import AlarmStratConfigDialog from './components/AlarmStratConfigDialog'
import AutoRestartConfigDialog from './components/AutoRestartConfigDialog'

export default {
  name: 'TenantSettings',
  components: {
    AlarmStratConfigDialog,
    AutoRestartConfigDialog
  },
  methods: {
    onAlarmStratConfig () {
      this.$refs.alarmStratConfigDialog.show()
    },
    onAutoRestartConfig () {
      this.$refs.autoRestartConfigDialog.show()
    }
  }
}
</script>
