Browse Source

机构查询页面、接口联调

sunkuosheng 2 years ago
parent
commit
384aa09930

+ 8 - 0
ruoyi-web/.env.development

@@ -0,0 +1,8 @@
+# 页面标题
+VITE_APP_TITLE = 若依管理系统
+
+# 开发环境配置
+VITE_APP_ENV = 'development'
+
+# 若依管理系统/开发环境
+VITE_APP_BASE_API = '/dev-api'

+ 11 - 0
ruoyi-web/.env.production

@@ -0,0 +1,11 @@
+# 页面标题
+VITE_APP_TITLE = 若依管理系统
+
+# 生产环境配置
+VITE_APP_ENV = 'production'
+
+# 若依管理系统/生产环境
+VITE_APP_BASE_API = '/prod-api'
+
+# 是否在打包时开启压缩,支持 gzip 和 brotli
+VITE_BUILD_COMPRESS = gzip

+ 11 - 0
ruoyi-web/.env.staging

@@ -0,0 +1,11 @@
+# 页面标题
+VITE_APP_TITLE = 若依管理系统
+
+# 生产环境配置
+VITE_APP_ENV = 'staging'
+
+# 若依管理系统/生产环境
+VITE_APP_BASE_API = '/stage-api'
+
+# 是否在打包时开启压缩,支持 gzip 和 brotli
+VITE_BUILD_COMPRESS = gzip

+ 60 - 0
ruoyi-web/package-lock.json

@@ -9,7 +9,10 @@
       "version": "0.0.0",
       "dependencies": {
         "@element-plus/icons-vue": "^2.0.6",
+        "axios": "0.26.1",
         "element-plus": "^2.2.8",
+        "file-saver": "2.0.5",
+        "js-cookie": "3.0.1",
         "vue": "^3.0.4",
         "vue-router": "^4.1.1"
       },
@@ -444,6 +447,14 @@
         "node": ">= 4.5.0"
       }
     },
+    "node_modules/axios": {
+      "version": "0.26.1",
+      "resolved": "https://registry.npmmirror.com/axios/-/axios-0.26.1.tgz",
+      "integrity": "sha512-fPwcX4EvnSHuInCMItEhAGnaSEXRBjtzh9fOtsE6E1G6p7vl7edEeZe11QHf18+6+9gR5PbKV/sGKNaD8YaMeA==",
+      "dependencies": {
+        "follow-redirects": "^1.14.8"
+      }
+    },
     "node_modules/base": {
       "version": "0.11.2",
       "resolved": "https://registry.npmmirror.com/base/-/base-0.11.2.tgz",
@@ -1525,6 +1536,11 @@
         "reusify": "^1.0.4"
       }
     },
+    "node_modules/file-saver": {
+      "version": "2.0.5",
+      "resolved": "https://registry.npmmirror.com/file-saver/-/file-saver-2.0.5.tgz",
+      "integrity": "sha512-P9bmyZ3h/PRG+Nzga+rbdI4OEpNDzAVyy74uVO9ATgzLK6VtAsYybF/+TOCvrc0MO793d6+42lLyZTw7/ArVzA=="
+    },
     "node_modules/fill-range": {
       "version": "7.0.1",
       "resolved": "https://registry.npmmirror.com/fill-range/-/fill-range-7.0.1.tgz",
@@ -1537,6 +1553,19 @@
         "node": ">=8"
       }
     },
+    "node_modules/follow-redirects": {
+      "version": "1.15.1",
+      "resolved": "https://registry.npmmirror.com/follow-redirects/-/follow-redirects-1.15.1.tgz",
+      "integrity": "sha512-yLAMQs+k0b2m7cVxpS1VKJVvoz7SS9Td1zss3XRwXj+ZDH00RJgnuLx7E44wx02kQLrdM3aOOy+FpzS7+8OizA==",
+      "engines": {
+        "node": ">=4.0"
+      },
+      "peerDependenciesMeta": {
+        "debug": {
+          "optional": true
+        }
+      }
+    },
     "node_modules/for-in": {
       "version": "1.0.2",
       "resolved": "https://registry.npmmirror.com/for-in/-/for-in-1.0.2.tgz",
@@ -1959,6 +1988,14 @@
       "integrity": "sha512-pZe//GGmwJndub7ZghVHz7vjb2LgC1m8B07Au3eYqeqv9emhESByMXxaEgkUkEqJe87oBbSniGYoQNIBklc7IQ==",
       "dev": true
     },
+    "node_modules/js-cookie": {
+      "version": "3.0.1",
+      "resolved": "https://registry.npmmirror.com/js-cookie/-/js-cookie-3.0.1.tgz",
+      "integrity": "sha512-+0rgsUXZu4ncpPxRL+lNEptWMOWl9etvPHc/koSRp6MPwpRYAhmk0dUG00J4bxVV3r9uUzfo24wW0knS07SKSw==",
+      "engines": {
+        "node": ">=12"
+      }
+    },
     "node_modules/json5": {
       "version": "1.0.1",
       "resolved": "https://registry.npmmirror.com/json5/-/json5-1.0.1.tgz",
@@ -4217,6 +4254,14 @@
       "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==",
       "dev": true
     },
+    "axios": {
+      "version": "0.26.1",
+      "resolved": "https://registry.npmmirror.com/axios/-/axios-0.26.1.tgz",
+      "integrity": "sha512-fPwcX4EvnSHuInCMItEhAGnaSEXRBjtzh9fOtsE6E1G6p7vl7edEeZe11QHf18+6+9gR5PbKV/sGKNaD8YaMeA==",
+      "requires": {
+        "follow-redirects": "^1.14.8"
+      }
+    },
     "base": {
       "version": "0.11.2",
       "resolved": "https://registry.npmmirror.com/base/-/base-0.11.2.tgz",
@@ -4992,6 +5037,11 @@
         "reusify": "^1.0.4"
       }
     },
+    "file-saver": {
+      "version": "2.0.5",
+      "resolved": "https://registry.npmmirror.com/file-saver/-/file-saver-2.0.5.tgz",
+      "integrity": "sha512-P9bmyZ3h/PRG+Nzga+rbdI4OEpNDzAVyy74uVO9ATgzLK6VtAsYybF/+TOCvrc0MO793d6+42lLyZTw7/ArVzA=="
+    },
     "fill-range": {
       "version": "7.0.1",
       "resolved": "https://registry.npmmirror.com/fill-range/-/fill-range-7.0.1.tgz",
@@ -5001,6 +5051,11 @@
         "to-regex-range": "^5.0.1"
       }
     },
+    "follow-redirects": {
+      "version": "1.15.1",
+      "resolved": "https://registry.npmmirror.com/follow-redirects/-/follow-redirects-1.15.1.tgz",
+      "integrity": "sha512-yLAMQs+k0b2m7cVxpS1VKJVvoz7SS9Td1zss3XRwXj+ZDH00RJgnuLx7E44wx02kQLrdM3aOOy+FpzS7+8OizA=="
+    },
     "for-in": {
       "version": "1.0.2",
       "resolved": "https://registry.npmmirror.com/for-in/-/for-in-1.0.2.tgz",
@@ -5331,6 +5386,11 @@
       "integrity": "sha512-pZe//GGmwJndub7ZghVHz7vjb2LgC1m8B07Au3eYqeqv9emhESByMXxaEgkUkEqJe87oBbSniGYoQNIBklc7IQ==",
       "dev": true
     },
