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

(-)a/koha-tmpl/intranet-tmpl/prog/js/vue/components/Vendors/VendorList.vue (-1 / +20 lines)
Lines 16-21 Link Here
16
                @edit="doEdit"
16
                @edit="doEdit"
17
                @delete="doDelete"
17
                @delete="doDelete"
18
                @select="doSelect"
18
                @select="doSelect"
19
                @receive="doReceive"
19
            ></KohaTable>
20
            ></KohaTable>
20
        </div>
21
        </div>
21
        <div v-else class="alert alert-info">
22
        <div v-else class="alert alert-info">
Lines 44-49 export default { Link Here
44
45
45
        const table = ref()
46
        const table = ref()
46
47
48
        const permissionsStore = inject("permissionsStore")
49
        const { isUserPermitted } = permissionsStore
50
47
        return {
51
        return {
48
            vendors,
52
            vendors,
49
            get_lib_from_av,
53
            get_lib_from_av,
Lines 52-57 export default { Link Here
52
            setConfirmationDialog,
56
            setConfirmationDialog,
53
            setMessage,
57
            setMessage,
54
            escape_str,
58
            escape_str,
59
            isUserPermitted,
55
        }
60
        }
56
    },
61
    },
57
    data() {
62
    data() {
Lines 89-94 export default { Link Here
89
                                        row.subscriptions_count === 0),
94
                                        row.subscriptions_count === 0),
90
                            },
95
                            },
91
                        },
96
                        },
97
                        {
98
                            receive: {
99
                                text: this.$__("Receive shipments"),
100
                                icon: "fa fa-inbox",
101
                                should_display: row =>
102
                                    row.active &&
103
                                    this.isUserPermitted(
104
                                        "CAN_user_acquisition_order_receive"
105
                                    ),
106
                            },
107
                        },
92
                    ],
108
                    ],
93
                },
109
                },
94
            },
110
            },
Lines 121-126 export default { Link Here
121
                params: { vendor_id: id },
137
                params: { vendor_id: id },
122
            })
138
            })
123
        },
139
        },
140
        doReceive({ id }, dt, event) {
141
            event.preventDefault()
142
            window.open(`/cgi-bin/koha/acqui/parcels.pl?booksellerid=${id}`)
143
        },
124
        doEdit({ id }, dt, event) {
144
        doEdit({ id }, dt, event) {
125
            this.$router.push({
145
            this.$router.push({
126
                name: "VendorFormAddEdit",
146
                name: "VendorFormAddEdit",
127
- 

Return to bug 38010