Browse Source

Merge branch 'master' of http://git.bozedu.net:3000/tongrenlu/jingNing_H5_Mobile

zhuf 1 year ago
parent
commit
ced16f4bbc

BIN
src/assets/index/qjgl.png


BIN
src/assets/index/shgl.png


BIN
src/assets/index/wcgl.png


BIN
src/assets/index/xsewm.png


BIN
src/assets/index/yygl.png


+ 6 - 0
src/main.ts

@@ -2,9 +2,14 @@ import { createApp } from 'vue'
 import { createPinia } from 'pinia'
 import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
 import router from './router/index'
+import { ImagePreview } from 'vant';
 import App from './App.vue'
 import 'vant/es/toast/style'
 import 'vant/es/dialog/style'
+import 'vant/lib/index.css'
+
+
+
 import 'amfe-flexible'
 
 import 'virtual:windi.css'
@@ -19,3 +24,4 @@ pinia.use(piniaPluginPersistedstate)
 app.use(pinia)
 app.use(router)
 app.mount('#app')
+app.use(ImagePreview)

+ 45 - 0
src/pages/administrativeService/leaveManagement/apiItem.js

@@ -0,0 +1,45 @@
+import request from '~/utils/request';
+//列表数据
+export const queryApi = (data = {}) =>
+  request({
+    url: '/xdbg/xzfw_qjgl/index',
+    data
+  });
+// 添加接口
+export const addApi = (data = {}) => request({
+  url: '/xdbg/xzfw_qjgl/add',
+  data: { xdbg_xzfw_qjgl: data }
+});
+//编辑接口
+export const editApi = (chooseId, data = {}) => request({
+  url: '/xdbg/xzfw_qjgl/edit',
+  data: { xxq_id: chooseId, xdbg_xzfw_qjgl: data }
+});
+//详情接口
+export const detailApi = (chooseId) => request({
+  url: '/xdbg/xzfw_qjgl/detail',
+  data: { xxq_id: chooseId }
+});
+//删除接口
+export const deleteApi = (chooseId) => request({
+  url: '/xdbg/xzfw_qjgl/delete',
+  data: { xxq_id: chooseId }
+});
+//搜索接口
+export const searchApi = (keyIn_keyword) => request({
+  url: '/xdbg/xzfw_qjgl/index',
+  data: keyIn_keyword
+})
+
+//通用-科室列表(组织机构use_org)
+export const org_list = (data = {}) =>
+  request({
+    url: '/user/org/index',
+    data
+  });
+//用户列表
+export const org_users = (data) =>
+  request({
+    url: '/user/main/index',
+    data
+  })

+ 313 - 0
src/pages/administrativeService/leaveManagement/index.vue

