gaoluyang
3 天以前 c4d25912d11ab9059f8165c25a161634bb9b5e97
proapp
1.工作台分类修改
已修改3个文件
131 ■■■■■ 文件已修改
src/config/oaWorkbench.js 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/pages/indexItem.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/pages/works.vue 83 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/config/oaWorkbench.js
@@ -5,64 +5,26 @@
 */
export const OA_MODULES = [
  {
    key: "HrManage",
    name: "人事管理",
    key: "HumanResources",
    name: "人力资源",
    children: [
      // { label: "员工档案", icon: "/static/images/icon/renyuanxinzi.svg", path: OA_NAV.staffArchive },
      // { label: "员工合同", icon: "/static/images/icon/hetongguanli.svg", path: OA_NAV.staffContract },
      { label: "转正申请", icon: "/static/images/icon/hetongguanli.svg", path: OA_NAV.regularApply },
      { label: "调岗申请", icon: "/static/images/icon/renyuanxinzi.svg", path: OA_NAV.transferApply },
      // { label: "离职申请", icon: "/static/images/icon/qingjiaguanli.svg", path: OA_NAV.resignApply },
      { label: "工作交接", icon: "/static/images/icon/gongchuguanli.svg", path: OA_NAV.workHandover },
      // { label: "岗位管理", icon: "/static/images/icon/gongxuguanli.svg", path: OA_NAV.postManage },
    ],
  },
  {
    key: "AttendManage",
    name: "假勤管理",
    key: "CollaborativeOffice",
    name: "协同办公",
    children: [
      { label: "请假申请", icon: "/static/images/icon/qingjiaguanli.svg", path: OA_NAV.leaveApply },
      { label: "加班申请", icon: "/static/images/icon/dakaqiandao.svg", path: OA_NAV.overtimeApply },
    ],
  },
  {
    key: "ReimburseManage",
    name: "报销管理",
    children: [
      { label: "差旅报销", icon: "/static/images/icon/chuchaiguanli.svg", path: OA_NAV.travelReimburse },
      { label: "费用报销", icon: "/static/images/icon/baoxiaoguanli.svg", path: OA_NAV.costReimburse },
    ],
  },
  // {
  //   key: "ContractManage",
  //   name: "合同管理",
  //   children: [
  //     { label: "采购合同", icon: "/static/images/icon/caigoutaizhang.svg", path: OA_NAV.purchaseContract },
  //     { label: "销售合同", icon: "/static/images/icon/xiaoshoutaizhang.svg", path: OA_NAV.saleContract },
  //   ],
  // },
  {
    key: "ApproveManage",
    name: "审批管理",
    children: [
      { label: "审批列表", icon: "/static/images/icon/xietongshenpi.svg", path: OA_NAV.approveList },
      { label: "审批模板", icon: "/static/images/icon/guizhangzhidu.svg", path: OA_NAV.approveTemplate },
    ],
  },
  // {
  //   key: "EnterpriseNews",
  //   name: "企业新闻",
  //   children: [
  //     { label: "企业新闻", icon: "/static/images/icon/zhishiku.svg", path: OA_NAV.enterpriseNews },
  //   ],
  // },
  // {
  //   key: "NoticeAnnouncement",
  //   name: "公告通知",
  //   children: [
  //     { label: "公告通知", icon: "/static/images/icon/tongzhigonggao.svg", path: OA_NAV.noticeAnnouncement },
  //   ],
  // },
];
/** 工作台扁平菜单(纯前端配置) */
src/pages/indexItem.vue
@@ -27,7 +27,6 @@
<script setup>
  import { onMounted, reactive, ref } from "vue";
  import { OA_WORKBENCH_ITEMS } from "@/config/oaWorkbench.js";
  import useUserStore from "@/store/modules/user";
  import { onLoad } from "@dcloudio/uni-app";
  import PageHeader from "@/components/PageHeader.vue";
@@ -111,7 +110,6 @@
      { icon: "/static/images/icon/baojiaguanli.svg", label: "报价审批" },
      { icon: "/static/images/icon/fahuoguanli.svg", label: "发货审批" },
    ],
    "OA办公": OA_WORKBENCH_ITEMS.map(item => ({ ...item })),
  };
  // 处理常用功能点击
