Browse Source

学生请假未完成

新疆警官学校中职
ndbs 1 year ago
parent
commit
ec805d5939
4 changed files with 179 additions and 56 deletions
  1. +53
    -19
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/Check/list.vue
  2. +30
    -11
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/Check/single.vue
  3. +65
    -18
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/list.vue
  4. +31
    -8
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/single.vue

+ 53
- 19
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/Check/list.vue View File

@@ -26,7 +26,7 @@
</view> -->


<view class="customlist-item-field">
<!-- <view class="customlist-item-field">
<text class="customlist-item-field-title">审核时间:</text>
{{ displayListItem(item, "CheckTime") }}
</view>
@@ -34,7 +34,7 @@
<view class="customlist-item-field">
<text class="customlist-item-field-title">审核人:</text>
{{ displayListItem(item, "CheckUserNo") }}
</view>
</view> -->

<view class="customlist-item-field">
<text class="customlist-item-field-title">请假类型:</text>
@@ -120,6 +120,12 @@
title="请假类型" placeholder="按请假类型查询" />
<l-select v-model="queryData.CheckStatus" @change="searchChange" :range="dataSource.CheckStatus"
title="审核状态" placeholder="按审核状态查询" />
<l-input
v-model="queryData.StuName"
@change="searchChange"
title ="姓名"
placeholder="按姓名查询"
/>
<!-- 重置查询条件按钮 -->
<view class="padding-tb">
<l-button @click="reset" line="orange" class="block" block>重置查询条件</l-button>
@@ -224,6 +230,7 @@
queryData: {
LeaveType: "",
CheckStatus: '',
StuName:'',
// CreateUser: "",
},

@@ -239,10 +246,31 @@
value: t.value,
text: t.text
})),
CheckStatus: Object.values(this.GET_GLOBAL('dataDictionary').LeaveCheck).map(t => ({
value: t.value,
text: t.text
})),
// CheckStatus: Object.values(this.GET_GLOBAL('dataDictionary').LeaveCheck).map(t => ({
// value: t.value,
// text: t.text
// })),
CheckStatus:[
{
value:'0',
text:'草稿'
},
{
value:'1',
text:'审核中'
},
{
value:'2',
text:'审核通过'
},
{
value:'3',
text:'审核未通过'
}
],
},

// 页面相关参数
@@ -391,7 +419,6 @@
this.NAV_TO(`./single?type=edit&id=${id}`);
return;
case "join":
// console.log(123);
this.NAV_TO(`/pages/EducationalAdministration/StuLeaveManagement/Check/list?meetId=${id}`);
return;

@@ -414,15 +441,16 @@
return;

case 'check':
await this.HTTP_GET('/Learun/adms/EducationalAdministration/StuLeaveManagement/ischeck', id)
.then(res => {
if (res) {
this.NAV_TO(`./single?type=edit&id=${id}`)
return
} else {
return;
}
})
this.NAV_TO(`./single?type=edit&id=${id}`)
// await this.HTTP_GET('/Learun/adms/EducationalAdministration/StuLeaveManagement/ischeck', id)
// .then(res => {
// if (res) {
// this.NAV_TO(`./single?type=edit&id=${id}`)
// return
// } else {
// return;
// }
// })
return;

