소스 검색

代码上传

zhangqiOMG 2 년 전
부모
커밋
0a55821e5a

+ 1 - 0
.gitignore

@@ -0,0 +1 @@
+node_modules

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 0 - 0
dist/assets/index-f8cf5307.js


+ 1 - 1
src/components/detailTemplate/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <div>
+  <div style="margin-top:10px;">
     <a-card class="mt-10" :headStyle="{padding:'0 10px'}" :bodyStyle="{padding:'20px'}" :bordered="false">
       <template #title>
         <div class="flex-between">

+ 4 - 271
src/components/layout/header.vue

@@ -1,281 +1,14 @@
-
 <template>
-<div class="header">
-  <a-menu style="flex:1" v-model:selectedKeys="current" mode="horizontal" @click="itemClick">
-    <a-sub-menu v-for="item in mods" :key="item.systemmoduleid">
-      <template #title>
-        <div>
-          <!-- <span class="menu-icon">{{item.systemmodulename.substr(0, 1)}}</span> -->
-          <img width="15" style="margin-top:-2px;margin-right:5px" :src="item.iconurl" alt="">
-          {{item.systemmodulename}}
-      </div>
-      </template>
-      <a-menu-item v-for="app in item.apps" :key="app.systemappid" @click="routeChange(app)">{{app.meta.title}}</a-menu-item>
-    </a-sub-menu>
-  </a-menu>
-  <a-space>
-    <a-dropdown>
-      <a class="ant-dropdown-link" @click.prevent>
-        切换主题
-        <DownOutlined />
-      </a>
-      <template #overlay>
-        <a-menu>
-          <a-menu-item>
-            <a @click="setTheme('normal')">默认主题</a>
-          </a-menu-item>
-          <a-menu-item>
-            <a @click="setTheme('light')">明亮主题</a>
-          </a-menu-item>
-          <a-menu-item>
-            <a @click="setTheme('caffairs')">商务主题</a>
-          </a-menu-item>
-        </a-menu>
-      </template>
-    </a-dropdown>
-    <a-button type="text" @click="router.push('/shopCart')">
-      购物车
-      <template #icon>
-        <ShoppingCartOutlined/>
-      </template>
-    </a-button>
-    
-    <a-dropdown class="dropdown-link">
-      <a class="ant-dropdown-link" @click.prevent>
-        {{act_name}}
-        <DownOutlined />
-      </a>
-      <template #overlay>
-        <a-menu>
-          <a-menu-item v-for="item in a_list" :key="item.index">
-            <a @click="accountItemClick(item,false)">{{item.sitename + '-' + item.name}}</a>
-          </a-menu-item>
-          <a-menu-divider />
-          <a-menu-item>
-            <logout-outlined />
-            <a class="color-red" @click="loginOut">&nbsp;退出登录</a>
-          </a-menu-item>
-        </a-menu>
-      </template>
-    </a-dropdown>
-  </a-space>
-</div>
+  <div class="header">
+  </div>
 </template>
 
 <script setup>
-import Api  from '@/api/api'
-import less from 'less'
-
-import { defineComponent,ref, reactive,onMounted,onBeforeMount,createVNode ,watch} from 'vue';
-
-import { useAuthStore } from '../../stores/modules/auth'
-import { storeToRefs } from 'pinia'
-
-import { DownOutlined,LogoutOutlined ,SettingOutlined,ExclamationCircleOutlined,ShoppingCartOutlined} from '@ant-design/icons-vue';
-import {ConfigProvider, Modal } from 'ant-design-vue';
-import { useRouter } from "vue-router";
-const router = useRouter()
-
-const actApp = ref({})
-const colorState = ref({})
-let current = ref([]);
-
-let a_list = ref([]);
-const at_account = ref({})
-const store = useAuthStore()
-
-let { system,mods,act_mods } = storeToRefs(store)
-
-const act_name = ref('')
-const count = ref('')
-const auth = async (data) => {
-  store.systemAuthData(data)
-
-  let app = sessionStorage.getItem('app')
-
-  if (app) 
-    return false
-  if (mods.value) 
-    return sessionStorage.setItem('app',JSON.stringify(mods.value[0].apps[0]))
-  router.push({path:mods.value[0].apps[0].path})
-};
-
-const getAccountList = ()=>{
-  
-  a_list.value = JSON.parse(sessionStorage.getItem('a_list'))
-
-  let hasActAccount = sessionStorage.getItem('active_account') ? true:false
-
-  let act_account = JSON.parse(sessionStorage.getItem('active_account'))
-
-  accountItemClick(hasActAccount ? act_account : a_list.value[0],true)
-  
-};
-
-const accountItemClick = (account,bool)=>{
-
-  setSessionStorage(account)
-
-  at_account.value = account
-
-  let data = {
-    "classname": "sysmanage.develop.userauthforweb.userauth",
-    "method": "query_userauth",
-    "content": {
-      "place": 1
-    },
-    "systemappid": ""
-  }
-  auth(data)
-  if (!bool)
-   return router.go(0)
-}
-const setSessionStorage = (account)=>{
-  sessionStorage.setItem('active_account',JSON.stringify(account))
-  sessionStorage.setItem('token',account.token)
-  act_name.value = `${account.name}-${account.sitename}`
-}
-const routeChange = (app)=>{
-  actApp.value = app
-  sessionStorage.setItem('app',JSON.stringify(app))
-  router.push({path:app.path,meta:{APP:app}})
-}
-
-const itemClick = (item, key, keyPath)=>{
-  current.value = item.keyPath
-}
-const loginOut = ()=>{
-  Modal.confirm({
-    title: '注意',
-    icon: createVNode(ExclamationCircleOutlined),
-    content: '确定登出当前账号吗?',
-    okText: '确认',
-    cancelText: '取消',
-    onOk () {
-      Api.loginout({})
-      router.push({path:'/'})
-    }
-  });
-}
-const setTheme = (themeName)=> {
-  if (themeName === 'light') {
-    colorState.value = {
-      primaryColor: '#f23557',
-      errorColor: '#eb586f',
-      warningColor: '#ffde7d',
-      successColor: '#4aa0d5',
-      infoColor: '#d8e9f0',
-    }
-   
-    ConfigProvider.config({
-      theme: colorState.value
-    });
-    
-  } else if (themeName === 'normal') {
-    colorState.value = {
-      primaryColor: '#4e71f7',
-      errorColor: '#ff4d4f',
-      warningColor: '#faad14',
-      successColor: '#52c41a',
-      infoColor: '#1890ff',
-    }
-    ConfigProvider.config({
-      theme: colorState.value
-    });
-  } else if (themeName === 'caffairs') {
-    colorState.value = {
-      primaryColor: '#404b69',
-      errorColor: '#ff5f5f',
-      warningColor: '#ffc93c',
-      successColor: '#1fab89',
-      infoColor: '#dbedf3',
-    }
-    ConfigProvider.config({
-      theme: colorState.value
-    });
-  }
-  
-}
-const shoppingCartCount = async ()=>{
-  const res = await Api.optionstype('shoppingcartcount')
-  count.value = res.data
-}
-const checkHasApp = (to)=>{
-  let [arr, mode, app] = [[], [], []];
-  system.value.forEach(e=>{
-    mode = mode.concat(...e.modules)
-  })
-
-  mode.forEach(e=>{
-    arr = arr.concat(...e.apps)
-  })
-  let hasApp = arr.some(e=>e.name == to.meta.name)
-  if (!hasApp) 
-    return router.replace({name:'404'})
-}
-const getAppData = ()=> {
-  let app = mods.value.map(e=>e.apps)
-  app.forEach(e=>{
-    e.forEach(a=>{
-      if (router.currentRoute.value.meta.name == a.name) {
-        sessionStorage.setItem('app',JSON.stringify(a))
-      }
-    })
-  })
-}
-onMounted(()=>{
-  getAccountList()
-  store.hideKeyWords(at_account.value)
-  shoppingCartCount()
- 
-})
-onBeforeMount(()=>{
- setTheme('normal')
-})
-watch(() => router.currentRoute.value,(to, from) => {
-  // console.log(to)
-  getAppData()
-  checkHasApp(to)
-})
 </script>
