更新修改

dev
lion 1 year ago
parent 414031a65a
commit c2a7e10fb7

@ -35,7 +35,6 @@
</div> </div>
<div> <div>
<span>同行人</span> <span>同行人</span>
<span> <span>
<template v-if="submitObj.appointment_accompany&&submitObj.appointment_accompany.length>0"> <template v-if="submitObj.appointment_accompany&&submitObj.appointment_accompany.length>0">
<template v-for="item in submitObj.appointment_accompany"> <template v-for="item in submitObj.appointment_accompany">
@ -58,6 +57,13 @@
</template> </template>
</span> </span>
</div> </div>
<div v-if="submitObj.status===1">
<span>预约二维码链接</span>
<span>
<a :href="baseUrl+submitObj.h5_url" target="_blank" style="color:blue">{{baseUrl}}{{submitObj.h5_url}}</a>
</span>
</div>
<div v-if="type==='show'"> <div v-if="type==='show'">
<span>审核意见</span> <span>审核意见</span>
<span> <span>
@ -149,6 +155,7 @@
id: '', id: '',
submitObj: {}, submitObj: {},
thirdArr: [], thirdArr: [],
baseUrl:`${process.env.VUE_APP_BASE_API}`,
form: { form: {
name: '', name: '',
}, },

@ -40,7 +40,7 @@
</div> </div>
<div> <div>
<xy-table :list="list" :total="total" @pageIndexChange="pageIndexChange" @pageSizeChange="pageSizeChange" <xy-table :list="list" :showIndexFixed="'left'" :total="total" @pageIndexChange="pageIndexChange" @pageSizeChange="pageSizeChange"
:table-item="table_item"> :table-item="table_item">
<template v-slot:status> <template v-slot:status>
<el-table-column align='center' label="状态" width="120" header-align="center"> <el-table-column align='center' label="状态" width="120" header-align="center">
@ -60,7 +60,7 @@
</template> </template>
<template v-slot:btns> <template v-slot:btns>
<el-table-column align='center' label="操作" width="220" header-align="center"> <el-table-column align='center' fixed="right" label="操作" width="220" header-align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="primary" size="small" v-if="scope.row.status>0" <el-button type="primary" size="small" v-if="scope.row.status>0"
@click="checkBook('show',scope.row.id)">查看</el-button> @click="checkBook('show',scope.row.id)">查看</el-button>

@ -82,7 +82,7 @@
let _except = [] let _except = []
// //
if (this.tableName === 'users') { if (this.tableName === 'users') {
_except = ['plate', 'is_import', 'is_vip', 'is_schoolmate', 'appointment_total', 'letter', 'score', 'code', _except = ['introduce','honour','company_need_fund','company_other','remark','plate', 'is_import', 'is_vip', 'is_schoolmate', 'appointment_total', 'letter', 'score', 'code',
'pid' 'pid'
] ]
} }
@ -128,9 +128,14 @@
} }
// + // +
if (this.tableName === 'users') { if (this.tableName === 'users') {
b.unshift({
key: 'status',
title: '审核状态',
width: 120
});
b.unshift({ b.unshift({
key: 'course_name', key: 'course_name',
title: '课程名字', title: '课程名',
width: 120 width: 120
}); });
} }
@ -211,10 +216,10 @@
console.log("data", data) console.log("data", data)
if (this.tableName === 'course_keeps') { if (this.tableName === 'course_keeps') {
data.push(['(上传前请删除示例)', '', '', '']) data.push(['(上传前请删除示例)', '', '', ''])
data.push(['(请设置单元格格式为文本格式)2024-09-03', 'xxx', '出勤/缺勤']) data.push(['2024-09-03', 'xxx', '出勤/缺勤'])
}else if (this.tableName === 'course_contents') { }else if (this.tableName === 'course_contents') {
data.push(['(上传前请删除示例)', '', '', '']) data.push(['(上传前请删除示例)', '', '', ''])
data.push(['(请设置单元格格式为文本格式)2024-09-03', '上午13:00-14:00', '王老师', '《战略思维2》', '苏州大学', '老师简介']) data.push(['2024-09-03', '上午13:00-14:00', '王老师', '《战略思维2》', '苏州大学', '老师简介'])
}else if(this.tableName === 'course_signs'){ }else if(this.tableName === 'course_signs'){
data.push(['(请确保学员联系方式不为空)', '', '', '']) data.push(['(请确保学员联系方式不为空)', '', '', ''])
} }