default:
@@ -475,10 +503,16 @@
},
// 审核状态
CheckStatusitem(data) {
if (data) {
return data == '1' ? '通过' : '不通过'
if (data == '0') {
return '草稿'
} else if(data == '1') {
return '审核中'
} else if(data == '2') {
return '审核通过'
} else if(data == '3') {
return '审核未通过'
} else {
return '申请中'
return data
}
},
// 请假类型审核


+ 30
- 11
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/Check/single.vue View File

@@ -1,15 +1,24 @@
<template>
<view class="page">
<view v-if="ready">
<l-select
<!-- <l-select
@input="setValue('StuLeaveManagement.CheckStatus', $event)"
:value="getValue('StuLeaveManagement.CheckStatus')"
:range="dataSource.StuLeaveManagement.CheckStatus"
title="审核状态"
:disabled="!edit"
required
/>
<l-textarea
/> -->
<l-input
@input="setValue('StuLeaveManagement.CheckStatus', $event)"
:value=" CheckStatusitem(getValue('StuLeaveManagement.CheckStatus'))"
title="审核状态"
required
:disabled="!edit"
/>
<!-- <l-textarea
@input="setValue('StuLeaveManagement.CheckRemark', $event)"
:value="getValue('StuLeaveManagement.CheckRemark')"
title="审核备注"
@@ -29,7 +38,7 @@
title="审核人"
v-if="!edit"
:disabled="!edit"
/>
/> -->
<l-select
@input="setValue('StuLeaveManagement.LeaveType', $event)"
:value="getValue('StuLeaveManagement.LeaveType')"
@@ -188,7 +197,7 @@ export default {
// 表单项数据结构
scheme: {
StuLeaveManagement: {
CheckStatus: { type: 'select', title: '审核状态', dataSource: '0',verify:"NotNull" },
CheckStatus: { type: 'text', title: '审核状态' },
CheckRemark: { type: 'texteditor', title: '审核备注', },
CheckTime:{ type: 'text', title: '审核人' },
CheckUserNo: { type: 'select', title: '审核人',dataSource: '1' },
@@ -220,7 +229,7 @@ export default {
ClassDiredctorNo:[],
CheckUserNo:[],
LeaveType: Object.values(this.GET_GLOBAL('dataDictionary').LeaveType).map(t => ({ value: t.value, text: t.text })),
CheckStatus: Object.values(this.GET_GLOBAL('dataDictionary').LeaveCheck).map(t => ({ value: t.value, text: t.text }))
// CheckStatus: Object.values(this.GET_GLOBAL('dataDictionary').LeaveCheck).map(t => ({ value: t.value, text: t.text }))
}
}
}
@@ -242,7 +251,6 @@ export default {
// 拉取表单数据,同时拉取所有来自数据源的选单数据
await Promise.all([
this.FETCH_DATASOURCE('bjsj').then(result => {
console.log(result)
this.dataSource.StuLeaveManagement.ClassNo = result.data.sort((a,b)=>{return b.classno-a.classno}).map(t => ({ text: t.classname, value: t.classno }))
}),
this.FETCH_DATASOURCE('EmpInfo').then(result => {
@@ -258,7 +266,6 @@ export default {
this.dataSource.StuLeaveManagement.DeptNo = result.data.map(t => ({ text: t.deptname, value: t.deptno }));
}),
this.FETCH_DATASOURCE('CdMajorInfo').then(result => {
console.log()
this.dataSource.StuLeaveManagement.MajorNo = result.data.map(t => ({ text: t.majorname, value: t.majorno }));
}),
])
@@ -275,7 +282,6 @@ export default {
} else {
const result = await this.HTTP_GET('/Learun/adms/EducationalAdministration/StuLeaveManagement/form', this.id)
this.origin = await this.formatFormData(result)
// console.log(this.origin,this.origin.prototype)
}
this.current = this.COPY(this.origin)
},
@@ -293,7 +299,6 @@ export default {
break

case 'save':
// console.log(this.current)
const verifyResult = this.verifyForm()
if (verifyResult.length > 0) {
this.CONFIRM('表单验证失败', verifyResult.join('\n'))
@@ -350,7 +355,21 @@ export default {
// 设置表单值
setValue(path, val) {
set(this.current, path, val)
}
},
// 审核状态
CheckStatusitem(data) {
if (data == '0') {
return '草稿'
} else if(data == '1') {
return '审核中'
} else if(data == '2') {
return '审核通过'
} else if(data == '3') {
return '审核未通过'
} else {
return data
}
},
}
}
</script>


+ 65
- 18
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/list.vue View File

@@ -19,15 +19,15 @@
{{ CheckStatusitem(displayListItem(item, "CheckStatus")) }}
</view>

<view class="customlist-item-field">
<!-- <view class="customlist-item-field">
<text class="customlist-item-field-title">审核备注:</text>
{{ displayListItem(item, "CheckRemark") }}
</view>
</view> -->

<view class="customlist-item-field">
<!-- <view class="customlist-item-field">
<text class="customlist-item-field-title">审核人:</text>
{{ displayListItem(item, "CheckUserNo") }}
</view>
</view> -->

<view class="customlist-item-field">
<text class="customlist-item-field-title">请假类型:</text>
@@ -94,9 +94,11 @@
{{ displayListItem(item, "ClassTutorNo") }}
</view>

<l-customlist-action @join="action('join', item.Id)" :showEdit="!item.CheckStatus"
@edit="action('edit', item.Id)" :showDelete="!item.CheckStatus"
@delete="action('delete', item.Id)" @view="action('view', item.Id)" />
<l-customlist-action
:showButton="item.CheckStatus ==0 && user.userId == item.CreateUserId" buttonText="提交" @join="action('join', item.Id)"
:showEdit="item.CheckStatus ==0 && user.userId == item.CreateUserId" @edit="action('edit', item.Id)"
:showDelete="item.CheckStatus ==0 && user.userId == item.CreateUserId" @delete="action('delete', item.Id)"
@view="action('view', item.Id)" />
</view>
</l-customlist>
</l-scroll-list>
@@ -228,10 +230,24 @@
value: t.value,
text: t.text
})),
CheckStatus: Object.values(this.GET_GLOBAL('dataDictionary').LeaveCheck).map(t => ({
value: t.value,
text: t.text
})),
CheckStatus:[
{
value:'0',
text:'草稿'
},
{
value:'1',
text:'审核中'
},
{
value:'2',
text:'审核通过'
},
{
value:'3',
text:'审核未通过'
}
],
},

