MT#64432 Fix typo

* Fix missing subscriber_id parameter in setSharedValue()
* rename "options" to "data" for consistency

Change-Id: Ice57d3cb4a2318055c574ea9169a9cf49b9561c5
(cherry picked from commit df136f71aa)
(cherry picked from commit c2e3179bde)
mr14.1.1
Debora Crescenzo 4 months ago committed by Crescenzo Debora
parent d2a8887007
commit 363229e5c8

@ -32,16 +32,16 @@ export async function getEntryById (subscriberId, id) {
})
}
export async function getPhonebook (options) {
export async function getPhonebook (data) {
return getList({
path: `api/v2/subscribers/${options.subscriber_id}/phonebook`,
params: options
path: `api/v2/subscribers/${data.subscriber_id}/phonebook`,
params: data
})
}
export function setSharedValue (subscriberId, phonebookId, value) {
export function setSharedValue (data, value) {
return patchReplace({
path: `api/v2/subscribers/${subscriberId}/phonebook/${phonebookId}`,
path: `api/v2/subscribers/${data.subscriber_id}/phonebook/${data.id}`,
fieldPath: 'shared',
value
})

@ -87,7 +87,7 @@ export default {
async updateSharedValue (context, row) {
const newValue = !row.shared
context.commit('setSharedValue', { id: row.id, value: newValue })
await setSharedValue(row.id, newValue)
await setSharedValue(row, newValue)
}
}
}

Loading…
Cancel
Save