@ -0,0 +1,191 @@
<template>
<div>
<xy-dialog ref="dialog" :width="70" :is-show.sync="isShow" :type="'form'"
:title="type === 'add' ? '新增校友捐赠' : '编辑校友捐赠'" :form="form" :rules='rules' @submit="submit">
<template v-slot:username>
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;">*</span>姓名
</div>
<div class="xy-table-item-content">
<el-input v-model="form.username" placeholder="请输入姓名" clearable style="width: 100%;"></el-input>
</div>
</div>
</template>
<template v-slot:course>
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;">*</span>就读班级
</div>
<div class="xy-table-item-content">
<el-select v-model="form.course" placeholder="请选择就读班级" clearable style="width: 100%;">
<el-option v-for="(item,index) in course_options" :key="index" :label="item.value" :value="item.value">
</el-option>
</el-select>
</div>
</div>
</template>
<template v-slot:mobile>
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;">*</span>联系方式
</div>
<div class="xy-table-item-content">
<el-input v-model="form.mobile" placeholder="请输入联系方式" clearable style="width: 100%;"></el-input>
</div>
</div>
</template>
<template v-slot:company_name>
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;"></span>公司名称
</div>
<div class="xy-table-item-content">
<el-input v-model="form.company_name" placeholder="请输入公司名称" clearable style="width: 100%;"></el-input>
</div>
</div>
</template>
<template v-slot:company_position>
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;"></span>职务
</div>
<div class="xy-table-item-content">
<el-input v-model="form.company_position" placeholder="请输入职务" clearable style="width: 100%;"></el-input>
</div>
</div>
</template>
<template v-slot:donate>
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;"></span>我希望捐赠
</div>
<div class="xy-table-item-content">
<el-input v-model="form.donate" placeholder="请输入" type="textarea" clearable style="width: 100%;"></el-input>
</div>
</div>
</template>
</xy-dialog>
</div>
</template>
<script>
import {
save,
show
} from "@/api/system/baseForm.js"
export default {
components: {
},
data() {
return {
isShow: false,
type: 'add',
id: '',
table_name: 'donates',
course_options:[{
label: '高研班|第一期高级科创人才研修班',
value: '高研班|第一期高级科创人才研修班'
}, {
label: '高研班|第二期高级科创人才研修班',
value: '高研班|第二期高级科创人才研修班'
},{
label: '高研班|第三期高级科创人才研修班',
value: '高研班|第三期高级科创人才研修班'
}, {
label: '高研班|第四期高级科创人才研修班',
value: '高研班|第四期高级科创人才研修班'
},{
label: '高研班|第五期高级科创人才研修班',
value: '高研班|第五期高级科创人才研修班'
}, {
label: '高研班|第六期高级科创人才研修班',
value: '高研班|第六期高级科创人才研修班'
}, {
label: '其他',
value: '其他'
}],
form: {
username: '',
course: '',
mobile: '',
company_name: '',
company_position: '',
donate: ''
},
rules: {
username: [{
required: true,
message: '请输入姓名'
}],
course: [{
required: true,
message: '请选择就读班级'
}],
mobile: [{
required: true,
message: '请输入联系方式'
}],
mobile: [{
required: true,
message: '请输入联系方式'
}]
}
}
},
created() {},
methods: {
submit() {
if (this.id) {
this.form.id = this.id
}
if (this.type == 'add') {
this.form.id = ''
}
console.log("this.form",this.form)
save({
table_name: this.table_name,
...this.form
}).then(res => {
this.$message({
type: 'success',
message: this.type === 'add' ? '新增成功' : '编辑成功'
})
this.isShow = false
this.$emit('refresh')
})
},
getDetail() {
show({
id: this.id,
table_name: this.table_name,
}).then(res => {
this.form = this.base.requestToForm(res, this.form)
})
}
},
watch: {
isShow(newVal) {
if (newVal) {
if (this.type === 'editor') {
this.getDetail()
}
} else {
this.id = ''
this.type = "add"
this.$refs['dialog'].reset()
}
},
}
}
</script>
<style scoped lang="scss">
</style>