@@ -0,0 +1,313 @@
+<<<<<<< HEAD
+<template>
+  <div>
+2222
+  </div>
+</template>
+
+<script setup>
+
+</script>
+
+<style lang="scss" scoped>
+
+=======
+<script setup >
+import {ref} from 'vue';
+import {userInfo} from '~/store/user';
+const {uo_type,user_id,uo_id} = userInfo
+import {queryApi,org_users} from './apiItem';
+
+const isBureau = ref(false) // 当前用户是否局端
+isBureau.value = uo_type === '1'
+/***************************请假管理*******************************************/
+
+//外出管理-返回
+const onClickLeft = () => history.back();
+
+const tabActive = ref(0);
+
+const applyType = ref();
+const applyTypeOption = ref([
+  { text: '请假类型', value: '' },
+  { text: '事假', value: 1 },
+  { text: '病假', value: 2 },
+  { text: '婚假', value: 3 },
+  { text: '丧假', value: 4 },
+  { text: '产假', value: 5 },
+  { text: '年休假', value: 6 },
+  { text: '调休', value: 7 },
+  { text: '其他', value: 8 },
+]);
+const applyReason = ref();
+
+
+const tableList = ref([])
+const loading = ref(false)
+const finished = ref(false)
+
+const onLoad = () => {
+  // 异步更新数据
+  // setTimeout 仅做示例,真实场景中一般为 ajax 请求
+  setTimeout(() => {
+    for (let i = 0; i < 10; i++) {
+      list.value.push(list.value.length + 1);
+    }
+
+    // 加载状态结束
+    loading.value = false;
+
+    // 数据全部加载完成
+    if (list.value.length >= 40) {
+      finished.value = true;
+    }
+  }, 1000);
+
+  let transObjs = {
+    page:1
+  }
+  queryApi(transObjs)
+  .then(res => {
+    tableList.value = res.data.page_data;
+    if (tableList.value.length >= res.data.total_rows) {
+      finished.value = true;
+    }
+
+  })
+  .catch(error => {
+    console.log(error)
+  })
+};
+
+const onSubmit = () => {
+  show.value = true;
+}
+
+const show = ref(false);
+
+const value1 = ref('');
+const value2 = ref('');
+const value3 = ref('abc');
+const value4 = ref('');
+const pattern = /\d{6}/;
+
+// 校验函数返回 true 表示校验通过,false 表示不通过
+const validator = (val) => /1\d{10}/.test(val);
+
+// 校验函数可以直接返回一段错误提示
+const validatorMessage = (val) => `${val} 不合法,请重新输入`;
+
+// 校验函数可以返回 Promise,实现异步校验
+const asyncValidator = (val) =>
+  new Promise((resolve) => {
+    showLoadingToast('验证中...');
+
+    setTimeout(() => {
+      closeToast();
+      resolve(val === '1234');
+    }, 1000);
+  });
+
+const onFailed = (errorInfo) => {
+  console.log('failed', errorInfo);
+};
+
+/***************************请假审批*******************************************/
+const applyPerson = ref();
+
+const userLIST = ref([]);
+//获取用户列表
+const getUserList=()=> {
+  let transObjs = {
+    dept_id: uo_id,
+    page: 1,
+    limit: 99999,
+  };
+  org_users(transObjs).then((res) => {
+    if (res.code == 1) {
+      let tempArr = [];
+      res.data.page_data.forEach(item => {
+        tempArr.push({
+          text: item.user_realname,
+          value:item.user_id,
+        })
+      })
+      userLIST.value = tempArr;
+    }
+  });
+}
+getUserList();
+
+
+const handleCheckDialog = (item) => {
+  if (user_id == item.xxq_spr_user_id) {
+    this.dialogCheckVisible = true;
+    this.curCheckId = row.xxq_id;
+  } else {
+    showNotify({ type: 'warning', message: '此条申请,您无法审核~' });
+    return
+  }
+}
+
+
+</script>
+
+<template>
+<div class="leaveMag">
+  <div v-show="isBureau">
+    <div style="width: 100%;text-align: center;"><span style="font-size: 20px;">本功能仅对校端用户开放</span></div>
+  </div>
+  <div class="index" v-show="!isBureau">
+    <van-nav-bar title="请假管理" left-text="返回" left-arrow @click-left="onClickLeft"/>
+
+    <van-tabs v-model:active="tabActive">
+      <van-tab title="请假管理">
+
+        <van-dropdown-menu>
+          <van-dropdown-item v-model="applyType" title="请假类型" :options="applyTypeOption"  @change="dropItemChange" />
+          <van-dropdown-item ref="itemRef2" title="请假事由">
+            <van-cell-group inset>
+              <van-field v-model="applyReason" placeholder="请输入请假事由" />
+            </van-cell-group>
+            <div style="padding: 5px 16px;">
+              <van-button type="primary" block round @click="onConfirm(0)">
+                确认
+              </van-button>
+            </div>
+          </van-dropdown-item>
+        </van-dropdown-menu>
+
+        <van-list v-model:loading="loading" :finished="finished" finished-text="没有更多了" @load="onLoad">
+          <van-cell v-for="(item,index ) in tableList" :key="index" :title="item" >
+            <template #title>
+              <div>申请时间:{{ item.xxq_sqsj }}</div>
+              <div>请假人:{{ item.xxq_qjr }}</div>
+            </template>
+            <template #label>
+              <div>开始时间:{{ item.xxq_kssj }}</div>
+              <div>结束时间:{{ item.xxq_jssj }}</div>
+              <div>请假时长(天):{{ item.xxq_qjsc }}</div>
+              <div>状态:
+                <span :class="item.xxq_zt_option_k == '1' ? 'greenText' : (item.xxq_zt_option_k == '3' ? 'redText' : '')" >{{ item.xxq_zt }}</span>
+              </div>
+            </template>
+
+          </van-cell>
+        </van-list>
+
+        <van-submit-bar  button-text="请假申请" @submit="onSubmit" />
+
+        <van-dialog v-model:show="show" title="请假申请" confirmButtonDisabled="false">
+          <van-form @failed="onFailed">
+            <van-cell-group inset>
+              <!-- 通过 pattern 进行正则校验 -->
+              <van-field
+                v-model="value1"
+                name="申请时间"
+                label="申请时间"
+                placeholder="正则校验"
+                :rules="[{ pattern, message: '请输入正确内容' }]"
+              />
+              <!-- 通过 validator 进行函数校验 -->
+              <van-field
+                v-model="value2"
+                name="请假人:"
+                label="请假人:"
+                placeholder="函数校验"
+                :rules="[{ validator, message: '请输入正确内容' }]"
+              />
+              <!-- 通过 validator 返回错误提示 -->
+              <van-field
+                v-model="value3"
+                name="validatorMessage"
+                placeholder="校验函数返回错误提示"
+                :rules="[{ validator: validatorMessage }]"
+              />
+              <!-- 通过 validator 进行异步函数校验 -->
+              <van-field
+                v-model="value4"
+                name="asyncValidator"
+                placeholder="异步函数校验"
+                :rules="[{ validator: asyncValidator, message: '请输入正确内容' }]"
+              />
+            </van-cell-group>
+            <div style="margin: 16px;">
+              <van-button round block type="primary" native-type="submit">
+                提交
+              </van-button>
+            </div>
+          </van-form>
+
+        </van-dialog>
+
+      </van-tab>
+      <van-tab title="请假审批">
+        <van-dropdown-menu>
+          <van-dropdown-item v-model="applyType" title="请假类型" :options="applyTypeOption"  />
+          <van-dropdown-item v-model="applyPerson" title="申请人" :options="userLIST"  />
+          <van-dropdown-item ref="itemRef2" title="请假事由">
+            <van-cell-group inset>
+              <van-field v-model="applyReason" placeholder="请输入请假事由" />
+            </van-cell-group>
+            <div style="padding: 5px 16px;">
+              <van-button type="primary" block round @click="onConfirm(0)">
+                确认
+              </van-button>
+            </div>
+          </van-dropdown-item>
+        </van-dropdown-menu>
+
+        <van-list v-model:loading="loading" :finished="finished" finished-text="没有更多了" @load="onLoad">
+          <van-cell v-for="(item,index) in tableList" :key="index" :title="item" >
+            <template #title>
+              <div>申请时间:{{ item.xxq_sqsj }}</div>
+              <div>请假人:{{ item.xxq_qjr }}</div>
+            </template>
+            <template #label>
+              <div>开始时间:{{ item.xxq_kssj }}</div>
+              <div>结束时间:{{ item.xxq_jssj }}</div>
+              <div>请假时长(天):{{ item.xxq_qjsc }}</div>
+              <div>请假事由:{{ item.xxq_qjsy }}</div>
+
+            </template>
+
+            <template #right-icon>
+              <van-button type="primary" size="small" @click="handleCheckDialog(item)">审核</van-button>
+            </template>
+          </van-cell>
+        </van-list>
+
+      </van-tab>
+    </van-tabs>
+
+
+
+
+
+
+  </div>
+</div>
+</template>
+
+<style lang="scss" scoped>
+.vant-table-container {
+  width: 100%;
+  padding: 20px;
+  box-sizing: border-box;
+}
+
+.even-row {
+  background-color: #f7f7f7;
+}
+
+.odd-row {
+  background-color: #ffffff;
+}
+.greenText{
+  color: green;
+}
+.redText{
+  color: red;
+}
+>>>>>>> liua
+</style>