-<style>
-.header .ant-menu-horizontal {
-  border-bottom: none;
-}
-</style>
 <style scoped>
 .header{
-  display: flex;
-  align-items: center;
-  position: sticky;
-  top:0px;
-  padding-right: 60px;
-  border-bottom: 1px solid #f0f0f0;
+  height: 50px;
   background: #fff;
-  z-index: 1000;
-}
-.dropdown-link{
-  margin-top: -1px;
-}
-.color-red{
-  color:red
-}
-.flex{
-  display: flex;
-  align-items: center;
-  justify-content: space-around;
-}
-.menu-icon{
-  display: inline-block;
-  height: 20px;
-  width: 20px;
-  padding-top: -2px;
-  font-size: 10px;
-  text-align: center;
-  line-height: 20px;
-  color: #999;
-  border-radius:100% ;
-  border:1px solid #f1f2f3;
-  background: #f1f2f3;
+  border-bottom:1px solid #f1f2f3
 }
 </style>

+ 7 - 4
src/components/layout/index.vue

@@ -1,10 +1,11 @@
 <template>
   <a-layout class="layout">
     <!-- <web-socket></web-socket> -->
+    <headTemp></headTemp>
     <div class="flex">
-      <asideTemp style="flex:1 0 auto;"></asideTemp>
+      <asideTemp></asideTemp>
+      <menuTemp></menuTemp>
       <a-layout-content class="content-height">
-        <headTemp style="width:100%;margin:10px 0"></headTemp>
         <div :style="{ padding: '0px', minHeight: 'calc(100vh - 146px)'}">
           <router-view v-slot="{ Component }">
             <transition  mode="out-in">
@@ -26,7 +27,8 @@
 </template>
 <script setup>
 import headTemp from './header.vue';
-import asideTemp from './aside.vue'
+import asideTemp from './systemMod.vue'
+import menuTemp from './menu.vue'
 import webSocket from '../webSocket/index.vue'
 import { useRouter } from "vue-router";
 const router = useRouter()
@@ -59,7 +61,8 @@ const router = useRouter()
   background: #fff;
 }
 .content-height{
-  height: calc(100vh - 70px);
+  flex:1;
+  height: calc(100vh - 120px);
   padding:0 10px 10px 10px;
   overflow-y: scroll;
 }

+ 41 - 0
src/components/layout/menu.vue

@@ -0,0 +1,41 @@
+<template>
+  <div class="menu">
+    <a-menu style="flex:1" v-model:selectedKeys="current" mode="inline" @click="itemClick">
+      <a-sub-menu v-for="item in mods" :key="item.systemmoduleid">
+        <template #title>
+          <div>
+            <img width="15" style="margin-top:-2px;margin-right:5px" :src="item.iconurl" alt="">
+            {{item.systemmodulename}}
+        </div>
+        </template>
+        <a-menu-item v-for="app in item.apps" :key="app.systemappid" @click="routeChange(app)">{{app.meta.title}}</a-menu-item>
+      </a-sub-menu>
+    </a-menu>
+  </div>
+</template>
+
+<script setup>
+import { ref,onMounted,watch} from 'vue';
+import { useAuthStore } from '@/stores/modules/auth'
+import { storeToRefs } from 'pinia'
+import { useRouter } from "vue-router"
+import { MenuFoldOutlined,MenuUnfoldOutlined} from '@ant-design/icons-vue'
+const router = useRouter()
+const store = useAuthStore()
+let { mods } = storeToRefs(store)
+
+const current = ref([])
+const itemClick = (item, key, keyPath)=>{
+  current.value = item.keyPath
+}
+const routeChange = (app)=>{
+  store.appData(app)
+  router.push({path:app.path})
+}
+</script>
+<style scoped>
+.menu{
+  width: 180px;
+  background: #fff;
+}
+</style>

+ 16 - 27
src/components/layout/aside.vue → src/components/layout/systemMod.vue

@@ -1,25 +1,12 @@
 <template>
-  <div class="asides" :style="!collapsed?'max-width:230px':'max-width:79px'">
-    <div v-if="siteInfo.attinfos" class="logo-panel flex">
-      <div class="flex">
-        <img style="width:40px" :src="siteInfo.attinfos[0].url" alt="">
-        <h4 v-if="!collapsed">
-          <b>楚楚E订单</b><br/>
-          <small style="color:#999">CHUCHU-ESYSTEM</small>
-        </h4>
-      </div>
-      <menu-fold-outlined v-if="!collapsed" @click="onCollapsed"/>
-    </div>
-    <div class="aside-item" :class="act_sys.systemid == item.systemid?'onSystem':''" v-for="item in system" :key="item.index"  @click="onsystemClick(item)">
-      <span v-if="collapsed" class="menu-icon uncollapsed">{{item.systemname.substr(0, 1)}}</span>
+  <div class="asides">
+    <div class="aside-item" :class="act_sys.systemid == item.systemid?'onSystem':''" v-for="item in system" :key="item.index"  @click="onSystemClick(item)">
+      <span v-if="collapsed" class="menu-icon uncollapsed"><span class="aside-menu-icon">{{item.systemname.substr(0, 1)}}</span></span>
       <span class="collapsed" v-if="!collapsed">
         <span class="aside-menu-icon">{{item.systemname.substr(0, 1)}}</span>
         {{item.systemname}}
       </span>
     </div>
-    <div v-if="collapsed" class="showCollapse">
-      <menu-unfold-outlined @click="onCollapsed"/>
-    </div>
   </div>
 </template>
 
@@ -35,19 +22,22 @@ const router = useRouter()
 const store = useAuthStore()
 
 const act_sys = ref({})
+
 let { system,mods } = storeToRefs(store)
 
 const siteInfo = ref({})