@ -0,0 +1,198 @@
<template>
<div>
<div>
<div ref="lxHeader">
<lx-header icon="md-apps" :text="$route.meta.title" style="margin-bottom: 10px; border: 0px; margin-top: 15px">
<div slot="content">
<div class="searchwrap" style="display: flex;align-items: center;">
<div>
<el-input v-model="select.username" placeholder="请输入姓名"></el-input>
</div>
<div>
<el-select v-model="select.course" placeholder="请选择就读班级" clearable>
<el-option v-for="(item,index) in course_options" :key="index" :label="item.value" :value="item.value">
</el-option>
</el-select>
</div>
<div>
<el-button type="primary" size="small" @click="select.page=1,getList()"></el-button>
</div>
<div>
<el-button type="primary" size="small" @click="editNotice('add')"></el-button>
</div>
</div>
</div>
</lx-header>
</div>
</div>
<div>
<xy-table :list="list" :total="total" @pageIndexChange="pageIndexChange" @pageSizeChange="pageSizeChange"
:table-item="table_item">
<template v-slot:btns>
<el-table-column align='center' fixed="right" label="操作" width="180" header-align="center">
<template slot-scope="scope">
<el-button type="primary" size="small" @click="editNotice('editor',scope.row.id)"></el-button>
<el-popconfirm style="margin:0 10px" @confirm="deleteList(scope.row.id)" title="确定删除吗?">
<el-button type="danger" size="small" slot="reference">删除</el-button>
</el-popconfirm>
</template>
</el-table-column>
</template>
</xy-table>
</div>
<add-donate ref="addDonate" @refresh="getList"></add-donate>
</div>
</template>
<script>
import addDonate from './components/addDonate.vue';
import {
index,
destroy
} from "@/api/system/baseForm.js"
export default {
components: {
addDonate
},
data() {
return {
select: {
username:'',
course:'',
table_name: 'donates',
page: 1,
page_size: 10
},
course_options:[{
label: '高研班|第一期高级科创人才研修班',
value: '高研班|第一期高级科创人才研修班'
}, {
label: '高研班|第二期高级科创人才研修班',
value: '高研班|第二期高级科创人才研修班'
},{
label: '高研班|第三期高级科创人才研修班',
value: '高研班|第三期高级科创人才研修班'
}, {
label: '高研班|第四期高级科创人才研修班',
value: '高研班|第四期高级科创人才研修班'
},{
label: '高研班|第五期高级科创人才研修班',
value: '高研班|第五期高级科创人才研修班'
}, {
label: '高研班|第六期高级科创人才研修班',
value: '高研班|第六期高级科创人才研修班'
}, {
label: '其他',
value: '其他'
}],
list: [],
total: 0,
table_item: [{
prop: 'username',
label: '姓名',
align: 'left',
width: 160,
}, {
prop: 'course',
label: '就读班级',
align: 'left',
// width:240
}, {
prop: 'mobile',
label: '联系方式',
align: 'center',
width: 160,
}, {
prop: 'company_name',
label: '公司名称',
align: 'left',
width: 240,
}, {
prop: 'company_position',
label: '职务',
align: 'center',
width: 160,
}, {
prop: 'donate',
label: '我希望捐赠',
align: 'center',
width: 240,
}]
}
},
created() {
this.getList()
},
methods: {
pageIndexChange(e) {
this.select.page = e
this.getList()
},
pageSizeChange(e) {
this.select.page_size = e
this.select.page = 1
this.getList()
},
editNotice(type, id) {
if (type == 'editor') {
this.$refs.addDonate.id = id
}
this.$refs.addDonate.type = type
this.$refs.addDonate.isShow = true
},
async getList() {
const res = await index({
page_size: this.select.page_size,
page: this.select.page,
table_name: this.select.table_name,
filter:[{
key:'username',
op:'like',
value:this.select.username
},{
key:'course',
op:'like',
value:this.select.course
}]
})
this.list = res.data
this.total = res.total
},
deleteList(id) {
var that = this;
destroy({
id: id,
table_name: this.select.table_name
}).then(response => {
this.$Message.success('操作成功');
this.getList()
}).catch(error => {
console.log(error)
reject(error)
})
},
}
}
</script>
<style lang="scss" scoped>
.searchwrap {
display: flex;
align-items: center;
&>div {
display: flex;
align-items: center;
margin-right: 10px;
span {
min-width: 70px;
}
}
}
</style>

