|
|
@@ -55,6 +55,10 @@ import {
|
|
|
withdrawPresignTransfer
|
|
|
} from '../../api/market.js'
|
|
|
import { collectAllowedActions } from '../../market/action-policy.js'
|
|
|
+import {
|
|
|
+ isPaymentEntryView,
|
|
|
+ filterProtocolActionsForPaymentEntry
|
|
|
+} from '../../market/payment-entry.js'
|
|
|
import { marketErrorMessage } from '../../market/market-error.js'
|
|
|
import { getMarketModule } from '../../market/module-registry.js'
|
|
|
import { resolveStatusTone } from '../../market/status-tone.js'
|
|
|
@@ -105,11 +109,17 @@ const statusTone = computed(() => resolveStatusTone(
|
|
|
))
|
|
|
const actionPending = ref(false)
|
|
|
const pendingAction = ref('')
|
|
|
-const allowedActions = computed(() => collectAllowedActions(
|
|
|
- context.value.module,
|
|
|
- context.value.marketRole,
|
|
|
- detail.value
|
|
|
-))
|
|
|
+const allowedActions = computed(() => {
|
|
|
+ const raw = collectAllowedActions(
|
|
|
+ context.value.module,
|
|
|
+ context.value.marketRole,
|
|
|
+ detail.value
|
|
|
+ )
|
|
|
+ if (context.value.module === 'protocol' && isPaymentEntryView(route.query)) {
|
|
|
+ return filterProtocolActionsForPaymentEntry(raw)
|
|
|
+ }
|
|
|
+ return raw
|
|
|
+})
|
|
|
const sections = computed(() => {
|
|
|
if (moduleContract.value.detailSections) return moduleContract.value.detailSections(detail.value)
|
|
|
if (Array.isArray(detail.value?.sections)) return detail.value.sections
|