+ 45 - 0
src/pages/administrativeService/outManagement/apiItem.js

@@ -0,0 +1,45 @@
+import request from '@/utils/request';
+//列表数据
+export const queryApi = (choosePage, data = {}) =>
+  request({
+    url: '/xdbg/xzfw_wcgl/index',
+    data: { limit: 10, page: choosePage },
+  });
+// 添加接口
+export const addApi = (data = {}) => request({
+  url: '/xdbg/xzfw_wcgl/add',
+  data: { xdbg_xzfw_wcgl: data }
+});
+//编辑接口
+export const editApi = (chooseId, data = {}) => request({
+  url: '/xdbg/xzfw_wcgl/edit',
+  data: { xxw_id: chooseId, xdbg_xzfw_wcgl: data }
+});
+//详情接口
+export const detailApi = (chooseId) => request({
+  url: '/xdbg/xzfw_wcgl/detail',
+  data: { xxw_id: chooseId }
+});
+//删除接口
+export const deleteApi = (chooseId) => request({
+  url: '/xdbg/xzfw_wcgl/delete',
+  data: { xxw_id: chooseId }
+});
+//搜索接口
+export const searchApi = (keyIn_keyword) => request({
+  url: '/xdbg/xzfw_wcgl/index',
+  data: keyIn_keyword
+});
+
+//用户列表
+export const org_users = (data = {}) =>
+  request({
+    url: '/user/main/index',
+    data: {
+      dept_id: data.dept_id,
+      all: '1',
+      page: data.page,
+      limit: data.limit
+
+    }
+  })

+ 46 - 0
src/pages/administrativeService/outManagement/index.vue

@@ -0,0 +1,46 @@
+<<<<<<< HEAD
+<template>
+  <div>
+1111333333
+  </div>
+</template>
+
+<script setup>
+
+</script>
+
+<style lang="scss" scoped>
+
+</style>
+=======
+<script>
+import { ref } from "vue";
+import { userInfo } from "~/store/user";
+const { uo_type } = userInfo;
+import { queryApi } from "./apiItem";
+
+const isBureau = ref(false); // 当前用户是否局端
+isBureau.value = uo_type === "1";
+
+//外出管理-返回
+const onClickLeft = () => history.back();
+
+
+</script>
+
+<template>
+  <div class="outMag">
+    <div v-show="isBureau">
+      <div style="width: 100%; text-align: center">
+        <span style="font-size: 20px">本功能仅对校端用户开放</span>
+      </div>
+    </div>
+    <div class="index" v-show="!isBureau">
+      <van-nav-bar title="外出管理" left-text="返回" left-arrow @click-left="onClickLeft"/>
+
+    </div>
+  </div>
+</template>
+
+<style lang="scss" scoped></style>
+>>>>>>> liua

+ 1 - 1
src/pages/borrowReceive/schoolPropertyList/index.vue

@@ -121,7 +121,7 @@ function dropItemChange() {
         <template #label>
           <div><span>资产分类:{{ item.xhx_zcfl }}</span></div>
           <div style="color: black;">
-            <div><span>{{ `状态:${item.xhx_zt}\u00A0\u00A0\u00A0单价${item.xhx_dj}` }}</span></div>
+            <div><span>{{ `状态:${item.xhx_zt}\u00A0\u00A0\u00A0单价${item.xhx_dj}` }}</span></div>
             <div><span>审批人:{{ item.xhx_spr }}</span></div>
           </div>
         </template>

+ 18 - 0
src/pages/menuData.js

@@ -70,6 +70,8 @@ export const menuList = [
     title: '行政服务',
     list: [
       { icon: getAssetsImages('index/jslswc.png'), menuName: '教师临时外出', path: '/administrativeService/teacherTempGoOut' },
+      { icon: getAssetsImages('index/qjgl.png'), menuName: '请假管理', path: '/administrativeService/leaveManagement' },
+      { icon: getAssetsImages('index/wcgl.png'), menuName: '外出管理', path: '/administrativeService/outManagement' },
     ],
   },
   {
@@ -129,4 +131,20 @@ export const menuList = [
       { icon: getAssetsImages('index/xmlcgl.png'), menuName: '我的调代课', path: '/tdk/wdtdk' },
     ],
   },
+  {
+    tag: 'zyyy',
+    title: '资源预约',
+    list: [
+      { icon: getAssetsImages('index/yygl.png'), menuName: '预约管理', path: '/resourceOrder/orderManager' },
+      { icon: getAssetsImages('index/shgl.png'), menuName: '审核管理', path: '/resourceOrder/auditManager' },
+    ],
+  },
+  {
+    tag: 'wypj',
+    title: '五育评价',
+    list: [
+      { icon: getAssetsImages('index/xsewm.png'), menuName: '学生二维码', path: '/wuYuAppraise/orderManager' },
+
+    ],
+  },
 ]

