diff --git a/pages/work/BusinessApproval/ListItem.vue b/pages/work/BusinessApproval/ListItem.vue
index 5c38220..89e7c75 100644
--- a/pages/work/BusinessApproval/ListItem.vue
+++ b/pages/work/BusinessApproval/ListItem.vue
@@ -8,6 +8,20 @@
style="margin: 0;margin-bottom: 20px"
@click="handleDetail(item)"
>
+
+
+
+
+ {{ index + 1 }}
+ {{ item.usernames }}
+
+
+ {{ item.contractcode }}
+
+
+
+
货主:
@@ -25,24 +39,27 @@
订单金额:
{{ item.contractmoney.toFixed(2) }}
-
- 区域:
- {{ item.areaName }}
-
+
+
+
+
\ No newline at end of file
diff --git a/pages/work/BusinessApproval/index.vue b/pages/work/BusinessApproval/index.vue
index 246bf01..fc0ac66 100644
--- a/pages/work/BusinessApproval/index.vue
+++ b/pages/work/BusinessApproval/index.vue
@@ -1,5 +1,5 @@
-
+
@@ -13,7 +13,37 @@
-
+
+
+
+ 已选订单数量:
+ {{ selected.length }}
+
+
+ 已选订单总金额:
+ {{ totalMoney.toFixed(2) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
{
loading.value = false
}
+const selected = ref([])
+const totalMoney = ref(0)
+const handleSelect = (payload) => {
+ const {checked, data} = payload
+ const id = data.saleid
+
+ if (checked) {
+ if (!selected.value.includes(id)) {
+ selected.value.push(id)
+ }
+ } else {
+ selected.value = selected.value.filter(item => item !== id)
+ }
+
+ totalMoney.value = tableData.value.filter(item => selected.value.includes(item.saleid))
+ .map(i => i.contractmoney)
+ .reduce((a, b) => a + b, 0)
+ ?? 0
+
+}
+
+const targetRef = ref(null)
+const isFixed = ref(false)
+
+const handleScroll = () => {
+ if (!targetRef.value) return
+
+ const rect = targetRef.value.$el
+ ? targetRef.value.$el.getBoundingClientRect()
+ : targetRef.value.getBoundingClientRect()
+
+ isFixed.value = rect.top <= -140
+}
+
onMounted(async () => {
await handleQuery()
})
+watch(targetRef, (el) => {
+ if (!el) return
+ window.addEventListener('scroll', handleScroll)
+})
+
+onUnmounted(() => {
+ window.removeEventListener('scroll', handleScroll)
+})