单应用项目,可以创建很多独立工具类页面 ,不用登录 初始化的页面
zhangchen
2025-07-24 e4d0a31d7be408fea3e8e7ba68ed88ff0b05cd7b
ID1625-用户登录功能提示
2个文件已修改
42 ■■■■■ 已修改文件
postcss.config.js 32 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/mobile/bedsideAuxiliaryScreen/components/Header.vue 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
postcss.config.js
@@ -3,22 +3,22 @@
    'postcss-pxtorem': {
      rootValue: 37.5,
      propList: ['*'],
      include: file => {
        if (!file) return false;
        const normalized = file.replace(/\\/g, '/');
        // 只转换 mobile 目录里的样式 OR element-plus 目录里的样式
        // 但 element-plus 样式只在 mobile 目录被引用时才生效,需保证引用范围
        return normalized.includes('/src/views/mobile/') || normalized.includes('/node_modules/element-plus/');
      },
      exclude: file => {
        if (!file) return false;
        const normalized = file.replace(/\\/g, '/');
        // 排除除 element-plus 外的 node_modules,防止无关样式被转
        if (/node_modules/.test(normalized) && !normalized.includes('/node_modules/element-plus/')) {
          return true;
        }
        return false;
      },
      // include: file => {
      //   if (!file) return false;
      //   const normalized = file.replace(/\\/g, '/');
      //   // 只转换 mobile 目录里的样式 OR element-plus 目录里的样式
      //   // 但 element-plus 样式只在 mobile 目录被引用时才生效,需保证引用范围
      //   return normalized.includes('/src/views/mobile/') || normalized.includes('/node_modules/element-plus/');
      // },
      // exclude: file => {
      //   if (!file) return false;
      //   const normalized = file.replace(/\\/g, '/');
      //   // 排除除 element-plus 外的 node_modules,防止无关样式被转
      //   if (/node_modules/.test(normalized) && !normalized.includes('/node_modules/element-plus/')) {
      //     return true;
      //   }
      //   return false;
      // },
      minPixelValue: 2,
    }
  }
src/views/mobile/bedsideAuxiliaryScreen/components/Header.vue
@@ -33,7 +33,7 @@
        alt=""
        @click="openSettingDeviceDialog"
      />
      <img :src="userImg" class="btn-img" alt="" />
      <img :src="userImg" class="btn-img" alt="" @click="openLoginDialog" />
    </div>
  </div>
  <!-- 设置设备编号组件 -->
@@ -51,6 +51,7 @@
import { useBedsideAuxiliaryScreenStore } from "@/store/bedsideAuxiliaryScreen";
import { EPatForm } from "@/store/type/bedsideAuxiliaryScreen.type";
import { ElMessage } from "element-plus";
const bedsideAuxiliaryScreenStore = useBedsideAuxiliaryScreenStore();
@@ -78,6 +79,13 @@
const openSettingDeviceDialog = () => {
  settingDeviceDialogRef.value?.openDialog();
};
const openLoginDialog = () => {
  ElMessage({
    message: "功能开发中,敬请期待!",
    type: "warning",
  });
};
</script>
<style lang="less" scoped>