|
@@ -2,27 +2,14 @@
|
|
<div>
|
|
<div>
|
|
<section class="content">
|
|
<section class="content">
|
|
<div class="box box-info">
|
|
<div class="box box-info">
|
|
- <!-- 头信息 -->
|
|
|
|
<div class="box-header with-border">
|
|
<div class="box-header with-border">
|
|
<h3 class="box-title">课程列表</h3>
|
|
<h3 class="box-title">课程列表</h3>
|
|
- <div class="box-tools pull-right">
|
|
|
|
- <button
|
|
|
|
- type="button"
|
|
|
|
- class="btn btn-box-tool"
|
|
|
|
- data-widget="collapse"
|
|
|
|
- >
|
|
|
|
- <i class="fa fa-minus"></i>
|
|
|
|
- </button>
|
|
|
|
- </div>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
- <!-- 正文信息 -->
|
|
|
|
<div
|
|
<div
|
|
- class="box-body"
|
|
|
|
v-loading.body="fileLoading"
|
|
v-loading.body="fileLoading"
|
|
element-loading-text="课程上传中,请稍后..."
|
|
element-loading-text="课程上传中,请稍后..."
|
|
>
|
|
>
|
|
- <!-- 表单 -->
|
|
|
|
<el-form
|
|
<el-form
|
|
:inline="true"
|
|
:inline="true"
|
|
:model="formSearch"
|
|
:model="formSearch"
|
|
@@ -35,14 +22,14 @@
|
|
class="input_width_lg"
|
|
class="input_width_lg"
|
|
placeholder="请输入课程名称"
|
|
placeholder="请输入课程名称"
|
|
v-model="formSearch.name"
|
|
v-model="formSearch.name"
|
|
- ></el-input>
|
|
|
|
|
|
+ />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="课程代码" class="pull-left">
|
|
<el-form-item label="课程代码" class="pull-left">
|
|
<el-input
|
|
<el-input
|
|
class="input_width_lg"
|
|
class="input_width_lg"
|
|
placeholder="请输入课程代码"
|
|
placeholder="请输入课程代码"
|
|
v-model="formSearch.code"
|
|
v-model="formSearch.code"
|
|
- ></el-input>
|
|
|
|
|
|
+ />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="课程状态" class="pull-left">
|
|
<el-form-item label="课程状态" class="pull-left">
|
|
<el-select
|
|
<el-select
|
|
@@ -56,8 +43,7 @@
|
|
:label="item.label"
|
|
:label="item.label"
|
|
:value="item.value"
|
|
:value="item.value"
|
|
:key="item.value"
|
|
:key="item.value"
|
|
- >
|
|
|
|
- </el-option>
|
|
|
|
|
|
+ />
|
|
</el-select>
|
|
</el-select>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="层次" class="pull-left">
|
|
<el-form-item label="层次" class="pull-left">
|
|
@@ -72,8 +58,7 @@
|
|
:label="item.label"
|
|
:label="item.label"
|
|
:value="item.value"
|
|
:value="item.value"
|
|
:key="item.value"
|
|
:key="item.value"
|
|
- >
|
|
|
|
- </el-option>
|
|
|
|
|
|
+ />
|
|
</el-select>
|
|
</el-select>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="专业" class="pull-left" prop="specialtyId">
|
|
<el-form-item label="专业" class="pull-left" prop="specialtyId">
|
|
@@ -92,8 +77,7 @@
|
|
:label="item.name"
|
|
:label="item.name"
|
|
:value="item.id"
|
|
:value="item.id"
|
|
:key="item.id"
|
|
:key="item.id"
|
|
- >
|
|
|
|
- </el-option>
|
|
|
|
|
|
+ />
|
|
</el-select>
|
|
</el-select>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item class="pull-right">
|
|
<el-form-item class="pull-right">
|
|
@@ -145,7 +129,7 @@
|
|
v-model="courseForm.code"
|
|
v-model="courseForm.code"
|
|
auto-complete="off"
|
|
auto-complete="off"
|
|
placeholder="请输入课程代码"
|
|
placeholder="请输入课程代码"
|
|
- ></el-input>
|
|
|
|
|
|
+ />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-row>
|
|
</el-row>
|
|
<el-row>
|
|
<el-row>
|
|
@@ -155,7 +139,7 @@
|
|
v-model="courseForm.name"
|
|
v-model="courseForm.name"
|
|
auto-complete="off"
|
|
auto-complete="off"
|
|
placeholder="请输入课程名称"
|
|
placeholder="请输入课程名称"
|
|
- ></el-input>
|
|
|
|
|
|
+ />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-row>
|
|
</el-row>
|
|
<el-row>
|
|
<el-row>
|
|
@@ -171,8 +155,7 @@
|
|
:label="item.label"
|
|
:label="item.label"
|
|
:value="item.value"
|
|
:value="item.value"
|
|
:key="item.value"
|
|
:key="item.value"
|
|
- >
|
|
|
|
- </el-option>
|
|
|
|
|
|
+ />
|
|
</el-select>
|
|
</el-select>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-row>
|
|
</el-row>
|
|
@@ -218,18 +201,22 @@
|
|
:auto-upload="false"
|
|
:auto-upload="false"
|
|
:multiple="false"
|
|
:multiple="false"
|
|
>
|
|
>
|
|
- <el-button size="small" slot="trigger" type="primary"
|
|
|
|
- >选择文件</el-button
|
|
|
|
- >
|
|
|
|
- <el-button size="small" type="success" @click="submitUpload"
|
|
|
|
- >确认上传</el-button
|
|
|
|
- >
|
|
|
|
- <el-button size="small" type="danger" @click="removeFile"
|
|
|
|
- >清空文件</el-button
|
|
|
|
- >
|
|
|
|
- <el-button size="small" type="info" @click="exportFile"
|
|
|
|
- >下载模板</el-button
|
|
|
|
|
|
+ <el-button size="small" slot="trigger" type="primary">
|
|
|
|
+ 选择文件
|
|
|
|
+ </el-button>
|
|
|
|
+ <el-button
|
|
|
|
+ size="small"
|
|
|
|
+ type="success"
|
|
|
|
+ @click="submitUpload"
|
|
>
|
|
>
|
|
|
|
+ 确认上传
|
|
|
|
+ </el-button>
|
|
|
|
+ <el-button size="small" type="danger" @click="removeFile">
|
|
|
|
+ 清空文件
|
|
|
|
+ </el-button>
|
|
|
|
+ <el-button size="small" type="info" @click="exportFile">
|
|
|
|
+ 下载模板
|
|
|
|
+ </el-button>
|
|
<div slot="tip" class="el-upload__tip">
|
|
<div slot="tip" class="el-upload__tip">
|
|
只能上传xlsx文件
|
|
只能上传xlsx文件
|
|
</div>
|
|
</div>
|
|
@@ -271,14 +258,14 @@
|
|
class="input_width_lg"
|
|
class="input_width_lg"
|
|
placeholder="请输入专业名称"
|
|
placeholder="请输入专业名称"
|
|
v-model="specialtySearchForm.name"
|
|
v-model="specialtySearchForm.name"
|
|
- ></el-input>
|
|
|
|
|
|
+ />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="专业代码" class="pull-left">
|
|
<el-form-item label="专业代码" class="pull-left">
|
|
<el-input
|
|
<el-input
|
|
class="input_width_lg"
|
|
class="input_width_lg"
|
|
placeholder="请输入专业代码"
|
|
placeholder="请输入专业代码"
|
|
v-model="specialtySearchForm.code"
|
|
v-model="specialtySearchForm.code"
|
|
- ></el-input>
|
|
|
|
|
|
+ />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item class="pull-right">
|
|
<el-form-item class="pull-right">
|
|
<el-button
|
|
<el-button
|
|
@@ -286,14 +273,16 @@
|
|
type="primary"
|
|
type="primary"
|
|
icon="search"
|
|
icon="search"
|
|
@click="searchSpecialtyPage"
|
|
@click="searchSpecialtyPage"
|
|
- >查询
|
|
|
|
|
|
+ >
|
|
|
|
+ 查询
|
|
</el-button>
|
|
</el-button>
|
|
<el-button
|
|
<el-button
|
|
size="small"
|
|
size="small"
|
|
type="primary"
|
|
type="primary"
|
|
icon="search"
|
|
icon="search"
|
|
@click="addRelation"
|
|
@click="addRelation"
|
|
- >新增
|
|
|
|
|
|
+ >
|
|
|
|
+ 新增
|
|
</el-button>
|
|
</el-button>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-row>
|
|
</el-row>
|
|
@@ -305,13 +294,10 @@
|
|
border
|
|
border
|
|
style="width: 100%;text-align:center;"
|
|
style="width: 100%;text-align:center;"
|
|
>
|
|
>
|
|
- <el-table-column prop="id" label="ID" width="150">
|
|
|
|
- </el-table-column>
|
|
|
|
- <el-table-column prop="name" label="专业名称" width="250">
|
|
|
|
- </el-table-column>
|
|
|
|
- <el-table-column prop="code" label="专业代码"> </el-table-column>
|
|
|
|
- <el-table-column prop="updateTime" label="更新时间" width="170">
|
|
|
|
- </el-table-column>
|
|
|
|
|
|
+ <el-table-column prop="id" label="ID" width="150" />
|
|
|
|
+ <el-table-column prop="name" label="专业名称" width="250" />
|
|
|
|
+ <el-table-column prop="code" label="专业代码" />
|
|
|
|
+ <el-table-column prop="updateTime" label="更新时间" width="170" />
|
|
<el-table-column label="操作">
|
|
<el-table-column label="操作">
|
|
<div slot-scope="scope">
|
|
<div slot-scope="scope">
|
|
<span>
|
|
<span>
|
|
@@ -333,8 +319,7 @@
|
|
:page-size="10"
|
|
:page-size="10"
|
|
layout="total, prev, pager, next, jumper"
|
|
layout="total, prev, pager, next, jumper"
|
|
:total="specialtyTotal"
|
|
:total="specialtyTotal"
|
|
- >
|
|
|
|
- </el-pagination>
|
|
|
|
|
|
+ />
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
|
|
@@ -365,15 +350,14 @@
|
|
:label="item.name"
|
|
:label="item.name"
|
|
:value="item.id"
|
|
:value="item.id"
|
|
:key="item.id"
|
|
:key="item.id"
|
|
- >
|
|
|
|
- </el-option>
|
|
|
|
|
|
+ />
|
|
</el-select>
|
|
</el-select>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-row>
|
|
</el-row>
|
|
<el-row class="pull_center">
|
|
<el-row class="pull_center">
|
|
- <el-button type="primary" @click="submitAddRelationForm"
|
|
|
|
- >保 存</el-button
|
|
|
|
- >
|
|
|
|
|
|
+ <el-button type="primary" @click="submitAddRelationForm">
|
|
|
|
+ 保 存
|
|
|
|
+ </el-button>
|
|
<el-button @click="addRelationDialog = false;">取 消</el-button>
|
|
<el-button @click="addRelationDialog = false;">取 消</el-button>
|
|
</el-row>
|
|
</el-row>
|
|
</el-form>
|
|
</el-form>
|
|
@@ -383,70 +367,55 @@
|
|
<el-table
|
|
<el-table
|
|
:data="tableData"
|
|
:data="tableData"
|
|
border
|
|
border
|
|
|
|
+ resizable
|
|
|
|
+ stripe
|
|
style="width: 100%;text-align:center;"
|
|
style="width: 100%;text-align:center;"
|
|
@selection-change="selectChange"
|
|
@selection-change="selectChange"
|
|
>
|
|
>
|
|
- <el-table-column type="selection" width="50"></el-table-column>
|
|
|
|
- <el-table-column prop="id" label="课程ID" width="150">
|
|
|
|
- </el-table-column>
|
|
|
|
- <el-table-column prop="name" label="课程名称" width="250">
|
|
|
|
- </el-table-column>
|
|
|
|
- <el-table-column prop="code" label="课程代码"> </el-table-column>
|
|
|
|
|
|
+ <el-table-column type="selection" width="50" />
|
|
|
|
+ <el-table-column prop="id" label="课程ID" width="80" />
|
|
|
|
+ <el-table-column prop="name" label="课程名称" width="180" />
|
|
|
|
+ <el-table-column prop="code" label="课程代码" />
|
|
<el-table-column label="层次">
|
|
<el-table-column label="层次">
|
|
- <template slot-scope="scope">
|
|
|
|
- <div>
|
|
|
|
- <span>{{ getLevel(scope.row.level) }}</span>
|
|
|
|
- </div>
|
|
|
|
- </template>
|
|
|
|
|
|
+ <span slot-scope="scope">{{ getLevel(scope.row.level) }}</span>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="状态" width="70">
|
|
<el-table-column label="状态" width="70">
|
|
- <template slot-scope="scope">
|
|
|
|
- <div>
|
|
|
|
- <span>
|
|
|
|
- <el-tag :type="getTag(scope.row.enable)">
|
|
|
|
- {{ getEnable(scope.row.enable) }}
|
|
|
|
- </el-tag>
|
|
|
|
- </span>
|
|
|
|
- </div>
|
|
|
|
- </template>
|
|
|
|
- </el-table-column>
|
|
|
|
- <el-table-column prop="updateTime" label="更新时间" width="170">
|
|
|
|
|
|
+ <span slot-scope="scope">
|
|
|
|
+ <el-tag :type="getTag(scope.row.enable)">
|
|
|
|
+ {{ getEnable(scope.row.enable) }}
|
|
|
|
+ </el-tag>
|
|
|
|
+ </span>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
|
|
+ <el-table-column prop="updateTime" label="更新时间" width="170" />
|
|
<el-table-column label="操作">
|
|
<el-table-column label="操作">
|
|
- <template slot-scope="scope">
|
|
|
|
- <div>
|
|
|
|
- <el-button size="mini" type="primary" @click="relation(row);">
|
|
|
|
- 关联专业
|
|
|
|
|
|
+ <div slot-scope="scope">
|
|
|
|
+ <el-button size="mini" type="primary" @click="relation(row);">
|
|
|
|
+ 关联专业
|
|
|
|
+ </el-button>
|
|
|
|
+ <span>
|
|
|
|
+ <el-button size="mini" type="info" @click="editCourse(row);">
|
|
|
|
+ <i class="el-icon-edit"></i> 修改
|
|
</el-button>
|
|
</el-button>
|
|
- <span>
|
|
|
|
- <el-button
|
|
|
|
- size="mini"
|
|
|
|
- type="info"
|
|
|
|
- @click="editCourse(row);"
|
|
|
|
- >
|
|
|
|
- <i class="el-icon-edit"></i> 修改
|
|
|
|
- </el-button>
|
|
|
|
- </span>
|
|
|
|
- <span v-if="!scope.row.enable">
|
|
|
|
- <el-button
|
|
|
|
- size="mini"
|
|
|
|
- type="success"
|
|
|
|
- @click="enableById(row);"
|
|
|
|
- >
|
|
|
|
- <i class="fa fa-check" aria-hidden="true"></i>启用
|
|
|
|
- </el-button>
|
|
|
|
- </span>
|
|
|
|
- <span v-if="scope.row.enable">
|
|
|
|
- <el-button
|
|
|
|
- size="mini"
|
|
|
|
- type="warning"
|
|
|
|
- @click="disableById(row);"
|
|
|
|
- >
|
|
|
|
- <i class="fa fa-close" aria-hidden="true"></i>禁用
|
|
|
|
- </el-button>
|
|
|
|
- </span>
|
|
|
|
- </div>
|
|
|
|
- </template>
|
|
|
|
|
|
+ </span>
|
|
|
|
+ <span v-if="!scope.row.enable">
|
|
|
|
+ <el-button
|
|
|
|
+ size="mini"
|
|
|
|
+ type="success"
|
|
|
|
+ @click="enableById(row);"
|
|
|
|
+ >
|
|
|
|
+ <i class="fa fa-check" aria-hidden="true"></i>启用
|
|
|
|
+ </el-button>
|
|
|
|
+ </span>
|
|
|
|
+ <span v-if="scope.row.enable">
|
|
|
|
+ <el-button
|
|
|
|
+ size="mini"
|
|
|
|
+ type="warning"
|
|
|
|
+ @click="disableById(row);"
|
|
|
|
+ >
|
|
|
|
+ <i class="fa fa-close" aria-hidden="true"></i>禁用
|
|
|
|
+ </el-button>
|
|
|
|
+ </span>
|
|
|
|
+ </div>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
<div class="page pull-right">
|
|
<div class="page pull-right">
|
|
@@ -768,7 +737,6 @@ export default {
|
|
"?" +
|
|
"?" +
|
|
param;
|
|
param;
|
|
this.$http.get(url).then(response => {
|
|
this.$http.get(url).then(response => {
|
|
- console.log(response);
|
|
|
|
this.tableData = response.data.content;
|
|
this.tableData = response.data.content;
|
|
this.total = response.data.totalElements;
|
|
this.total = response.data.totalElements;
|
|
});
|
|
});
|