View | Details | Raw Unified | Return to bug 38010
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/js/vue/components/DropdownButtons.vue (+30 lines)
Line 0 Link Here
1
<template>
2
    <div class="btn-group">
3
        <a
4
            class="btn btn-default dropdown-toggle"
5
            data-bs-toggle="dropdown"
6
            href="#"
7
            ><i class="fa fa-plus"></i> New</a
8
        >
9
        <ul class="dropdown-menu">
10
            <li v-for="(item, index) in items" :key="index">
11
                <ButtonLink
12
                    :to="item.to"
13
                    :title="$__(item.title)"
14
                    :callback="item.callback"
15
                />
16
            </li>
17
        </ul>
18
    </div>
19
</template>
20
21
<script>
22
import ButtonLink from "./ButtonLink.vue"
23
24
export default {
25
    components: { ButtonLink },
26
    props: ["items"],
27
}
28
</script>
29
30
<style></style>
(-)a/koha-tmpl/intranet-tmpl/prog/js/vue/components/Vendors/VendorShow.vue (-23 / +25 lines)
Lines 2-11 Link Here
2
    <div v-if="!initialized">{{ $__("Loading") }}</div>
2
    <div v-if="!initialized">{{ $__("Loading") }}</div>
3
    <div v-else id="vendors_show">
3
    <div v-else id="vendors_show">
4
        <Toolbar>
4
        <Toolbar>
5
            <ButtonLink
5
            <DropdownButtons
6
                :to="{ name: 'VendorFormAdd' }"
6
                :items="[
7
                icon="plus"
7
                    {
8
                :title="$__('New vendor')"
8
                        to: {
9
                            path: '/cgi-bin/koha/acqui/basketheader.pl',
10
                            query: { booksellerid: vendor.id, op: 'add_form' },
11
                        },
12
                        title: 'Basket',
13
                        callback: 'redirect',
14
                    },
15
                    {
16
                        to: {
17
                            path: '/cgi-bin/koha/admin/aqcontract.pl',
18
                            query: { booksellerid: vendor.id, op: 'add_form' },
19
                        },
20
                        title: 'Contract',
21
                        callback: 'redirect',
22
                    },
23
                    {
24
                        to: { name: 'VendorFormAdd' },
25
                        title: 'Vendor',
26
                    },
27
                ]"
9
            />
28
            />
10
            <ButtonLink
29
            <ButtonLink
11
                :to="{
30
                :to="{
Lines 15-38 Link Here
15
                icon="pencil"
34
                icon="pencil"
16
                :title="$__('Edit vendor')"
35
                :title="$__('Edit vendor')"
17
            />
36
            />
18
            <ButtonLink
19
                :to="{
20
                    path: '/cgi-bin/koha/acqui/basketheader.pl',
21
                    query: { booksellerid: vendor.id, op: 'add_form' },
22
                }"
23
                icon="plus"
24
                :title="$__('New basket')"
25
                callback="redirect"
26
            />
27
            <ButtonLink
28
                :to="{
29
                    path: '/cgi-bin/koha/admin/aqcontract.pl',
30
                    query: { booksellerid: vendor.id, op: 'add_form' },
31
                }"
32
                icon="plus"
33
                :title="$__('New contract')"
34
                callback="redirect"
35
            />
36
            <ButtonLink
37
            <ButtonLink
37
                :to="{
38
                :to="{
38
                    path: '/cgi-bin/koha/acqui/parcels.pl',
39
                    path: '/cgi-bin/koha/acqui/parcels.pl',
Lines 91-96 import VendorContacts from "./VendorContacts.vue" Link Here
91
import VendorSubscriptions from "./VendorSubscriptions.vue"
92
import VendorSubscriptions from "./VendorSubscriptions.vue"
92
import VendorContracts from "./VendorContracts.vue"
93
import VendorContracts from "./VendorContracts.vue"
93
import VendorBaskets from "./VendorBaskets.vue"
94
import VendorBaskets from "./VendorBaskets.vue"
95
import DropdownButtons from "../DropdownButtons.vue"
94
96
95
export default {
97
export default {
96
    setup() {
98
    setup() {
Lines 146-151 export default { Link Here
146
    components: {
148
    components: {
147
        Toolbar,
149
        Toolbar,
148
        ButtonLink,
150
        ButtonLink,
151
        DropdownButtons,
149
        VendorDetails,
152
        VendorDetails,
150
        VendorOrderingInformation,
153
        VendorOrderingInformation,
151
        VendorInterfaces,
154
        VendorInterfaces,
152
- 

Return to bug 38010