+ 230 - 0
src/pages/resourceOrder/auditManager/index.vue

@@ -0,0 +1,230 @@
+<script setup>
+import { closeToast, showLoadingToast, showToast } from "vant";
+import { userInfo } from '~/store/user'
+
+const { uo_type } = userInfo
+const isBureau = ref(false)// 当前用户是否局端
+isBureau.value = uo_type === '1'
+const list = ref([])
+const loading = ref(false)
+const finished = ref(false)
+let page = 1
+const param = $ref({
+  keyword: '',
+  xhz_cdmc: '',
+  xhz_ssbm: '',
+  xhz_jyr: '',
+  xhz_pzr: '',
+  xhz_zt: ''
+})
+function onLoad() {
+  loading.value = true
+  request({
+    url: '/xdhq/hqgl_zyyy/index',
+    method: 'post',
+    data: {
+      ...param,
+      page,
+      limit: 20,
+    },
+  }).then((res) => {
+    const data = res.data
+    list.value = [...list.value, ...data.page_data]
+    finished.value = data.total_page === page
+    page++
+    loading.value = false
+  })
+}
+function onClickSearch() {
+  reGetList()
+}
+const itemRef1 = ref(null)
+const itemRef2 = ref(null)
+const itemRef3 = ref(null)
+const itemRef4 = ref(null)
+function onConfirm(num) {
+  let temp = [itemRef1, itemRef2, itemRef3, itemRef4]
+  temp[num].value.toggle()
+  reGetList()
+}
+function reGetList() {
+  page = 1
+  list.value = []
+  finished.value = false
+  onLoad()
+}
+
+const statusOption = $ref([{ text: '状态', value: '' }, { text: '通过', value: '1' }, { text: '未通过', value: '2' }, { text: '待审核', value: '3' }])
+function dropItemChange() {
+  reGetList()
+}
+
+const auditDialogShow = ref(false);
+const auditchecked = ref("");
+const xhz_yy = ref('')
+let operaItem = {}
+
+function audit(item) {
+  operaItem = item
+  auditDialogShow.value = true
+}
+function beforeCloseDialog(action) {
+  if (action == "confirm") {
+    if (auditchecked.value == "") {
+      showToast("请选择审核结果");
+      return false;
+    } else if (auditchecked.value === "2" && xhz_yy.value == "") {
+      showToast("请填写意见");
+      return false;
+    } else {
+      dialogSubmit();
+      return true;
+    }
+  } else {
+    return true;
+  }
+}
+function dialogSubmit() {
+  const transObj = {
+    xhz_id: operaItem.xhz_id,
+    xdhq_hqgl_zyyy: {
+      xhz_zt: auditchecked.value, // 待审核 1通过 2驳回
+      xhz_yy: xhz_yy.value, // 处理意见
+    },
+  };
+  showLoadingToast({
+    message: "提交中...",
+    forbidClick: true,
+  });
+  request({
+    url: "/xdhq/hqgl_zyyy/edit",
+    data: transObj,
+  }).then((res) => {
+    closeToast();
+    if (res.code == 1) {
+      showToast(res.msg);
+      list.value = [];
+      page = 1;
+      onLoad();
+    }
+  });
+}
+</script>
+
+<template>
+  <div v-show="isBureau">
+    <div style="width: 100%;text-align: center;"><span style="font-size: 20px;">本功能仅对校端用户开放</span></div>
+  </div>
+  <div class="index" v-show="!isBureau">
+    <van-search v-model="param.keyword" :clearable="false" show-action placeholder="请输入搜索关键词" @search="onClickSearch">
+      <template #action>
+        <div @click="onClickSearch">
+          搜索
+        </div>
+      </template>
+    </van-search>
+    <van-dropdown-menu>
+      <van-dropdown-item ref="itemRef1" title="场地名称">
+        <van-cell-group inset>
+          <van-field v-model="param.xhz_cdmc" placeholder="请输入场地名称" />
+        </van-cell-group>
+        <div style="padding: 5px 16px;">
+          <van-button type="primary" block round @click="onConfirm(0)">
+            确认
+          </van-button>
+        </div>
+      </van-dropdown-item>
+
+      <van-dropdown-item ref="itemRef2" title="所属部门">
+        <van-cell-group inset>
+          <van-field v-model="param.xhz_ssbm" placeholder="请输入所属部门" />
+        </van-cell-group>
+        <div style="padding: 5px 16px;">
+          <van-button type="primary" block round @click="onConfirm(1)">
+            确认
+          </van-button>
+        </div>
+      </van-dropdown-item>
+      <van-dropdown-item ref="itemRef3" title="借用人">
+        <van-cell-group inset>
+          <van-field v-model="param.xhz_jyr" placeholder="请输入借用人" />
+        </van-cell-group>
+        <div style="padding: 5px 16px;">
+          <van-button type="primary" block round @click="onConfirm(2)">
+            确认
+          </van-button>
+        </div>
+      </van-dropdown-item>
+      <van-dropdown-item ref="itemRef4" title="批准人">
+        <van-cell-group inset>
+          <van-field v-model="param.xhz_pzr" placeholder="请输入批准人" />
+        </van-cell-group>
+        <div style="padding: 5px 16px;">
+          <van-button type="primary" block round @click="onConfirm(3)">
+            确认
+          </van-button>
+        </div>
+      </van-dropdown-item>
+      <van-dropdown-item v-model="param.xhz_zt" :options="statusOption" @change="dropItemChange" />
+
+    </van-dropdown-menu>
+    <van-list v-model:loading="loading" :finished="finished" finished-text="没有更多了" @load="onLoad">
+      <van-cell v-for="item in list" :key="item">
+        <template #title>
+          <span>{{ `${item.xhz_cdmc}` }}</span>
+        </template>
+        <template #value>
+          <div>
+            <van-button class="w-60px" type="primary" size="small" @click="audit(item)"
+              v-show="item.xhz_zt_option_k == 3">审核</van-button>
+          </div>
+        </template>
+        <template #label>
+          <div><span>{{ `所属部门:${item.xhz_ssbm}\u00A0\u00A0\u00A0状态:${item.xhz_zt}` }}</span></div>
+          <div style="color: black;">
+            <div><span>{{ `借用人:${item.xhz_jyr}\u00A0\u00A0\u00A0批准人:${item.xhz_pzr}` }}</span>
+            </div>
+            <div><span>借用时间:{{ item.xhz_jysj_ks + '至' + item.xhz_jysj_js }}</span></div>
+          </div>
+        </template>
+      </van-cell>
+    </van-list>
+
+    <van-dialog v-model:show="auditDialogShow" title="审核" confirm-button-text="提交" show-cancel-button
+      :before-close="beforeCloseDialog">
+      <div class="dialogDiv">
+        <van-radio-group v-model="auditchecked">
+          <van-cell-group inset>
+            <van-cell title="通过" clickable @click="auditchecked = '1'">
+              <template #right-icon>
+                <van-radio name="1" />
+              </template>
+            </van-cell>
+            <van-cell title="不通过" clickable @click="auditchecked = '2'">
+              <template #right-icon>
+                <van-radio name="2" />
+              </template>
+            </van-cell>
+          </van-cell-group>
+        </van-radio-group>
+        <van-field v-if="auditchecked === '2'" v-model="xhz_yy" rows="3" autosize type="textarea" placeholder="填写原因" />
+      </div>
+    </van-dialog>
+  </div>
+</template>
+
+<style lang="scss" scoped>
+:deep(.van-cell__title) {
+  width: 70% !important;
+  flex: auto
+}
+
+:deep(.van-cell__value) {
+  width: 30% !important;
+  flex: auto
+}
+
+:deep(.van-ellipsis) {
+  font-size: 14px !important;
+}
+</style>

+ 175 - 0
src/pages/resourceOrder/orderManager/index.vue

@@ -0,0 +1,175 @@
+<script setup>
+import { userInfo } from '~/store/user'
+import { showImagePreview } from 'vant';
+
+const { uo_type } = userInfo
+const isBureau = ref(false)// 当前用户是否局端
+isBureau.value = uo_type === '1'
+const list = ref([])
+const loading = ref(false)
+const finished = ref(false)
+let page = 1
+const param = $ref({
+  keyword: '',
+  xhzz_cdbh: '',
+  xhzz_cdmc: '',
+  xhzl_flbm: '',
+  xhzz_fzr: ''
+})
+function onLoad() {
+  loading.value = true
+  request({
+    url: '/xdhq/hqgl_zyyyzy/index',
+    method: 'post',
+    data: {
+      ...param,
+      page,
+      limit: 20,
+    },
+  }).then((res) => {
+    const data = res.data
+    list.value = [...list.value, ...data.page_data]
+    finished.value = data.total_page === page
+    page++
+    loading.value = false
+  })
+}
+function onClickSearch() {
+  reGetList()
+}
+const itemRef1 = ref(null)
+const itemRef2 = ref(null)
+const itemRef3 = ref(null)
+const itemRef4 = ref(null)
+function onConfirm(num) {
+  let temp = [itemRef1, itemRef2, itemRef3, itemRef4]
+  temp[num].value.toggle()
+  reGetList()
+}
+function reGetList() {
+  page = 1
+  list.value = []
+  finished.value = false
+  onLoad()
+}
+const router = useRouter()
+function order(item) {
+  router.push({
+    path: "/resourceOrder/orderManager/orderFrom",
+    query: { xhzz_id: item.xhzz_id },
+  });
+}
+const placeCategoryOption = $ref([{ text: '场地类别', value: '' }])
+request({
+  url: '/xdhq/hqgl_zyyylb/index', data: {
+    page: 1,
+    limit: 9999
+  }
+}).then(res => {
+  for (let item of res.data.page_data) {
+    placeCategoryOption.push({ text: item.xhzl_flmc, value: item.xhzl_flbm })
+  }
+})
+function dropItemChange() {
+  reGetList()
+}
+
+
+function getFullUrl(url) {
+  if (!url)
+    return ''
+  if (url.includes('60.188.226.44:8090')) {
+    url = url.replace('60.188.226.44:8090', 'jnjymf.bozedu.net')
+  }
+  return url.startsWith('http') ? url : `http://jnjymf.bozedu.net/${url}`
+}
+
+function previewImg(url) {
+  showImagePreview([url]);
+}
+</script>
+
+<template>
+  <div v-show="isBureau">
+    <div style="width: 100%;text-align: center;"><span style="font-size: 20px;">本功能仅对校端用户开放</span></div>
+  </div>
+  <div class="index" v-show="!isBureau">
+    <van-search v-model="param.keyword" :clearable="false" show-action placeholder="请输入搜索关键词" @search="onClickSearch">
+      <template #action>
+        <div @click="onClickSearch">
+          搜索
+        </div>
+      </template>
+    </van-search>
+    <van-dropdown-menu>
+      <van-dropdown-item ref="itemRef1" title="场地编号">
+        <van-cell-group inset>
+          <van-field v-model="param.xhzz_cdbh" placeholder="请输入场地编号" />
+        </van-cell-group>
+        <div style="padding: 5px 16px;">
+          <van-button type="primary" block round @click="onConfirm(0)">
+            确认
+          </van-button>
+        </div>
+      </van-dropdown-item>
+
+      <van-dropdown-item ref="itemRef3" title="场地名称">
+        <van-cell-group inset>
+          <van-field v-model="param.xhzz_cdmc" placeholder="请输入场地名称" />
+        </van-cell-group>
+        <div style="padding: 5px 16px;">
+          <van-button type="primary" block round @click="onConfirm(2)">
+            确认
+          </van-button>
+        </div>
+      </van-dropdown-item>
+      <van-dropdown-item v-model="param.xhzl_flbm" :options="placeCategoryOption" @change="dropItemChange" />
+      <van-dropdown-item ref="itemRef4" title="负责人">
+        <van-cell-group inset>
+          <van-field v-model="param.xhzz_fzr" placeholder="请输入负责人" />
+        </van-cell-group>
+        <div style="padding: 5px 16px;">
+          <van-button type="primary" block round @click="onConfirm(3)">
+            确认
+          </van-button>
+        </div>
+      </van-dropdown-item>
+    </van-dropdown-menu>
+    <van-list v-model:loading="loading" :finished="finished" finished-text="没有更多了" @load="onLoad">
+      <van-cell v-for="item in list" :key="item">
+        <template #title>
+          <span>{{ `${item.xhzz_cdmc}\u00A0\u00A0\u00A0 ${item.xhzz_cdbh}` }}</span>
+        </template>
+        <template #value>
+          <div>
+            <div>
+              <van-button class="w-60px" type="primary" size="small" @click="order(item)">预约</van-button>
+            </div>
+            <div style="margin-top: 10px;">
+              <img :src="getFullUrl(item.xhzz_tp)" @click="previewImg(getFullUrl(item.xhzz_tp))" />
+            </div>
+          </div>
+        </template>
+        <template #label>
+          <div><span>{{ `场地类别:${item.xhzl_flmc}` }}</span></div>
+          <div style="color: black;">
+            <div><span>{{ `占地面积:${item.xhzz_zdmj}\u00A0\u00A0\u00A0所属校区:${item.xhzz_ssxq}` }}</span></div>
+            <div><span>地址:{{ item.xhzz_dz }}</span></div>
+          </div>
+        </template>
+      </van-cell>
+    </van-list>
+  </div>
+</template>
+
+<style lang="scss" scoped>
+:deep(.van-cell__title) {
+  width: 70% !important;
+  flex: auto
+}
+
+:deep(.van-cell__value) {
+  width: 30% !important;
+  flex: auto
+}
+</style>