-const collapsed = ref(false)
-const onsystemClick = (item)=>{
-  act_sys.value = item
-  mods.value = item.modules
-  router.push({path:item.modules[0].apps[0].path})
+const collapsed = ref(true)
+
+const onSystemClick = (system)=>{
+  act_sys.value = system
+  // mods.value = item.modules
+  // router.push({path:item.modules[0].apps[0].path})
+  store.modulesData(system)
 }
 
 const siteData = async ()=>{
   const res = await Api.requested({
-    classname:'webmanage.site.site',
+    classname:'manager.site.site',
     method:'querySite',
     content:{}
   })
@@ -58,6 +48,7 @@ const onCollapsed = ()=>{
 }
 
 onMounted (()=>{
+  store.systemData()
   siteData()
 })
 
@@ -68,17 +59,15 @@ watch (()=>system.value,() => {
 <style less scoped>
 .asides{
   position: relative;
-  width: 230px;
+  width:79px;
   background: #fff;
-  box-shadow: 2px 0 6px rgba(168, 173, 177, 0.35);
   transition: .1s ease-out all;
+  border-right: 1px solid #f1f2f3;
 }
 .aside-item {
   cursor: pointer;
   color: #333;
-  /* margin:10px; */
-  /* border-radius:5px; */
-  margin: 35px 0;
+  margin:10px 0 35px 0;
   transition: .1s linear;
   overflow: hidden;
 }

+ 4 - 11
src/components/listTemplate/field/index.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="fieldPanel">
-    <a-card>
+    <a-card :bodyStyle="{padding:'20px 10px 0 10px'}">
       <!-- <template #title>筛选</template> -->
       <a-form
         ref="formRef"
@@ -10,8 +10,8 @@
         :wrapper-col="{ span: 18 }"
         :model="formState"
         @finish="onFinish">
-          <a-row>
-            <a-col v-for="(i) in searchType" :key="i"  :md="{ span: 24, offset: 0 }" :lg="{ span: 8, offset: 0 }" :xxl="{span: 6, offset: 0 }">
+          <a-row :gutter="16">
+            <a-col v-for="(i) in searchType" :key="i"  :md="{ span: 24, offset: 0 }" :lg="{ span: 6, offset: 0 }" :xxl="{span: 6, offset: 0 }">
               <a-form-item
                 
                 :name="i.key"
@@ -27,20 +27,13 @@
                 <a-range-picker style="width:100%" v-if="i.type == 'datepickerRange'" v-model:value="formState[i.key]" value-format="YYYY-MM-DD" @change="dateRangeChange(formState[i.key],i)"/>
               </a-form-item>
             </a-col>
-          </a-row>
-          <a-row style="text-align:right">
-            <a-col :span="24">
+            <a-col :md="{ span: 24, offset: 0 }" :lg="{ span: 6, offset: 0 }" :xxl="{span: 6, offset: 0 }">
               <a-space>
                 <a-button type="primary" html-type="submit">查询</a-button>
                 <a-button @click="() => formRef.resetFields()">重置</a-button>
               </a-space>
             </a-col>
           </a-row>
-          <a-row>
-            <a-col :span="24">
-              <slot name="more"></slot>
-            </a-col>
-          </a-row>
       </a-form>
     </a-card>
   </div>

+ 3 - 3
src/components/listTemplate/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <div>
+  <div style="margin-top:10px">
     <div>
       <field v-if="searchType" :searchType="searchType" @onSubmit="search"></field>
     </div>
@@ -59,7 +59,7 @@
   import { useBaseStore } from '@/stores/modules/base'
   const store = useAuthStore()
   const base = useBaseStore()
-  let { system,mods,act_mods } = storeToRefs(store)
+  let { app } = storeToRefs(store)
   let { PageUpParam,nowPageData,keyid,pageTotal } = storeToRefs(base)
   const router = useRouter()
   const props = defineProps({
@@ -85,7 +85,7 @@
   }
   const getTableLayout = ()=>{
     let _app = {}
-    _app = JSON.parse(sessionStorage.getItem('app'))
+    _app = app.value
     columns.value = _app.meta.tables[props.tableName].tablecols.map(e=>{
       return {
         title:e.title,

+ 1 - 1
src/components/upload/index.vue

@@ -136,7 +136,7 @@ const appfolderid = ref('')
 const salematerialfolderid = ref('')
 const querySite_Parameter = async ()=> {
   const res = await Api.requested({
-    "classname": "webmanage.site.site",
+    "classname": "manager.site.site",
     "method": "querySite_Parameter",
     "content": {}
   })

+ 4 - 2
src/router/index.js

@@ -1,4 +1,5 @@
 import { createRouter, createWebHashHistory } from 'vue-router'
+import modelNormal from './modelNormal.js'
 const routes = [
   {
     path: '/',
@@ -8,7 +9,8 @@ const routes = [
   {
     path: '/home',
     name: 'home',
-    component: ()=>import(/* webpackChunkName: "about" */ '@/components/layout/index.vue')
+    component: ()=>import(/* webpackChunkName: "about" */ '@/components/layout/index.vue'),
+    children:[]
   },
   {
     path: '/404',
@@ -20,7 +22,7 @@ const routes = [
     redirect: "/404"
   },
 ]
-
+routes[1].children = [...routes[1].children,...modelNormal]
 const router = createRouter({
   history: createWebHashHistory(),
   routes

+ 63 - 0
src/router/modelNormal.js

@@ -0,0 +1,63 @@
+const moduleNormal = [
+  {
+    path: '/reportcenter',
+    name: 'reportcenter',
+    meta: {
+      title: '报表中心',
+      name: 'reportcenter',
+      keepAlive:false
+    },
+    component: ()=>import(/* webpackChunkName: "about" */ '@/system/moduleNormal/reportcenter/index.vue'),
+  },
+  {
+    path: '/custom_option',
+    name: 'custom_option',
+    meta: {
+      title: '自定义选项分类',
+      name: 'custom_option',
+      keepAlive:false
+    },
+    component: ()=>import(/* webpackChunkName: "about" */ '@/system/moduleNormal/customOptions/index.vue'),
+  },
+  {
+    path: '/account_manage',
+    name: 'users',
+    meta: {
+      title: '用户管理',
+      name: 'users',
+      keepAlive:false
+    },
+    component: () => import(/* webpackChunkName: "about" */ '@/system/moduleNormal/userManage/index.vue')
+  },
+  {
+    path: '/accountManageDetail',
+    name: 'accountManageDetail',
+    meta: {
+      title: '用户详情',
+      name: 'users',
+      keepAlive:false
+    },
+    component: () => import(/* webpackChunkName: "about" */ '@/system/moduleNormal/userManage/detail/index.vue')
+  },
+  {
+    path: '/role_manage',
+    name: 'roles',
+    meta: {
+      title: '角色管理',
+      name: 'roles',
+      keepAlive:false
+    },
+    component: () => import(/* webpackChunkName: "about" */ '@/system/moduleNormal/roleManage/index.vue')
+  },
+  {
+    path: '/roleManageDetail',
+    name: 'roleManageDetail',
+    meta: {
+      title: '角色管理详情',
+      name: 'roles',
+      keepAlive:false
+    },
+    component: () => import(/* webpackChunkName: "about" */ '@/system/moduleNormal/roleManage/detail/index.vue')
+  },
+];
+export default moduleNormal;

+ 38 - 1
src/stores/modules/auth.js

@@ -7,10 +7,21 @@ export const useAuthStore = defineStore('auth', {
     return {
       system: [],
       mods:[],
+      app:{},
       act_mods:{},
       hiddenSensitiveFields:false
     }
   },
+  // 开启数据缓存
+  persist: {
+    enabled: true,
+    strategies: [
+      {
+        storage: localStorage,
+        paths: ['system', 'mods','app','act_mods']
+      }
+    ]
+  },
   getters:{},
   actions:{
     async systemAuthData (data) {
@@ -38,7 +49,33 @@ export const useAuthStore = defineStore('auth', {
       } else {
         this.hiddenSensitiveFields = false
       }
-    }
+    },
+    // 系统数据
+    async systemData () {
+      const res = await Api.requested({
+        "classname": "sysmanage.develop.userauthforweb.userauth",
+        "method": "query_userauth",
+        "content": {
+          "place": 1
+        },
+        "systemappid": ""
+      })
+      this.system = res.data
+      this.mods = this.system[0].modules
+    },
+    // 获取模块数据
+    modulesData (system) {
+      this.mods = system.modules
+    },
+    // 获取应用数据
+    appData (app) {
+      this.app = app
+    },
+    // 设置默认账号
+    defaultAccount (account) {
+      sessionStorage.setItem('token',account.token)
+    },
+
   }
     
 })

+ 38 - 0
src/system/moduleNormal/customOptions/index.vue

@@ -0,0 +1,38 @@
+<template>
+  <div>
+    <listTemp ref="list" :param="param" :tableName="'optiontTable'" :searchType="searchType">
+      <template #operation>
+        自定义选项分类
+      </template>
+      <template #operationRight>
+      </template>
+      <template #tb_cell="{data}">
+        <template v-if="data.column.dataIndex == 'operation'">
+          <detail :id="data.record.optiontypeid"></detail>
+        </template>
+      </template>
+    </listTemp>
+  </div>
+</template>
+<script setup>
+  import utils from '@/utils/utils'
+  import Api from '@/api/api'
+  import listTemp from '@/components/listTemplate/index.vue';
+  import detail from './modules/detail.vue';
+  import { ref } from 'vue'
+  import { useRouter } from "vue-router";
+  import { onMounted } from "vue";
+  const router = useRouter()
+  const list = ref()
+  let dataSource = ref([])
+  let searchType = ref([
+    {label:'搜索',key:'condition',type:'input'},
+  ])
+  let param = ref({"id":20220901092401,"content":{"pageNumber":1,"pageSize":99999999,"where":{"condition":""}}}
+)
+  const onSuccess = ()=>{
+    list.value.tableData()
+  }
+</script>
+<style>
+</style>

+ 180 - 0
src/system/moduleNormal/customOptions/modules/detail.vue

@@ -0,0 +1,180 @@
+<template>
+  <div>
+    <a-button type="link" @click="showDrawer">管理二级</a-button>
+    <a-drawer
+      v-model:visible="visible"
+      class="custom-class"
+      title="二级分类"
+      placement="right"
+      width="900"
+      :closable="false"
+      @close="onClose"
+    >
+    <a-button class="mt-10" type="primary" @click="showModal">添加分类</a-button>
+    <normalTable rowKey="optiontypemxid" ref="list" size="small" :param="param" :columns="utils.TBLayout('optionDetailsTable')">
+      <template #tb_cell="{data}">
+        <template v-if="data.column.dataIndex == 'subvalues'">
+          <a-tag v-for="item in data.record.subvalues" :key="item.optiontypeid">{{item}}</a-tag>
+        </template>
+        <template v-if="data.column.dataIndex == 'operation'">
+          <a-space v-if="data.record.siteid !== ''">
+            <a-button type="link" @click="editOption(data.record)">编辑</a-button>
+            <a-button type="link" @click="deleteOption(data.record)">删除</a-button>
+          </a-space>
+        </template>
+      </template>
+    </normalTable>
+      <template #extra>
+        <a-space>
+          <a-button @click="onClose">关闭</a-button>
+        </a-space>
+      </template>
+    </a-drawer>
+    <a-modal
+      v-model:visible="modalVisble"
+      class="custom-class"
+      title="分类"
+      placement="right"
+      size="900"
+      :closable="false"
+      @close="onClose"
+      @ok="submit">
+      <a-form ref="formRef" :model="form" size="small" layout="vertical">
+        <a-row :gutter="16">
+          <a-col :span="24">
+            <a-form-item label="分类名称" name="value" :rules="[{ required: true, message: '请输入分类名称' }]">
+              <a-input v-model:value="form.value" placeholder="分类名称" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="24">
+            <a-form-item label="分类描述" name="remarks" :rules="[{ required: true, message: '请输入分类描述' }]">
+              <a-input v-model:value="form.remarks" placeholder="分类描述" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="24">
+            <a-form-item label="二级分类">
+              <a-tag v-for="item in form.subvalues" :key="item.index"  @close="handleClose(item)" closable>{{item}}</a-tag>
+              <a-input
+                v-if="inputVisible"
+                ref="inputRef"
+                v-model:value="inputValue"
+                type="text"
+                size="small"
+                :style="{ width: '78px' }"
+                @blur="handleInputConfirm"
+                @keyup.enter="handleInputConfirm"
+              />
+              <a-tag v-else style="background: #fff; border-style: dashed" @click="showInput">
+                <plus-outlined />
+                添加子分类
+              </a-tag>
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+    </a-modal>
+  </div>
+</template>
+
+<script setup>
+import {ref,defineProps,nextTick} from 'vue'
+import Api from '@/api/api'
+import utils from '@/utils/utils'
+import normalTable from '@/template/normalTable/index.vue'
+import { PlusOutlined } from '@ant-design/icons-vue';
+
+const props = defineProps(['id'])
+const visible = ref(false)
+const inputVisible= ref(false)
+const inputValue = ref('')
+const modalVisble = ref(false)
+const param = ref({
+  "id": 20220901092501,
+  "content": {
+    "pageNumber": 1,
+    "pageSize": 20,
+    "optiontypeid":props.id
+  }
+})
+const list = ref()
+const form = ref({
+  "optiontypeid":props.id,
+  "optiontypemxid":0,
+  "isused":"1",
+  "value":"",
+  "remarks":"",
+  "subvalues":[],
+  "sequence":0
+})
+
+const showDrawer = ()=>{
+  visible.value = true
+  setTimeout(() => {
+    list.value.listData()
+  }, 1000);
+  
+}
+const showModal = ()=>{
+  modalVisble.value = true
+}
+const inputRef = ref()
+const showInput = () => {
+  inputVisible.value = true;
+  nextTick(() => {
+    inputRef.value.focus();
+  });
+};
+ const handleInputConfirm = () => {
+  if (inputValue.value && inputValue.value !== '') {
+    form.value.subvalues.push(inputValue.value)
+    inputValue.value = ''
+  }
+  inputVisible.value = false
+};
+const handleClose = (tag)=>{
+  form.value.subvalues = form.value.subvalues.filter(e=>{
+    if (e !== tag) {
+      return e
+    }
+  })
+  console.log(form.value.subvalues)
+}
+const onClose = () => {
+  visible.value = false;
+};
+const formRef = ref()
+const submit = async ()=>{
+  try {
+    const values = await formRef.value.validateFields();
+    const res = await Api.requested({
+      id:20220901092601,
+      content:form.value
+    })
+    utils.message(res,'添加成功',()=>{
+      list.value.listData()
+      modalVisble.value = false
+      formRef.value.resetFields();
+      form.value.subvalues = []
+    })
+  } catch (errorInfo) {
+    console.log('Failed:', errorInfo);
+  }
+}
+const deleteOption = async (data)=>{
+  const res = await Api.requested({
+    id:20220901092701,
+    content:{
+      optiontypemxid:data.optiontypemxid
+    }
+  })
+  utils.message(res,'删除成功',()=>{
+    list.value.listData()
+  })
+}
+const editOption = (data)=>{
+  modalVisble.value = true
+  form.value = Object.assign({},form.value,data)
+}
+</script>
+<style>
+</style>

+ 63 - 0
src/system/moduleNormal/reportcenter/index.vue

@@ -0,0 +1,63 @@
+<template>
+  <div class="y-container">
+    <listTemp :columns="columns" :param="param" :tableName="'reportcenterTable'">
+      <template #operation>
+        报表中心
+      </template>
+      <template #tb_cell="{data}">
+        <template v-if="data.column.dataIndex == 'name'">
+          <a-button type="link"><span class="btn-link" @click="goDetail(data.record)">{{data.record.name}}</span></a-button>
+        </template>
+      </template>
+    </listTemp>
+  </div>
+</template>
+
+<script setup>
+  import listTemp from '@/components/listTemplate/index.vue';
+  import Api from '@/api/api'
+  import { ref } from 'vue'
+  import { useRouter } from "vue-router";
+  import { onMounted } from "vue";
+  const router = useRouter()
+  let columns = ref([])
+  let dataSource = ref([])
+  let param = ref({
+    "content": {
+      "pageNumber":1,
+      "pageSize":20,
+      "systemappid":JSON.parse(sessionStorage.getItem('app')).systemappid
+    },
+    "id": 20221213094401,
+  })
+  const getBaseUrl = () => {
+    
+    if (process.env.NODE_ENV == 'development') return process.env.BASE_API
+    let href = window.location.href
+    let index = href.indexOf('/')
+    let num = 0
+    while (index != -1) {
+      num++
+      index = href.indexOf('/',index+1)
+      if (num++ == 3) {
+        return href.slice(0,index)
+      } 
+    }
+  }
+  const goDetail = async (data)=> {
+    console.log(process.env.BASE_API)
+    let res = await Api.requested({
+      "id":20221213094501,
+      "content": {
+        sys_reportid:data.sys_reportid,
+        dataid:0
+      }
+    })
+    window.open(getBaseUrl() + res.data)
+  }
+</script>
+<style scoped>
+.btn-link{
+  text-decoration: underline;
+}
+</style>

+ 112 - 0
src/system/moduleNormal/roleManage/detail/index.vue

@@ -0,0 +1,112 @@
+<template>
+  <div>
+    <detail-template :headData="mainAreaData" :title="`${roleData.rolename}`" :tabs="['授权信息']" ownertable="user" :delParam="{id:'20221101132002',content:{roleids:[router.currentRoute.value.query.id]}}" :disable="utils.isDisabled(roleData.status,['ACTIVE'])">
+      <template #operation>
+        <edit :data="roleData" @onSuccess="mianData"></edit>
+      </template>
+      <template #tab0>
+        <addAuth @onSuccess="mianData"></addAuth>
+        <auth :data="roleData" @onSuccess="mianData"></auth>
+      </template>
+      <template #tab1>
+      </template>
+    </detail-template>
+  </div>
+</template>
+
+<script setup>
+import Api from '@/api/api'
+import utils  from '@/utils/utils'
+import addAuth from './modules/addAuth.vue'
+import normalTable from '@/template/normalTable/index.vue'
+import detailTemplate from '@/components/detailTemplate/index.vue'
+import edit from './modules/edit.vue'
+import auth from './tabs/auth.vue'
+import { message, Modal } from 'ant-design-vue'
+import { ExclamationCircleOutlined } from '@ant-design/icons-vue';
+import { useRouter } from "vue-router";
+import { onMounted,ref,createVNode } from "vue";
+const router = useRouter()
+const mainAreaData = ref([])
+
+const roleData = ref({})
+const mianData = async ()=>{
+  const res = await Api.requested({
+   "classname": "manager.role.role",
+    "method": "query_roleMain",
+    "content": {
+      "nocache":true,
+      "roleid": router.currentRoute.value.query.id
+    }
+  })
+  roleData.value = res.data
+  changeDataStructure(res.data)
+
+}
+const changeDataStructure = (data) => {
+  mainAreaData.value = [
+    {
+      label:'角色名称',
+      value:data.rolename
+    },
+    {
+      label:'角色描述',
+      value:data.remarks
+    },
+    {
+      label:'角色类型',
+      value:data.usertypename
+    }
+  ]
+}
+const changeUserStatus = (message,isactive)=>{
+  Modal.confirm({
+    title: '提示',
+    icon: createVNode(ExclamationCircleOutlined),
+    content: `确定${message}当前账号吗?`,
+    async onOk() {
+      const res = await Api.requested({
+        "classname": "manager.users.users",
+        "method": "changeStatus",
+        "content": {
+          "userid": router.currentRoute.value.query.id,
+          "isactive": isactive
+        }
+      })
+      utils.message(res,`${message}成功`,()=>{
+        mianData()
+      })
+    },
+    onCancel() {},
+  })
+}
+
+const reloadPassword = ()=>{
+  Modal.confirm({
+    title: '提示',
+    icon: createVNode(ExclamationCircleOutlined),
+    content: `确定重置当前账号密码吗?`,
+    async onOk() {
+      const res = await Api.requested({
+        "classname": "manager.users.users",
+        "method": "resetPassword",
+        "content": {
+          "userid": router.currentRoute.value.query.id
+        }
+      })
+      utils.message(res,`重置成功`,()=>{
+        mianData()
+      })
+    },
+    onCancel() {},
+  })
+}
+const onSelectChange = (val) =>{
+  console.log(val,'orderManage')
+}
+onMounted (()=>{
+  mianData()
+})
+</script>
+<style>
+</style>

+ 114 - 0
src/system/moduleNormal/roleManage/detail/modules/addAuth.vue

@@ -0,0 +1,114 @@
+<template>
+  <div>
+    <a-button class="mt-10" type="primary" @click="showDrawer">角色授权</a-button>
+    <a-drawer
+      v-model:visible="visible"
+      class="custom-class"
+      title="授权"
+      placement="right"
+      width="900"
+      :closable="false"
+      @close="onClose"
+    >
+      <normalTable rowKey="systemappid" size="small" :filterMultiple="true" :param="{method:'query_appselect',classname:'manager.role.role',content:{pageNumber:1,pageSize:10}}" :columns="utils.TBLayout('AuthAppsTable')" @onSelect="onSelect"></normalTable>
+
+      <a-button :disabled="optionSelect.length == 0" class="mt-10" type="primary" @click="addOptions">添加选中</a-button>
+      <normalTable ref="app" rowKey="optionid" size="small" :filterMultiple="false" :param="appParam" :columns="columns" @onSelect="onSelectOptions" :noQuery="true"></normalTable>
+      <template #extra>
+        <a-space>
+          <a-button @click="onClose">关闭</a-button>
+          <a-button type="primary" @click="submit">保存</a-button>
+        </a-space>
+      </template>
+    </a-drawer>
+  </div>
+</template>
+
+<script setup>
+  import { ref,onMounted,defineEmits } from 'vue'
+  import Api from '@/api/api'
+  import utils from '@/utils/utils'
+  import normalTable from '@/template/normalTable/index.vue'
+  import { useRouter } from "vue-router";
+  const router = useRouter()
+  const emit = defineEmits(['onSuccess'])
+  const visible = ref(false)
+  const showDrawer = ()=>{
+    visible.value = true
+  }
+  const formRef = ref()
+  const onClose = () => {
+    visible.value = false
+  };
+  const submit = async ()=>{
+    try {
+      const values = await formRef.value.validateFields();
+    } catch (errorInfo) {
+      console.log('Failed:', errorInfo);
+    }
+  }
+  const authData = async ()=>{
+    const res = await Api.requested({
+      "classname":"manager.role.role",
+      "method":"query_appselect",
+      "content":{
+        "pageNumber":1,
+        "pageSize":10,
+        "where":{
+          "condition":"",
+          "systemname":"",
+          "systemagentname":"",
+          "systemmodulename":"",
+          "systemappname":""
+        }
+      }
+    })
+  }
+  const appParam = ref({
+    method:'query_appoptionselect',
+    classname:'manager.role.role',
+    content:{
+      roleid:router.currentRoute.value.query.id,
+      systemappid:0
+    }
+  })
+  const app = ref()
+  const onSelect = async (val)=>{
+    appParam.value.content.systemappid = val.pop().systemappid
+    app.value.listData()
+  }
+
+  const optionSelect = ref([])
+  const onSelectOptions = (val)=>{
+    optionSelect.value = val
+  }
+  const addOptions = async ()=>{
+    const res = await Api.requested({
+      classname:"manager.role.role",
+      method:"add_appauth",
+      content:{
+        roleid:router.currentRoute.value.query.id,
+        systemapps:[{systemappid: appParam.value.content.systemappid, optionids:optionSelect.value.map(e=>e.optionid), hiddenfields: []}]
+      }
+    })
+    utils.message(res,'授权成功',()=>{
+      app.value.listData()
+      emit('onSuccess')
+    })
+  }
+  const columns = [{
+    title: '功能描述',
+    dataIndex: 'optionname',
+    key: 'optionname',
+  },
+  {
+    title: '名称',
+    dataIndex: 'option',
+    key: 'option',
+  },]
+  onMounted (()=>{
+    authData()
+  })
+</script>
+<style>
+</style>

+ 104 - 0
src/system/moduleNormal/roleManage/detail/modules/edit.vue

@@ -0,0 +1,104 @@
+<template>
+  <div>
+    <a-button :disabled="disabled" type="primary" @click="showDrawer">编辑</a-button>
+    <a-drawer
+      v-model:visible="visible"
+      class="custom-class"
+      title="编辑用户"
+      placement="right"
+      width="600"
+      :closable="false"
+      @close="onClose"
+    >
+      <a-form ref="formRef" :model="form" size="small" layout="vertical">
+        <a-row :gutter="16">
+          <a-col :span="24">
+            <a-form-item label="角色名称" name="rolename" :rules="[{ required: true, message: '请输入角色名称'}]">
+              <a-input v-model:value="form.rolename" placeholder="角色名称" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="24">
+            <a-form-item label="角色描述" name="remarks" :rules="[{ required: true, message: '请输入角色描述'}]">
+              <a-input v-model:value="form.remarks" placeholder="输入角色描述" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="角色类型" name="usertype" :rules="[{ required: true, message: '请输入角色描述'}]">
+              <a-select
+                ref="select"
+                v-model:value="form.usertype"
+                placeholder="选择角色类型"
+                style="width: 100%"
+              >
+                <a-select-option v-for="item in userTypeOptions" :key="item.value" :value="Number(item.value)">{{item.remarks}}</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="是否隐藏敏感信息">
+              <a-select
+                ref="select"
+                v-model:value="form.isshieldinfo"
+                placeholder="选择角色"
+                style="width: 100%"
+              >
+                <a-select-option :value="1">是</a-select-option>
+                <a-select-option :value="0">否</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+      <template #extra>
+        <a-space>
+          <a-button @click="onClose">关闭</a-button>
+          <a-button type="primary" @click="submit">保存</a-button>
+        </a-space>
+      </template>
+    </a-drawer>
+  </div>
+</template>
+
+<script setup>
+import {ref,defineEmits,defineProps} from 'vue'
+import Api from '@/api/api'
+import utils from '@/utils/utils'
+const emit = defineEmits(['onSuccess'])
+const visible = ref(false)
+const props = defineProps(['data','disabled'])
+const form = ref({
+})
+const showDrawer = ()=>{
+  roles()
+  visible.value = true
+  form.value = Object.assign({},form.value,props.data)
+}
+const onClose = () => {
+  visible.value = false;
+  formRef.value.resetFields();
+};
+const formRef = ref()
+const submit = async ()=>{
+  try {
+    const values = await formRef.value.validateFields();
+    const res = await Api.requested({
+      "classname": "manager.role.role",
+      "method": "insertormodify_role",
+      "content": form.value
+    })
+    utils.message(res,'编辑成功',()=>{
+      onClose()
+      emit('onSuccess')
+    })
+  } catch (errorInfo) {
+    console.log('Failed:', errorInfo);
+  }
+}
+const userTypeOptions = ref([])
+const roles = async ()=>{
+  const res = await Api.optionstype('usertype')
+  userTypeOptions.value = res.data
+}
+</script>
+<style>
+</style>

+ 41 - 0
src/system/moduleNormal/roleManage/detail/tabs/auth.vue

@@ -0,0 +1,41 @@
+<template>
+  <div>
+    <a-table size="small" :dataSource="props.data.apps" :columns="utils.TBLayout('detailsAppsTable')">
+      <template #bodyCell="{ column, record }">
+        <template v-if="column.dataIndex === 'auth'">
+          <div style="width:500px">
+            <a-tag v-for="item in record.options" :key="item.optionid" @close="deleteOptions(record.systemappid,item)" closable>{{item.optionname}}</a-tag>
+          </div>
+        </template>
+      </template>
+    </a-table>
+  </div>
+</template>
+
+<script setup>
+  import { ref,onMounted,defineProps,defineEmits } from 'vue'
+  import Api from '@/api/api'
+  import utils from '@/utils/utils'
+  import { useRouter } from "vue-router";
+  const router = useRouter()
+  const props = defineProps(['data'])
+  const emit = defineEmits(['onSuccess'])
+  const deleteOptions = async (systemappid,item)=>{
+    console.log(systemappid,item)
+    const res = await Api.requested({
+      classname:"manager.role.role",
+      method:"delete_appauth",
+      content:{
+        roleid:router.currentRoute.value.query.id,
+        systemapps:[{systemappid: systemappid, optionids: [item.optionid], hiddenfields: []}]
+      }
+    })
+    utils.message(res,'删除成功',()=>{
+      emit('onSuccess')
+    })
+  }
+  onMounted (()=>{
+  })
+</script>
+<style>
+</style>

+ 54 - 0
src/system/moduleNormal/roleManage/index.vue

@@ -0,0 +1,54 @@
+<template>
+  <div>
+    <listTemp ref="list" keyRouteName="rolename" :param="param" :tableName="'roleTable'" :searchType="searchType" :detailPage="{name:'roleManageDetail',idname:'roleid'}">
+      <template #operation>
+        <add @onSuccess="onSuccess"></add>
+      </template>
+    </listTemp>
+  </div>
+</template>
+<script setup>
+  import utils from '@/utils/utils'
+  import Api from '@/api/api'
+  import listTemp from '@/components/listTemplate/index.vue';
+  import add from './modules/add.vue';
+  import { ref,onMounted } from 'vue'
+  import { useRouter } from "vue-router";
+  const router = useRouter()
+  const list = ref()
+  let columns = ref([])
+  let dataSource = ref([])
+  const statusOptions = ref([])
+  const typeOptions = ref([])
+  let searchType = ref([
+    {label:'搜索',key:'condition',type:'input'},
+  ])
+  let param = ref({
+    "content": {
+      "pageNumber": 1,
+      "pageSize": 20,
+      "where": {
+        "condition": "",
+      }
+    },
+    "id": 20221101131902,
+  })
+  const onSuccess = ()=>{
+    list.value.tableData()
+  }
+
+  const status = async ()=>{
+    const res = await Api.optionstype('userstatus')
+    statusOptions.value = res.data
+  }
+  const userType = async ()=>{
+    const res = await Api.optionstype('usertype')
+    typeOptions.value = res.data
+  }
+  onMounted(()=>{
+    status()
+    userType()
+  })
+</script>
+<style>
+</style>

+ 115 - 0
src/system/moduleNormal/roleManage/modules/add.vue

@@ -0,0 +1,115 @@
+<template>
+  <div>
+    <a-button type="primary" @click="showDrawer">新建</a-button>
+    <a-drawer
+      v-model:visible="visible"
+      class="custom-class"
+      title="创建角色"
+      placement="right"
+      width="600"
+      :closable="false"
+      @close="onClose"
+    >
+      <a-form ref="formRef" :model="form" size="small" layout="vertical">
+        <a-row :gutter="16">
+          <a-col :span="24">
+            <a-form-item label="角色名称" name="rolename" :rules="[{ required: true, message: '请输入角色名称'}]">
+              <a-input v-model:value="form.rolename" placeholder="角色名称" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="24">
+            <a-form-item label="角色描述" name="remarks" :rules="[{ required: true, message: '请输入角色描述'}]">
+              <a-input v-model:value="form.remarks" placeholder="输入角色描述" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="角色类型" name="usertype" :rules="[{ required: true, message: '请输入角色描述'}]">
+              <a-select
+                ref="select"
+                v-model:value="form.usertype"
+                placeholder="选择角色类型"
+                style="width: 100%"
+              >
+                <a-select-option v-for="item in userTypeOptions" :key="item.value" :value="item.value">{{item.remarks}}</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="是否隐藏敏感信息">
+              <a-select
+                ref="select"
+                v-model:value="form.isshieldinfo"
+                placeholder="选择角色"
+                style="width: 100%"
+              >
+                <a-select-option :value="1">是</a-select-option>
+                <a-select-option :value="0">否</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+      <template #extra>
+        <a-space>
+          <a-button @click="onClose">关闭</a-button>
+          <a-button type="primary" @click="submit">保存</a-button>
+        </a-space>
+      </template>
+    </a-drawer>
+  </div>
+</template>
+
+<script setup>
+import {ref,defineEmits} from 'vue'
+import Api from '@/api/api'
+import utils from '@/utils/utils'
+import { useRouter } from "vue-router";
+const router = useRouter()
+const emit = defineEmits(['onSuccess'])
+const visible = ref(false)
+const form = ref({
+  roleid:0,
+  userid: 0,
+  isshieldinfo:0
+})
+const validatePhoneNumber = async (rule, value)=> {
+  const phoneNumberPattern = /^1\d{10}$/;
+  if (phoneNumberPattern.test(value)) {
+    return Promise.resolve();
+  }
+  return Promise.reject('请输入有效的手机号码');
+}
+const showDrawer = ()=>{
+  visible.value = true
+  roles()
+}
+const onClose = () => {
+  visible.value = false;
+  formRef.value.resetFields();
+};
+const formRef = ref()
+const submit = async ()=>{
+  try {
+    const values = await formRef.value.validateFields();
+    const res = await Api.requested({
+      "classname": "manager.role.role",
+      "method": "insertormodify_role",
+      "content": form.value
+    })
+    utils.message(res,'创建成功',()=>{
+      onClose()
+      emit('onSuccess')
+      router.push({path:'/roleManageDetail',query:{id:res.data.roleid}})
+    })
+  } catch (errorInfo) {
+    console.log('Failed:', errorInfo);
+  }
+}
+const userTypeOptions = ref([])
+const roles = async ()=>{
+  const res = await Api.optionstype('usertype')
+  userTypeOptions.value = res.data
+}
+</script>
+<style>
+</style>

+ 118 - 0
src/system/moduleNormal/userManage/detail/index.vue

@@ -0,0 +1,118 @@
+<template>
+  <div>
+    <detail-template :headData="mainAreaData" :title="`${userData.name}(${userData.accountno})`" :tabs="['负责团队','参与团队']" ownertable="user" :delParam="{id:'20221031141202',content:{userids:[router.currentRoute.value.query.id]}}" :disable="utils.isDisabled(userData.status,['ACTIVE'])">
+      <template #operation>
+        <edit :disabled="utils.isDisabled(userData.status,['ACTIVE'])" :data="userData" @onSuccess="mianData"></edit>
+        <a-button type="primary" @click="reloadPassword">密码重置</a-button>
+        <a-button :disabled="utils.isDisabled(userData.status,['ACTIVE'])" type="primary" @click="changeUserStatus('启用',1)">启用</a-button>
+        <a-button :disabled="utils.isDisabled(userData.status,['INACTIVE'])" type="primary" @click="changeUserStatus('停用',0)">停用</a-button>
+      </template>
+      <template #tab0>
+        <normal-table size="small" :columns="utils.TBLayout('partakeTeamTable')" :param="{id: 20230302174201, content: {leaderuserid:router.currentRoute.value.query.id}}"></normal-table>
+      </template>
+      <template #tab1>
+        <normal-table size="small" :columns="utils.TBLayout('partakeTeamTable')" :param="{id: 20230302174501, content: {leaderuserid:router.currentRoute.value.query.id}}"></normal-table>
+      </template>
+    </detail-template>
+  </div>
+</template>
+
+<script setup>
+import Api from '@/api/api'
+import utils  from '@/utils/utils'
+
+import normalTable from '@/template/normalTable/index.vue'
+import detailTemplate from '@/components/detailTemplate/index.vue'
+import edit from './modules/edit.vue'
+import { message, Modal } from 'ant-design-vue'
+import { ExclamationCircleOutlined } from '@ant-design/icons-vue';
+import { useRouter } from "vue-router";
+import { onMounted,ref,createVNode } from "vue";
+const router = useRouter()
+const mainAreaData = ref([])
+
+const userData = ref({})
+const mianData = async ()=>{
+  const res = await Api.requested({
+    "classname": "manager.users.users",
+    "method": "query_userMain",
+    "content": {
+      "nocache":true,
+      "userid": router.currentRoute.value.query.id
+    }
+  })
+  userData.value = res.data
+  changeDataStructure(res.data)
+
+}
+const changeDataStructure = (data) => {
+  mainAreaData.value = [
+    {
+      label:'账号类型',
+      value:data.usertypename
+    },
+    {
+      label:'状态',
+      value:data.status === 'ACTIVE'?'启用':data.status === 'INACTIVE'?'停用':'其他'
+    },
+    {
+      label:'联系方式',
+      value:data.phonenumber
+    },
+    {
+      label:'授权角色',
+      value:data.userrole.map(e=>e.rolename).join(',')
+    }
+  ]
+}
+const changeUserStatus = (message,isactive)=>{
+  Modal.confirm({
+    title: '提示',
+    icon: createVNode(ExclamationCircleOutlined),
+    content: `确定${message}当前账号吗?`,
+    async onOk() {
+      const res = await Api.requested({
+        "classname": "manager.users.users",
+        "method": "changeStatus",
+        "content": {
+          "userid": router.currentRoute.value.query.id,
+          "isactive": isactive
+        }
+      })
+      utils.message(res,`${message}成功`,()=>{
+        mianData()
+      })
+    },
+    onCancel() {},
+  })
+}
+
+const reloadPassword = ()=>{
+  Modal.confirm({
+    title: '提示',
+    icon: createVNode(ExclamationCircleOutlined),
+    content: `确定重置当前账号密码吗?`,
+    async onOk() {
+      const res = await Api.requested({
+        "classname": "manager.users.users",
+        "method": "resetPassword",
+        "content": {
+          "userid": router.currentRoute.value.query.id
+        }
+      })
+      utils.message(res,`重置成功`,()=>{
+        mianData()
+      })
+    },
+    onCancel() {},
+  })
+}
+const onSelectChange = (val) =>{
+  console.log(val,'orderManage')
+}
+onMounted (()=>{
+  mianData()
+})
+</script>
+<style>
+</style>

+ 107 - 0
src/system/moduleNormal/userManage/detail/modules/edit.vue

@@ -0,0 +1,107 @@
+<template>
+  <div>
+    <a-button :disabled="disabled" type="primary" @click="showDrawer">编辑</a-button>
+    <a-drawer
+      v-model:visible="visible"
+      class="custom-class"
+      title="编辑用户"
+      placement="right"
+      width="600"
+      :closable="false"
+      @close="onClose"
+    >
+      <a-form ref="formRef" :model="form" size="small" layout="vertical">
+        <a-row :gutter="16">
+          <a-col :span="12">
+            <a-form-item label="选择角色">
+              <a-select
+                ref="select"
+                mode="multiple"
+                v-model:value="form.roleids"
+                placeholder="选择角色"
+                style="width: 100%"
+              >
+                <a-select-option v-for="item in rolesOptions" :key="item.roleid" :value="item.roleid">{{item.rolename}}</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="账号" name="accountno">
+              <a-input v-model:value="form.accountno" placeholder="账号" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="手机号码" name="phonenumber" :rules="[{ required: true, message: '请输入手机号码'},{ validator: validatePhoneNumber, message: '请输入有效的手机号码' }]">
+              <a-input v-model:value="form.phonenumber" placeholder="输入手机号码" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="用户名称" name="name" :rules="[{ required: true, message: '请输入用户名称' }]">
+              <a-input v-model:value="form.name" placeholder="输入用户名称" />
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+      <template #extra>
+        <a-space>
+          <a-button @click="onClose">关闭</a-button>
+          <a-button type="primary" @click="submit">保存</a-button>
+        </a-space>
+      </template>
+    </a-drawer>
+  </div>
+</template>
+
+<script setup>
+import {ref,defineEmits,defineProps} from 'vue'
+import Api from '@/api/api'
+import utils from '@/utils/utils'
+const emit = defineEmits(['onSuccess'])
+const visible = ref(false)
+const props = defineProps(['data','disabled'])
+const form = ref({
+  userid: 0,
+  remarks:''
+})
+const validatePhoneNumber = async (rule, value)=> {
+  const phoneNumberPattern = /^1\d{10}$/;
+  if (phoneNumberPattern.test(value)) {
+    return Promise.resolve();
+  }
+  return Promise.reject('请输入有效的手机号码');
+}
+const showDrawer = ()=>{
+  form.value = Object.assign({},form.value,props.data)
+  form.value.roleids = props.data.userrole.map(e=>e.roleid)
+  visible.value = true
+  roles()
+}
+const onClose = () => {
+  visible.value = false;
+  formRef.value.resetFields();
+};
+const formRef = ref()
+const submit = async ()=>{
+  try {
+    const values = await formRef.value.validateFields();
+    const res = await Api.requested({
+      "classname": "manager.users.users",
+      "method": "insertormodify_user",
+      "content": form.value
+    })
+    utils.message(res,'编辑成功',()=>{
+      onClose()
+      emit('onSuccess')
+    })
+  } catch (errorInfo) {
+    console.log('Failed:', errorInfo);
+  }
+}
+const rolesOptions = ref([])
+const roles = async ()=>{
+  const res = await Api.optionstype('role')
+  rolesOptions.value = res.data
+}
+</script>
+<style>
+</style>

+ 56 - 0
src/system/moduleNormal/userManage/index.vue

@@ -0,0 +1,56 @@
+<template>
+  <div>
+    <listTemp ref="list" keyRouteName="accountno" :param="param" :tableName="'accountTable'" :searchType="searchType" :detailPage="{name:'accountManageDetail',idname:'userid'}">
+      <template #operation>
+        <add @onSuccess="onSuccess"></add>
+      </template>
+    </listTemp>
+  </div>
+</template>
+<script setup>
+  import utils from '@/utils/utils'
+  import Api from '@/api/api'
+  import listTemp from '@/components/listTemplate/index.vue';
+  import add from './modules/add.vue';
+  import { ref,onMounted } from 'vue'
+  import { useRouter } from "vue-router";
+  const router = useRouter()
+  const list = ref()
+  let columns = ref([])
+  let dataSource = ref([])
+  const statusOptions = ref([])
+  const typeOptions = ref([])
+  let searchType = ref([
+    {label:'状态',key:'status',type:'select',dataSource:statusOptions},
+    {label:'用户类型:',key:'usertype',type:'select',dataSource:typeOptions},
+    {label:'搜索',key:'condition',type:'input'},
+  ])
+  let param = ref({
+    "content": {
+      "pageNumber": 1,
+      "pageSize": 20,
+      "where": {
+        "condition": "",
+      }
+    },
+    "id": 20221031141102,
+  })
+  const onSuccess = ()=>{
+    list.value.tableData()
+  }
+
+  const status = async ()=>{
+    const res = await Api.optionstype('userstatus')
+    statusOptions.value = res.data
+  }
+  const userType = async ()=>{
+    const res = await Api.optionstype('usertype')
+    typeOptions.value = res.data
+  }
+  onMounted(()=>{
+    status()
+    userType()
+  })
+</script>
+<style>
+</style>

+ 104 - 0
src/system/moduleNormal/userManage/modules/add.vue

@@ -0,0 +1,104 @@
+<template>
+  <div>
+    <a-button type="primary" @click="showDrawer">新建</a-button>
+    <a-drawer
+      v-model:visible="visible"
+      class="custom-class"
+      title="创建用户"
+      placement="right"
+      width="600"
+      :closable="false"
+      @close="onClose"
+    >
+      <a-form ref="formRef" :model="form" size="small" layout="vertical">
+        <a-row :gutter="16">
+          <a-col :span="12">
+            <a-form-item label="选择角色">
+              <a-select
+                ref="select"
+                mode="multiple"
+                v-model:value="form.roleids"
+                placeholder="选择角色"
+                style="width: 100%"
+              >
+                <a-select-option v-for="item in rolesOptions" :key="item.roleid" :value="item.roleid">{{item.rolename}}</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="账号" name="accountno">
+              <a-input v-model:value="form.accountno" placeholder="账号" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="手机号码" name="phonenumber" :rules="[{ required: true, message: '请输入手机号码'},{ validator: validatePhoneNumber, message: '请输入有效的手机号码' }]">
+              <a-input v-model:value="form.phonenumber" placeholder="输入手机号码" />
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="用户名称" name="name" :rules="[{ required: true, message: '请输入用户名称' }]">
+              <a-input v-model:value="form.name" placeholder="输入用户名称" />
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+      <template #extra>
+        <a-space>
+          <a-button @click="onClose">关闭</a-button>
+          <a-button type="primary" @click="submit">保存</a-button>
+        </a-space>
+      </template>
+    </a-drawer>
+  </div>
+</template>
+
+<script setup>
+import {ref,defineEmits} from 'vue'
+import Api from '@/api/api'
+import utils from '@/utils/utils'
+const emit = defineEmits(['onSuccess'])
+const visible = ref(false)
+const form = ref({
+  userid: 0,
+  remarks:''
+})
+const validatePhoneNumber = async (rule, value)=> {
+  const phoneNumberPattern = /^1\d{10}$/;
+  if (phoneNumberPattern.test(value)) {
+    return Promise.resolve();
+  }
+  return Promise.reject('请输入有效的手机号码');
+}
+const showDrawer = ()=>{
+  visible.value = true
+  roles()
+}
+const onClose = () => {
+  visible.value = false;
+  formRef.value.resetFields();
+};
+const formRef = ref()
+const submit = async ()=>{
+  try {
+    const values = await formRef.value.validateFields();
+    const res = await Api.requested({
+      "classname": "manager.users.users",
+      "method": "insertormodify_user",
+      "content": form.value
+    })
+    utils.message(res,'创建成功',()=>{
+      onClose()
+      emit('onSuccess')
+    })
+  } catch (errorInfo) {
+    console.log('Failed:', errorInfo);
+  }
+}
+const rolesOptions = ref([])
+const roles = async ()=>{
+  const res = await Api.optionstype('role')
+  rolesOptions.value = res.data
+}
+</script>
+<style>
+</style>

+ 1 - 1
src/utils/utils.js

@@ -25,7 +25,6 @@ export default {
   },
   // 获取应用表格
   TBLayout (appname) {
-    console.log(appname)
     try {
       // 获取应用数据
       let apps = JSON.parse(sessionStorage.getItem('app'))
@@ -33,6 +32,7 @@ export default {
       let tablecols = apps.meta.tables[appname].tablecols.map(e=>{
         return {
           title:e.title,
+          filter:e.filter,
           dataIndex:e.columnname,
           width:e.width == 0?'150':e.width,
           ellipsis:true,

+ 7 - 7
src/views/login/login.vue

@@ -56,13 +56,16 @@ import { useRouter } from "vue-router";
 import Api  from '@/api/api'
 import md5 from 'js-md5'
 import { message } from 'ant-design-vue';
+import { useAuthStore } from '@/stores/modules/auth'
+import { storeToRefs } from 'pinia'
+const store = useAuthStore()
 
 export default defineComponent({
   setup() {
     const router = useRouter()
     const formState = reactive({
-      phonenumber: '',
-      password: '',
+      phonenumber: 'admin',
+      password: '123456',
       remember: true,
     });
     let loading = ref(false)
@@ -85,13 +88,10 @@ export default defineComponent({
         if (res.account_list[0].status == 'INACTIVE')
           return message.error('当前账号已停用!')
         loading.value = false
+
         sessionStorage.setItem('a_list',JSON.stringify(res.account_list))
+        store.defaultAccount(res.account_list[0])
         router.replace({path:'/home'})
-        // if (res.account_list[0].usertype == 21 || res.account_list[0].usertype == 22) {
-        //   router.replace({path:'/home'})
-        // } else {
-        //   message.error('当前账号非经销商类型,无法登陆!')
-        // }
         
       } else {
         loading.value = false

이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.