diff --git a/src/api/biz-role-rights.js b/src/api/biz-role-rights.js index e9b4fb3..c4563c8 100644 --- a/src/api/biz-role-rights.js +++ b/src/api/biz-role-rights.js @@ -17,7 +17,6 @@ export default { GlobalOps: { Change: 16384, ReadFullRecord: 8192, Select: 0 }, User: { Change: 2, ReadFullRecord: 1, Select: 131071 }, UserOptions: { Change: 2, ReadFullRecord: 1, Select: 0 }, - Vendor: { Change: 106, ReadFullRecord: 98565, Select: 131071 }, ServerState: { Change: 16384, ReadFullRecord: 131071, Select: 0 }, LogFile: { Change: 0, ReadFullRecord: 24576, Select: 0 }, Backup: { Change: 16384, ReadFullRecord: 8195, Select: 0 }, @@ -38,12 +37,14 @@ export default { Reminder: { Change: 124927, ReadFullRecord: 124927, Select: 124927 }, Review: { Change: 124927, ReadFullRecord: 124927, Select: 124927 }, Integration: { Change: 49514, ReadFullRecord: 49514, Select: 49514 }, + Vendor: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, License: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, TrialLicenseRequest: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, SubscriptionServer: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, Purchase: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, + VendorNotification: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, Product: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, GZCase: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, - VendorNotification: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, - Subscription: { Change: 32842, ReadFullRecord: 65797, Select: 131071 } + Subscription: { Change: 32842, ReadFullRecord: 65797, Select: 131071 }, + SubscriptionItem: { Change: 32842, ReadFullRecord: 65797, Select: 131071 } }; diff --git a/src/api/open-object-handler.js b/src/api/open-object-handler.js index a9e1ef4..880d7b7 100644 --- a/src/api/open-object-handler.js +++ b/src/api/open-object-handler.js @@ -283,6 +283,36 @@ export default { params: { recordid: tid.id } }); break; + case socktype.SubscriptionItem: + (async () => { + try { + const res = await window.$gz.api.get( + `search/ancestor/${tid.type}/${tid.id}` + ); + + if (res.error) { + throw new Error( + window.$gz.errorHandler.errorToString(res, vm) + ); + } + if (res.data.id && res.data.id != 0) { + vm.$router.push({ + name: "subscription-edit", + params: { recordid: res.data.id } + }); + // this.handleOpenObjectClick(vm, { + // type: socktype.Subscription, + // id: res.data.id, + // }); + // return; + } + } catch (e) { + //throw new Error(e); + throw new Error(window.$gz.errorHandler.errorToString(e, vm)); + } + })(); + + break; default: window.$gz.eventBus.$emit( diff --git a/src/views/biz-subscription-item-list.vue b/src/views/biz-subscription-item-list.vue index 598e107..a8d6216 100644 --- a/src/views/biz-subscription-item-list.vue +++ b/src/views/biz-subscription-item-list.vue @@ -132,7 +132,7 @@ function generateMenu(vm) { const menuOptions = { isMain: true, icon: "$sockiFileContract", - title: "SubscriptionList", + title: "SubscriptionItemList", menuItems: [], formData: { sockType: window.$gz.type.Subscription