+ 56 - 0
src/pages/resourceOrder/orderManager/orderFrom/dateTImePicker.vue

@@ -0,0 +1,56 @@
+<script setup>
+
+const props = defineProps({
+  label: {
+    type: String,
+    default: '',
+  },
+})
+
+defineExpose({
+  getResult
+})
+function getResult() {
+  return result
+}
+let result = $ref('')
+let showDatePicker = $ref(false)
+let showTimePicker = $ref(false)
+
+const onDateConfirm = ({ selectedValues }) => {
+  result = selectedValues.join('/');
+  showDatePicker = false;
+  showTimePicker = true
+};
+const onTimeConfirm = ({ selectedValues }) => {
+  result = result + ' ' + selectedValues.join(':');
+  showTimePicker = false;
+};
+
+let oldResult = ''
+const clickPop = () => {
+  oldResult = result
+  showDatePicker = true
+}
+const clickCancel = () => {
+  result = oldResult
+  showDatePicker = false
+  showTimePicker = false
+
+}
+const currentTime = ref(['12', '00', '00']);
+const columnsType = ['hour', 'minute', 'second'];
+
+const minDate = new Date(2020, 0, 1)
+</script>
+<template>
+  <van-field v-model="result" is-link readonly name="datePicker" :label='props.label' placeholder="点击选择时间"
+    @click="clickPop" :rules="[{ required: true, message: '请选择时间' }]" />
+  <van-popup v-model:show="showDatePicker" position="bottom">
+    <van-date-picker :min-date="minDate" @confirm="onDateConfirm" @cancel="clickCancel" />
+  </van-popup>
+  <van-popup v-model:show="showTimePicker" position="bottom">
+    <van-time-picker @confirm="onTimeConfirm" @cancel="clickCancel" v-model="currentTime" title="选择时间"
+      :columns-type="columnsType" />
+  </van-popup>
+</template>

+ 83 - 0
src/pages/resourceOrder/orderManager/orderFrom/index.vue

