|
@@ -70,6 +70,10 @@
|
|
|
:value="item.id"
|
|
|
></el-option>
|
|
|
</el-select>
|
|
|
+ <div class="typeCheck">
|
|
|
+ <el-switch v-model="typeCheck"></el-switch
|
|
|
+ ><span>查看所有学生</span>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -1191,8 +1195,21 @@ export default {
|
|
|
isPre: false,
|
|
|
isNext: false,
|
|
|
checkJson: [],
|
|
|
+ typeCheck: false,
|
|
|
};
|
|
|
},
|
|
|
+ watch: {
|
|
|
+ typeCheck(newValue, oldValue) {
|
|
|
+ this.loading = true;
|
|
|
+ this.tableData = [];
|
|
|
+ if (newValue) {
|
|
|
+ this.getWorks1();
|
|
|
+ } else {
|
|
|
+ this.page = 1;
|
|
|
+ this.getWorks();
|
|
|
+ }
|
|
|
+ },
|
|
|
+ },
|
|
|
mounted() {
|
|
|
this.$nextTick(function () {
|
|
|
this.tableHeight =
|
|
@@ -1828,6 +1845,26 @@ export default {
|
|
|
console.error(err);
|
|
|
});
|
|
|
},
|
|
|
+ getWorks1() {
|
|
|
+ this.isLoading = true;
|
|
|
+ let params = {
|
|
|
+ cid: this.id,
|
|
|
+ uname: this.uname,
|
|
|
+ stage: this.chooseDy,
|
|
|
+ task: this.chooseTask,
|
|
|
+ };
|
|
|
+ this.ajax
|
|
|
+ .get(this.$store.state.api + "getCourseWorks4", params)
|
|
|
+ .then((res) => {
|
|
|
+ this.isLoading = false;
|
|
|
+ this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
|
|
|
+ this.tableData = res.data[0];
|
|
|
+ })
|
|
|
+ .catch((err) => {
|
|
|
+ this.isLoading = false;
|
|
|
+ console.error(err);
|
|
|
+ });
|
|
|
+ },
|
|
|
getCourseDetail() {
|
|
|
let params = {
|
|
|
cid: this.cid,
|
|
@@ -3555,4 +3592,15 @@ export default {
|
|
|
.allRightBox {
|
|
|
padding: 10px 12px;
|
|
|
}
|
|
|
+.typeCheck {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: flex-end;
|
|
|
+ margin-left: 10px;
|
|
|
+ /* margin-bottom: 20px; */
|
|
|
+}
|
|
|
+
|
|
|
+.typeCheck > span {
|
|
|
+ margin-left: 10px;
|
|
|
+}
|
|
|
</style>
|