1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
| <template>
| <cl-select-table v-model="value" :title="t('选择订单详情')" :service="service.shop.recycleitem" :columns="columns"
| :multiple="multiple" :dict='{ "text": "itemname" }' pickerType="text" />
| </template>
|
| <script setup lang="ts">
| defineOptions({
| name: "recycle-item-select"
| });
|
| import { useCool } from "/@/cool";
| import { useI18n } from "vue-i18n";
| import { CrudProps } from "/#/crud";
| import { ref, useModel } from "vue";
|
| const props = defineProps({
| ...CrudProps,
| modelValue: null,
| multiple: Boolean
| });
|
| const { service } = useCool();
| const { t } = useI18n();
|
| const value = useModel(props, "modelValue");
|
| const columns = ref([
| { label: t("订单编号"), prop: "orderNo", minWidth: 140 },
| { label: t("项目名称"), prop: "itemName", minWidth: 140 },
| { label: t("分类ID"), prop: "categoryId", minWidth: 120 },
| { label: t("重量"), prop: "weight", minWidth: 140, sortable: "custom" },
| { label: t("单价"), prop: "unitPrice", minWidth: 140, sortable: "custom" },
| { label: t("金额"), prop: "amount", minWidth: 140, sortable: "custom" },
| { label: t("碳积分"), prop: "carbonPoint", minWidth: 140, sortable: "custom" }
| ]);
| </script>
|
|