统一后台状态列顺序、详情布局与测量计费展示
This commit is contained in:
@@ -89,6 +89,18 @@ describe('CustomerBillingRulesPanel', () => {
|
||||
expect(document.body.textContent).toContain('标准中箱')
|
||||
})
|
||||
|
||||
it('shows weighted volume and volume weight with the coefficient applied to all three dimensions', async () => {
|
||||
vi.mocked(listCustomerChargeRules).mockResolvedValue([{ ...chargeRule, defaultRule: true, lengthFactor: 1.25 }])
|
||||
const wrapper = mount(CustomerBillingRulesPanel, { attachTo: document.body, props: { customerId: '8', customerName: '柏悦物流' }, global: { plugins: [ElementPlus] } })
|
||||
await flushPromises()
|
||||
|
||||
const chargeTable = wrapper.findAll('.el-table')[1]!
|
||||
const largeRow = chargeTable.findAll('.el-table__body tbody tr')[3]!
|
||||
const values = largeRow.findAll('td').map(cell => cell.text())
|
||||
expect(values[4]).toBe('0.293')
|
||||
expect(values[6]).toBe('48.93')
|
||||
})
|
||||
|
||||
it('hides permission codes in the no-access state', async () => {
|
||||
const auth = useAuthStore()
|
||||
auth.permissions = []
|
||||
|
||||
Reference in New Issue
Block a user