@ -261,7 +261,7 @@
<Button ghost type="primary" v-if="active===1" @click="active=0"></Button> <Button ghost type="primary" v-if="active===1" @click="active=0"></Button>
<!-- <Button ghost type="primary" v-if="active===0" @click="next"></Button> --> <!-- <Button ghost type="primary" v-if="active===0" @click="next"></Button> -->
<Button type="primary" ghost @click="checkSubmit" v-if="active===0"></Button> <Button type="primary" ghost @click="checkSubmit" v-if="active===0"></Button>
<Button type="primary" @click="closeSubmit"></Button> <!-- <Button type="primary" @click="closeSubmit"></Button> -->
</template> </template>

@ -23,22 +23,19 @@
</template> </template>
{{student_info[item.field]?student_info[item.field]:''}} {{student_info[item.field]?student_info[item.field]:''}}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item v-if="type==='check' || type==='checkshow' || type==='setPosition'"> <el-descriptions-item :span="2" v-if="type==='check' || type==='checkshow' || type==='setPosition'">
<template slot="label"> <template slot="label">
本班职务 本班职务
</template> </template>
{{sign_result.position?sign_result.position:''}} {{sign_result.position?sign_result.position:''}}
</el-descriptions-item> </el-descriptions-item>
</el-descriptions>
</div>
<!-- 报名信息 --> <!-- 报名信息 -->
<template v-if="sign_info.length>0"> <template v-if="sign_info.length>0">
<lx-header v-if="type==='check' || type==='checkshow' || type==='setPosition'" icon="" text="报名信息" <!-- <lx-header v-if="type==='check' || type==='checkshow' || type==='setPosition'" icon="" text="报名信息"
style="margin-bottom: 10px; border: 0px; margin-top: 15px"> style="margin-bottom: 10px; border: 0px; margin-top: 15px">
</lx-header> </lx-header> -->
<div v-if="type==='check' || type==='checkshow' || type==='setPosition'"> <template v-if="type==='check' || type==='checkshow' || type==='setPosition'">
<el-descriptions class="margin-top" :column="2" border> <!-- <el-descriptions class="margin-top" :column="2" border> -->
<template v-for="item in sign_info"> <template v-for="item in sign_info">
<el-descriptions-item :span="2" v-if="item.submit_files && item.submit_files.length>0"> <el-descriptions-item :span="2" v-if="item.submit_files && item.submit_files.length>0">
<template slot="label"> <template slot="label">
@ -50,7 +47,7 @@
</template> </template>
</div> </div>
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item v-else> <el-descriptions-item v-else :span="2">
<template slot="label"> <template slot="label">
{{item.name}} {{item.name}}
</template> </template>
@ -59,9 +56,13 @@
</template> </template>
<!-- </el-descriptions> -->
</template>
</template>
</el-descriptions> </el-descriptions>
</div> </div>
</template>
<!-- 审核查看 --> <!-- 审核查看 -->
<lx-header v-if="type=='checkshow' || type=='check'" icon="" text="审核结果" <lx-header v-if="type=='checkshow' || type=='check'" icon="" text="审核结果"
@ -297,9 +298,11 @@
let _arr = [] let _arr = []
if (res.data && Array.isArray(res.data)) { if (res.data && Array.isArray(res.data)) {
res.data.map(item => { res.data.map(item => {
if(item.edit_input==='files'){
if (!this.base.isNull(item.value) && item.value.indexOf("/storage/files/") !== -1) { if (!this.base.isNull(item.value) && item.value.indexOf("/storage/files/") !== -1) {
item.submit_files = item.value.split(",") item.submit_files = item.value.split(",")
} }
}
// //
if (!this.student_info.hasOwnProperty(item.field)) { if (!this.student_info.hasOwnProperty(item.field)) {
console.log("item.field") console.log("item.field")

Loading…
Cancel
Save