소스 검색

信息化办公设备

长阳分支中职
yxq 1 개월 전
부모
커밋
5d5628eb1c
1개의 변경된 파일41개의 추가작업 그리고 13개의 파일을 삭제
  1. +41
    -13
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OfficeEquipment/single.vue

+ 41
- 13
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OfficeEquipment/single.vue 파일 보기

@@ -1,11 +1,15 @@
<template>
<view class="page">
<view v-if="ready">
<l-select @input="setValue('OfficeEquipment.Name', $event)" :value="getValue('OfficeEquipment.Name')"
:range="dataSource.OfficeEquipment.Name" title="姓名" required />
<l-select @input="setValue('OfficeEquipment.Department', $event)"
<!-- <l-select @input="setValue('OfficeEquipment.Name', $event)" :value="getValue('OfficeEquipment.Name')"
:range="dataSource.OfficeEquipment.Name" title="姓名" required /> -->
<l-organize-picker @input="setValue('OfficeEquipment.Name', $event)"
:value="getValue('OfficeEquipment.Name')" type="user" title="姓名" required :readonly="!edit"/>
<l-organize-picker @input="setValue('OfficeEquipment.Department', $event)"
:value="getValue('OfficeEquipment.Department')" type="department" title="部门" required :readonly="!edit"/>
<!-- <l-select @input="setValue('OfficeEquipment.Department', $event)"
:value="getValue('OfficeEquipment.Department')" :range="dataSource.OfficeEquipment.Department"
title="部门" required />
title="部门" required /> -->
<l-input @input="setValue('OfficeEquipment.Code', $event)" :value="getValue('OfficeEquipment.Code')"
:disabled="!edit" title="设备编号" required />
<l-input @input="setValue('OfficeEquipment.DeviceName', $event)"
@@ -67,22 +71,33 @@
scheme: {
OfficeEquipment: {
Name: {
type: 'select',title:'姓名',verify: "NotNull"
type: 'select',
title: '姓名',
verify: "NotNull"
},
Department: {
type: 'select',title:'部门',verify: "NotNull"
type: 'select',
title: '部门',
verify: "NotNull"
},
Code: {
type: 'text',title:'设备编号',verify: "NotNull"
type: 'text',
title: '设备编号',
verify: "NotNull"
},
DeviceName: {
type: 'text',title:'设备名称',verify: "NotNull"
type: 'text',
title: '设备名称',
verify: "NotNull"
},
Description: {
type: 'text',title:'配置描述',verify: "NotNull"
type: 'text',
title: '配置描述',
verify: "NotNull"
},
Remark: {
type: 'text',title:'备注'
type: 'text',
title: '备注'
}
},
},
@@ -117,7 +132,9 @@
this.FETCH_DATASOURCE('teacheruserdata').then(result => {
this.dataSource.OfficeEquipment.Name = result.data.map(t => ({
text: t.f_realname,
value: t.f_encode
value: t.f_encode,
f_encode: t.f_encode,
f_userid: t.f_userid,
}));
}),
this.FETCH_DATASOURCE('classdata').then(result => {
@@ -143,9 +160,13 @@
// this.origin.OfficeEquipment.Department = userInfo.departmentId
} else {
const result = await this.HTTP_GET('/Learun/adms/EducationalAdministration/officeEquipment/form',
this
.id)
this.id)
this.origin = await this.formatFormData(result)
let arr = this.dataSource.OfficeEquipment.Name
let obj = arr.find(e => e.f_encode == this.origin.OfficeEquipment.Name)
this.origin.OfficeEquipment.Name = obj ? obj.f_userid : this.origin.OfficeEquipment.Name

}
this.current = this.COPY(this.origin)
},
@@ -175,6 +196,13 @@

this.LOADING('正在提交...')
const postData = await this.getPostData(this.id)
let strEntity = JSON.parse(postData.strEntity)

let arr = this.dataSource.OfficeEquipment.Name
let obj = arr.find(e => e.f_userid == strEntity.Name)
strEntity.Name = obj ? obj.f_encode : strEntity.Name

postData.strEntity = JSON.stringify(strEntity)
this.HTTP_POST('/Learun/adms/EducationalAdministration/OfficeEquipment/save', postData, '提交失败')
.then(success => {
this.HIDE_LOADING()


불러오는 중...
취소
저장