// 页面相关参数
@@ -384,9 +400,19 @@
this.NAV_TO(`./single?type=edit&id=${id}`);
return;
case "join":
// console.log(123);
this.NAV_TO(`/pages/EducationalAdministration/StuLeaveManagement/list?meetId=${id}`);
return;
if (!(await this.CONFIRM('提交项目', '确定要提交该项吗?', true))) {
return
}
this.HTTP_POST('/Learun/adms/EducationalAdministration/StuLeaveManagement/submit', id, '提交失败')
.then(success => {
if (!success) {
return
}
this.TOAST('提交成功', 'success')
this.refreshList()
})
return

case "delete":
if (!(await this.CONFIRM("删除项目", "确定要删除该项吗?", true))) {
@@ -405,7 +431,22 @@
this.refreshList();
});
return;

case 'check':
if (!(await this.CONFIRM('提交项目', '确定要提交该项吗?', true))) {
return
}
this.HTTP_POST('/learun/adms/FundsApply/submit', id, '提交失败')
.then(success => {
if (!success) {
return
}
this.TOAST('提交成功', 'success')
this.refreshList()
})
return
default:
return;
}
@@ -456,10 +497,16 @@
},
// 审核状态
CheckStatusitem(data) {
if (data) {
return data == '1' ? '通过' : '不通过'
if (data == '0') {
return '草稿'
} else if(data == '1') {
return '审核中'
} else if(data == '2') {
return '审核通过'
} else if(data == '3') {
return '审核未通过'
} else {
return '申请中'
return data
}
},
// 请假类型审核


+ 31
- 8
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuLeaveManagement/single.vue View File

@@ -1,15 +1,24 @@
<template>
<view class="page">
<view v-if="ready">
<l-select
<!-- <l-select
@input="setValue('StuLeaveManagement.CheckStatus', $event)"
:value="getValue('StuLeaveManagement.CheckStatus')"
:range="dataSource.StuLeaveManagement.CheckStatus"
title="审核状态"
:disabled="!edit"
v-if="!edit"
/>
<l-textarea
/> -->
<l-input
@input="setValue('StuLeaveManagement.CheckStatus', $event)"
:value=" CheckStatusitem(getValue('StuLeaveManagement.CheckStatus'))"
title="审核状态"
:disabled="!edit"
v-if="!edit"
/>
<!-- <l-textarea
@input="setValue('StuLeaveManagement.CheckRemark', $event)"
:value="getValue('StuLeaveManagement.CheckRemark')"
title="审核备注"
@@ -23,7 +32,7 @@
title="审核人"
v-if="!edit"
:disabled="!edit"
/>
/> -->
<l-select
@input="setValue('StuLeaveManagement.LeaveType', $event)"
:value="getValue('StuLeaveManagement.LeaveType')"
@@ -196,7 +205,7 @@ export default {
// 表单项数据结构
scheme: {
StuLeaveManagement: {
CheckStatus: { type: 'select', title: '审核状态', dataSource: '0' },
CheckStatus: { type: 'text', title: '审核状态' },
CheckRemark: { type: 'texteditor', title: '审核备注', },
CreateUserNo: { type: 'text', title: '学号' },
LeaveType: { type: 'select', title: '请假类型', dataSource: '0',verify:"NotNull" },
@@ -230,7 +239,7 @@ export default {
ClassDiredctorNo:[],
CheckUserNo:[],
LeaveType: Object.values(this.GET_GLOBAL('dataDictionary').LeaveType).map(t => ({ value: t.value, text: t.text })),
CheckStatus: Object.values(this.GET_GLOBAL('dataDictionary').LeaveCheck).map(t => ({ value: t.value, text: t.text }))
// CheckStatus: Object.values(this.GET_GLOBAL('dataDictionary').LeaveCheck).map(t => ({ value: t.value, text: t.text }))
}
}
}
@@ -255,7 +264,6 @@ export default {
// this.dataSource.StuLeaveManagement.CheckStatus = result.data.map(t => ({ text: t.name, value: t.id }))
// }),
this.FETCH_DATASOURCE('bjsj').then(result => {
console.log(result)
this.dataSource.StuLeaveManagement.ClassNo = result.data.sort((a,b)=>{return b.classno-a.classno}).map(t => ({ text: t.classname, value: t.classno }))
}),
this.FETCH_DATASOURCE('EmpInfo').then(result => {
@@ -374,7 +382,22 @@ export default {
// 设置表单值
setValue(path, val) {
set(this.current, path, val)
}
},
// 审核状态
CheckStatusitem(data) {
// console.log(data)
if (data == '0') {
return '草稿'
} else if(data == '1') {
return '审核中'
} else if(data == '2') {
return '审核通过'
} else if(data == '3') {
return '审核未通过'
} else {
return data
}
},
}
}
</script>


Loading…
Cancel
Save