Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dd_zhxy
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangqi
dd_zhxy
Commits
28614cd6
Commit
28614cd6
authored
Nov 10, 2023
by
peijy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
11.10 修改测试问题
parent
0d6babba
Show whitespace changes
Inline
Side-by-side
Showing
35 changed files
with
638 additions
and
245 deletions
+638
-245
.env.development
+3
-3
.env.production
+3
-3
components.d.ts
+0
-1
src/components/schoolYear.vue
+8
-7
src/service/laboratoryManagement.js
+3
-1
src/service/schoolProperty.js
+4
-0
src/views/dd.vue
+6
-3
src/views/parent/TeacherList.vue
+2
-1
src/views/parent/schoolClub/clubApply.vue
+6
-6
src/views/parent/schoolClub/clueDetail.vue
+83
-5
src/views/parent/schoolClub/index.vue
+17
-2
src/views/parent/studentCourseSelection/index.vue
+25
-4
src/views/parent/studentCourseSelection/totalScoreView.vue
+6
-6
src/views/tabbar/PersonInfo.vue
+8
-9
src/views/tabbar/main/index.vue
+4
-4
src/views/teacher/GradeListTeac.vue
+14
-12
src/views/teacher/laboratoryManagement/leader/laboratoryCompleteStatistics.vue
+16
-10
src/views/teacher/laboratoryManagement/leader/laboratoryRecord.vue
+8
-5
src/views/teacher/laboratoryManagement/levelPart/gradeLaboratoryApprove.vue
+12
-7
src/views/teacher/laboratoryManagement/levelPart/gradeLaboratoryComplete.vue
+8
-5
src/views/teacher/laboratoryManagement/levelPart/gradeLaboratoryDetail.vue
+34
-29
src/views/teacher/laboratoryManagement/levelPart/laboratoryCompleteDetail.vue
+9
-5
src/views/teacher/laboratoryManagement/manager/checkGradeComplete.vue
+86
-19
src/views/teacher/laboratoryManagement/manager/gradeLaboratory.vue
+16
-9
src/views/teacher/laboratoryManagement/manager/personalLaboratoryApprove.vue
+10
-9
src/views/teacher/laboratoryManagement/teacher/PersonalLaboratoryApplication.vue
+25
-9
src/views/teacher/laboratoryManagement/teacher/PersonalLaboratoryApplyDetail.vue
+95
-35
src/views/teacher/laboratoryManagement/teacher/laboratoryApplicationRecord.vue
+12
-8
src/views/teacher/laboratoryManagement/teacher/laboratoryArrangement.vue
+18
-9
src/views/teacher/schoolProperty/borrowDetail.vue
+1
-1
src/views/teacher/schoolProperty/borrowList.vue
+1
-1
src/views/teacher/schoolProperty/deviceList.vue
+1
-1
src/views/teacher/schoolProperty/deviceListInfo.vue
+7
-3
src/views/teacher/schoolProperty/returnDetail.vue
+66
-6
src/views/teacher/schoolProperty/returnList.vue
+21
-7
No files found.
.env.development
View file @
28614cd6
#
NODE_ENV='development'
#
VUE_APP_MODE='development'
# VUE_APP_API_URL='/abc
'
NODE_ENV='development'
VUE_APP_MODE='development'
VUE_APP_API_URL='/wx_api
'
.env.production
View file @
28614cd6
#
NODE_ENV='production'
#
VUE_APP_MODE='production'
#
VUE_APP_API_URL='/wx_api' //上线nginx所在地址(处理跨域问题)
NODE_ENV='production'
VUE_APP_MODE='production'
VUE_APP_API_URL='/wx_api' //上线nginx所在地址(处理跨域问题)
components.d.ts
View file @
28614cd6
...
...
@@ -23,7 +23,6 @@ declare module '@vue/runtime-core' {
VanCollapseItem
:
typeof
import
(
'vant/es'
)[
'CollapseItem'
]
VanConfigProvider
:
typeof
import
(
'vant/es'
)[
'ConfigProvider'
]
VanDatetimePicker
:
typeof
import
(
'vant/es'
)[
'DatetimePicker'
]
VanDialog
:
typeof
import
(
'vant/es'
)[
'Dialog'
]
VanDropdownItem
:
typeof
import
(
'vant/es'
)[
'DropdownItem'
]
VanDropdownMenu
:
typeof
import
(
'vant/es'
)[
'DropdownMenu'
]
VanEmpty
:
typeof
import
(
'vant/es'
)[
'Empty'
]
...
...
src/components/schoolYear.vue
View file @
28614cd6
...
...
@@ -27,7 +27,6 @@ const store = useStore()
const
emits
=
defineEmits
([
'select'
])
//学年学期选择器
const
schoolYearResult
=
ref
(
''
);
console
.
log
(
'schoolYearResult'
,
schoolYearResult
.
value
)
const
showPicker
=
ref
(
false
);
const
onConfirm
=
(
value
)
=>
{
...
...
@@ -39,15 +38,15 @@ const onConfirm = (value) => {
};
const
columns
=
ref
([]);
onMounted
(
async
()
=>
{
const
data
=
{
userId
:
store
.
state
.
userInfo
.
userId
}
console
.
log
(
'data'
,
data
)
let
schoolYear
=
await
getSchoolYear
(
data
);
//
const data = {
//
userId:store.state.userInfo.userId
//
}
//
console.log('data',data)
let
schoolYear
=
await
getSchoolYear
();
console
.
log
(
'schoolYear'
,
schoolYear
);
if
(
schoolYear
.
code
==
200
){
const
schoolYearColumns
=
schoolYear
.
data
.
map
(
item
=>
{
return
item
.
gradeYear
return
item
})
console
.
log
(
'schoolYearColumns'
,
schoolYearColumns
)
columns
.
value
=
[{
values
:
schoolYearColumns
},{
values
:
[
'上学期'
,
'下学期'
],}]
...
...
@@ -55,8 +54,10 @@ onMounted(async () => {
let
result
=
await
getNewSchoolYear
();
console
.
log
(
'result1'
,
result
)
if
(
result
.
code
==
200
){
// schoolYearResult.value = [result.schoolYear,columns[1].values[result.semester-1]]
schoolYearResult
.
value
=
result
.
schoolYear
+
'-'
+
columns
.
value
[
1
].
values
[
result
.
semester
-
1
]
console
.
log
(
'schoolYearResult.value'
,
schoolYearResult
.
value
)
const
value
=
[
result
.
schoolYear
,
result
.
semester
]
emits
(
"select"
,
value
)
console
.
log
(
'emits'
,
value
)
...
...
src/service/laboratoryManagement.js
View file @
28614cd6
...
...
@@ -51,7 +51,9 @@ export function getTeacherLabList(data){
/********************** 实验室管理员 *******************/
//查询实验室列表
export
function
getLabList
(
data
){
return
axios
.
get
(
'/wx/schoolLab/list'
)
return
axios
.
get
(
'/wx/schoolLab/list'
,{
params
:
data
})
};
//1.年纪实验室预约
//年级实验室预约分配列表
...
...
src/service/schoolProperty.js
View file @
28614cd6
...
...
@@ -56,6 +56,10 @@ export function returnEquipment(data) {
);
}
//物品归还详情
export
function
getDeatil
(
id
){
return
axios
.
get
(
`/wx/equipment/getReturningEquipmentById/
${
id
}
`
)
}
/********** 物品领用 ***********/
//领用列表
...
...
src/views/dd.vue
View file @
28614cd6
...
...
@@ -34,7 +34,8 @@ onMounted(() => {
// 获取code
const
getCode
=
()
=>
{
dd
.
getAuthCode
({
corpId
:
'dingaa3937ff8b7dd267f2c783f7214b6d69'
,
// corpId: 'dingaa3937ff8b7dd267f2c783f7214b6d69',
corpId
:
'dingccea40788226c988f2c783f7214b6d69'
,
success
:
(
res
)
=>
{
console
.
log
(
'获取新的免登码成功'
,
res
);
const
code
=
res
.
code
...
...
@@ -61,7 +62,8 @@ const getRoleType = async (code) => {
typeResult
.
value
=
type
.
data
if
(
type
.
data
.
length
==
1
)
{
dd
.
getAuthCode
({
corpId
:
'dingaa3937ff8b7dd267f2c783f7214b6d69'
,
// corpId: 'dingaa3937ff8b7dd267f2c783f7214b6d69',
corpId
:
'dingccea40788226c988f2c783f7214b6d69'
,
success
:
(
res
)
=>
{
console
.
log
(
'获取新的免登码成功'
,
res
);
const
code
=
res
.
code
...
...
@@ -111,7 +113,8 @@ const getgetToken = async (code, roleType) => {
const
confirmDialog
=
()
=>
{
console
.
log
(
'确认'
,
checked
.
value
)
dd
.
getAuthCode
({
corpId
:
'dingaa3937ff8b7dd267f2c783f7214b6d69'
,
// corpId: 'dingaa3937ff8b7dd267f2c783f7214b6d69',
corpId
:
'dingccea40788226c988f2c783f7214b6d69'
,
success
:
(
res
)
=>
{
console
.
log
(
'获取新的免登码成功'
,
res
);
const
code
=
res
.
code
...
...
src/views/parent/TeacherList.vue
View file @
28614cd6
...
...
@@ -24,7 +24,8 @@
<div
v-for=
"item in teacherList"
:key=
"item.id"
>
<div
class=
"main_list_one"
>
<div
class=
"left"
>
{{
item
.
teacherName
+
"("
+
item
.
courseName
+
")"
}}
{{
item
.
teacherName
}}
<span
v-if=
"item.courseName"
>
(
{{
item
.
courseName
}}
)
</span>
</div>
<a
:href=
"'tel:' + item.teacherTel"
class=
"right"
>
{{
item
.
teacherTel
...
...
src/views/parent/schoolClub/clubApply.vue
View file @
28614cd6
...
...
@@ -26,12 +26,12 @@
name=
"sex"
label=
"性别"
/>
<van-field
<!--
<van-field-->
v-model=
"cardid"
name=
"cardid"
label=
"身份证号"
/
>
<!-- v-model="cardid"-->
<!-- name="cardid"-->
<!-- label="身份证号"-->
<!-- />--
>
<van-field
v-model=
"phone"
...
...
@@ -113,7 +113,7 @@ onMounted(async ()=>{
reason
.
value
=
result
.
data
.
reason
status
.
value
=
result
.
data
.
status
phone
.
value
=
result
.
data
.
phone
cardid
.
value
=
result
.
data
.
cardid
//
cardid.value = result.data.cardid
}
console
.
log
(
'result'
,
result
)
})
...
...
src/views/parent/schoolClub/clueDetail.vue
View file @
28614cd6
...
...
@@ -16,11 +16,25 @@
</div>
<div
class=
"clubContent"
>
<div>
<div
style=
"display:flex;justify-content: center;margin-top: 30px"
>
<div
class=
"pxh"
></div>
<div
class=
"pxht"
></div>
<p
class=
"title"
>
社团宗旨
</p>
<p
class=
"content"
>
{{
aim
}}
</p>
<div
class=
"pxh"
></div>
<div
class=
"pxht"
></div>
</div>
<p
class=
"aim"
>
{{
aim
}}
</p>
</div>
<div>
<div
style=
"display:flex;justify-content: center;margin-top: 30px"
>
<div
class=
"pxh"
></div>
<div
class=
"pxh"
></div>
<p
class=
"title"
>
社团简介
</p>
<div
class=
"pxh"
></div>
<div
class=
"pxh"
></div>
</div>
<p
class=
"content"
>
{{
intro
}}
</p>
</div>
</div>
...
...
@@ -35,9 +49,11 @@ import {useStore} from "vuex";
import
{
useRouter
,
useRoute
}
from
"vue-router"
;
const
router
=
useRouter
()
const
route
=
useRoute
()
const
baseUrl
=
process
.
env
.
VUE_APP_API_URL
const
content
=
ref
()
const
aim
=
ref
(
''
)
const
intro
=
ref
(
''
)
const
href
=
window
.
location
.
origin
onMounted
(
async
()
=>
{
let
result
=
await
getClubDetail
(
route
.
query
.
id
)
console
.
log
(
'result'
,
result
)
...
...
@@ -46,7 +62,7 @@ onMounted( async () => {
intro
.
value
=
result
.
data
.
intro
if
(
result
.
data
.
imgs
){
content
.
value
=
result
.
data
.
imgs
.
split
(
','
).
map
(
item
=>
{
return
item
.
replace
(
'dev-api'
,
'wx_api'
)
return
baseUrl
+
item
})
}
...
...
@@ -81,10 +97,72 @@ const goback = () => {
/*background-color: #39a9ed;*/
}
.title
{
font-size
:
14px
;
text-align
:
center
;
height
:
0.56rem
;
font-family
:
PingFang
SC
;
font-weight
:
700
;
color
:
#000000
;
font-size
:
0.45rem
;
margin
:
0
0.26667rem
;
}
.aim
{
font-family
:
Slideqiuhong
!important
;
color
:
rgb
(
111
,
120
,
125
);
margin
:
10px
0px
15px
;
font-size
:
20px
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
}
.content
{
font-size
:
12px
;
background
:
rgb
(
245
,
247
,
247
);
padding
:
0px
15px
15px
;
font-family
:
"PingFang SC"
;
color
:
rgb
(
111
,
120
,
125
);
font-size
:
14px
;
line-height
:
26px
;
margin-top
:
12px
;
}
.pxh
{
position
:
relative
;
text-align
:
center
;
width
:
0.16rem
;
height
:
0.148rem
;
line-height
:
0.148rem
;
}
.pxh
:before
{
position
:
absolute
;
top
:
0
;
left
:
0
;
bottom
:
0
;
right
:
0
;
content
:
""
;
background
:
#39befe
;
z-index
:
10
;
-webkit-transform
:
skewX
(
-45deg
);
-ms-transform
:
skewX
(
-45deg
);
transform
:
skewX
(
-45deg
);
}
.pxht
{
position
:
relative
;
text-align
:
center
;
width
:
0.16rem
;
height
:
0.148rem
;
line-height
:
0.148rem
;
margin-left
:
0.05333rem
;
}
.pxht
:before
{
position
:
absolute
;
opacity
:
30%
;
top
:
0
;
left
:
0
;
bottom
:
0
;
right
:
0
;
content
:
""
;
background
:
#39befe
;
z-index
:
10
;
-webkit-transform
:
skewX
(
-45deg
);
-ms-transform
:
skewX
(
-45deg
);
transform
:
skewX
(
-45deg
);
}
</
style
>
src/views/parent/schoolClub/index.vue
View file @
28614cd6
...
...
@@ -11,13 +11,21 @@
<div
class=
"clubItem"
v-for=
"item in list"
:key=
"item.id"
>
<div
style=
"position: relative;width: 100%;height: 100%"
@
click=
"toDetail(item.id,item.name)"
>
<div
class=
"image"
>
<!--
<van-image-->
<!-- fit="fill"-->
<!-- position="center"-->
<!-- width="100%"-->
<!-- height="100%"-->
<!-- radius="10"-->
<!-- :src="item.imgs == null ? '':item.imgs.split(',')[0].replace('dev-api','wx_api')"-->
<!-- />-->
<van-image
fit=
"fill"
position=
"center"
width=
"100%"
height=
"100%"
radius=
"10"
:src=
"item.imgs == null ? '':
item.imgs.split(',')[0].replace('dev-api','wx_api')
"
:src=
"item.imgs == null ? '':
baseUrl +item.imgs.split(',')[0]
"
/>
</div>
<div
class=
"clubName"
>
{{
item
.
name
}}
</div>
...
...
@@ -37,15 +45,19 @@ import {getClubInfo} from '@/service/schoolClub'
import
{
onMounted
,
ref
}
from
"vue"
;
import
{
useRouter
}
from
"vue-router"
;
import
{
Toast
}
from
"vant"
;
const
router
=
useRouter
()
const
baseUrl
=
process
.
env
.
VUE_APP_API_URL
const
list
=
ref
([]);
const
loading
=
ref
(
false
);
const
finished
=
ref
(
false
);
const
refreshing
=
ref
(
false
);
const
src
=
ref
()
const
imgArr
=
ref
([])
onMounted
(
async
()
=>
{
const
href
=
window
.
location
.
origin
onMounted
(
async
()
=>
{
console
.
log
(
'baseUrl'
,
baseUrl
)
})
const
onLoad
=
async
()
=>
{
if
(
refreshing
.
value
)
{
...
...
@@ -59,6 +71,9 @@ const onLoad = async () => {
loading
.
value
=
false
;
list
.
value
=
result
.
data
// imgArr.value = result.data.map(item => item.imgs)
// list.imgs = result.data.imgs.map(item => {
// item.split(',')[0]
// })
imgArr
.
value
=
result
.
data
.
imgs
finished
.
value
=
true
}
else
{
...
...
src/views/parent/studentCourseSelection/index.vue
View file @
28614cd6
...
...
@@ -8,7 +8,7 @@
<div>
<div
class=
"main"
>
<div
style=
"margin: 16px;float: right"
>
<van-button
style=
"height: 30px;width: 1
0
0px;"
@
click=
"checkGrade"
round
type=
"primary"
native-type=
"submit"
>
<van-button
style=
"height: 30px;width: 1
2
0px;"
@
click=
"checkGrade"
round
type=
"primary"
native-type=
"submit"
>
成绩查看
</van-button>
</div>
...
...
@@ -751,6 +751,7 @@ import {
getDicts
,
//获取数据字典
getStudentInfo
,
//学生选课信息查询
saveSelectInfo
,
//保存选课信息
getPersonGrade
,
//获取个人成绩
}
from
"@/service/studentCourseSelection"
;
const
router
=
useRouter
();
...
...
@@ -904,13 +905,26 @@ onMounted(async () => {
});
//成绩查看按钮
const
checkGrade
=
()
=>
{
const
checkGrade
=
async
()
=>
{
let
gradeResult
=
await
getPersonGrade
(
store
.
state
.
userInfo
.
studentId
)
console
.
log
(
'gradeResult'
,
gradeResult
)
if
(
gradeResult
.
code
==
200
){
if
(
gradeResult
.
data
.
length
>
0
){
router
.
push
({
path
:
"/totalScoreView"
,
query
:
{
id
:
store
.
state
.
userInfo
.
studentId
data
:
gradeResult
.
data
}
})
}
else
{
Toast
(
'暂无成绩'
)
}
}
else
{
Toast
(
'信息获取失败'
)
}
};
const
subjectColumn
=
ref
([])
const
params
=
reactive
({
...
...
@@ -933,9 +947,16 @@ const toSubjectGrade = async (name, value) => {
let
result
=
await
getSelectGrade
(
data
)
console
.
log
(
'result66'
,
result
)
if
(
result
.
code
==
200
)
{
if
(
result
.
data
.
length
>
0
){
subjectColumn
.
value
=
result
.
data
}
isShowDialog
.
show
=
true
;
}
else
{
Toast
(
"暂无成绩!"
);
}
}
else
{
Toast
(
"信息获取失败!"
);
}
// router.replace({
// path: "/subjectAchievement",
// query: {
...
...
src/views/parent/studentCourseSelection/totalScoreView.vue
View file @
28614cd6
...
...
@@ -87,11 +87,11 @@ const isCollaps = (item, num) => {
item
.
isShow
=
true
};
onMounted
(
async
()
=>
{
console
.
log
(
'query.
id'
,
query
.
id
)
let
result
=
await
getPersonGrade
(
query
.
id
)
console
.
log
(
'result'
,
result
)
if
(
result
.
code
==
200
)
{
column
.
value
=
result
.
data
.
map
(
item
=>
{
console
.
log
(
'query.
data'
,
query
.
data
)
//
let result = await getPersonGrade(query.id)
//
console.log('result', result)
//
if (result.code == 200) {
column
.
value
=
query
.
data
.
map
(
item
=>
{
return
{
totalScore
:
item
.
totalScore
,
//总成绩
ranking
:
item
.
ranking
,
//总成绩年纪排名
...
...
@@ -117,7 +117,7 @@ onMounted(async () => {
}
})
console
.
log
(
'column'
,
column
.
value
)
}
//
}
})
const
goback
=
(
g
)
=>
{
router
.
back
()
...
...
src/views/tabbar/PersonInfo.vue
View file @
28614cd6
...
...
@@ -116,15 +116,14 @@
</van-collapse>
<div
class=
"main_one_betn"
>
<!-- 多组 例如 第一个孩子、第二个孩子的信息 -->
<van-button
class=
"main_one_btn_item"
plain
round
size=
"small"
type=
"primary"
@
click=
"showPopup"
>
添加监护人
</van-button
>
<!-- <van-button-->
<!-- class="main_one_btn_item"-->
<!-- plain-->
<!-- round-->
<!-- size="small"-->
<!-- type="primary"-->
<!-- @click="showPopup"-->
<!-- >添加监护人 </van-button> -->
<van-button
class=
"main_one_btn_item"
round
...
...
src/views/tabbar/main/index.vue
View file @
28614cd6
...
...
@@ -434,10 +434,10 @@
<!--2023-08-24 新增实验室管理模块-->
<!--2023-09-11 新增安全管理模块-->
<van-grid-item
icon=
"photo-o"
text=
"安全管理"
url=
"#/safetyManagement"
>
<van-image
style=
"width: 48px"
:src=
"require('@/assets/index/dcwj.png')"
/
>
<span
class=
"item_text"
>
安全管理
</span
>
</van-grid-item
>
<!--
<van-grid-item
icon=
"photo-o"
text=
"安全管理"
url=
"#/safetyManagement"
>
--
>
<!--
<van-image
style=
"width: 48px"
:src=
"require('@/assets/index/dcwj.png')"
/>
--
>
<!--
<span
class=
"item_text"
>
安全管理
</span>
--
>
<!--
</van-grid-item>
--
>
<!--2023-09-11 新增安全管理模块-->
<!--
<van-grid-item
icon=
"photo-o"
text=
"我的领用"
url=
" #/myUse"
>
...
...
src/views/teacher/GradeListTeac.vue
View file @
28614cd6
...
...
@@ -9,11 +9,11 @@
<div
class=
"main"
>
<div
class=
"main_search"
>
<div
class=
"main_search_2"
>
<van-config-provider
:theme-vars=
"themeVars"
>
<van-config-provider
>
<van-dropdown-menu
class=
"main_search_2_cd"
active-color=
"#1989fa"
overlay=
"
false
"
overlay=
"
overlay
"
>
<van-dropdown-item
v-model=
"state.gradeId"
...
...
@@ -44,8 +44,8 @@
font-size: 14px;
position: unset;
"
center=
"false"
border=
"
false
"
border=
"
border
"
title-class=
"gradeinfo_top"
title=
"班 级"
:value=
"state.className"
...
...
@@ -61,8 +61,8 @@
font-size: 14px;
position: unset;
"
center=
"false"
border=
"
false
"
border=
"
border
"
title-class=
"gradeinfo_top"
title=
"年 级"
:value=
"state.gradeName"
...
...
@@ -78,8 +78,8 @@
font-size: 14px;
position: unset;
"
center=
"false"
border=
"
false
"
border=
"
border
"
title-class=
"gradeinfo_top"
title=
"开始学年"
:value=
"state.schoolYear"
...
...
@@ -95,8 +95,8 @@
font-size: 14px;
position: unset;
"
center=
"false"
border=
"
false
"
border=
"
border
"
title-class=
"gradeinfo_top"
title=
"所在教学楼"
:value=
"state.houseName"
...
...
@@ -113,8 +113,8 @@
position: unset;
"
center=
"false"
border=
"
false
"
border=
"
border
"
title-class=
"gradeinfo_top"
title=
"别名"
:value=
"state.gradeAlias"
...
...
@@ -354,6 +354,8 @@ export default {
});
const
store
=
useStore
();
console
.
log
(
store
.
state
.
imgUrl
);
const
overlay
=
ref
(
false
);
const
border
=
ref
(
false
)
const
imgUrl
=
ref
(
""
);
const
list
=
ref
([]);
const
loading
=
ref
(
true
);
...
...
src/views/teacher/laboratoryManagement/leader/laboratoryCompleteStatistics.vue
View file @
28614cd6
...
...
@@ -109,11 +109,12 @@ const onLoad = async () => {
console
.
log
(
type
)
//领导-实验室完成情况统计
title
.
value
=
'实验室完成情况'
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if(semester.value == '上学期' ||semester.value == '1'){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
...
...
@@ -132,17 +133,20 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
if
(
type
==
5
){
console
.
log
(
type
)
//实验室管理员-实验计划完成统计
title
.
value
=
'实验计划完成统计'
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if(semester.value == '上学期' ||semester.value == '1'){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
...
...
@@ -162,6 +166,8 @@ const onLoad = async () => {
return
;
}
}
}
}
//点击事件
...
...
src/views/teacher/laboratoryManagement/leader/laboratoryRecord.vue
View file @
28614cd6
...
...
@@ -103,11 +103,12 @@ const onLoad = async () => {
refreshing
.
value
=
false
;
}
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if(semester.value == '上学期' ||semester.value == '1' ){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
...
...
@@ -127,6 +128,8 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
//下拉刷新
...
...
src/views/teacher/laboratoryManagement/levelPart/gradeLaboratoryApprove.vue
View file @
28614cd6
...
...
@@ -34,7 +34,9 @@
<van-image
v-if=
"item.sub == '1'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/physics.png')"
></van-image>
<van-image
v-if=
"item.sub == '3'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/biology.png')"
></van-image>
<van-image
v-if=
"item.sub == '2'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/chemistry.png')"
></van-image>
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
<!--
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
-->
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
experimentName
}}
</span>
</div>
<div
class=
"subject"
>
<van-icon
style=
"margin-right: 3px"
name=
"bookmark-o"
/>
...
...
@@ -52,7 +54,7 @@
</div>
<div
class=
"room"
>
<van-icon
style=
"margin-right: 3px"
name=
"home-o"
/>
<span
style=
"font-size: 14px;padding-left: 5px"
>
{{
item
.
labName
}}
</span>
<span
style=
"font-size: 14px;padding-left: 5px"
>
{{
item
.
schoolLabClassYearRelationList
?
item
.
schoolLabClassYearRelationList
.
map
(
item
=>
item
.
labName
).
toString
()
:
''
}}
</span>
</div>
<div
class=
"time"
>
<van-icon
style=
"margin-right: 3px"
name=
"clock-o"
/>
...
...
@@ -130,11 +132,12 @@ const onLoad = async () => {
refreshing
.
value
=
false
;
}
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if(semester.value == '上学期' ||semester.value == '1' ){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
...
...
@@ -154,6 +157,8 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
//下拉刷新
const
onRefresh
=
()
=>
{
...
...
src/views/teacher/laboratoryManagement/levelPart/gradeLaboratoryComplete.vue
View file @
28614cd6
...
...
@@ -96,11 +96,12 @@ const onLoad = async () => {
refreshing
.
value
=
false
;
}
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if(semester.value == '上学期' ||semester.value == '1' ){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
...
...
@@ -120,6 +121,8 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
//下拉刷新
...
...
src/views/teacher/laboratoryManagement/levelPart/gradeLaboratoryDetail.vue
View file @
28614cd6
...
...
@@ -103,24 +103,24 @@
v-model=
"form.semester"
label=
"学期"
/>
<van-field
v-model=
"form.labName"
is-link
readonly
name=
"picker"
label=
"实验室"
placeholder=
"选择实验室"
@
click=
"showPickerLab = true"
:rules=
"[
{ required: true, message: '请选择实验室' }]"
<!--
<van-field-->
<!-- v-model="form.labName"-->
<!-- is-link-->
<!-- readonly-->
<!-- name="picker"-->
<!-- label="实验室"-->
<!-- placeholder="选择实验室"-->
<!-- @click="showPickerLab = true"-->
<!-- :rules="[
{ required: true, message: '请选择实验室' }]"-->
/
>
<van-popup
v-model:show=
"showPickerLab"
position=
"bottom"
>
<van-picker
:columns=
"columnsLabName"
@
confirm=
"onConfirmLab"
@
cancel=
"showPickerLab = false"
/
>
</van-popup
>
<!-- />--
>
<!--
<van-popup
v-model:show=
"showPickerLab"
position=
"bottom"
>
--
>
<!--
<van-picker-->
<!-- :columns="columnsLabName"-->
<!-- @confirm="onConfirmLab"-->
<!-- @cancel="showPickerLab = false"-->
<!-- />--
>
<!--
</van-popup>
--
>
<van-field
v-model=
"form.plannedStartTime"
is-link
...
...
@@ -205,7 +205,7 @@
</div>
<div
v-else
style=
"margin: 20px;display: flex;justify-content: center"
>
<van-button
style=
"margin-right: 50px;width: 90px;height: 30px"
round
type=
"primary"
native-type=
"submit"
>
同意
提交
</van-button>
<van-button
style=
"width: 90px;height: 30px"
round
type=
"success"
@
click=
"goback"
>
取消
...
...
@@ -260,17 +260,17 @@ onMounted(async () => {
}
console
.
log
(
'columnsLab.value'
,
columnsLab
.
value
)
//实验室下拉框
let
labResult
=
await
getLabList
()
console
.
log
(
'labResult'
,
labResult
)
if
(
labResult
.
code
==
200
){
columnsLabName
.
value
=
labResult
.
rows
.
map
(
item
=>
{
return
{
text
:
item
.
labName
,
value
:
item
.
id
}
})
console
.
log
(
'columnsLabName.value'
,
columnsLabName
.
value
)
}
//
let labResult = await getLabList()
//
console.log('labResult',labResult)
//
if(labResult.code == 200){
//
columnsLabName.value = labResult.rows.map(item => {
//
return{
//
text:item.labName,
//
value:item.id
//
}
//
})
//
console.log('columnsLabName.value',columnsLabName.value)
//
}
if
(
type
==
'查看'
){
title
.
value
=
'年级实验室预约查看'
let
result
=
await
getApproveDetail
(
route
.
query
.
id
)
...
...
@@ -282,6 +282,7 @@ onMounted(async () => {
form
.
semester
=
form
.
semester
==
'1'
?
'上学期'
:
'下学期'
;
form
.
experimentClassify
=
form
.
experimentClassify
==
'1'
?
'分组实验'
:
form
.
experimentClassify
==
'2'
?
'演示实验'
:
'探究实验'
;
form
.
planTime
=
result
.
data
.
plannedStartTime
+
'-'
+
result
.
data
.
plannedEndTime
form
.
labName
=
result
.
data
.
schoolLabClassYearRelationList
.
map
(
item
=>
item
.
labName
).
toString
()
}
}
if
(
type
==
'修改'
){
...
...
@@ -328,6 +329,8 @@ const onConfirmLabName = async (value) => {
form
.
sub
=
form
.
sub
==
'1'
?
'物理'
:
form
.
sub
==
'2'
?
'化学'
:
'生物'
;
form
.
semester
=
form
.
semester
==
'1'
?
'上学期'
:
'下学期'
;
form
.
experimentClassify
=
form
.
experimentClassify
==
'1'
?
'分组实验'
:
form
.
experimentClassify
==
'2'
?
'演示实验'
:
'探究实验'
;
form
.
plannedStartTime
=
''
;
form
.
plannedEndTime
=
''
;
};
//实验室下拉选择
const
labNameId
=
ref
(
''
)
...
...
@@ -385,6 +388,7 @@ const onSubmit = async () => {
if
(
type
==
'新增'
){
const
data
=
{
experimentName
:
form
.
experimentName
,
experimentPlanId
:
form
.
id
,
grade
:
form
.
grade
,
gradeId
:
form
.
gradeId
,
...
...
@@ -412,6 +416,7 @@ const onSubmit = async () => {
}
else
{
const
data
=
{
id
:
route
.
query
.
id
,
experimentName
:
form
.
experimentName
,
experimentPlanId
:
form
.
id
,
grade
:
form
.
grade
,
gradeId
:
form
.
gradeId
,
...
...
src/views/teacher/laboratoryManagement/levelPart/laboratoryCompleteDetail.vue
View file @
28614cd6
...
...
@@ -106,11 +106,12 @@ const onLoad = async () => {
refreshing
.
value
=
false
;
}
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if(semester.value == '上学期' ||semester.value == '1' ){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
...
...
@@ -126,12 +127,15 @@ const onLoad = async () => {
loading
.
value
=
false
;
list
.
value
=
result
.
data
finished
.
value
=
true
console
.
log
(
'finished.value'
,
finished
.
value
)
}
else
{
Toast
(
"获取信息失败!"
);
finished
.
value
=
true
;
loading
.
value
=
false
;
return
;
}
}
}
//下拉刷新
...
...
src/views/teacher/laboratoryManagement/manager/checkGradeComplete.vue
View file @
28614cd6
...
...
@@ -110,7 +110,15 @@
<!-- />-->
<!--
</van-popup>
-->
<!-- 单选框 name='lab'对应提交的名 :name='index'对应提交的值 -->
<van-field
name=
"lab"
label=
"实验室"
:rules=
"[
{ required: true, message: '请选择实验室' }]">
<div>
<van-field
v-if=
"formData.declareState == '3'"
v-model=
"formData.labName"
readonly
name=
"labName"
label=
"实验室"
/>
<van-field
v-else
name=
"lab"
label=
"实验室"
:rules=
"[
{ required: true, message: '请选择实验室' }]">
<template
#
input
>
<van-checkbox-group
v-model=
"checked"
direction=
"horizontal"
icon-size=
"18px"
>
<van-checkbox
:disabled=
"formData.declareState == '3'"
v-for=
"item in columnsLab"
:key=
"item.value"
:name=
"item.value"
style=
"margin-bottom: 8px"
>
...
...
@@ -119,6 +127,8 @@
</van-checkbox-group>
</
template
>
</van-field>
</div>
</van-cell-group>
<div
v-if=
"name == 'grade'"
class=
"topTitle"
>
(非必填)完善信息
</div>
<van-cell-group
inset
style=
"padding: 10px"
>
...
...
@@ -135,16 +145,44 @@
/>
</van-cell-group>
<div
style=
"margin: 20px;display: flex;justify-content: center"
>
<van-button
v-if=
"name == 'grade'"
style=
"margin-right: 50px;width: 90px;height: 30px"
round
type=
"primary"
native-type=
"submit"
>
<div
n
v-if=
"name == 'grade'"
>
<van-button
v-if=
"state == '3'"
style=
"margin-right: 50px;width: 90px;height: 30px"
round
type=
"primary"
@
click=
"goback"
>
关闭
</van-button>
<div
v-else
>
<van-button
style=
"margin-right: 50px;width: 90px;height: 30px"
round
type=
"primary"
native-type=
"submit"
>
同意
</van-button>
<van-button
v-if=
"name == 'personal'"
style=
"margin-right: 50px;width: 90px;height: 30px"
round
type=
"primary"
native-type=
"submit"
>
<van-button
style=
"width: 90px;height: 30px"
round
type=
"success"
@
click=
"goback"
>
取消
</van-button>
</div>
</div>
<div>
<div
v-if=
"name == 'personal'"
>
<van-button
v-if=
"state == '3'"
style=
"margin-right: 50px;width: 90px;height: 30px"
round
type=
"primary"
native-type=
"submit"
>
关闭
</van-button>
<div
v-else
>
<van-button
style=
"margin-right: 50px;width: 90px;height: 30px"
round
type=
"primary"
native-type=
"submit"
>
分配
</van-button>
<van-button
style=
"width: 90px;height: 30px"
round
type=
"success"
@
click=
"goback"
>
取消
</van-button>
</div>
</div>
</div>
</div>
</van-form>
</template>
...
...
@@ -160,6 +198,7 @@ const store = useStore();
const
router
=
useRouter
();
const
route
=
useRoute
();
const
name
=
route
.
query
.
name
;
const
state
=
route
.
query
.
declareState
const
title
=
ref
(
''
)
const
formData
=
reactive
({
sub
:
''
,
...
...
@@ -170,24 +209,16 @@ const formData = reactive({
experimentName
:
''
,
experimentClassify
:
''
,
chapterContent
:
''
,
declareState
:
''
declareState
:
''
,
labName
:
''
})
const
selectStartTime
=
ref
(
''
)
const
selectEndTime
=
ref
(
''
)
const
checked
=
ref
([])
const
columnsLab
=
ref
([])
onMounted
(
async
()
=>
{
let
labResult
=
await
getLabList
()
console
.
log
(
'labResult'
,
labResult
)
if
(
labResult
.
code
==
200
){
columnsLab
.
value
=
labResult
.
rows
.
map
(
item
=>
{
return
{
text
:
item
.
labName
,
value
:
item
.
id
}
})
console
.
log
(
'columnsLab.value'
,
columnsLab
.
value
)
}
console
.
log
(
'state'
,
state
)
if
(
name
==
'personal'
){
//个人实验审批接口
title
.
value
=
'实验室分配'
...
...
@@ -195,12 +226,12 @@ onMounted(async ()=>{
console
.
log
(
'res'
,
res
)
if
(
res
.
code
==
200
){
Object
.
assign
(
formData
,
res
.
data
)
if
(
res
.
data
.
schoolLabClassYearRelationList
!=
null
||
undefined
||
''
){
checked
.
value
=
res
.
data
.
schoolLabClassYearRelationList
.
map
(
item
=>
{
if
(
res
.
data
.
schoolTeacherExperimentApplyLabsList
!=
null
||
res
.
data
.
schoolTeacherExperimentApplyLabsList
!=
undefined
||
res
.
data
.
schoolTeacherExperimentApplyLabsList
!=
''
){
console
.
log
(
'666666'
)
checked
.
value
=
res
.
data
.
schoolTeacherExperimentApplyLabsList
.
map
(
item
=>
{
return
item
.
labId
})
}
console
.
log
(
'checked.value'
,
checked
.
value
)
formData
.
sub
=
formData
.
sub
==
'1'
?
'物理'
:
formData
.
sub
==
'2'
?
'化学'
:
'生物'
;
formData
.
semester
=
formData
.
semester
==
'1'
?
'上学期'
:
'下学期'
;
...
...
@@ -210,6 +241,9 @@ onMounted(async ()=>{
}
if
(
name
==
'grade'
){
title
.
value
=
'年级实验室分配'
if
(
route
.
query
.
declareState
==
'3'
){
//已分配
//管理员年级实验分配接口
let
res
=
await
getGradePlanDetail
(
route
.
query
.
id
)
console
.
log
(
'res'
,
res
)
...
...
@@ -225,7 +259,40 @@ onMounted(async ()=>{
formData
.
semester
=
formData
.
semester
==
'1'
?
'上学期'
:
'下学期'
;
formData
.
experimentClassify
=
formData
.
experimentClassify
==
'1'
?
'分组实验'
:
formData
.
experimentClassify
==
'2'
?
'演示实验'
:
'探究实验'
;
formData
.
plannedTime
=
res
.
data
.
plannedStartTime
+
'-'
+
res
.
data
.
plannedEndTime
formData
.
labName
=
res
.
data
.
schoolLabClassYearRelationList
.
map
(
item
=>
item
.
labName
).
toString
()
}
}
else
{
//未分配
//详情
let
res
=
await
getGradePlanDetail
(
route
.
query
.
id
)
console
.
log
(
'res'
,
res
)
if
(
res
.
code
==
200
){
Object
.
assign
(
formData
,
res
.
data
)
formData
.
sub
=
formData
.
sub
==
'1'
?
'物理'
:
formData
.
sub
==
'2'
?
'化学'
:
'生物'
;
formData
.
semester
=
formData
.
semester
==
'1'
?
'上学期'
:
'下学期'
;
formData
.
experimentClassify
=
formData
.
experimentClassify
==
'1'
?
'分组实验'
:
formData
.
experimentClassify
==
'2'
?
'演示实验'
:
'探究实验'
;
formData
.
plannedTime
=
res
.
data
.
plannedStartTime
+
'-'
+
res
.
data
.
plannedEndTime
}
console
.
log
(
'未分配'
)
const
params
=
{
plannedStartTime
:
route
.
query
.
plannedStartTime
,
plannedEndTime
:
route
.
query
.
plannedEndTime
}
//实验室列表
let
labResult
=
await
getLabList
(
params
)
console
.
log
(
'labResult'
,
labResult
)
if
(
labResult
.
code
==
200
){
columnsLab
.
value
=
labResult
.
data
.
map
(
item
=>
{
return
{
text
:
item
.
labName
,
value
:
item
.
labId
}
})
// console.log('columnsLab.value',columnsLab.value)
}
}
}
})
...
...
@@ -246,7 +313,7 @@ const onConfirmDate = (values) => {
const
dateArrays
=
ref
([])
//提交
const
onSubmit
=
async
(
values
)
=>
{
console
.
log
(
'values'
,
values
)
console
.
log
(
'checked.value'
,
checked
.
value
)
if
(
name
==
'grade'
&&
checked
.
value
.
length
!=
0
){
console
.
log
(
'submit'
,
values
);
...
...
src/views/teacher/laboratoryManagement/manager/gradeLaboratory.vue
View file @
28614cd6
...
...
@@ -21,13 +21,14 @@
@
load=
"onLoad"
>
<div
v-for=
"(item,index) in list"
:key=
"index"
>
<div
class=
"card"
@
click=
"toDetail(item.id)"
>
<div
class=
"card"
@
click=
"toDetail(item.id
,item.declareState,item.plannedStartTime,item.plannedEndTime
)"
>
<div
class=
"topContent"
>
<div
class=
"topLeft"
>
<van-image
v-if=
"item.sub == '1'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/physics.png')"
></van-image>
<van-image
v-if=
"item.sub == '3'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/biology.png')"
></van-image>
<van-image
v-if=
"item.sub == '2'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/chemistry.png')"
></van-image>
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
<!--
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
-->
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
experimentName
}}
</span>
</div>
<div
class=
"topRight"
>
<div
v-if=
"item.declareState == '3'"
class=
"assigned"
>
已分配
</div>
...
...
@@ -90,11 +91,12 @@ const onLoad = async () => {
refreshing
.
value
=
false
;
}
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if(semester.value == '上学期' ||semester.value == '1' ){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
...
...
@@ -113,15 +115,20 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
//点击事件
const
toDetail
=
(
id
)
=>
{
const
toDetail
=
(
id
,
declareState
,
statrtTime
,
endTime
)
=>
{
router
.
push
({
path
:
'/laboratoryManagement/gradeLaboratory/checkGradeComplete'
,
query
:{
id
:
id
,
name
:
'grade'
name
:
'grade'
,
declareState
:
declareState
,
plannedStartTime
:
statrtTime
,
plannedEndTime
:
endTime
,
}
})
}
...
...
src/views/teacher/laboratoryManagement/manager/personalLaboratoryApprove.vue
View file @
28614cd6
...
...
@@ -22,7 +22,7 @@
@
load=
"onLoad"
>
<div
v-for=
"(item,index) in list"
:key=
"index"
>
<div
class=
"card"
@
click=
"toDetail(item.id)"
>
<div
class=
"card"
@
click=
"toDetail(item.id
,item.declareState
)"
>
<div
class=
"topContent"
>
<div
class=
"topLeft"
>
<van-image
v-if=
"item.sub == '1'"
style=
"height: 20px;width: 20px;vertical-align: middle"
...
...
@@ -40,23 +40,23 @@
</div>
</div>
<div
class=
"middleContent"
>
<div
style=
"
margin-right: 50px
"
>
<div
style=
"
width: 50%
"
>
<span>
级部:
</span>
<span>
{{
item
.
grade
}}
</span>
</div>
<div>
<div
style=
"width: 50%;"
>
<span>
学期:
</span>
<span>
{{
item
.
schoolYear
}}{{
item
.
semester
==
'1'
?
'上学期'
:
'下学期'
}}
</span>
</div>
</div>
<div
class=
"bottomContent"
>
<div
style=
"
margin-right: 70px
"
>
<div
style=
"
width: 50%
"
>
<span>
教师:
</span>
<span>
{{
item
.
applyName
}}
</span>
</div>
<div>
<div
style=
"width: 50%;"
>
<span>
实验室:
</span>
<span>
{{
item
.
labName
}}
</span>
<span>
{{
item
.
schoolTeacherExperimentApplyLabsList
.
map
(
item
=>
item
.
labName
).
toString
()
}}
</span>
</div>
</div>
...
...
@@ -133,12 +133,13 @@ const onLoad = async () => {
}
//点击事件
const
toDetail
=
(
id
)
=>
{
const
toDetail
=
(
id
,
declareState
)
=>
{
router
.
push
({
path
:
'/laboratoryManagement/gradeLaboratory/checkGradeComplete'
,
query
:
{
id
:
id
,
name
:
'personal'
name
:
'personal'
,
declareState
:
declareState
}
})
}
...
...
@@ -224,7 +225,7 @@ const goback = () => {
padding-bottom
:
10px
;
display
:
flex
;
flex-direction
:
row
;
/*justify-content: space-
between
;*/
/*justify-content: space-
around
;*/
color
:
#6f787d
;
}
...
...
src/views/teacher/laboratoryManagement/teacher/PersonalLaboratoryApplication.vue
View file @
28614cd6
...
...
@@ -17,7 +17,7 @@
<schoolYear
@
select=
"handleSelect"
></schoolYear>
<!--新增按钮 -->
<div
style=
"margin-right: 20px;"
>
<van-button
size=
"mini"
round
type=
"primary"
@
click=
"addDetail"
>
新增申请
</van-button>
<van-button
:disabled=
"noSub"
size=
"mini"
round
type=
"primary"
@
click=
"addDetail"
>
新增申请
</van-button>
</div>
</div>
...
...
@@ -38,8 +38,9 @@
:src=
"require('../../../../assets/icon/biology.png')"
></van-image>
<van-image
v-if=
"item.sub == '2'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/chemistry.png')"
></van-image>
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
<!--
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
-->
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
experimentName
}}
</span>
</div>
<div
class=
"topRight"
>
<div
v-if=
"item.declareState == '3'"
class=
"assigned"
>
已分配
</div>
...
...
@@ -82,7 +83,7 @@
<
script
setup
>
import
{
getPersonalLabApplyList
,
deleteApply
,
applyToReport
}
from
'@/service/laboratoryManagement'
import
{
getSubject
}
from
'@/service/laboratoryManagement'
import
{
reactive
,
onMounted
,
toRefs
,
ref
}
from
"vue"
;
import
{
useStore
}
from
"vuex"
;
import
{
useRouter
,
useRoute
}
from
"vue-router"
;
...
...
@@ -110,7 +111,18 @@ const loading = ref(false);
const
finished
=
ref
(
false
);
const
refreshing
=
ref
(
false
);
const
searchValue
=
ref
(
''
);
const
noSub
=
ref
(
false
)
onMounted
(
async
()
=>
{
// 获取学科
let
subjectResult
=
await
getSubject
()
console
.
log
(
'subjectResult'
,
subjectResult
)
if
(
subjectResult
.
code
==
200
){
if
(
JSON
.
stringify
(
subjectResult
.
data
)
==
"{}"
){
noSub
.
value
=
true
}
}
})
//列表加载事件
const
onLoad
=
async
()
=>
{
if
(
refreshing
.
value
)
{
...
...
@@ -118,15 +130,17 @@ const onLoad = async () => {
refreshing
.
value
=
false
;
}
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
)
{
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if (semester.value == '上学期' || semester.value == '1') {
// semester.value = '1'
// } else {
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
querText
:
searchValue
.
value
,
applyId
:
store
.
state
.
userInfo
.
userId
}
console
.
log
(
'params'
,
params
)
//接口
...
...
@@ -144,6 +158,8 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
//新增按钮
const
addDetail
=
()
=>
{
...
...
src/views/teacher/laboratoryManagement/teacher/PersonalLaboratoryApplyDetail.vue
View file @
28614cd6
...
...
@@ -4,11 +4,35 @@
</div>
<van-form>
<van-cell-group
inset
>
<div>
<div
v-if=
"name == '新增' && subSelect"
>
<van-field
v-model=
"formData.subName"
is-link
readonly
name=
"picker"
label=
"学科"
placeholder=
"点击选择学科"
@
click=
"showPickerSub = true"
:rules=
"[
{ required: true, message: '学科不能为空' }]"
/>
<van-popup
v-model:show=
"showPickerSub"
position=
"bottom"
>
<van-picker
:columns=
"columnsSub"
@
confirm=
"onConfirmSub"
@
cancel=
"showPickerSub = false"
/>
</van-popup>
</div>
<van-field
v-else
v-model=
"formData.sub"
readonly
label=
"学科"
:rules=
"[
{ required: true, message: '学科不能为空' }]"
/>
</div>
<van-field
readonly
v-model=
"formData.grade"
...
...
@@ -35,6 +59,7 @@
:readonly=
"name == '查看' ? true : false"
v-model=
"formData.experimentName"
label=
"实验名称"
:rules=
"[
{ required: true, message: '实验名称不能为空' }]"
/>
<van-field
v-if=
"name == '新增' ||name =='修改'"
...
...
@@ -45,6 +70,7 @@
label=
"计划开始时间"
placeholder=
"点击选择实验时间"
@
click=
"showStartCalendar = true"
:rules=
"[
{ required: true, message: '计划开始时间不能为空' }]"
/>
<van-calendar
v-model:show=
"showStartCalendar"
@
confirm=
"onConfirmStartTime"
/>
<van-field
...
...
@@ -56,6 +82,8 @@
label=
"计划结束时间"
placeholder=
"点击选择实验时间"
@
click=
"showEndCalendar = true"
:rules=
"[
{ required: true, message: '计划结束时间不能为空' }]"
/>
<van-calendar
v-model:show=
"showEndCalendar"
@
confirm=
"onConfirmEndTime"
/>
<div
v-if=
"name == '新增' ||name =='修改'"
>
...
...
@@ -65,6 +93,8 @@
v-model=
"formData.experimentClassify"
label=
"实验分类"
@
click=
"showPickerClassify = true"
:rules=
"[
{ required: true, message: '实验分类不能为空' }]"
/>
<van-popup
v-model:show=
"showPickerClassify"
position=
"bottom"
>
<van-picker
...
...
@@ -204,9 +234,12 @@ const name = route.query.name
const
submitSub
=
ref
();
const
gradeId
=
ref
();
const
submitSemester
=
ref
();
const
submitExperimentClassify
=
ref
()
const
submitExperimentClassify
=
ref
();
//学科是否展示下拉框
const
subSelect
=
ref
(
false
);
const
formData
=
reactive
({
sub
:
''
,
subName
:
''
,
grade
:
''
,
semester
:
''
,
experimentTime
:
''
,
...
...
@@ -223,17 +256,22 @@ const formData = reactive({
plannedStartTime
:
''
,
plannedEndTime
:
''
,
})
//学科下拉框
const
showPickerSub
=
ref
(
false
)
const
columnsSub
=
ref
([])
//实验分类下拉框
const
showPickerClassify
=
ref
(
false
);
const
columnsClassify
=
ref
([]);
//实验室下拉框
const
showPickerLab
=
ref
(
false
);
const
columnsLab
=
ref
([]);
//
const showPickerLab = ref(false);
//
const columnsLab = ref([]);
//节次下拉框
const
showPickerSection
=
ref
(
false
);
const
columnsSection
=
ref
([]);
//
const showPickerSection = ref(false);
//
const columnsSection = ref([]);
//班级下拉框
const
showPickerClass
=
ref
(
false
);
...
...
@@ -258,6 +296,7 @@ onMounted(async () => {
formData
.
sub
=
formData
.
sub
==
'1'
?
'物理'
:
formData
.
sub
==
'2'
?
'化学'
:
'生物'
;
formData
.
semester
=
formData
.
semester
==
'1'
?
'上学期'
:
'下学期'
;
formData
.
experimentClassify
=
formData
.
experimentClassify
==
'1'
?
'分组实验'
:
formData
.
experimentClassify
==
'2'
?
'演示实验'
:
'探究实验'
;
formData
.
labName
=
detailResult
.
data
.
schoolTeacherExperimentApplyLabsList
.
map
(
item
=>
item
.
labName
).
toString
()
}
if
(
name
==
'修改'
){
title
.
value
=
'修改教师演示实验室申请'
...
...
@@ -271,7 +310,21 @@ onMounted(async () => {
let
subjectResult
=
await
getSubject
()
console
.
log
(
'subjectResult'
,
subjectResult
)
if
(
subjectResult
.
code
==
200
){
formData
.
sub
=
subjectResult
.
msg
const
arr
=
Object
.
keys
(
subjectResult
.
data
)
console
.
log
(
'arr'
,
arr
)
if
(
arr
.
length
>
0
){
subSelect
.
value
=
true
columnsSub
.
value
=
arr
.
map
(
item
=>
{
console
.
log
(
item
,
subjectResult
.
data
[
item
])
return
{
text
:
item
,
value
:
subjectResult
.
data
[
item
]
}
})
console
.
log
(
'columnsSub.value'
,
columnsSub
.
value
)
}
else
{
subSelect
.
value
=
false
}
}
//获取级部和学期
...
...
@@ -295,29 +348,35 @@ onMounted(async () => {
}
//实验室下拉框
let
labResult
=
await
getLabList
()
console
.
log
(
'labResult'
,
labResult
)
if
(
labResult
.
code
==
200
){
columnsLab
.
value
=
labResult
.
rows
.
map
(
item
=>
{
return
{
text
:
item
.
labName
,
value
:
item
.
id
}
})
console
.
log
(
'columnsLab.value'
,
columnsLab
.
value
)
};
//
let labResult = await getLabList()
//
console.log('labResult',labResult)
//
if(labResult.code == 200){
//
columnsLab.value = labResult.rows.map(item => {
//
return{
//
text:item.labName,
//
value:item.id
//
}
//
})
//
console.log('columnsLab.value',columnsLab.value)
//
};
//节次下拉框
let
sectionResult
=
await
getDicts
(
'course_arrange'
)
console
.
log
(
'sectionResult'
,
sectionResult
)
if
(
sectionResult
.
code
==
200
){
sectionResult
.
data
.
forEach
(
ele
=>
{
columnsSection
.
value
.
push
({
text
:
ele
.
dictLabel
,
value
:
ele
.
dictValue
})
})
}
//
let sectionResult = await getDicts('course_arrange')
//
console.log('sectionResult',sectionResult)
//
if(sectionResult.code == 200){
//
sectionResult.data.forEach(ele => {
//
columnsSection.value.push({text:ele.dictLabel,value:ele.dictValue})
//
})
//
}
})
//学科选择
const
onConfirmSub
=
(
value
)
=>
{
console
.
log
(
'value'
,
value
)
formData
.
subName
=
value
.
text
;
formData
.
sub
=
value
.
value
;
showPickerSub
.
value
=
false
}
//实验类型选择
const
onConfirmClassify
=
(
value
)
=>
{
console
.
log
(
'value'
,
value
)
...
...
@@ -342,17 +401,17 @@ const onConfirmEndTime = (date) => {
//实验室分类下拉框
const
onConfirmLab
=
(
value
)
=>
{
formData
.
labName
=
value
.
text
;
formData
.
labNameId
=
value
.
value
;
showPickerLab
.
value
=
false
;
};
//
const onConfirmLab = (value) => {
//
formData.labName = value.text;
//
formData.labNameId = value.value;
//
showPickerLab.value = false;
//
};
//节次分类下拉框
const
onConfirmSection
=
(
value
)
=>
{
formData
.
section
=
value
.
text
;
formData
.
sectionId
=
value
.
value
;
showPickerSection
.
value
=
false
;
};
//
const onConfirmSection = (value) => {
//
formData.section = value.text;
//
formData.sectionId = value.value;
//
showPickerSection.value = false;
//
};
//班级分类下拉框
const
onConfirmClass
=
(
value
)
=>
{
...
...
@@ -410,6 +469,7 @@ const submit = async () => {
applyTime
:
formatDate
(
new
Date
()),
}
console
.
log
(
'新增data'
,
data
)
let
addResult
=
await
addPersonalApply
(
data
)
console
.
log
(
'addResult'
,
addResult
)
if
(
addResult
.
code
==
200
){
...
...
src/views/teacher/laboratoryManagement/teacher/laboratoryApplicationRecord.vue
View file @
28614cd6
...
...
@@ -31,8 +31,9 @@
:src=
"require('../../../../assets/icon/biology.png')"
></van-image>
<van-image
v-if=
"item.sub == '2'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/chemistry.png')"
></van-image>
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
<!--
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
-->
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
experimentName
}}
</span>
</div>
<div
class=
"topRight"
>
<div
v-if=
"item.applyState == '0'"
class=
"assigned"
>
未回复
</div>
...
...
@@ -105,16 +106,17 @@ const onLoad = async () => {
refreshing
.
value
=
false
;
}
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
)
{
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
// if (semester.value == '上学期' || semester.value == '1') {
// semester.value = '1'
// } else {
// semester.value = '2'
// }
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
semester
:
semester
.
value
,
querText
:
searchValue
.
value
,
userId
:
store
.
state
.
userInfo
.
userId
//
userId: store.state.userInfo.userId
}
console
.
log
(
'params'
,
params
)
//接口
...
...
@@ -130,6 +132,8 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
//card点击事件
...
...
src/views/teacher/laboratoryManagement/teacher/laboratoryArrangement.vue
View file @
28614cd6
...
...
@@ -29,10 +29,12 @@
<van-image
v-if=
"item.sub == '1'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/physics.png')"
></van-image>
<van-image
v-if=
"item.sub == '3'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/biology.png')"
></van-image>
<van-image
v-if=
"item.sub == '2'"
style=
"height: 20px;width: 20px;vertical-align: middle"
:src=
"require('../../../../assets/icon/chemistry.png')"
></van-image>
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
<!--
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
sub
==
'1'
?
'物理'
:
item
.
sub
==
'2'
?
'化学'
:
'生物'
}}
研究
</span>
-->
<span
style=
"font-size: 16px;font-weight: bold;padding-left: 5px"
>
{{
item
.
experimentName
}}
</span>
</div>
<div
class=
"topRight"
>
<div
class=
"assigned"
@
click=
"toApply(item.id)"
>
申请
</div>
<div
class=
"assigned"
@
click
.
stop
=
"toApply(item.id)"
>
申请
</div>
<!--
<div
class=
"unAssigned"
>
未分配
</div>
-->
</div>
</div>
...
...
@@ -78,6 +80,7 @@ const router = useRouter();
const
semester
=
ref
(
''
);
const
year
=
ref
(
''
);
const
searchValue
=
ref
(
''
);
//选中学年的参数
const
handleSelect
=
(
value
)
=>
{
console
.
log
(
'handleSelect'
,
value
)
...
...
@@ -102,16 +105,20 @@ const onLoad = async () => {
list
.
value
=
[];
refreshing
.
value
=
false
;
}
// if(semester.value == '上学期' ||semester.value == '1' ){
// semester.value = '1'
// }else{
// semester.value = '2'
// }
console
.
log
(
'semester.value'
,
semester
.
value
)
if
(
semester
.
value
==
'上学期'
||
semester
.
value
==
'1'
){
semester
.
value
=
'1'
}
else
{
semester
.
value
=
'2'
}
if
(
semester
.
value
){
const
params
=
{
schoolYear
:
year
.
value
,
//
schoolYear: year.value,
semester
:
semester
.
value
,
querText
:
searchValue
.
value
querText
:
searchValue
.
value
,
declareState
:
'3'
// applyId : store.state.userInfo.userId
}
console
.
log
(
'params'
,
params
)
//接口
...
...
@@ -127,6 +134,8 @@ const onLoad = async () => {
loading
.
value
=
false
;
return
;
}
}
}
//card点击事件
...
...
src/views/teacher/schoolProperty/borrowDetail.vue
View file @
28614cd6
...
...
@@ -22,7 +22,7 @@
<van-field
readonly
v-model=
"borrowForm.returnEquipmentCondition"
label=
"归还时设备情况"
/>
</div>
<van-field
:readonly=
"queryId ? true : false"
v-model=
"borrowForm.deadline"
label=
"借用期限(天)"
placeholder=
"请输入借用期限"
/>
placeholder=
"请输入借用期限"
:rules=
"[
{pattern:/^[0-9]*$/, message: '请输入数字',trigger:'onBlur'}]"
/>
</van-cell-group>
<div
v-if=
"queryId"
style=
"margin: 30px; display: flex;justify-content: center"
>
<van-button
round
type=
"success"
size=
"small"
style=
"width: 80px;margin-left: 20px;"
@
click=
"goback"
>
...
...
src/views/teacher/schoolProperty/borrowList.vue
View file @
28614cd6
...
...
@@ -55,7 +55,7 @@ const getCode = () => {
// router.push({
// path: "/schoolProperty/borrow/detail",
// query: {
// encode:'100
101202300003
'
// encode:'100
000202300024
'
// }
// })
}
...
...
src/views/teacher/schoolProperty/deviceList.vue
View file @
28614cd6
...
...
@@ -21,7 +21,7 @@
<van-button
size=
"small"
round
type=
"danger"
class=
"btn"
@
click=
"deleteDevice(item.id)"
>
删 除
</van-button>
</div>
<div
v-if=
"item.disposeState == 1"
>
<van-button
style=
"margin-right: 10px"
size=
"small"
round
type=
"success"
class=
"btn"
@
click=
"toDetail('反馈',item.id)"
>
反 馈
</van-button
>
<!--
<van-button
style=
"margin-right: 10px"
size=
"small"
round
type=
"success"
class=
"btn"
@
click=
"toDetail('反馈',item.id)"
>
反 馈
</van-button>
--
>
<van-button
size=
"small"
round
type=
"default"
class=
"btn"
@
click=
"toDetail('查看',item.id)"
>
查 看
</van-button>
</div>
<div
class=
"state"
>
...
...
src/views/teacher/schoolProperty/deviceListInfo.vue
View file @
28614cd6
...
...
@@ -337,7 +337,8 @@ const onSubmit = async () => {
reportRepairTime
:
fixForm
.
reportRepairTime
,
reportRepairId
:
fixForm
.
reportRepairId
,
reportRepair
:
fixForm
.
reportRepair
,
problem
:
fixForm
.
problem
problem
:
fixForm
.
problem
,
place
:
fixForm
.
place
}
console
.
log
(
'params'
,
params
)
let
result
=
await
editDevice
(
params
)
...
...
@@ -355,7 +356,9 @@ const onSubmit = async () => {
classificationCode
:
fixForm
.
classificationCode
,
reportRepairId
:
userId
,
reportRepair
:
fixForm
.
reportRepair
,
problem
:
fixForm
.
problem
problem
:
fixForm
.
problem
,
place
:
fixForm
.
place
,
}
console
.
log
(
'params'
,
params
)
let
result
=
await
addDevice
(
params
)
...
...
@@ -376,7 +379,8 @@ const feedBack = async () => {
repairId
:
fixForm
.
repairId
,
repairState
:
fixForm
.
repairState
,
repairPhone
:
fixForm
.
repairPhone
,
repairTime
:
fixForm
.
repairTime
repairTime
:
fixForm
.
repairTime
,
disposeState
:
'1'
}
console
.
log
(
'params'
,
params
)
let
result
=
await
submitFeedback
(
params
)
...
...
src/views/teacher/schoolProperty/returnDetail.vue
View file @
28614cd6
...
...
@@ -19,7 +19,29 @@
<!--
</div>
-->
<van-field
readonly
v-model=
"returnForm.deadline"
label=
"借用期限"
placeholder=
"请输入借用期限"
/>
<van-field
:readonly=
"queryId ? true : false"
v-model=
"returnForm.returnEquipmentCondition"
label=
"归还时设备情况"
/>
<div>
<van-field
v-if=
"queryId"
readonly
v-model=
"returnForm.returnEquipmentCondition"
label=
"归还时设备情况"
/>
<!--
<van-field
v-else
v-model=
"returnForm.returnEquipmentCondition"
label=
"归还时设备情况"
/>
-->
<van-field
v-else
v-model=
"returnForm.returnEquipmentConditionText"
is-link
readonly
name=
"picker"
label=
"归还时设备情况"
placeholder=
"点击选择归还时设备情况"
@
click=
"showPickerReturn = true"
/>
<van-popup
v-model:show=
"showPickerReturn"
position=
"bottom"
>
<van-picker
:columns=
"columnsReturn"
@
confirm=
"onConfirmReturn"
@
cancel=
"showPickerReturn = false"
/>
</van-popup>
</div>
<van-field
:readonly=
"queryId ? true : false"
v-model=
"returnForm.remark"
label=
"备注"
placeholder=
"请输入备注"
/>
</van-cell-group>
<div
v-if=
"queryId"
style=
"margin: 30px; display: flex;justify-content: center"
>
...
...
@@ -38,7 +60,10 @@
<
script
setup
>
import
moment
from
'moment'
;
import
{
returnEquipment
,
getEquipmentDetail
}
from
"@/service/schoolProperty"
import
{
returnEquipment
,
getEquipmentDetail
,
getDeatil
}
from
"@/service/schoolProperty"
import
{
getDicts
}
from
"@/service/studentCourseSelection"
;
import
{
reactive
,
ref
,
onMounted
}
from
"vue"
;
import
{
useRoute
,
useRouter
}
from
"vue-router"
;
import
{
Dialog
,
Toast
}
from
"vant"
;
...
...
@@ -53,9 +78,11 @@ console.log('queryEncode', queryEncode)
const
store
=
useStore
()
const
userName
=
store
.
state
.
userInfo
.
teacherName
const
userId
=
store
.
state
.
userInfo
.
userId
const
showPickerReturn
=
ref
(
false
);
const
columnsReturn
=
ref
([])
let
title
=
ref
(
''
)
// 页面标题
let
returnForm
=
reactive
({
// 表单数据
id
:
''
,
encode
:
''
,
//自编码
equipmentName
:
''
,
//设备名称
model
:
''
,
//型号
...
...
@@ -68,19 +95,45 @@ let returnForm = reactive({ // 表单数据
receivedBy
:
''
})
onMounted
(
async
()
=>
{
if
(
queryId
)
{
let
result
=
await
getEquipmentDetail
(
queryEncode
)
let
result
=
await
getDeatil
(
queryId
)
if
(
result
.
code
==
200
){
console
.
log
(
'result'
,
result
)
title
.
value
=
'归还情况查看'
Object
.
assign
(
returnForm
,
result
.
data
)
returnForm
.
borrowTime
=
result
.
data
.
borrowTime
returnForm
.
returnTime
=
result
.
data
.
returnTime
returnForm
.
deadline
=
returnForm
.
returnTime
-
returnForm
.
borrowTime
// returnForm.deadline = returnForm.returnTime - returnForm.borrowTime
returnForm
.
deadline
=
result
.
data
.
sjuseTime
}
let
dictList
=
await
getDicts
(
'equipment_state'
)
console
.
log
(
'dictList'
,
dictList
)
if
(
dictList
.
code
==
200
){
dictList
.
data
.
map
(
item
=>
{
if
(
returnForm
.
returnEquipmentCondition
==
item
.
dictValue
){
returnForm
.
returnEquipmentCondition
=
item
.
dictLabel
}
})
}
}
else
{
title
.
value
=
'物品归还'
//归还状态下拉框
let
dictList
=
await
getDicts
(
'equipment_state'
)
console
.
log
(
'dictList'
,
dictList
)
if
(
dictList
.
code
==
200
)
{
dictList
.
data
.
forEach
(
item
=>
{
columnsReturn
.
value
.
push
({
value
:
item
.
dictValue
,
text
:
item
.
dictLabel
})
})
}
let
equipmentRes
=
await
getEquipmentDetail
(
queryEncode
)
console
.
log
(
'equipmentRes'
,
equipmentRes
)
if
(
equipmentRes
.
code
==
3000
)
{
Dialog
.
alert
({
title
:
'提示'
,
...
...
@@ -116,6 +169,12 @@ onMounted(async () => {
}
});
//归还时设备情况确认
const
onConfirmReturn
=
(
value
)
=>
{
returnForm
.
returnEquipmentConditionText
=
value
.
text
;
returnForm
.
returnEquipmentCondition
=
value
.
value
;
showPickerReturn
.
value
=
false
;
};
//借用日期确认
const
onConfirmBorrowTime
=
(
date
)
=>
{
borrowTime
.
value
=
`
${
date
.
getFullYear
()}
-
${
date
.
getMonth
()
+
1
}
-
${
date
.
getDate
()}
`
...
...
@@ -140,7 +199,8 @@ const onSubmit = async () => {
remark
:
returnForm
.
remark
,
receivedById
:
userId
,
receivedBy
:
userName
,
equipmentId
:
returnForm
.
equipmentId
equipmentId
:
returnForm
.
equipmentId
,
sjuseTime
:
returnForm
.
deadline
}
console
.
log
(
'params'
,
params
)
let
result
=
await
returnEquipment
(
params
)
...
...
src/views/teacher/schoolProperty/returnList.vue
View file @
28614cd6
...
...
@@ -8,6 +8,7 @@
<van-list
v-model:loading=
"loading"
:finished=
"finished"
finished-text=
"没有更多了"
@
load=
"getList"
>
<div
v-for=
"(item,index) in list"
:key=
"index"
@
click=
"toDetailPage(item.id,item.encode)"
>
<div
v-if=
"item.returnState == 0"
class=
"listBlock"
>
<div
class=
"flexBLock"
>
<div>
<div>
型号:
{{
item
.
model
}}
</div>
...
...
@@ -23,7 +24,7 @@
<div>
借用期限(天)
</div>
</div>
</div>
<div>
备注:
已借用取回,暂不外借,设备换修。已借用取回,暂不外借,设备换修。
</div>
<div>
备注:
{{
item
.
remark
}}
</div>
<div
v-if=
"item.returnState == 0"
class=
"waitReturn"
>
待归还
</div>
<!--
<div
v-if=
"item.returnState == 1"
class=
"endReturn"
>
已归还
</div>
-->
</div>
...
...
@@ -34,12 +35,15 @@
<
script
setup
>
import
{
getEquipmentList
}
from
"@/service/schoolProperty"
import
{
getDicts
}
from
"@/service/studentCourseSelection"
;
import
{
useRouter
}
from
"vue-router"
;
import
{
onMounted
,
ref
,
reactive
}
from
"vue"
;
import
{
useStore
}
from
"vuex"
;
import
{
Toast
}
from
"vant"
;
import
{
scanCodeFun
}
from
"../../../utils/scanCode"
;
import
{
login
}
from
"../../../service/home"
;
const
router
=
useRouter
();
const
store
=
useStore
();
const
id
=
store
.
state
.
userInfo
.
userId
;
...
...
@@ -50,9 +54,14 @@ const pullLoading = ref(false);
const
finished
=
ref
(
false
);
const
pageNum
=
ref
(
0
);
const
equipmentName
=
ref
(
''
)
const
retrunDetail
=
ref
([])
onMounted
(
async
()
=>
{
let
dictList
=
await
getDicts
(
'equipment_state'
)
if
(
dictList
.
code
==
200
){
retrunDetail
.
value
=
dictList
.
data
console
.
log
(
'retrunDetail.value'
,
retrunDetail
.
value
)
}
})
//获取列表数据
const
getList
=
async
()
=>
{
...
...
@@ -65,10 +74,16 @@ const getList = async () => {
userId
:
id
,
}
let
result
=
await
getEquipmentList
(
params
)
console
.
log
(
'
resul
t'
,
result
)
console
.
log
(
'
lis
t'
,
result
)
if
(
result
.
code
==
200
){
loading
.
value
=
false
;
list
.
value
=
result
.
data
;
list
.
value
.
map
(
item
=>
{
const
same
=
retrunDetail
.
value
.
find
(
value
=>
item
.
returnEquipmentCondition
===
value
.
dictValue
)
if
(
same
){
item
.
returnEquipmentCondition
=
same
.
dictLabel
}
})
finished
.
value
=
true
}
else
{
Toast
(
"获取信息失败!"
);
...
...
@@ -97,15 +112,14 @@ const onSearch = async (val) =>{
}
//扫码获取
const
getCode
=
()
=>
{
// let enCode = scanCodeFun(store.state.appid,2) //获取到的设备自编码
let
enCode
=
scanCodeFun
(
2
)
//获取到的设备自编码
// console.log(1)
//测试
// router.push({
// path: "/schoolProperty/return/detail",
// query: {
// encode:'100
101202300003
'
// encode:'100
000202300026
'
// }
// })
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment