Add preparing tab, clarify order status actions and stage banners
This commit is contained in:
@@ -15,7 +15,7 @@ export function useOrdersPage() {
|
||||
const companies = ref<Company[]>([])
|
||||
const customers = ref<Customer[]>([])
|
||||
const orderList = ref<Order[]>([])
|
||||
const activeTab = ref('all')
|
||||
const activeTab = ref(typeof route.query.tab === 'string' && route.query.tab.trim() ? route.query.tab.trim() : 'all')
|
||||
const selectedOrderId = ref<string>('')
|
||||
const searchQuery = ref('')
|
||||
const showAddModal = ref(false)
|
||||
@@ -140,6 +140,15 @@ export function useOrdersPage() {
|
||||
},
|
||||
)
|
||||
|
||||
watch(
|
||||
() => route.query.tab,
|
||||
(tab) => {
|
||||
if (typeof tab === 'string' && tab.trim()) {
|
||||
activeTab.value = tab.trim()
|
||||
}
|
||||
},
|
||||
)
|
||||
|
||||
function selectOrder(order: Order, openDetail = false) {
|
||||
selectedOrderId.value = order.id
|
||||
if (openDetail) {
|
||||
|
||||
Reference in New Issue
Block a user