src/pages/works.vue
@@ -1,28 +1,5 @@
<template>
  <view class="content">
    <!-- OA办公模块 -->
    <view class="common-module oa-module"
          v-if="hasOaItems">
      <view class="module-header">
        <view class="module-title-container">
          <text class="module-title">OA办公</text>
        </view>
      </view>
      <view class="module-content">
        <up-grid :border="false"
                 col="4">
          <up-grid-item v-for="(item, index) in oaItems"
                        :key="index"
                        @click="handleCommonItemClick(item)">
            <view class="icon-container">
              <image :src="item.icon"
                     class="item-icon"></image>
            </view>
            <text class="item-label">{{item.label}}</text>
          </up-grid-item>
        </up-grid>
      </view>
    </view>
    <!-- 协同办公模块 -->
    <view class="common-module collaboration-module"
          v-if="hasCollaborationItems">
@@ -331,7 +308,6 @@
  import { userLoginFacotryList } from "@/api/login";
  import { getProductWorkOrderById } from "@/api/productionManagement/productionReporting";
  import DownloadProgressMask from "@/components/DownloadProgressMask.vue";
  import { OA_WORKBENCH_ITEMS } from "@/config/oaWorkbench.js";
  import modal from "@/plugins/modal";
  import useUserStore from "@/store/modules/user";
@@ -510,6 +486,21 @@
      icon: "/static/images/icon/hetongguanli.svg",
      label: "合同管理",
    },
    {
      icon: "/static/images/icon/hetongguanli.svg",
      label: "转正申请",
      path: "/pages/oa/HrManage/regular-apply/index",
    },
    {
      icon: "/static/images/icon/renyuanxinzi.svg",
      label: "调动申请",
      path: "/pages/oa/HrManage/transfer-apply/index",
    },
    {
      icon: "/static/images/icon/gongchuguanli.svg",
      label: "工作交接",
      path: "/pages/oa/HrManage/work-handover/index",
    },
  ]);
  const qualityItems = reactive([
    {
@@ -559,17 +550,22 @@
      label: "安全培训考核",
    },
  ]);
  // OA办公功能数据(纯前端配置,不参与后端权限过滤)
  const oaItems = reactive(
    OA_WORKBENCH_ITEMS.map(item => ({ ...item }))
  );
  // 协同办公功能数据
  const collaborationItems = reactive([
    {
      icon: "/static/images/icon/xietongshenpi.svg",
      label: "协同审批",
    },
    // {
    //   icon: "/static/images/icon/xietongshenpi.svg",
    //   label: "协同审批",
    // },
        {
            icon: "/static/images/icon/guizhangzhidu.svg",
            label: "审批管理",
            path: "/pages/oa/ApproveManage/approve-template/index",
        },
        {
            icon: "/static/images/icon/xietongshenpi.svg",
            label: "协同审批",
            path: "/pages/oa/ApproveManage/approve-list/index",
        },
    {
      icon: "/static/images/icon/huiyiguanli.svg",
      label: "会议管理",
@@ -593,6 +589,26 @@
    {
      icon: "/static/images/icon/kehubaifang.svg",
      label: "客户拜访",
    },
    {
      icon: "/static/images/icon/qingjiaguanli.svg",
      label: "请假申请",
      path: "/pages/oa/AttendManage/leave-apply/index",
    },
    {
      icon: "/static/images/icon/dakaqiandao.svg",
      label: "加班申请",
      path: "/pages/oa/AttendManage/overtime-apply/index",
    },
    {
      icon: "/static/images/icon/chuchaiguanli.svg",
      label: "差旅报销",
      path: "/pages/oa/ReimburseManage/travel-reimburse/index",
    },
    {
      icon: "/static/images/icon/baoxiaoguanli.svg",
      label: "费用报销",
      path: "/pages/oa/ReimburseManage/cost-reimburse/index",
    },
  ]);
@@ -1303,7 +1319,6 @@
  const hasAfterSalesServiceItems = computed(
    () => afterSalesServiceItems.length > 0
  );
  const hasOaItems = computed(() => oaItems.length > 0);
  const hasCollaborationItems = computed(() => collaborationItems.length > 0);
  const hasSafetyItems = computed(() => safetyItems.length > 0);
  const hasQualityItems = computed(() => qualityItems.length > 0);