Skip to content

Commit

Permalink
refactor(components): add a name prop to the period dropdown
Browse files Browse the repository at this point in the history
  • Loading branch information
thread-koder committed Jan 18, 2024
1 parent b0ec6aa commit fd76170
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion components/PeriodDropdown.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div>
<select id="period" name="period" @change="onChange">
<select :id="name" :name="name" @change="onChange">
<option value="last_year">Last Year</option>
<option value="last_30_days" selected>Last 30 Days</option>
<option value="last_month">Last Month</option>
Expand All @@ -24,6 +24,9 @@
<script>
export default {
name: 'PeriodDropdown',
props: {
name: { type: String, default: 'period' },
},
data() {
return {
todayDate: new Date().toLocaleString('en-GB', {
Expand Down

0 comments on commit fd76170

Please sign in to comment.