fix:作品模块、公司简介、在线报名模块优化
This commit is contained in:
parent
51e28181e4
commit
04951d9fa8
@ -38,18 +38,19 @@
|
||||
</el-dropdown>
|
||||
</el-space>
|
||||
<!-- 数据表格 -->
|
||||
<DataTable ref="tableRef" v-loading="loading" style="width: 100%" :onSelectionChange="data => (selectionData = data)"
|
||||
:column="column" :params="params" :request="params => tableDataInit(params)">
|
||||
<DataTable :header-cell-style="{ 'text-align': 'center' }" :cell-style="{ 'text-align': 'center' }" ref="tableRef"
|
||||
v-loading="loading" style="width: 100%" :onSelectionChange="data => (selectionData = data)" :column="column"
|
||||
:params="params" :request="params => tableDataInit(params)">
|
||||
<!-- 简介图片 -->
|
||||
<template #company_profile_img="scope">
|
||||
<el-image v-if="scope.row.company_profile_img" :src="scope.row.company_profile_img.split(',')[0]" lazy
|
||||
:preview-src-list="scope.row.company_profile_img.split(',')" :preview-teleported="true"
|
||||
:hide-on-click-modal="true" fit="contain" class="el-avatar-plus"></el-image>
|
||||
:hide-on-click-modal="true" fit="contain" class="el-avatar"></el-image>
|
||||
<template v-else>暂无图片</template>
|
||||
</template>
|
||||
<!-- 简介内容 -->
|
||||
<template #company_profile_content="scope">
|
||||
<div style="height: 300px;" v-html="scope.row.company_profile_content"></div>
|
||||
<div style="height: 150px;" v-html="scope.row.company_profile_content"></div>
|
||||
</template>
|
||||
<!-- 排序 -->
|
||||
<template #company_profile_order="scope">
|
||||
@ -129,7 +130,7 @@ const column = [
|
||||
{
|
||||
prop: "company_profile_img",
|
||||
label: '简介图片',
|
||||
width: '300'
|
||||
width: '200'
|
||||
},
|
||||
{
|
||||
prop: "company_profile_content",
|
||||
@ -145,7 +146,7 @@ const column = [
|
||||
{
|
||||
label: '操作',
|
||||
prop: 'chaoz',
|
||||
width: '250',
|
||||
width: '200',
|
||||
fixed: 'right'
|
||||
}
|
||||
];
|
||||
@ -213,10 +214,13 @@ watch(drag, () => {
|
||||
const loading = ref(false)
|
||||
async function handleEditOrder(data) {
|
||||
loading.value = true
|
||||
const { code } = await editCompanyProfile(data);
|
||||
const { code, msg } = await editCompanyProfile(data);
|
||||
if (code == 0) {
|
||||
loading.value = false
|
||||
tableRef.value.reload()
|
||||
ElMessage.success(msg);
|
||||
} else {
|
||||
ElMessage.error(msg);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -75,8 +75,9 @@
|
||||
</el-dropdown>
|
||||
</el-space>
|
||||
<!-- 数据表格 -->
|
||||
<DataTable ref="tableRef" style="width: 100%" :onSelectionChange="data => (selectionData = data)" :column="column"
|
||||
:params="params" :request="params => getSignupList(params)">
|
||||
<DataTable :header-cell-style="{ 'text-align': 'center' }" :cell-style="{ 'text-align': 'center' }" ref="tableRef"
|
||||
style="width: 100%" :onSelectionChange="data => (selectionData = data)" :column="column" :params="params"
|
||||
:request="params => getSignupList(params)">
|
||||
<!-- 所属班级 -->
|
||||
<template #classes_name="scope">
|
||||
<el-tag type='warning'>{{ scope.row.classes_name }} </el-tag>
|
||||
@ -220,7 +221,7 @@ const column = [
|
||||
{
|
||||
label: '操作',
|
||||
prop: 'chaoz',
|
||||
width: '250',
|
||||
width: '200',
|
||||
fixed: 'right'
|
||||
}
|
||||
];
|
||||
|
@ -64,7 +64,8 @@
|
||||
</el-dropdown>
|
||||
</el-space>
|
||||
<!-- 数据表格 -->
|
||||
<DataTable ref="tableRef" style="width: 100%" v-loading="loading" :onSelectionChange="data => (selectionData = data)"
|
||||
<DataTable ref="tableRef" style="width: 100%" :header-cell-style="{ 'text-align': 'center' }"
|
||||
:cell-style="{ 'text-align': 'center' }" v-loading="loading" :onSelectionChange="data => (selectionData = data)"
|
||||
:column="column" :params="params" :request="params => tableDataInit(params)">
|
||||
<!-- 图片 -->
|
||||
<template #works_img="scope">
|
||||
@ -144,6 +145,7 @@ const EditWorksDialogVisible = ref(false);
|
||||
const EditWorksDialogRow = ref({});
|
||||
const DetailWorksDialogVisible = ref(false);
|
||||
const DetailWorksDialogRow = ref({});
|
||||
const loading = ref(false)
|
||||
|
||||
const headers = {
|
||||
Accept: "application/json",
|
||||
@ -166,17 +168,18 @@ const column = [
|
||||
{
|
||||
prop: "works_img",
|
||||
label: '作品图片',
|
||||
width: '250'
|
||||
width: '150'
|
||||
},
|
||||
{
|
||||
prop: "works_name",
|
||||
label: '作品名称',
|
||||
width: '150'
|
||||
width: '150',
|
||||
showOverflowTooltip: true,
|
||||
},
|
||||
{
|
||||
prop: "works_type_name",
|
||||
label: '作品类型',
|
||||
width: '150'
|
||||
width: '125'
|
||||
},
|
||||
{
|
||||
prop: "works_author",
|
||||
@ -186,7 +189,7 @@ const column = [
|
||||
{
|
||||
prop: "classes_name",
|
||||
label: '班型',
|
||||
width: '150'
|
||||
width: '125'
|
||||
},
|
||||
{
|
||||
prop: "works_likes_count",
|
||||
@ -249,23 +252,27 @@ watch(drag, () => {
|
||||
})
|
||||
|
||||
//排序
|
||||
const loading = ref(false)
|
||||
async function handleEditOrder(data) {
|
||||
loading.value = true
|
||||
const { code } = await editWorks(data);
|
||||
const { code, msg } = await editWorks(data);
|
||||
if (code == 0) {
|
||||
loading.value = false
|
||||
tableRef.value.reload()
|
||||
ElMessage.success(msg);
|
||||
} else {
|
||||
ElMessage.error(msg);
|
||||
}
|
||||
}
|
||||
|
||||
//点赞
|
||||
async function handleEditLikeCount(data) {
|
||||
loading.value = true
|
||||
const { code } = await editWorks(data);
|
||||
const { code, msg } = await editWorks(data);
|
||||
if (code == 0) {
|
||||
loading.value = false
|
||||
tableRef.value.reload()
|
||||
} else {
|
||||
ElMessage.error(msg);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -45,11 +45,11 @@
|
||||
</el-dropdown>
|
||||
</el-space>
|
||||
<!-- 数据表格 -->
|
||||
<el-table v-loading="loading" :data="dataList" ref="tableRef" border highlight-current-row
|
||||
<el-table v-loading="loading" :header-cell-style="{'text-align':'center'}" :cell-style="{'text-align':'center'}" :data="dataList" ref="tableRef" border highlight-current-row
|
||||
:onSelectionChange="data => (selectionData = data)" :default-expand-all="tableExpandAll" row-key="works_type_guid"
|
||||
:tree-props="{ children: 'children' }">
|
||||
<el-table-column type="selection" width="50" align="center" />
|
||||
<el-table-column prop="works_type_name" width="200" label="作品类型名称" :show-overflow-tooltip="true"> </el-table-column>
|
||||
<el-table-column prop="works_type_name" width="120" label="作品类型名称" :show-overflow-tooltip="true"> </el-table-column>
|
||||
<el-table-column sortable prop="works_type_order" width="200" label="排序" sort>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model='scope.row.works_type_order' controls-position="right"
|
||||
@ -143,8 +143,13 @@ function handleDetail(row) {
|
||||
//排序
|
||||
async function handleEditOrder(data) {
|
||||
loading.value = true
|
||||
await editWorksType(data);
|
||||
const { code, msg } = await editWorksType(data);
|
||||
if (code == 0) {
|
||||
ElMessage.success(msg);
|
||||
getList();
|
||||
} else {
|
||||
ElMessage.error(msg);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user