+    "js-cookie": {
+      "version": "3.0.1",
+      "resolved": "https://registry.npmmirror.com/js-cookie/-/js-cookie-3.0.1.tgz",
+      "integrity": "sha512-+0rgsUXZu4ncpPxRL+lNEptWMOWl9etvPHc/koSRp6MPwpRYAhmk0dUG00J4bxVV3r9uUzfo24wW0knS07SKSw=="
+    },
     "json5": {
       "version": "1.0.1",
       "resolved": "https://registry.npmmirror.com/json5/-/json5-1.0.1.tgz",

+ 4 - 1
ruoyi-web/package.json

@@ -9,7 +9,10 @@
     "@element-plus/icons-vue": "^2.0.6",
     "element-plus": "^2.2.8",
     "vue": "^3.0.4",
-    "vue-router": "^4.1.1"
+    "vue-router": "^4.1.1",
+    "axios": "0.26.1",
+    "file-saver": "2.0.5",
+    "js-cookie": "3.0.1"
   },
   "devDependencies": {
     "@types/node": "^18.0.3",

+ 52 - 0
ruoyi-web/src/api/dict/data.js

@@ -0,0 +1,52 @@
+import request from '@/utils/request'
+
+// 查询字典数据列表
+export function listData(query) {
+  return request({
+    url: '/system/dict/data/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询字典数据详细
+export function getData(dictCode) {
+  return request({
+    url: '/system/dict/data/' + dictCode,
+    method: 'get'
+  })
+}
+
+// 根据字典类型查询字典数据信息
+export function getDicts(dictType) {
+  return request({
+    url: '/system/dict/data/common/type/' + dictType,
+    method: 'get'
+  })
+}
+
+// 新增字典数据
+export function addData(data) {
+  return request({
+    url: '/system/dict/data',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改字典数据
+export function updateData(data) {
+  return request({
+    url: '/system/dict/data',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除字典数据
+export function delData(dictCode) {
+  return request({
+    url: '/system/dict/data/' + dictCode,
+    method: 'delete'
+  })
+}

+ 74 - 0
ruoyi-web/src/api/home.js

@@ -0,0 +1,74 @@
+import request from '@/utils/request'
+
+// 图片新闻
+export const lbList = () => {
+    return request({
+        url: '/portal/mhZcxw/lb/list',
+        method: 'get'
+    })
+}
+
+// 头条发布
+export const ttList = () => {
+    return request({
+        url: '/portal/mhZcxw/tt/list',
+        method: 'get'
+    })
+}
+
+// 热点专题
+export const rdList = () => {
+    return request({
+        url: '/portal/mhZcxw/rd/list',
+        method: 'get'
+    })
+}
+//政策查询
+export const zcList = () => {
+    return request({
+        url: '/portal/mhZcxw/zc/list',
+        method: 'get'
+    })
+}
+//规划报告
+export const ghList = () => {
+    return request({
+        url: '/portal/mhZcxw/gh/list',
+        method: 'get'
+    })
+}
+// 老龄数据
+export const llList = () => {
+    return request({
+        url: '/portal/mhZcxw/ll/list',
+        method: 'get'
+    })
+}
+//服务项目
+export const fwList = () => {
+    return request({
+        url: '/portal/mhZcxw/fw/list',
+        method: 'get'
+    })
+}
+//实用信息
+export const syList = () => {
+    return request({
+        url: '/portal/mhZcxw/sy/list',
+        method: 'get'
+    })
+}
+//行业管理
+export const hyList = () => {
+    return request({
+        url: '/portal/mhZcxw/hy/list',
+        method: 'get'
+    })
+}
+//外链接
+export const wlList = () => {
+    return request({
+        url: '/portal/mhZcxw/wl/list',
+        method: 'get'
+    })
+}

+ 31 - 2
ruoyi-web/src/components/Pagination/index.vue

@@ -44,7 +44,8 @@ const props = defineProps({
   },
   layout: {
     type: String,
-    default: 'total, sizes, prev, pager, next, jumper'
+    // default: 'total, sizes, prev, pager, next, jumper'
+    default: 'prev, pager, next, jumper'
   },
   background: {
     type: Boolean,
@@ -52,7 +53,7 @@ const props = defineProps({
   },
   autoScroll: {
     type: Boolean,
-    default: true
+    default: false
   },
   hidden: {
     type: Boolean,
@@ -99,8 +100,36 @@ function handleCurrentChange(val) {
 .pagination-container {
   background: #fff;
   padding: 32px 16px;
+  display: flex;
+  justify-content: center;
 }
 .pagination-container.hidden {
   display: none;
 }
+:deep(.el-pagination.is-background .el-pager li:not(.is-disabled).is-active)
+{
+  background: #B80100;
+  border-radius: 4px;
+  color: #FFFFFF;
+
+}
+:deep(.el-pagination.is-background .el-pager li:not(.is-disabled).is-active:hover)
+{
+  background: #B80100;
+  border-radius: 4px;
+  color: #FFFFFF;
+
+}
+:deep(.el-input__wrapper.is-focus){
+  box-shadow: 0 0 0 1px #B80100 inset;
+}
+:deep(.el-pagination.is-background .el-pager li:not(.is-disabled):hover)
+{
+  color: #B80100;
+}
+:deep(.el-pagination.is-background .btn-next:hover)
+{
+  color: #B80100;
+}
+
 </style>

+ 10 - 1
ruoyi-web/src/main.js

@@ -5,6 +5,11 @@ import router from './router/index'
 import "../src/assets/css/index.css";
 import ElementPlus from 'element-plus'
 import '../node_modules/element-plus/theme-chalk/index.css'
+import {zhCn} from "../node_modules/element-plus/es/locale";
+
+
+
+import { useDict } from '@/utils/dict'
 // 分页组件
 import Pagination from '@/components/Pagination'
 
@@ -14,9 +19,13 @@ for (let iconName in ElIcon){
     app.component(iconName, ElIcon[iconName])
 }
 
+
+// 全局方法挂载
+app.config.globalProperties.useDict = useDict
+
 app.component('Pagination', Pagination)
 
-app.use(ElementPlus);
+app.use(ElementPlus,{locale:zhCn});
 app.use(router);
 app.mount('#app');
 

+ 77 - 0
ruoyi-web/src/plugins/cache.js

@@ -0,0 +1,77 @@
+const sessionCache = {
+  set (key, value) {
+    if (!sessionStorage) {
+      return
+    }
+    if (key != null && value != null) {
+      sessionStorage.setItem(key, value)
+    }
+  },
+  get (key) {
+    if (!sessionStorage) {
+      return null
+    }
+    if (key == null) {
+      return null
+    }
+    return sessionStorage.getItem(key)
+  },
+  setJSON (key, jsonValue) {
+    if (jsonValue != null) {
+      this.set(key, JSON.stringify(jsonValue))
+    }
+  },
+  getJSON (key) {
+    const value = this.get(key)
+    if (value != null) {
+      return JSON.parse(value)
+    }
+  },
+  remove (key) {
+    sessionStorage.removeItem(key);
+  }
+}
+const localCache = {
+  set (key, value) {
+    if (!localStorage) {
+      return
+    }
+    if (key != null && value != null) {
+      localStorage.setItem(key, value)
+    }
+  },
+  get (key) {
+    if (!localStorage) {
+      return null
+    }
+    if (key == null) {
+      return null
+    }
+    return localStorage.getItem(key)
+  },
+  setJSON (key, jsonValue) {
+    if (jsonValue != null) {
+      this.set(key, JSON.stringify(jsonValue))
+    }
+  },
+  getJSON (key) {
+    const value = this.get(key)
+    if (value != null) {
+      return JSON.parse(value)
+    }
+  },
+  remove (key) {
+    localStorage.removeItem(key);
+  }
+}
+
+export default {
+  /**
+   * 会话级缓存
+   */
+  session: sessionCache,
+  /**
+   * 本地缓存
+   */
+  local: localCache
+}

+ 7 - 1
ruoyi-web/src/router/index.js

@@ -21,7 +21,13 @@ const router = createRouter({
           path: 'ylzc',
           component: () => import('../views/ylzc/index.vue'),
           name: 'ylzc',
-          meta: { title: '首页'}
+          meta: { title: '养老政策'}
+        },
+        {
+          path: 'jgcx',
+          component: () => import('../views/jgcx/index.vue'),
+          name: 'jgcx',
+          meta: { title: '机构查询'}
         }
       ],
       meta: {

+ 29 - 0
ruoyi-web/src/utils/auth.js

@@ -0,0 +1,29 @@
+import Cookies from 'js-cookie'
+
+const TokenKey = 'Admin-Token'
+
+const ExpiresInKey = 'Admin-Expires-In'
+
+export function getToken() {
+  return Cookies.get(TokenKey)
+}
+
+export function setToken(token) {
+  return Cookies.set(TokenKey, token)
+}
+
+export function removeToken() {
+  return Cookies.remove(TokenKey)
+}
+
+export function getExpiresIn() {
+  return Cookies.get(ExpiresInKey) || -1
+}
+
+export function setExpiresIn(time) {
+  return Cookies.set(ExpiresInKey, time)
+}
+
+export function removeExpiresIn() {
+  return Cookies.remove(ExpiresInKey)
+}

+ 17 - 0
ruoyi-web/src/utils/dict.js

@@ -0,0 +1,17 @@
+import { getDicts } from '@/api/dict/data'
+
+/**
+ * 获取字典数据
+ */
+export function useDict(...args) {
+  const res = ref({});
+  return (() => {
+    args.forEach((d, index) => {
+      res.value[d] = [];
+      getDicts(d).then(resp => {
+        res.value[d] = resp.data.map(p => ({ label: p.dictLabel, value: p.dictValue, elTagType: p.listClass, elTagClass: p.cssClass }))
+      })
+    })
+    return toRefs(res.value);
+  })()
+}

+ 6 - 0
ruoyi-web/src/utils/errorCode.js

@@ -0,0 +1,6 @@
+export default {
+  '401': '认证失败,无法访问系统资源',
+  '403': '当前操作没有权限',
+  '404': '访问资源不存在',
+  'default': '系统未知错误,请反馈给管理员'
+}

+ 158 - 0
ruoyi-web/src/utils/request.js

@@ -0,0 +1,158 @@
+import axios from 'axios'
+import { ElNotification , ElMessageBox, ElMessage, ElLoading } from 'element-plus'
+import { getToken } from '@/utils/auth'
+import errorCode from '@/utils/errorCode'
+import { tansParams, blobValidate } from '@/utils/ruoyi'
+import cache from '@/plugins/cache'
+import { saveAs } from 'file-saver'
+// import useUserStore from '@/store/modules/user'
+
+let downloadLoadingInstance;
+// 是否显示重新登录
+export let isRelogin = { show: false };
+
+axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
+// 创建axios实例
+const service = axios.create({
+  // axios中请求配置有baseURL选项,表示请求URL公共部分
+  baseURL: import.meta.env.VITE_APP_BASE_API,
+  // 超时
+  timeout: 10000
+})
+
+// request拦截器
+service.interceptors.request.use(config => {
+  // 是否需要设置 token
+  const isToken = (config.headers || {}).isToken === false
+  // 是否需要防止数据重复提交
+  const isRepeatSubmit = (config.headers || {}).repeatSubmit === false
+  if (getToken() && !isToken) {
+    config.headers['Authorization'] = 'Bearer ' + getToken() // 让每个请求携带自定义token 请根据实际情况自行修改
+  }
+  // get请求映射params参数
+  if (config.method === 'get' && config.params) {
+    let url = config.url + '?' + tansParams(config.params);
+    url = url.slice(0, -1);
+    config.params = {};
+    config.url = url;
+  }
+  if (!isRepeatSubmit && (config.method === 'post' || config.method === 'put')) {
+    const requestObj = {
+      url: config.url,
+      data: typeof config.data === 'object' ? JSON.stringify(config.data) : config.data,
+      time: new Date().getTime()
+    }
+    const sessionObj = cache.session.getJSON('sessionObj')
+    if (sessionObj === undefined || sessionObj === null || sessionObj === '') {
+      cache.session.setJSON('sessionObj', requestObj)
+    } else {
+      const s_url = sessionObj.url;                // 请求地址
+      const s_data = sessionObj.data;              // 请求数据
+      const s_time = sessionObj.time;              // 请求时间
+      const interval = 1000;                       // 间隔时间(ms),小于此时间视为重复提交
+      if (s_data === requestObj.data && requestObj.time - s_time < interval && s_url === requestObj.url) {
+        const message = '数据正在处理,请勿重复提交';
+        console.warn(`[${s_url}]: ` + message)
+        return Promise.reject(new Error(message))
+      } else {
+        cache.session.setJSON('sessionObj', requestObj)
+      }
+    }
+  }
+  return config
+}, error => {
+    console.log(error)
+    Promise.reject(error)
+})
+
+// 响应拦截器
+service.interceptors.response.use(res => {
+    // 未设置状态码则默认成功状态
+    const code = res.data.code || 200;
+    // 获取错误信息
+    const msg = errorCode[code] || res.data.msg || errorCode['default']
+    // 二进制数据则直接返回
+    if(res.request.responseType ===  'blob' || res.request.responseType ===  'arraybuffer'){
+      return res.data
+    }
+    if (code === 401) {
+      if (!isRelogin.show) {
+        isRelogin.show = true;
+        ElMessageBox.confirm('登录状态已过期,您可以继续留在该页面,或者重新登录', '系统提示', {
+          confirmButtonText: '重新登录',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }
+      ).then(() => {
+        isRelogin.show = false;
+        // useUserStore().logOut().then(() => {
+        //   location.href = '/index';
+        // })
+      }).catch(() => {
+        isRelogin.show = false;
+      });
+    }
+      return Promise.reject('无效的会话,或者会话已过期,请重新登录。')
+    } else if (code === 500) {
+      ElMessage({
+        message: msg,
+        type: 'error'
+      })
+      return Promise.reject(new Error(msg))
+    } else if (code !== 200) {
+      ElNotification.error({
+        title: msg
+      })
+      return Promise.reject('error')
+    } else {
+      return  Promise.resolve(res.data)
+    }
+  },
+  error => {
+    console.log('err' + error)
+    let { message } = error;
+    if (message == "Network Error") {
+      message = "后端接口连接异常";
+    }
+    else if (message.includes("timeout")) {
+      message = "系统接口请求超时";
+    }
+    else if (message.includes("Request failed with status code")) {
+      message = "系统接口" + message.substr(message.length - 3) + "异常";
+    }
+    ElMessage({
+      message: message,
+      type: 'error',
+      duration: 5 * 1000
+    })
+    return Promise.reject(error)
+  }
+)
+
+// 通用下载方法
+export function download(url, params, filename) {
+  downloadLoadingInstance = ElLoading.service({ text: "正在下载数据,请稍候", background: "rgba(0, 0, 0, 0.7)", })
+  return service.post(url, params, {
+    transformRequest: [(params) => { return tansParams(params) }],
+    headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
+    responseType: 'blob'
+  }).then(async (data) => {
+    const isLogin = await blobValidate(data);
+    if (isLogin) {
+      const blob = new Blob([data])
+      saveAs(blob, filename)
+    } else {
+      const resText = await data.text();
+      const rspObj = JSON.parse(resText);
+      const errMsg = errorCode[rspObj.code] || rspObj.msg || errorCode['default']
+      ElMessage.error(errMsg);
+    }
+    downloadLoadingInstance.close();
+  }).catch((r) => {
+    console.error(r)
+    ElMessage.error('下载文件出现错误,请联系管理员!')
+    downloadLoadingInstance.close();
+  })
+}
+
+export default service

+ 249 - 0
ruoyi-web/src/utils/ruoyi.js

@@ -0,0 +1,249 @@
+
+
+/**
+ * 通用js方法封装处理
+ * Copyright (c) 2019 ruoyi
+ */
+
+// 日期格式化
+export function parseTime(time, pattern) {
+  if (arguments.length === 0 || !time) {
+    return null
+  }
+  const format = pattern || '{y}-{m}-{d} {h}:{i}:{s}'
+  let date
+  if (typeof time === 'object') {
+    date = time
+  } else {
+    if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) {
+      time = parseInt(time)
+    } else if (typeof time === 'string') {
+      time = time.replace(new RegExp(/-/gm), '/').replace('T', ' ').replace(new RegExp(/\.[\d]{3}/gm), '');
+    }
+    if ((typeof time === 'number') && (time.toString().length === 10)) {
+      time = time * 1000
+    }
+    date = new Date(time)
+  }
+  const formatObj = {
+    y: date.getFullYear(),
+    m: date.getMonth() + 1,
+    d: date.getDate(),
+    h: date.getHours(),
+    i: date.getMinutes(),
+    s: date.getSeconds(),
+    a: date.getDay()
+  }
+  const time_str = format.replace(/{(y|m|d|h|i|s|a)+}/g, (result, key) => {
+    let value = formatObj[key]
+    // Note: getDay() returns 0 on Sunday
+    if (key === 'a') { return ['日', '一', '二', '三', '四', '五', '六'][value] }
+    if (result.length > 0 && value < 10) {
+      value = '0' + value
+    }
+    return value || 0
+  })
+  return time_str
+}
+
+// 表单重置
+export function resetForm(refName) {
+  if (this.$refs[refName]) {
+    this.$refs[refName].resetFields();
+  }
+}
+
+// 添加日期范围
+export function addDateRange(params, dateRange, propName) {
+  let search = params;
+  search.params = typeof (search.params) === 'object' && search.params !== null && !Array.isArray(search.params) ? search.params : {};
+  dateRange = Array.isArray(dateRange) ? dateRange : [];
+  if (typeof (propName) === 'undefined') {
+    search.params['beginTime'] = dateRange[0];
+    search.params['endTime'] = dateRange[1];
+  } else {
+    search.params['begin' + propName] = dateRange[0];
+    search.params['end' + propName] = dateRange[1];
+  }
+  return search;
+}
+
+// 回显数据字典
+export function selectDictLabel(datas, value) {
+  if (value === undefined) {
+    return "";
+  }
+  var actions = [];
+  Object.keys(datas).some((key) => {
+    if (datas[key].value == ('' + value)) {
+      actions.push(datas[key].label);
+      return true;
+    }
+  })
+  if (actions.length === 0) {
+    actions.push(value);
+  }
+  return actions.join('');
+}
+
+// 回显数据字典(字符串数组)
+export function selectDictLabels(datas, value, separator) {
+  if (value === undefined) {
+    return "";
+  }
+  var actions = [];
+  var currentSeparator = undefined === separator ? "," : separator;
+  var temp = value.split(currentSeparator);
+  Object.keys(value.split(currentSeparator)).some((val) => {
+    var match = false;
+    Object.keys(datas).some((key) => {
+      if (datas[key].value == ('' + temp[val])) {
+        actions.push(datas[key].label + currentSeparator);
+        match = true;
+      }
+    })
+    if (!match) {
+      actions.push(temp[val] + currentSeparator);
+    }
+  })
+  return actions.join('').substring(0, actions.join('').length - 1);
+}
+
+// 字符串格式化(%s )
+export function sprintf(str) {
+  var args = arguments, flag = true, i = 1;
+  str = str.replace(/%s/g, function () {
+    var arg = args[i++];
+    if (typeof arg === 'undefined') {
+      flag = false;
+      return '';
+    }
+    return arg;
+  });
+  return flag ? str : '';
+}
+
+// 转换字符串,undefined,null等转化为""
+export function parseStrEmpty(str) {
+  if (!str || str == "undefined" || str == "null") {
+    return "";
+  }
+  return str;
+}
+
+// 数据合并
+export function mergeRecursive(source, target) {
+  for (var p in target) {
+    try {
+      if (target[p].constructor == Object) {
+        source[p] = mergeRecursive(source[p], target[p]);
+      } else {
+        source[p] = target[p];
+      }
+    } catch (e) {
+      source[p] = target[p];
+    }
+  }
+  return source;
+};
+
+/**
+ * 构造树型结构数据
+ * @param {*} data 数据源
+ * @param {*} id id字段 默认 'id'
+ * @param {*} parentId 父节点字段 默认 'parentId'
+ * @param {*} children 孩子节点字段 默认 'children'
+ */
+export function handleTree(data, id, parentId, children) {
+  let config = {
+    id: id || 'id',
+    parentId: parentId || 'parentId',
+    childrenList: children || 'children'
+  };
+
+  var childrenListMap = {};
+  var nodeIds = {};
+  var tree = [];
+
+  for (let d of data) {
+    let parentId = d[config.parentId];
+    if (childrenListMap[parentId] == null) {
+      childrenListMap[parentId] = [];
+    }
+    nodeIds[d[config.id]] = d;
+    childrenListMap[parentId].push(d);
+  }
+
+  for (let d of data) {
+    let parentId = d[config.parentId];
+    if (nodeIds[parentId] == null) {
+      tree.push(d);
+    }
+  }
+
+  for (let t of tree) {
+    adaptToChildrenList(t);
+  }
+
+  function adaptToChildrenList(o) {
+    if (childrenListMap[o[config.id]] !== null) {
+      o[config.childrenList] = childrenListMap[o[config.id]];
+    }
+    if (o[config.childrenList]) {
+      for (let c of o[config.childrenList]) {
+        adaptToChildrenList(c);
+      }
+    }
+  }
+  return tree;
+}
+
+/**
+* 参数处理
+* @param {*} params  参数
+*/
+export function tansParams(params) {
+  let result = ''
+  for (const propName of Object.keys(params)) {
+    const value = params[propName];
+    var part = encodeURIComponent(propName) + "=";
+    if (value !== null && value !== "" && typeof (value) !== "undefined") {
+      if (typeof value === 'object') {
+        for (const key of Object.keys(value)) {
+          if (value[key] !== null && value[key] !== "" && typeof (value[key]) !== 'undefined') {
+            let params = propName + '[' + key + ']';
+            var subPart = encodeURIComponent(params) + "=";
+            result += subPart + encodeURIComponent(value[key]) + "&";
+          }
+        }
+      } else {
+        result += part + encodeURIComponent(value) + "&";
+      }
+    }
+  }
+  return result
+}
+
+
+// 返回项目路径
+export function getNormalPath(p) {
+  if (p.length === 0 || !p || p == 'undefined') {
+    return p
+  };
+  let res = p.replace('//', '/')
+  if (res[res.length - 1] === '/') {
+    return res.slice(0, res.length - 1)
+  }
+  return res;
+}
+
+// 验证是否为blob格式
+export async function blobValidate(data) {
+  try {
+    const text = await data.text();
+    JSON.parse(text);
+    return false;
+  } catch (error) {
+    return true;
+  }
+}

+ 112 - 175
ruoyi-web/src/views/home/index.vue

@@ -39,11 +39,11 @@
                 <div class="carousel flex_column" style="height: 395px">
                     <div class="flex xw_box" v-for="(item,index) in xwData" :key="index">
 
-                        <div class="xw_title title_overflow margin_left10 fs16">
+                        <div class="xw_title title_overflow margin_left10 fs16" :title="item.bt">
                             {{item.bt}}
                         </div>
-                        <div class="xw_date">
-                            {{item.issSj}}
+                        <div class="xw_date" :title="changDate(item.issSj,'two')">
+                            {{changDate(item.issSj,'one')}}
                         </div>
                     </div>
                 </div>
@@ -62,38 +62,19 @@
                     <div class="ckgd"> 【查看更多】</div>
                 </div>
                 <div class="rd_center">
-                    <el-tabs v-model="activeName">
-                        <el-tab-pane label="官方讯息" name="first">
-                            <div class="flex_column" style="height: 100%">
-                                <div class="flex" v-for="(item,index) in rdData" :key="index">
-                                    <div class="dian">
+                  <div class="flex_column" style="height: 100%">
+                    <div class="flex" v-for="(item,index) in rdData" :key="index">
+                      <div class="dian">
 
-                                    </div>
-                                    <div class="xw_title title_overflow fs14">
-                                        {{item.bt}}
-                                    </div>
-                                    <div class="xw_date">
-                                        {{item.issSj}}
-                                    </div>
-                                </div>
-                            </div>
-                        </el-tab-pane>
-                        <el-tab-pane label="最新政策" name="second">
-                            <div class="flex_column" style="height: 100%">
-                                <div class="flex" v-for="(item,index) in rdData" :key="index">
-                                    <div class="dian">
-
-                                    </div>
-                                    <div class="xw_title title_overflow fs14">
-                                        {{item.bt}}
-                                    </div>
-                                    <div class="xw_date">
-                                        {{item.issSj}}
-                                    </div>
-                                </div>
-                            </div>
-                        </el-tab-pane>
-                    </el-tabs>
+                      </div>
+                      <div class="xw_title title_overflow fs14" :title="item.bt">
+                        {{item.bt}}
+                      </div>
+                      <div class="xw_date" :title="changDate(item.issSj,'two')">
+                        {{changDate(item.issSj,'one')}}
+                      </div>
+                    </div>
+                  </div>
                 </div>
             </div>
             <div class="center_box flex_column">
@@ -107,64 +88,34 @@
                     <el-tabs v-model="activeName">
                         <el-tab-pane label="全部" name="first">
                             <div class="flex_column" style="height: 100%">
-                                <div class="flex" v-for="(item,index) in rdData" :key="index">
+                                <div class="flex" v-for="(item,index) in zcData.slice(0,5)" :key="index">
                                     <div class="dian">
 
                                     </div>
-                                    <div class="xw_title title_overflow fs14">
+                                    <div class="xw_title title_overflow fs14" :title="item.bt">
                                         {{item.bt}}
                                     </div>
-                                    <div class="xw_date">
-                                        {{item.issSj}}
-                                    </div>
+                                  <div class="xw_date" :title="changDate(item.issSj,'two')">
+                                    {{changDate(item.issSj,'one')}}
+                                  </div>
                                 </div>
                             </div>
                         </el-tab-pane>
-                        <el-tab-pane label="综合类" name="second">
-                            <div class="flex_column" style="height: 100%">
-                                <div class="flex" v-for="(item,index) in rdData" :key="index">
-                                    <div class="dian">
+                      <el-tab-pane v-for="item in XZ086" :label="item.label" :name="item.value">
+                        <div class="flex_column" style="height: 100%">
+                          <div class="flex" v-for="(item,index) in changZcData(zcData,activeName)" :key="index">
+                            <div class="dian">
 
-                                    </div>
-                                    <div class="xw_title title_overflow fs14">
-                                        {{item.bt}}
-                                    </div>
-                                    <div class="xw_date">
-                                        {{item.issSj}}
-                                    </div>
-                                </div>
                             </div>
-                        </el-tab-pane>
-                        <el-tab-pane label="服务类" name="three">
-                            <div class="flex_column" style="height: 100%">
-                                <div class="flex" v-for="(item,index) in rdData" :key="index">
-                                    <div class="dian">
-
-                                    </div>
-                                    <div class="xw_title title_overflow fs14">
-                                        {{item.bt}}
-                                    </div>
-                                    <div class="xw_date">
-                                        {{item.issSj}}
-                                    </div>
-                                </div>
+                            <div class="xw_title title_overflow fs14" :title="item.bt">
+                              {{item.bt}}
                             </div>
-                        </el-tab-pane>
-                        <el-tab-pane label="专项类" name="four">
-                            <div class="flex_column" style="height: 100%">
-                                <div class="flex" v-for="(item,index) in rdData" :key="index">
-                                    <div class="dian">
-
-                                    </div>
-                                    <div class="xw_title title_overflow fs14">
-                                        {{item.bt}}
-                                    </div>
-                                    <div class="xw_date">
-                                        {{item.issSj}}
-                                    </div>
-                                </div>
+                            <div class="xw_date" :title="changDate(item.issSj,'two')">
+                              {{changDate(item.issSj,'one')}}
                             </div>
-                        </el-tab-pane>
+                          </div>
+                        </div>
+                      </el-tab-pane>
                     </el-tabs>
                 </div>
             </div>
@@ -261,13 +212,13 @@
                 </div>
                 <div class="rd_center">
                     <div class="flex_column" style="height: 100%">
-                        <div class="flex bor_bt" v-for="(item,index) in zlData" :key="index">
+                        <div class="flex bor_bt" v-for="(item,index) in changeDict(XZ085)" :key="index">
                             <div class="flex" style="width: 50%">
                             <div class="dian">
 
                             </div>
                             <div class="zl_lh title_overflow fs14">
-                                {{item[0].bt}}
+                                {{item[0].label}}
                             </div>
                             </div>
                             <div class="flex" style="width: 50%">
@@ -275,7 +226,7 @@
 
                                 </div>
                                 <div class="zl_lh title_overflow fs14">
-                                    {{item[1].bt}}
+                                    {{item[1].label}}
                                 </div>
                             </div>
                         </div>
@@ -319,13 +270,13 @@
     <div class="footer_conter flex_column">
         <div class="rd_top">
             <div class="rd_title">
-                办事指南
+               相关链接
             </div>
         </div>
         <div class="footer">
         <div class="flex">
-            <div class="footer_title"  v-for="(item) in xgData" :key="item">
-                {{item}}
+            <div class="footer_title"  v-for="(item,index) in xgData" :key="index">
+              <el-link :href="item.url" target="_blank">{{item.bt}}</el-link>
             </div>
         </div>
     </div>
@@ -333,7 +284,10 @@
 </template>
 
 <script setup>
-    import {ref} from 'vue'
+    import {ref,onMounted} from 'vue'
+    import { lbList,rdList,ttList,zcList,wlList} from '@/api/home'
+    const { proxy } = getCurrentInstance();
+    const { XZ085,XZ086,XZ087,XZ088, XZ089 } = proxy.useDict("XZ085","XZ086","XZ087","XZ088", "XZ089");
 
     const activeName = ref('first');
     const zlData=ref([
@@ -342,7 +296,7 @@
         [{bt:'银龄宝典'},{bt:'实用信息'}],
         [{bt:'行业管理'},{bt:'社区养老'}]
     ])
-    const xgData= ref(['中国×××××网站','中国×××××网站','中国×××××网站','中国×××××网站','中国×××××网站','中国×××××网站','中国×××××网站','中国×××××网站']);
+    const xgData= ref([]);
     const jgData= ref([
         {src:new URL('../../assets/images/jg1.png', import.meta.url).href,label:'养老机构'},
         {src:new URL('../../assets/images/jg2.png', import.meta.url).href,label:'长者照护之家'},
@@ -352,89 +306,72 @@
         {src:new URL('../../assets/images/jg6.png', import.meta.url).href,label:'护理院/站'},
         {src:new URL('../../assets/images/jg7.png', import.meta.url).href,label:'养老机构'},
     ]);
-    const xwData = ref([
-        {
-            bt: '空中养老顾问',
-            issSj: '03-28',
-        },
-        {
-            bt: '全国养老护理职业技能大赛',
-            issSj: '03-28',
-        },
-        {
-            bt: '智慧养老应用场景案例征集xxxxxxxxxxx',
-            issSj: '03-28',
-        },
-        {
-            bt: '老年福祉产品大赛',
-            issSj: '03-28',
-        },
-        {
-            bt: '100万人次长者智能技术运xxxxxxxxxxxxxxxxxxxxxxxxx',
-            issSj: '03-28',
-        },
-        {
-            bt: '疫情防控狙击战',
-            issSj: '03-28',
-        },
-        {
-            bt: '长期护理保险试点文件汇总',
-            issSj: '03-28',
-        },
-        {
-            bt: '疫情防控狙击战',
-            issSj: '03-28',
-        },
-        {
-            bt: '长期护理保险试点文件汇总',
-            issSj: '03-28',
-        },
-        {
-            bt: '养老产业巨大刚需市场蓄势养老产业巨大刚需市场蓄势养老产业巨大刚需市场蓄势养老产业巨大刚需市场蓄势养老产业巨大刚需市场蓄势',
-            issSj: '03-28',
-        },
-    ]);
-    const rdData = ref([
-        {
-            bt: '空中养老顾问',
-            issSj: '03-28',
-        },
-        {
-            bt: '全国养老护理职业技能大赛',
-            issSj: '03-28',
-        },
-        {
-            bt: '智慧养老应用场景案例征集xxxxxxxxxxx',
-            issSj: '03-28',
-        },
-        {
-            bt: '老年福祉产品大赛',
-            issSj: '03-28',
-        },
-        {
-            bt: '100万人次长者智能技术运xxxxxxxxxxxxxxxxxxxxxxxxx',
-            issSj: '03-28',
-        },
-    ]);
-    const srcData = ref([
-        {
-            url: 'http://101.227.181.183:9100/img/1656989187784.jpg',
-            bt: '践行人民城市理念,聚焦民生话题,市民政局局长蒋蕊做客“2022民生访谈”'
-        },
-        {
-            url: 'http://101.227.181.183:9100/img/1655864384470.jpg',
-            bt: '严防控,暖关怀,虹口曲阳路街道为老年人办好离线“随申码”'
-        },
-        {
-            url: 'http://101.227.181.183:9100/img/1656310856184.jpg',
-            bt: '上海出台十条政策措施,扶持养老机构纾困发展'
-        },
-        {
-            url: 'http://101.227.181.183:9100/img/1656638878406.jpg',
-            bt: '市第一社会福利院:传承孝善文化,擘画养老蓝图'
-        },
-    ]);
-
+    const xwData = ref([]);
+    const rdData = ref([]);
+    const srcData = ref([]);
+    const zcData=ref([])
+    // 图片新闻
+    function getLbList(){
+      lbList().then(res=>{
+        srcData.value=res.rows;
+      })
+    }
+    // 头条发布
+    function getTtList(){
+      ttList().then(res=>{
+
+        xwData.value=res.rows.splice(0,10);
+      })
+    }
+    // 热点专题
+    function getRdList(){
+      rdList().then(res=>{
+        rdData.value=res.rows.splice(0,6);
+      })
+    }
+    //政策查询
+    function getZcList(){
+      zcList().then(res=>{
+        zcData.value=res.rows
+      })
+    }
+    function changDate(data,type){
+      let time='';
+      switch (type)
+      {
+        case 'one':
+          time=data.slice(-4,-2)+'-'+data.slice(-2)
+          break;
+        case 'two':
+          time=data.slice(0,data.length-4)+'-'+data.slice(-4,-2)+'-'+data.slice(-2)
+          break;
+      }
+      return time
+    }
+    function changZcData(data,value){
+     return  data.filter(item=>item.ffl===value)
+    }
+    function changeDict(data){
+      let list=data.slice(0,8);
+      let result=[];
+      for (let i=0;i<list.length;i+=2){
+        result.push(list.slice(i,i+2));
+       }
+       return  result;
+    }
+    //相关链接
+    function getWlList(){
+      wlList().then(res=>{
+        xgData.value=res.rows.slice(0,8);
+      })
+    }
+    onMounted(()=>{
+      getLbList();
+      getTtList();
+      getRdList();
+      getZcList();
+      getWlList();
+    })
 
 </script>
 <style>
@@ -449,7 +386,7 @@
         border-radius: 5px;
         width: 100%;
         height: 480px;
-        margin-top: 21px;
+        /*margin-top: 21px;*/
     }
 
     .main2 {
@@ -645,7 +582,7 @@
     }
 
     .center_box {
-        width: 50%;
+        width: 49%;
         /*height: 100%;*/
         background: #FFFFFF;
         box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1000)
@@ -663,7 +600,7 @@
         /*height: 100%;*/
         background: #FFFFFF;
         margin-top: 25px;
-        margin-bottom: 25px;
+        /*margin-bottom: 25px;*/
         box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1000)
     }
 
@@ -741,7 +678,7 @@
 
 
     .mg_right24{
-        margin-right: 24px;
+        margin-right: 2%;
     }
     .nav{
         width: 100%;

+ 2 - 2
ruoyi-web/src/views/index.vue

@@ -46,7 +46,7 @@
     const mentData = ref([
         {label: '首页',path:'/home'},
         {label: '养老政策',path:'/ylzc'},
-      {label: '机构查询'},
+      {label: '机构查询',path: '/jgcx'},
       {label: '在线申请'},
       {label: '养老顾问'},
       {label: '养老地图'},
@@ -154,7 +154,7 @@
     .centen_box{
         min-width: 1200px;
         width: 1200px;
-        margin: 0 auto;
+        margin: 21px auto;
     }
     .footer{
         min-width: 1200px;

+ 586 - 0
ruoyi-web/src/views/jgcx/index.vue

@@ -0,0 +1,586 @@
+<template>
+  <div class="main_box2">
+    <div class="bread">
+      <div class="bread_left">
+        <div class="gray">您现在所在位置:</div>
+        <el-breadcrumb separator=">>">
+          <el-breadcrumb-item :to="{ path: '/home' }"><span class="gray">首页</span></el-breadcrumb-item>
+          <el-breadcrumb-item><span class="red">机构查询</span></el-breadcrumb-item>
+        </el-breadcrumb>
+      </div>
+      <div class="bread_right">
+        <el-input class="input" v-model="input" placeholder="请输入内容"/>
+        <el-button :icon="Search" class="search">搜索</el-button>
+      </div>
+    </div>
+    <div class="center_box">
+      <div class="selcet_button">
+        <div class="lx">类型:</div>
+        <el-radio-group v-model="checkboxGroup1" size="large">
+          <el-radio-button v-for="city in cities" :key="city.value" :label="city.value" class="check_style">
+            {{ city.label }}
+          </el-radio-button>
+        </el-radio-group>
+      </div>
+      <div class="selcet_button">
+        <div class="lx">区域:</div>
+        <el-radio-group v-model="checkboxGroup2" size="large">
+          <el-radio-button v-for="city in cities2" :key="city.value" :label="city.value" class="check_style">
+            {{ city.label }}
+          </el-radio-button>
+        </el-radio-group>
+      </div>
+      <div class="kz_box selcet_button">
+        <div class="lx">扩展项:</div>
+        <div class="kz_select">
+          <div class="select_top">
+            <div class="select_box">
+              <div class="left_box">
+                     价格
+              </div>
+              <el-select v-model="value" placeholder="请选择价格">
+                <el-option
+                    v-for="item in options"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                />
+              </el-select>
+            </div>
+            <div class="select_box">
+              <div class="left_box">
+                机构等级
+              </div>
+              <el-select v-model="value" placeholder="请选择机构等级">
+                <el-option
+                    v-for="item in options"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                />
+              </el-select>
+            </div>
+            <div class="select_box">
+              <div class="left_box">
+                日常监测
+              </div>
+              <el-select v-model="value" placeholder="请选择日常监测">
+                <el-option
+                    v-for="item in options"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                />
+              </el-select>
+            </div>
+          </div>
+          <div class="select_top">
+            <div class="select_box">
+              <div class="left_box">
+                内设医疗机构
+              </div>
+              <el-select v-model="value" placeholder="请选择">
+                <el-option
+                    v-for="item in options"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                />
+              </el-select>
+            </div>
+            <div class="select_box">
+              <div class="left_box">
+                长护险定点
+              </div>
+              <el-select v-model="value" placeholder="请选择">
+                <el-option
+                    v-for="item in options"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                />
+              </el-select>
+            </div>
+          </div>
+          <div class="select_top">
+
+            <div class="select_box">
+              <div class="left_box">
+                收住认知症
+              </div>
+              <el-select v-model="value" placeholder="请选择">
+                <el-option
+                    v-for="item in options"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                />
+              </el-select>
+            </div>
+            <div class="select_box">
+              <div class="left_box">
+                有空余床位
+              </div>
+              <el-select v-model="value" placeholder="请选择">
+                <el-option
+                    v-for="item in options"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                />
+              </el-select>
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="selcet_button">
+        <div class="select_left">您的筛选条件包含</div>
+        <div class="select_center">
+          <el-tag
+              v-for="tag in tags"
+              :key="tag.name"
+              class="mx-1"
+              closable
+              type="info"
+              @close="handleClose(tag)"
+          >
+            {{ tag.name }}
+          </el-tag>
+        </div>
+        <div class="select_right">
+          <el-button>重置</el-button>
+        </div>
+      </div>
+      <div class="total">
+       <div> 搜索结果       共  <span class="red">314</span>  条结果(筹备或暂停状态机构未显示)</div>
+        <div class="map">结果在地图上展示</div>
+      </div>
+      <div class="bottom_box" v-loading="loading">
+        <div class="jg_box" v-for="(item,index) in jgData" :key="index">
+          <div class="jg_main">
+          <div class="img"></div>
+            <div class="rigth_nr">
+              <div class="height25 font_style1">
+                {{item.mc}}
+              </div>
+              <div class="height25 font_style2">
+                <el-rate
+                    v-model="item.dj"
+                    disabled
+                    text-color="#ff9900"
+                /> ({{changeNumber(item.dj)}}级)
+              </div>
+              <div class="height25 font_style3">
+                地址:{{item.dz}}
+              </div>
+              <div class="height25 font_style3">
+                电话:{{item.dh}}
+              </div>
+            </div>
+          </div>
+
+        </div>
+      </div>
+      <pagination
+          v-show="total > 0"
+          :total="total"
+          v-model:page="queryParams.pageNum"
+          v-model:limit="queryParams.pageSize"
+          @pagination="getList"
+      />
+    </div>
+  </div>
+</template>
+
+<script setup>
+
+import {ref,reactive, toRefs} from 'vue';
+import {Search} from '@element-plus/icons-vue'
+
+const input = ref('');
+const checkboxGroup1 = ref('')
+const cities = [
+  {label: '不限', value: '00'},
+  {label: '养老机构', value: '01'},
+  {label: '长者照护之家', value: '02'},
+  {label: '老年日照护机构', value: '04'},
+  {label: '助餐服务点', value: '05'},
+  {label: '社区养老服务组织', value: '06'},
+  {label: '社区为老服务中心', value: '07'},
+  {label: '护理站', value: '08'},
+  {label: '护理院', value: '09'}
+]
+const checkboxGroup2 = ref('')
+const cities2 = [
+  {label: '不限', value: '00'},
+  {label: '长春市', value: '01'},
+  {label: '吉林市', value: '02'},
+  {label: '四平市', value: '04'},
+  {label: '辽源市', value: '05'},
+  {label: '通化市', value: '06'},
+  {label: '白山市', value: '07'},
+  {label: '松原市', value: '08'},
+  {label: '白城市', value: '09'},
+  {label: '延边朝鲜族自治州', value: '10'}
+]
+const value = ref('')
+const options = [
+  {
+    value: 'Option1',
+    label: 'Option1',
+  },
+  {
+    value: 'Option2',
+    label: 'Option2',
+  },
+  {
+    value: 'Option3',
+    label: 'Option3',
+  },
+  {
+    value: 'Option4',
+    label: 'Option4',
+  },
+  {
+    value: 'Option5',
+    label: 'Option5',
+  },
+]
+const tags = ref([
+  { name: '内设医疗机构:是', value: 'ddx' },
+  { name: '社区类型:养老机构', value: '01' },
+  { name: '社区类型:养老机构1', value: '01' },
+  { name: '社区类型:养老机构2', value: '01' },
+  { name: '社区类型:养老机构3', value: '01' },
+  { name: '社区类型:养老机构4', value: '01' },
+  { name: '社区类型:养老机构5', value: '01' },
+
+])
+const rate = ref(3)
+const jgData = ref([
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  },
+  {
+    mc:'吉林顾村和平养老院',dj:3,dz:'长春市朝阳区12356号',dh:'0431-86963633'
+  }
+])
+const handleClose = (tag) => {
+  // dynamicTags.value.splice(dynamicTags.value.indexOf(tag), 1)
+   console.log(tag,'tag')
+}
+const data = reactive({
+  queryParams: {
+    pageNum: 1,
+    pageSize: 10,
+  },
+});
+
+const { queryParams} = toRefs(data);
+
+const total = ref(100);
+const loading = ref(false);
+/** 数据列表 */
+function getList() {
+  loading.value = true;
+  // listData(queryParams.value).then(response => {
+  //   dataList.value = response.rows;
+  //   total.value = response.total;
+  //   loading.value = false;
+  // });
+}
+function changeNumber(number){
+  let size="";
+  switch (number)
+  {
+    case 1:
+      size="一";
+      break;
+    case 2:
+      size="二";
+      break;
+    case 3:
+      size="三";
+      break;
+    case 4:
+      size="四";
+      break;
+    case 5:
+      size="五";
+      break;
+  }
+  return size;
+
+}
+</script>
+
+<style scoped>
+.main_box2 {
+  background: #FFFFFF;
+  border: 1px solid #DEDEDE;
+}
+
+.bread {
+  height: 58px;
+  border-bottom: 1px solid #DEDEDE;
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+}
+
+.bread_left {
+  display: flex;
+  margin-left: 34px;
+
+}
+
+.gray {
+  font-size: 16px;
+  font-weight: bold;
+  color: #666666;
+}
+
+:deep(.el-breadcrumb) {
+  font-size: 16px;
+  line-height: unset;
+}
+
+.red {
+  font-size: 16px;
+  font-weight: bold;
+  color: #B80100;
+}
+
+.bread_right {
+  margin-right: 12px;
+  display: flex;
+}
+
+:deep(.input .el-input__wrapper,.el-date-editor.el-input__wrapper) {
+  border: none;
+  height: 40px;
+  /*border-radius:unset;*/
+  border-top-left-radius: 20px;
+  border-bottom-left-radius: 20px;
+  margin-right: -2px;
+}
+
+.input {
+  width: 300px;
+}
+
+.selcet_button {
+  display: flex;
+  align-items: center;
+  margin: 22px 0;
+}
+
+.search {
+  width: 100px;
+  height: 42px;
+  background: #B80100;
+  border-radius: 0 20px 20px 0;
+  font-size: 14px;
+  font-weight: bold;
+  color: #FFFFFF;
+  line-height: 50px;
+}
+
+/*默认样式*/
+:deep(.el-radio-button__inner) {
+  border-left: #dcdfe6 solid 1px !important;
+  padding: 5px 12px;
+  font-size: 16px;
+  font-weight: bold;
+  color: #444B55;
+}
+
+/*选中样式*/
+:deep(.el-radio-button__original-radio:checked+.el-radio-button__inner) {
+  background-color: rgb(255 255 255 / 0%);
+  border-left: #B80100 solid 1px !important;
+  color: #B80100;
+  border-color: #B80100 !important;
+  box-shadow: none;
+}
+
+/*!*取消选中样式*!*/
+/*:deep(.el-radio-button.is-focus .el-radio-button__inner){*/
+/*  border-color:#dcdfe6;*/
+/*}*/
+.center_box {
+  margin-left: 25px;
+  margin-right: 25px;
+}
+
+.lx {
+  font-size: 16px;
+  font-weight: bold;
+  color: #444B55;
+  width: 70px;
+}
+
+.check_style {
+  margin-right: 11px;
+  margin-top: 5px;
+}
+.kz_box{
+  /*height: 90px;*/
+  padding: 10px 0;
+  background: #FBF2F2;
+  border-radius: 6px;
+}
+.kz_select{
+  display: flex;
+  flex-direction: column;
+}
+.select_top{
+  display: flex;
+  height: 30%;
+  margin-bottom: 1%;
+}
+.select_box{
+  display: flex;
+  margin-right: 13px;
+}
+.left_box{
+  width: 100px;
+  /*padding: 0 10px;*/
+  height: 30px;
+  background: #FFFFFF;
+  border: 1px solid #EF7E7E;
+  opacity: 0.8;
+  border-radius: 15px 0 0 15px;
+  font-size: 14px;
+  font-weight: bold;
+  color: #444B55;
+  line-height: 30px;
+  text-align: center;
+}
+:deep(.el-select .el-input__wrapper){
+  box-shadow: none;
+  border: 1px solid #EF7E7E;
+  border-left: none;
+  border-radius:0 15px 15px 0;
+  height: 30px;
+  padding: 0 11px;
+}
+.select_left{
+  width: 140px;
+  font-size: 14px;
+  font-weight: bold;
+  color: #444B55;
+}
+.select_center{
+  width: 960px;
+}
+.select_right{
+  width: 100px;
+  text-align: right;
+}
+:deep(.el-tag.el-tag--info){
+  font-size: 16px;
+  font-weight: bold;
+  color: #444B55;
+  padding: 15px 14px;
+  margin-right: 15px;
+  margin-top: 5px;
+  background-color: inherit;
+}
+.total{
+  font-size: 16px;
+  font-weight: bold;
+  color: #444B55;
+  display: flex;
+  justify-content: space-between;
+  margin-bottom: 22px;
+}
+.red{
+  color: #C53130;
+}
+.map{
+  width: 179px;
+  height: 28px;
+  background: #B80100;
+  border-radius: 6px;
+  color: #FFFFFF;
+  line-height: 28px;
+  text-align: center;
+}
+.bottom_box{
+  display: flex;
+  flex-wrap: wrap;
+  justify-content: space-between;
+}
+.jg_box{
+  width: 48%;
+  height: 149px;
+  background: #FAFAFC;
+  border: #B80100 solid 1px;
+  display: flex;
+  margin-bottom: 19px;
+}
+.jg_main{
+  width: 94%;
+  height: 85%;
+  margin: auto;
+  display: flex;
+  border: #B80100 solid 1px;
+  align-items: center;
+}
+.img{
+  width: 145px;
+  height: 110px;
+  border: #B80100 solid 1px;
+  margin-right: 21px;
+}
+.rigth_nr{
+  display: flex;
+  flex-direction: column;
+}
+.height25{
+  height: 25%;
+  display: flex;
+  align-items: center;
+
+}
+.font_style1{
+  font-size: 18px;
+  font-weight: bold;
+  color: #444B55;
+}
+.font_style2{
+  font-size: 14px;
+  font-weight: 400;
+  color: #444B55;
+}
+.font_style3{
+  font-size: 14px;
+  font-weight: 400;
+  color: #999999;
+}
+</style>

+ 5 - 5
ruoyi-web/src/views/ylzc/index.vue

@@ -118,8 +118,8 @@ const data = reactive({
 
 const { queryParams} = toRefs(data);
 
-const total = ref(0);
-const loading = ref(true);
+const total = ref(100);
+const loading = ref(false);
 const tableData = ref([
   {wzbt:'国家卫生健康委办公厅关于开展老年心理关爱行动的通知',wzly:'长春民政',fwzh:'国卫办老龄函〔2022〕204号',date:'06-20',year:'2020'},
   {wzbt:'国家卫生健康委办公厅关于开展老年心理关爱行动的通知',wzly:'长春民政',fwzh:'国卫办老龄函〔2022〕204号',date:'06-20',year:'2020'},
@@ -186,7 +186,7 @@ const addClass=(index)=>{
   return 'button_style'
 }
 
-/** 查询字典数据列表 */
+/** 数据列表 */
 function getList() {
   loading.value = true;
   // listData(queryParams.value).then(response => {
@@ -201,8 +201,8 @@ function getList() {
 .main_box2{
   background: #FFFFFF;
   border: 1px solid #DEDEDE;
-  margin-top: 21px;
-  margin-bottom: 70px;
+  /*margin-top: 21px;*/
+  /*margin-bottom: 70px;*/
 }
 
 .bread{