feat: Remove duplicate Switch Component (#4427)

This commit is contained in:
Pranav Raj S
2022-04-08 18:25:08 +05:30
committed by GitHub
parent bc7bcc20b8
commit b1efcde495
5 changed files with 67 additions and 118 deletions

View File

@@ -34,9 +34,9 @@
<td>{{ automation.name }}</td>
<td>{{ automation.description }}</td>
<td>
<toggle-button
:active="automation.active"
@click="toggleAutomation(automation, automation.active)"
<woot-switch
:value="automation.active"
@input="toggleAutomation(automation, automation.active)"
/>
</td>
<td>{{ readableTime(automation.created_on) }}</td>
@@ -131,12 +131,11 @@ import AddAutomationRule from './AddAutomationRule.vue';
import EditAutomationRule from './EditAutomationRule.vue';
import alertMixin from 'shared/mixins/alertMixin';
import timeMixin from 'dashboard/mixins/time';
import ToggleButton from 'dashboard/components/buttons/ToggleButton';
export default {
components: {
AddAutomationRule,
EditAutomationRule,
ToggleButton,
},
mixins: [alertMixin, timeMixin],
data() {

View File

@@ -62,7 +62,9 @@
/>
</div>
<div class="small-12 medium-3 business-hours">
<span class="business-hours-text">{{ $t('REPORT.BUSINESS_HOURS') }}</span>
<span class="business-hours-text margin-right-small">
{{ $t('REPORT.BUSINESS_HOURS') }}
</span>
<span>
<woot-switch v-model="businessHoursSelected" />
</span>

View File

@@ -146,9 +146,11 @@
/>
</div>
<div class="small-12 medium-3 business-hours">
<span class="business-hours-text">{{ $t('REPORT.BUSINESS_HOURS') }}</span>
<span>
<woot-switch v-model="businessHoursSelected" />
<span class="business-hours-text margin-right-small">
{{ $t('REPORT.BUSINESS_HOURS') }}
<span>
<woot-switch v-model="businessHoursSelected" />
</span>
</span>
</div>
</div>