@@ -0,0 +1,83 @@
+<script setup>
+import { userInfo } from "~/store/user";
+import { showFailToast, showToast } from 'vant'
+import dateTimePicker from './dateTImePicker.vue'
+
+const { uo_type } = userInfo;
+const isBureau = ref(false); // 当前用户是否局端
+isBureau.value = uo_type === "1";
+
+const router = useRouter()
+
+let transParams = $ref({
+  xhzz_cdbh: '',
+  xhz_cdmc: '',
+  xhz_ssbm: '',
+  xhz_jyr: '',
+  xhz_pzr: '',
+  xhz_jysj_ks: '',
+  xhz_jysj_js: '',
+  xhz_yt: ''
+})
+const jysj_stratRef = $ref()
+const jysj_endRef = $ref()
+const onSubmit = () => {
+  transParams.xhz_jysj_ks = jysj_stratRef.getResult()
+  transParams.xhz_jysj_js = jysj_endRef.getResult()
+  request({ url: '/xdhq/hqgl_zyyy/add', data: { xdhq_hqgl_zyyy: transParams } }).then(res => {
+    if (res.code == '1') {
+      showToast('预约成功等待审核');
+      router.go(-1)
+    } else {
+      showFailToast(res.msg);
+    }
+  })
+};
+const cancel = () => {
+  router.go(-1)
+}
+
+const { currentRoute } = useRouter()
+request({
+  url: '/xdhq/hqgl_zyyyzy/detail',
+  data: {
+    xhzz_id: currentRoute.value.query.xhzz_id,
+  }
+}).then(res => {
+  if (res.code == 1) {
+    transParams.xhzz_cdbh = res.data.one_info.xhzz_cdbh
+    transParams.xhz_cdmc = res.data.one_info.xhzz_cdmc
+  }
+})
+</script>
+<template>
+  <div v-show="isBureau">
+    <div style="width: 100%;text-align: center;"><span style="font-size: 20px;">本功能仅对校端用户开放</span></div>
+  </div>
+  <div v-show="!isBureau">
+    <van-form @submit="onSubmit">
+      <van-cell-group inset>
+        <van-field v-model="transParams.xhzz_cdbh" readonly name="场地编号" label="场地编号" placeholder="请输入场地编号" />
+        <van-field v-model="transParams.xhz_cdmc" readonly name="场地名称" label="场地名称" placeholder="请输入场地名称" />
+        <van-field v-model="transParams.xhz_ssbm" name="所属部门" label="所属部门" placeholder="请输入所属部门"
+          :rules="[{ required: true, message: '请输入所属部门' }]" />
+        <van-field v-model="transParams.xhz_jyr" name="借用人" label="借用人" placeholder="请输入借用人"
+          :rules="[{ required: true, message: '请输入借用人' }]" />
+        <van-field v-model="transParams.xhz_pzr" name="批准人" label="批准人" placeholder="请输入批准人"
+          :rules="[{ required: true, message: '请输入批准人' }]" />
+        <dateTimePicker ref="jysj_stratRef" label="借用时间_开始" />
+        <dateTimePicker ref="jysj_endRef" label="借用时间_结束" />
+        <van-field v-model="transParams.xhz_yt" name="用途" label="用途" placeholder="请输入用途"
+          :rules="[{ required: true, message: '请输入用途' }]" />
+      </van-cell-group>
+      <div style="margin: 16px;">
+        <van-button round block type="primary" native-type="submit">
+          提交
+        </van-button>
+        <van-button style="margin-top: 10px;" round block type="default" @click="cancel()">
+          取消
+        </van-button>
+      </div>
+    </van-form>
+  </div>
+</template>

+ 6 - 0
src/pages/wuYuAppraise/studentQR/index.vue

@@ -0,0 +1,6 @@
+<script setup>
+
+</script>
+<template>
+  123
+</template>

+ 28 - 13
src/store/produ/la.js

@@ -7,16 +7,16 @@ export default {
   "user_role_id": "7",
   "user_level_id": "1",
   "user_detail_id": "0",
-  "user_score": "2",
+  "user_score": "134",
   "create_dateline": "1658113811",
-  "modify_dateline": "1681286358",
+  "modify_dateline": "1692696847",
   "isdelete": "0",
   "area_id1": "0",
   "area_id2": "0",
   "area_id3": "0",
   "area_id4": "0",
-  "dept_id": "1037",
-  "dept_id_all": "1037",
+  "dept_id": "333",
+  "dept_id_all": "333",
   "class_id": null,
   "user_phone": "",
   "user_cardno": "",
@@ -55,7 +55,8 @@ export default {
   "wx_last_token": null,
   "wx_last_login": null,
   "wx_graduation": "0",
-  "token": "8acfOcfYEQGEoGEb3Tti7FSyiHWU0G9Bc_aqye6XvHRiJjsiwLemLLvh9eDTujtxSYSkVG4jJ_ab52LY6XtFg_aVAuPZGadey7jD0vqIHl_ap26t",
+  "power_set": null,
+  "token": "f2c13s93wtxoJJ8lVACuzIcuCnZSYa909r8bxoz4FACGWgAUwT4bSejSiPJkPSCzzqXv8iNFasvHeFQLexjs6veDo70Vapy00YWN2EHJBvU",
   "setting": {
       "sitename": "景宁教育魔方",
       "sitedomain": "http://60.188.226.44:8090/",
@@ -73,18 +74,32 @@ export default {
           "uo_type": "1"
       },
       {
-          "uo_id": "1037",
-          "uo_name": "钉钉部署",
-          "uo_master_username": "6360ae01f70a665a9821efbe",
+          "uo_id": "1036",
+          "uo_name": "学校人员组织",
+          "uo_master_username": "",
           "uo_type": "1"
+      },
+      {
+          "uo_id": "1045",
+          "uo_name": "小学",
+          "uo_master_username": "",
+          "uo_type": "1"
+      },
+      {
+          "uo_id": "333",
+          "uo_name": "景宁畲族自治县红星小学",
+          "uo_master_username": "6360ae4ef70a665a9821efc3",
+          "uo_type": "2"
       }
   ],
-  "uo_id": "1037",
-  "uo_type": "1",
-  "uo_name": "钉钉部署",
+  "uo_id": "333",
+  "uo_type": "2",
+  "uo_name": "景宁畲族自治县红星小学",
   "dept_ids": [
       "323",
-      "1037"
+      "1036",
+      "1045",
+      "333"
   ],
   "dept_master": []
-}
+}

