Commit f57ca13a by zhaopanyu

公文流转修改 1.5

parent 09b589fb
...@@ -58,7 +58,7 @@ export function loginOut() { ...@@ -58,7 +58,7 @@ export function loginOut() {
}); });
} }
export function getgetToken(id) { export function getgetToken(id) {
let result = axios.get("/wx/user/getToken") let result = axios.get("/wx/user/getToken");
return result; return result;
} }
...@@ -89,7 +89,7 @@ export function getjudgePermission() { ...@@ -89,7 +89,7 @@ export function getjudgePermission() {
export function getAttendanceList() { export function getAttendanceList() {
return axios.get( return axios.get(
"/school/studentAttendance/getAttendanceList?studentId=" + "/school/studentAttendance/getAttendanceList?studentId=" +
store.state.studentId store.state.studentId
); );
} }
...@@ -102,13 +102,13 @@ export function getCalendar(params) { ...@@ -102,13 +102,13 @@ export function getCalendar(params) {
export function getCalendardate(params) { export function getCalendardate(params) {
return axios.get( return axios.get(
"/wx/calendar/getCalendar/" + "/wx/calendar/getCalendar/" +
params.calendarId + params.calendarId +
"?date=" + "?date=" +
params.date + params.date +
"&pageSize=" + "&pageSize=" +
params.pageSize + params.pageSize +
"&pageNum=" + "&pageNum=" +
params.pageNum params.pageNum
); );
} }
...@@ -116,11 +116,11 @@ export function getCalendardate(params) { ...@@ -116,11 +116,11 @@ export function getCalendardate(params) {
export function getCalendarmoth(params) { export function getCalendarmoth(params) {
return axios.get( return axios.get(
"/wx/calendar/getMonth/" + "/wx/calendar/getMonth/" +
store.state.CalendarId + store.state.CalendarId +
"?start=" + "?start=" +
params.start + params.start +
"&end=" + "&end=" +
params.end params.end
); );
} }
...@@ -133,12 +133,12 @@ export function getResoucelist() { ...@@ -133,12 +133,12 @@ export function getResoucelist() {
export function getresourceDetails(params) { export function getresourceDetails(params) {
return axios.get( return axios.get(
"/wx/schoolResource/getResouceDetails/" + "/wx/schoolResource/getResouceDetails/" +
params.resourceId + params.resourceId +
"?pageSize=" + "?pageSize=" +
params.pageSize + params.pageSize +
"&pageNum=" + "&pageNum=" +
params.pageNum + params.pageNum +
(params.name ? "&name=" + params.name : "") (params.name ? "&name=" + params.name : "")
); );
} }
...@@ -158,11 +158,11 @@ export function getResouceupdateAll(resourceId, updateAll) { ...@@ -158,11 +158,11 @@ export function getResouceupdateAll(resourceId, updateAll) {
export function getResoucelistinfocommentList(params) { export function getResoucelistinfocommentList(params) {
return axios.get( return axios.get(
"/wx/schoolResource/commentList/" + "/wx/schoolResource/commentList/" +
params.detailsId + params.detailsId +
"?pageSize=" + "?pageSize=" +
params.pageSize + params.pageSize +
"&pageNum=" + "&pageNum=" +
params.pageNum, params.pageNum,
{ {
params: { params: {
studentId: store.state.studentId, studentId: store.state.studentId,
...@@ -195,9 +195,9 @@ export function getChildExam(params) { ...@@ -195,9 +195,9 @@ export function getChildExam(params) {
export function getStudentScore(examId) { export function getStudentScore(examId) {
return axios.get( return axios.get(
"/wx/schoolExam/getscore?studentId=" + "/wx/schoolExam/getscore?studentId=" +
store.state.studentId + store.state.studentId +
"&examId=" + "&examId=" +
examId examId
); );
} }
...@@ -205,13 +205,13 @@ export function getStudentScore(examId) { ...@@ -205,13 +205,13 @@ export function getStudentScore(examId) {
export function getChildExamtec(params) { export function getChildExamtec(params) {
return axios.get( return axios.get(
"/wx/schoolExam/list/" + "/wx/schoolExam/list/" +
params.gradeId + params.gradeId +
"?pageSize=" + "?pageSize=" +
params.pageSize + params.pageSize +
"&pageNum=" + "&pageNum=" +
params.pageNum + params.pageNum +
"&examName=" + "&examName=" +
params.examName params.examName
); );
} }
...@@ -301,7 +301,10 @@ export function messageinfoteac(id) { ...@@ -301,7 +301,10 @@ export function messageinfoteac(id) {
//消息读取 //消息读取
export function changeStatus(id) { export function changeStatus(id) {
let url = store.state.userLoginType == 1 ? "/wx/parentMessage/changeStatus/" : "/wx/message/changeStatus/" let url =
store.state.userLoginType == 1
? "/wx/parentMessage/changeStatus/"
: "/wx/message/changeStatus/";
let result = axios.put(url + id + "?status=1"); let result = axios.put(url + id + "?status=1");
return result; return result;
} }
...@@ -310,12 +313,12 @@ export function changeStatus(id) { ...@@ -310,12 +313,12 @@ export function changeStatus(id) {
export function getparentPushList(params) { export function getparentPushList(params) {
let result = axios.get( let result = axios.get(
"/wx/parentMessage/parentPushList/" + "/wx/parentMessage/parentPushList/" +
store.state.userInfo.userId + store.state.userInfo.userId +
"?" + "?" +
"pageSize=" + "pageSize=" +
params.pageSize + params.pageSize +
"&pageNum=" + "&pageNum=" +
params.pageNum params.pageNum
); );
return result; return result;
} }
...@@ -325,12 +328,12 @@ export function getteacherPushList(params) { ...@@ -325,12 +328,12 @@ export function getteacherPushList(params) {
console.log("我是老师"); console.log("我是老师");
let result = axios.get( let result = axios.get(
"/wx/message/teacherPushList/" + "/wx/message/teacherPushList/" +
store.state.userInfo.userId + store.state.userInfo.userId +
"?" + "?" +
"pageSize=" + "pageSize=" +
params.pageSize + params.pageSize +
"&pageNum=" + "&pageNum=" +
params.pageNum params.pageNum
); );
return result; return result;
} }
...@@ -455,8 +458,8 @@ export function getMemberByGradeId(params) { ...@@ -455,8 +458,8 @@ export function getMemberByGradeId(params) {
"?pageSize=" + params.pageSize + "&pageNum=" + params.pageNum + studentName "?pageSize=" + params.pageSize + "&pageNum=" + params.pageNum + studentName
? +"&studentName=" + params.studentName ? +"&studentName=" + params.studentName
: "" + gradeId == 0 : "" + gradeId == 0
? "" ? ""
: "&gradeId=" + params.gradeId; : "&gradeId=" + params.gradeId;
// let url = // let url =
// "/wx/schoolGrade/getMemberByGradeId" + // "/wx/schoolGrade/getMemberByGradeId" +
// params.gradeId==0? "+ // params.gradeId==0? "+
...@@ -634,14 +637,14 @@ export function cancelLeave(taskId, params) { ...@@ -634,14 +637,14 @@ export function cancelLeave(taskId, params) {
}); });
} }
//根据用户找到所在的组织 //根据用户找到所在的组织
export function getUserDept(userId){ export function getUserDept(userId) {
return axios({ return axios({
url: "/wx/teacherLeave/getUserDept/" + userId, url: "/wx/teacherLeave/getUserDept/" + userId,
method: "get", method: "get",
}); });
} }
//根据部门和部门id 获取当前机构的 科室主任 处室主任 //根据部门和部门id 获取当前机构的 科室主任 处室主任
export function getDeptGrapRole(deptName,deptId){ export function getDeptGrapRole(deptName, deptId) {
return axios({ return axios({
url: `/wx/teacherLeave/getDeptGrapRole?deptName=${deptName}&deptId=${deptId}`, url: `/wx/teacherLeave/getDeptGrapRole?deptName=${deptName}&deptId=${deptId}`,
method: "get", method: "get",
...@@ -1101,7 +1104,7 @@ export function getpersonalListinfo(id) { ...@@ -1101,7 +1104,7 @@ export function getpersonalListinfo(id) {
}); });
} }
//请假时间 //请假时间
export function getTotalTime(query,type) { export function getTotalTime(query, type) {
return axios({ return axios({
url: `/wx/teacherLeave/getTotalTime/${store.state.userInfo.userId}/${type}`, url: `/wx/teacherLeave/getTotalTime/${store.state.userInfo.userId}/${type}`,
method: "get", method: "get",
...@@ -1264,11 +1267,7 @@ export function postStudentLeave(params) { ...@@ -1264,11 +1267,7 @@ export function postStudentLeave(params) {
} }
export function postStudentLeavecancel(params) { export function postStudentLeavecancel(params) {
return axios({ return axios({
url: url: "/wx/studentLeave/cancel/" + params.taskId + "/" + params.instanceId,
"/wx/studentLeave/cancel/" +
params.taskId +
"/" +
params.instanceId,
method: "post", method: "post",
data: params.schoolStudentLeave, data: params.schoolStudentLeave,
}); });
...@@ -1319,7 +1318,7 @@ export function uploadfileImg(query) { ...@@ -1319,7 +1318,7 @@ export function uploadfileImg(query) {
}); });
} }
export function postexam(query, id, iscm) { export function postexam(query, id, iscm) {
let url = iscm ? "/wx/schoolDcwj/edit/" + id : "/wx/schoolDcwj/commit/" + id let url = iscm ? "/wx/schoolDcwj/edit/" + id : "/wx/schoolDcwj/commit/" + id;
return axios({ return axios({
url: url, url: url,
method: "POST", method: "POST",
...@@ -1345,18 +1344,18 @@ export function getschoolXxfbdetail(query) { ...@@ -1345,18 +1344,18 @@ export function getschoolXxfbdetail(query) {
}); });
} }
export function postfz(id, query) { export function postfz(id, query) {
let url = "/wx/schoolXxfb/commit/" + id let url = "/wx/schoolXxfb/commit/" + id;
return axios({ return axios({
url: url, url: url,
method: "POST", method: "POST",
params: { ...query } params: { ...query },
}); });
} }
/** /**
* 信息采集 * 信息采集
*/ */
export function getmatch(query) { export function getmatch(query) {
let url = "/wx/schoolInfo/match" let url = "/wx/schoolInfo/match";
return axios({ return axios({
url: url, url: url,
method: "get", method: "get",
...@@ -1364,16 +1363,15 @@ export function getmatch(query) { ...@@ -1364,16 +1363,15 @@ export function getmatch(query) {
}); });
} }
export function postmaintain(query) { export function postmaintain(query) {
let url = "/wx/schoolInfo/maintain" let url = "/wx/schoolInfo/maintain";
return axios({ return axios({
url: url, url: url,
method: "PUT", method: "PUT",
data: query data: query,
}); });
} }
export function getAcquisitionList(query) { export function getAcquisitionList(query) {
let url = "/wx/schoolInfo/getAcquisitionList/" + query let url = "/wx/schoolInfo/getAcquisitionList/" + query;
return axios({ return axios({
url: url, url: url,
method: "get", method: "get",
...@@ -1389,3 +1387,62 @@ export function getTotalDay(query) { ...@@ -1389,3 +1387,62 @@ export function getTotalDay(query) {
params: query, params: query,
}); });
} }
// 查询我的任务
//我的任务
export function mytaskList(userId) {
return axios.get("/wx/officialflow/taskList/" + userId);
}
// 详情页
export function lookList(id) {
let url = "/wx/officialflow/review/getInfo/" + id;
return axios({
url: url,
method: "get",
params: id,
});
}
// 批阅人操作
export function offiCialflow(query) {
let url = "/wx/officialflow/review/" + query.id; // 在路径和查询参数之间加上 ?
return axios({
url: url,
method: "put",
data: query,
});
}
// 发起人操作
export function offiCialflowfq(query) {
let url = "/wx/officialflow/initiator";
return axios({
url: url,
method: "put",
data: query,
});
}
// 传阅人操作
export function offiCialflowcy(query) {
let url = "/wx/officialflow/circulator/" + query.id;
return axios({
url: url,
method: "put",
data: query,
});
}
//批阅人下拉框
export function getSchoolLeader(query) {
return axios({
url: "/wx/officialflow/getSchoolLeader",
method: "get",
params: query,
});
}
//传阅人
export function getTeacherList(query) {
return axios({
url: "/wx/officialflow/getTeacherList",
method: "get",
params: query,
});
}
<template>
<van-nav-bar title="传阅" left-text="返回" left-arrow @click-left="goback" />
<div style="margin: 0.1rem;font-weight: 700;">
<span style="margin-left: 10px; font-size: 18px;font-family: PingFang SC;background-color: #faf9f9;">公文信息</span>
<table style="border: 1px solid #e5ecf4;">
<tr style="border: 1px solid #e5ecf4;">
<td class="td-width"
style=" font-size: 15px;border: 1px solid #e5ecf4;width: 25%;background-color: #faf9f9;">发文字号</td>
<td style=" font-size: 15px;border: 1px solid #e5ecf4; " :colspan="3">{{ list && list.issuedNum ?
list.issuedNum : '' }}</td>
</tr>
<tr style="border: 1px solid #e5ecf4;">
<td class="td-width"
style=" font-size: 15px;border: 1px solid #e5ecf4;width: 25%;background-color: #faf9f9;">发文标题</td>
<td style=" font-size: 15px; border: 1px solid #e5ecf4;" :colspan="3">{{ list && list.issuedName ?
list.issuedName : '' }}</td>
</tr>
<tr style="border: 1px solid #e5ecf4;">
<td class="td-width"
style=" font-size: 15px;border: 1px solid #e5ecf4;width: 25%;background-color: #f9f9f9;background-color: #faf9f9;">
收文时间
</td>
<td style=" font-size: 15px;border: 1px solid #e5ecf4; "> {{ list && list.receiveDate ?
list.receiveDate : '' }}</td>
<td class="td-width"
style=" font-size: 15px;border: 1px solid #e5ecf4;background-color: #f9f9f9;background-color: #faf9f9; ">
办理期限</td>
<td style=" font-size: 15px;border: 1px solid #e5ecf4; ">{{ list && list.deadline ?
list.deadline : '' }}</td>
</tr>
<tr style="border: 1px solid #e5ecf4;">
<td class="td-width"
style=" font-size: 15px;border: 1px solid #e5ecf4;width: 25%;background-color: #faf9f9;">紧急程度</td>
<td style=" font-size: 15px;border: 1px solid #e5ecf4;" :colspan="3">{{ list && list.urgency ?
list.urgency : '' }}</td>
</tr>
<tr style="border: 1px solid #e5ecf4;">
<td class="td-spe" style=" font-size: 15px;border: 1px solid #e5ecf4;width: 25%;background-color: #faf9f9;">
简介</td>
<td style=" font-size: 15px;border: 1px solid #e5ecf4;" :colspan="3">{{ list && list.remarks ?
list.remarks : '' }}</td>
</tr>
<tr style="border: 1px solid #e5ecf4;">
<td class="td-spe" style="font-size: 15px;border: 1px solid #e5ecf4;width: 25%;background-color: #faf9f9;">
文件
</td>
<td style="font-size: 15px;border: 1px solid #e5ecf4;" :colspan="3">
{{ list && list.fileList ? list.fileList.map(item => item.fjmc).join(', ') : '' }}
</td>
</tr>
</table>
</div>
<!-- 流转信息 -->
<div style="
text-align: left;
margin: 0.2rem;
height: 20px;
font-family: PingFang SC;
font-weight: 700;
color: #242627;
font-size: 18px;
">
<span style="margin-left: 10px; height: 20px">流转信息</span>
</div>
<!-- 表格信息 -->
<div style="
margin-left: 0.2rem;
text-align: center;
min-width: 315px;
height: 68px;
background: #f5f7f7;
border: 1px solid;
border-color: #eeeeee;
display: flex;
align-items: center;
justify-content: space-around;
">
<div style="
height: 67px;
line-height: 67px;
min-width: 60px;
font-family: PingFang SC;
font-weight: 700;
color: #000000;
font-size: 15px;
border-right: 1px solid;
border-color: #eeeeee;
">
接收人
</div>
<div style="
height: 67px;
line-height: 67px;
min-width: 77px;
font-family: PingFang SC;
font-weight: 700;
color: #000000;
font-size: 15px;
border-right: 1px solid;
border-color: #eeeeee;
">
接收时间
</div>
<div style="
height: 67px;
line-height: 67px;
min-width: 137px;
font-family: PingFang SC;
font-weight: 700;
color: #000000;
font-size: 15px;
">
办理时间
</div>
<div style="
height: 67px;
line-height: 67px;
min-width: 137px;
font-family: PingFang SC;
font-weight: 700;
color: #000000;
font-size: 15px;
">
意见
</div>
</div>
<div v-for="item in review" :key="item" style="
display: flex;
/* height: 70px;
line-height: 70px; */
align-items: center;
justify-content: space-around;
/* min-width: 315px; */
border: 1px solid;
border-color: #eeeeee;
">
<div style="
/* height: 67px;
line-height: 67px;
min-width: 101px; */
font-family: PingFang SC;
text-align: center;
color: #000000;
font-size: 14px;
border-right: 1px solid;
border-color: #eeeeee;
">
{{ item.userName }}
</div>
<div style="
min-width: 77px;
font-family: PingFang SC;
color: #000000;
font-size: 14px;
text-align: center;
border-right: 1px solid;
border-color: #eeeeee;
display: flex;
align-items: center;
flex-direction: column;
">
<div style="">{{ item.receiveTime }}</div>
</div>
<div style="
height: 67px;
line-height: 67px;
min-width: 137px;
font-family: PingFang SC;
text-align: center;
color: #000000;
font-size: 14px;
">
{{ item.finishTime }}
</div>
<div style="
height: 67px;
line-height: 67px;
min-width: 137px;
font-family: PingFang SC;
color: #000000;
text-align: center;
font-size: 14px;
">
{{ item.opinion }}
</div>
</div>
</template>
<script setup>
import { ref, toRefs, computed, reactive, onMounted } from "vue";
import {
mytaskList,// 查询我的任务
lookList,// 详情页
offiCialflow,// 批阅人操作
offiCialflowfq,// 发起人操作
offiCialflowcy,// 传阅人操作
getSchoolLeader,//批阅人下拉框
getTeacherList//传阅人下拉框
} from "@/service/home";
import { useRouter, useRoute } from "vue-router";
import { createApp } from 'vue';
import { Field, CellGroup } from 'vant';
import { useStore } from "vuex";
import { Toast } from "vant";
const router = useRouter();
const route = useRoute();
const xzdetail = ref();
const app = createApp();
const list = ref();
const review = ref();
const store = useStore();
// 提交表单
const postForm = ref(null);
const detail = JSON.parse(decodeURIComponent(route.query.detail)); // 接收参数
const state = ref({
opinion: "", //意见
receiveUser: "", //用户id
});
app.use(Field);
app.use(CellGroup);
const loadData = async () => {
let result = await lookList(detail.id, {
});
list.value = result.offical;
console.log(list, 'list');
review.value = result.review;
console.log(review, 'review');
};
console.log(loadData, 'loadData');
const goback = async () => {
try {
const query = {
id: detail.id,
userId: store.state.userInfo.teacherId,
}; // 创建一个空的 query 对象
await offiCialflowcy(query); // 调用 offiCialflowcy 接口,并传递 query 对象
router.back();
} catch (error) {
}
};
onMounted(async () => {
loadData();
});
</script>
<style lang="less" scoped>
table {
border-collapse: collapse;
border: 1px solid gray;
width: 100%;
font-size: 0.28rem;
tr {
width: 100%;
.td-width {
text-align: center;
padding: 0.2225rem;
}
.td-spe {
text-align: center;
padding: 0.3525rem;
}
}
}
</style>
\ No newline at end of file
<template>
<van-nav-bar title="公文流转" left-text="返回" left-arrow @click-left="goback" />
<van-pull-refresh v-model="refreshing" @refresh="onRefresh">
<van-list v-model:loading="state.loading" :finished="finished" :finished-text="loadingText" @load="onLoad">
<div class="c_main_list" v-for="item in list" :key="item" style="padding: 18px 12px 15px 17px">
<div style="
font-family: PingFang SC;
font-weight: 700;
color: #000000;
font-size: 16px;
">
{{ item.issuedNum }}
</div>
<div style="font-size: 12px; margin: 10px -10px 10px -10px">
<van-cell-group inset>
<van-field v-model="item.issuedName" rows="4" autosize type="textarea" readonly placeholder="申请内容"
style="
background-color: #f5f7f7;
font-family: PingFang SC;
color: #6f787d;
font-size: 14px;
" />
</van-cell-group>
</div>
<div style="
display: flex;
align-items: center;
justify-content: flex-end;
margin-top: 23px;
">
<div v-if="item.receiveType == '1'" @click="goDetails(item)" class="flex_center" style="
width: 64px;
height: 32px;
border: 1px solid;
background: #ff7a6a;
border-radius: 3px;
font-family: PingFang SC;
font-weight: 700;
color: #ffffff;
font-size: 14px;
text-align: center;
margin-left: 10px;
">
批阅
</div>
<div v-if="item.receiveType == '2'" class="flex_center" @click="goDetails(item)" style="
width: 64px;
height: 32px;
background: #6aadff;
border-radius: 3px;
font-family: PingFang SC;
font-weight: 700;
color: #ffffff;
font-size: 14px;
text-align: center;
margin-left: 10px;
">
传阅
</div>
</div>
</div>
</van-list>
</van-pull-refresh>
<div class="box" style="
margin: 5px 6px 0 6px;
background-color: #ffffff;
height: 180px;
padding: 10px 10px 10px 10px;
"></div>
</template>
<script setup>
import { ref, toRefs, computed, reactive, onMounted } from "vue";
import { useRouter } from "vue-router";
import {
mytaskList,// 查询我的任务
lookList,// 详情页
offiCialflow,// 批阅人操作
offiCialflowfq,// 发起人操作
offiCialflowcy,// 传阅人操作
getSchoolLeader,//批阅人下拉框
getTeacherList//传阅人下拉框
} from "@/service/home";
import { Toast } from "vant";
import axios from "axios";
import { useStore } from "vuex";
import { formatDatetime } from "@/utils/time.js";
const state = reactive({
loading: false,
});
const receiveType = ref("");
const store = useStore();
const router = useRouter();
const list = ref([]);
const loading = ref(false);
const finished = ref(false);
const refreshing = ref(false);
const pageNum = ref(0);
const option1 = [
{ text: "全部", value: "" },
];
const change = async () => {
refreshing.value = true;
onRefresh();
};
const goDetails = (item) => {
// 批阅
if (item.receiveType == 1) {
router.push({
path: "/readOver",
query: {
detail: encodeURIComponent(JSON.stringify(item)),
},
});
}
// 传阅 查看
else if (item.receiveType == 2) {
router.push({
path: "/InitiateAction",
query: {
detail: encodeURIComponent(JSON.stringify(item)),
},
});
}
};
const onLoad = async () => {
if (refreshing.value) {
list.value = [];
pageNum.value = 0;
refreshing.value = false;
}
pageNum.value += 1;
let result = await mytaskList(store.state.userInfo.teacherId);
console.log(result, 'result');
if (result.code == 200) {
list.value.push(...result.data);
list.value.length === result.total && (finished.value = true);
} else {
Toast("获取信息失败!");
loading.value = false;
return;
}
loading.value = false; // 设置loading为false,表示数据加载完成
};
const onRefresh = () => {
// 清空列表数据
finished.value = false;
// 重新加载数据
// 将 loading 设置为 true,表示处于加载状态
loading.value = true;
onLoad();
};
const posttactleave = async () => {
let result = await postteacherLeave();
};
const goback = () => {
router.back();
};
</script>
<style lang="less" scoped>
.main_search_1 {
width: 100%;
flex: 1;
height: 15vw;
display: inline-block;
vertical-align: top;
margin: 0 0 -2px 0;
}
</style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment