优化
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
import { readFileSync } from 'node:fs'
|
||||
import { resolve } from 'node:path'
|
||||
import { describe, expect, it } from 'vitest'
|
||||
|
||||
describe('InboundTaskList measurement scope', () => {
|
||||
it('uses the inbound tenant isolation key for measurement and review requests', () => {
|
||||
const source = readFileSync(resolve('src/modules/inbounds/components/InboundTaskList.vue'), 'utf8')
|
||||
|
||||
expect(source.match(/:tenant-id="selectedInbound\.tenantId"/g)).toHaveLength(2)
|
||||
expect(source).not.toContain('selectedInbound.customerId || selectedInbound.tenantId')
|
||||
})
|
||||
})
|
||||
@@ -260,7 +260,7 @@ onBeforeUnmount(() => { disposed = true; requestSerial += 1 })
|
||||
<el-dialog
|
||||
v-model="taskDialogOpen"
|
||||
:title="selectedInbound ? `${taskLabel} · ${selectedInbound.inboundCode || selectedInbound.id}` : taskLabel"
|
||||
width="min(1500px, calc(100vw - 32px))"
|
||||
width="min(1180px, calc(100vw - 32px))"
|
||||
top="4vh"
|
||||
destroy-on-close
|
||||
append-to-body
|
||||
@@ -268,13 +268,13 @@ onBeforeUnmount(() => { disposed = true; requestSerial += 1 })
|
||||
>
|
||||
<MeasurementReviewPanel
|
||||
v-if="isReview && selectedInbound"
|
||||
:customer-id="selectedInbound.customerId || selectedInbound.tenantId"
|
||||
:tenant-id="selectedInbound.tenantId"
|
||||
:inbound-id="selectedInbound.id"
|
||||
@changed="handleTaskChanged"
|
||||
/>
|
||||
<InboundMeasurementPanel
|
||||
v-else-if="selectedInbound"
|
||||
:customer-id="selectedInbound.customerId || selectedInbound.tenantId"
|
||||
:tenant-id="selectedInbound.tenantId"
|
||||
:inbound-id="selectedInbound.id"
|
||||
@changed="handleTaskChanged"
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user