周宾
5 天以前 d3fdb7d54b346f46aa17484dda5af59d70586dd6
src/pages/productionManagement/productionDispatching/components/DispatchModal.vue
@@ -1,7 +1,7 @@
<template>
   <up-popup
      v-model:show="show"
      mode="bottom"
   <uni-popup
      ref="popup"
      type="bottom"
      :round="20"
      :safeAreaInsetBottom="true"
      @close="handleClose"
@@ -131,7 +131,7 @@
         @confirm="handleDateSelect"
         @cancel="showDatePicker = false"
      />
   </up-popup>
   </uni-popup>
</template>
<script setup>
@@ -141,12 +141,13 @@
import useUserStore from "@/store/modules/user";
import dayjs from "dayjs";
const { proxy } = getCurrentInstance();
const userStore = useUserStore();
const emit = defineEmits(['confirm']);
// 弹窗显示状态
const show = ref(false);
const popup = ref()
const submitting = ref(false);
// 选择器显示状态
@@ -155,12 +156,13 @@
// 用户列表
const userList = ref([]);
const userColumns = computed(() => [
   userList.value.map(user => ({
const userColumns = computed(() => {
   console.log('userList',userList)
   return userList.value.map(user => ({
      label: user.nickName,
      value: user.userId
   }))
]);
});
// 选中的用户名称(用于显示)
const selectedUserName = computed(() => {
@@ -210,8 +212,7 @@
         schedulingUserId: userStore.id,
         schedulingDate: dayjs().format("YYYY-MM-DD")
      });
      show.value = true;
      popup.value.open()
   } catch (error) {
      uni.showToast({
         title: '加载用户列表失败',
@@ -292,7 +293,7 @@
// 关闭弹窗
const handleClose = () => {
   show.value = false;
   popup.value.close()
   showUserPicker.value = false;
   showDatePicker.value = false;