+ 5 - 5
src/store/user.js

@@ -1,11 +1,11 @@
 import { defineStore } from 'pinia'
 
-// import produ from './produ/lwj'
+import produ from './produ/la'
 
-// localStorage.setItem(
-//   'userInfo',
-//   JSON.stringify(produ),
-// )
+localStorage.setItem(
+  'userInfo',
+  JSON.stringify(produ),
+)
 
 // const RoleMap = {
 //   JLD: [1, 2, 3],

+ 170 - 0
src/utils/request.js

@@ -0,0 +1,170 @@
+import axios from 'axios'
+import { showNotify  } from 'vant'
+
+import { userInfo } from '~/store/user'
+const { token } = userInfo
+
+const service = axios.create({
+  baseURL: window.globalVariables.api,
+  method: 'post',
+  timeout: 60000,
+  headers: {
+    'Content-Type': 'application/x-www-form-urlencoded',
+  },
+})
+
+service.interceptors.request.use(
+  (config) => {
+    // do something before request is sent
+
+    config.data = Object.assign(
+      {
+        token,
+        site: 'jnmf',
+        client: 'web',
+        api: 'json',
+        // from: 'backend',
+        issubmit: (config.url.endsWith('add') || config.url.endsWith('edit')) ? 1 : undefined
+      },
+      config.data || {}
+    )
+    if (config.method === 'get') {
+      config.params = Object.assign(
+        {
+          token,
+        },
+        config.params || {}
+      )
+    }
+    // 短时间多个请求会冲突
+    // console.groupCollapsed('axios: ' + config.url)
+    // console.log('request', config.data)
+    return config
+  },
+  (error) => {
+    // do something with request error
+    console.log(error) // for debug
+    return Promise.reject(error)
+  }
+)
+
+// response interceptor
+let isRelogin = false
+service.interceptors.response.use(
+  (response, c) => {
+    const { code, msg, data } = response.data
+    if (code === '10001') {
+      if (!isRelogin) {
+        isRelogin = true
+        showNotify({
+          type: 'warning',
+          message: msg
+        })
+        request({
+          url: '/user/main/login',
+          data: {
+            token: data.token
+          }
+        }).then(res => {
+          if (res.code == 1) {
+            localStorage.setItem('userInfo', JSON.stringify(res.data));
+            isRelogin = false
+            // 视情况打开
+            location.reload()
+          }
+        })
+      }
+
+    } else if (code != '1') {
+      // Message.error({ message: msg, dangerouslyUseHTMLString: true })
+      showNotify({
+        type: 'warning',
+        message: msg
+      })
+    }
+    // console.log('response', response.data)
+    // console.groupEnd()
+    return response.data
+  },
+  (error) => {
+    console.error('err' + error) // for debug
+    return Promise.reject(error)
+  }
+)
+
+// 上传
+export const request = axios.create({
+  baseURL: window.globalVariables.api,
+  method: 'post',
+  timeout: 5000,
+  headers: {
+    'Content-Type': 'application/x-www-form-urlencoded',
+  },
+})
+request.interceptors.response.use(
+  (response) => {
+    const { code, msg } = response.data
+    if (code !== '1') {
+      showNotify({
+        type: 'warning',
+        message: msg
+      })
+    }
+    return response.data
+  },
+  (error) => {
+    console.log('err' + error) // for debug
+    return Promise.reject(error)
+  }
+)
+
+export function download(url, data, name) {
+  const params = Object.assign({ token, limit: 10000, page: 1, api: 'xls' }, data)
+  const paramsStr = Object.entries(params).map(([k, v]) => `${k}=${v}`).join('&')
+  const el = document.createElement('a')
+  const href = `${window.globalVariables.api}${url}?${paramsStr}`
+  el.setAttribute('href', href)
+  name && el.setAttribute('download', name)
+  el.click()
+}
+
+export function download2(url, data, name) {
+  const el = document.createElement('a')
+  // const href = `${window.globalVariables.api}/openapi/download.php?path=${url}&name=${name}`
+  const ext = url.split('.').pop()
+  const filename = name.endsWith(`.${ext}`) ? name : `${name}.${ext}`
+  const href = `${window.globalVariables.oss}/${url}/${filename}`
+  el.setAttribute('href', href)
+  name && el.setAttribute('download', name)
+  console.log('download2:', href)
+  el.click()
+}
+
+export function download3(url, data, name) {
+  const el = document.createElement('a')
+  const href = `${url}/${name}`
+  el.setAttribute('href', href)
+  name && el.setAttribute('download', name)
+  el.click()
+}
+
+const obj2form = (data) => {
+  const formData = new FormData()
+  Object.keys(data).forEach(key => formData.append(key, data[key]))
+  return formData;
+}
+export default (...args) => {
+  console.log('args :>> ', args);
+  if (!isRelogin) {
+    const c = args[0]
+    if (c.$type === 'import')
+      return service(Object.assign({ ...c }, {
+        timeout: 10 * 60 * 1000,
+        transformRequest: [obj2form],
+      }))
+    return service(...args)
+  }
+  else
+    return Promise.reject({})
+}
+