Skip to content

Commit

Permalink
Move import link to fundraising overview page
Browse files Browse the repository at this point in the history
  • Loading branch information
mrcage committed Jan 10, 2024
1 parent 24127b6 commit 806af59
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 19 deletions.
15 changes: 2 additions & 13 deletions resources/js/pages/fundraising/DonationsIndexPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,24 +24,21 @@
</template>
</template>
</DonationsTable>
<div class="d-flex">
<ButtonGroup :items="navButtons"/>
<p>
<DonationsExportDialog v-if="can('view-fundraising-entities')"/>
</div>
</p>
</b-container>
</template>

<script>
import DonationsTable from '@/components/fundraising/DonationsTable.vue'
import ButtonGroup from "@/components/common/ButtonGroup.vue";
import DonationsExportDialog from "@/components/fundraising/DonationsExportDialog.vue";
export default {
title() {
return this.$t("Donations");
},
components: {
DonationsTable,
ButtonGroup,
DonationsExportDialog,
},
data () {
Expand All @@ -50,14 +47,6 @@ export default {
currencies: {},
channels: [],
isBusy: false,
navButtons: [
{
to: { name: "fundraising.donations.import" },
icon: "upload",
text: this.$t("Import"),
show: this.can("manage-fundraising-entities")
}
],
}
}
}
Expand Down
8 changes: 7 additions & 1 deletion resources/js/pages/fundraising/FundraisingIndexPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
<b-row>
<b-col
v-for="(button, idx) in buttons.filter(btn => btn.show)" :key="idx"
sm="6" md="6" lg="6" class="mb-4"
sm="6" md="6" lg="4" class="mb-4"
>
<b-button :key="button.text" :to="button.to" class="d-block">
<font-awesome-icon :icon="button.icon"/>
Expand Down Expand Up @@ -70,6 +70,12 @@ export default {
icon: "donate",
text: this.$t("Manage donations"),
show: this.can("view-fundraising-entities")
},
{
to: { name: "fundraising.donations.import" },
icon: "upload",
text: this.$t("Import"),
show: this.can("manage-fundraising-entities")
}
],
error: null,
Expand Down
5 changes: 0 additions & 5 deletions resources/js/router/fundraising.js
Original file line number Diff line number Diff line change
Expand Up @@ -240,11 +240,6 @@ export default [
text: i18n.t('Donation Management'),
to: { name: 'fundraising.index' }
},
{
text: i18n.t('Donations'),
to: { name: "fundraising.donations.index" },
show: can("view-fundraising-entities")
},
{
text: i18n.t('Import'),
}
Expand Down

0 comments on commit 806af59

Please sign in to comment.