Merge remote-tracking branch 'origin/master'

hehai
zhiyong.ning 4 years ago
commit a800fc3da8
  1. 3
      src/main/java/com/msdw/tms/api/ClassTeachingApi.java
  2. 14
      src/main/java/com/msdw/tms/controller/ClassTeachingController.java
  3. 2
      src/main/java/com/msdw/tms/dao/ClassTeachingDao.java
  4. 30
      src/main/java/com/msdw/tms/entity/BroadcastEntity.java
  5. 2
      src/main/java/com/msdw/tms/service/ClassTeachingService.java
  6. 17
      src/main/java/com/msdw/tms/service/impl/ClassTeachingServiceImpl.java
  7. 2
      src/main/resources/application.yml
  8. 3
      src/main/resources/mapper/tms/ClassTeachingDao.xml

@ -18,4 +18,7 @@ public interface ClassTeachingApi {
@ApiOperation(value = "查看成绩",notes = "查看成绩")
R queryAchievement();
@ApiOperation(value = "查看虚拟仿真课程列表",notes = "查看虚拟仿真课程列表")
R querySimulationPlayList(Integer page,Integer size);
}

@ -3,6 +3,7 @@ package com.msdw.tms.controller;
import com.msdw.tms.api.ClassTeachingApi;
import com.msdw.tms.common.utils.PageUtils;
import com.msdw.tms.common.utils.R;
import com.msdw.tms.entity.BroadcastEntity;
import com.msdw.tms.entity.ExperimentalTeachingEntity;
import com.msdw.tms.entity.vo.ProjectRecordVo;
import com.msdw.tms.service.ClassTeachingService;
@ -96,4 +97,17 @@ public class ClassTeachingController implements ClassTeachingApi {
public R queryAchievement(){
return R.ok();
}
/**
* 查看虚拟仿真课程列表信息
* @param page
* @param size
* @return
*/
@Override
@GetMapping("/simulationPlayList")
public R querySimulationPlayList(@RequestParam Integer page,@RequestParam Integer size){
PageUtils page1 = classTeachingService.querySimulationPlayList(page,size);
return R.ok().put("data",page1);
}
}

@ -2,6 +2,7 @@ package com.msdw.tms.dao;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.msdw.tms.entity.BroadcastEntity;
import com.msdw.tms.entity.ExperimentalTeachingEntity;
import com.msdw.tms.entity.vo.ProjectRecordVo;
import org.apache.ibatis.annotations.Mapper;
@ -15,4 +16,5 @@ public interface ClassTeachingDao {
void updateSurplusTime(@Param("cla") ProjectRecordVo recordVo);
void updateSurplusTimeNull(@Param("cla") ProjectRecordVo recordVo);
IPage<BroadcastEntity> querySimulationPlayList(Page page1);
}

@ -0,0 +1,30 @@
package com.msdw.tms.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.experimental.Accessors;
@Data
@Accessors(chain = true)
@TableName("tms_broadcast")
public class BroadcastEntity {
/**
* 主键
*/
@TableId(type = IdType.AUTO)
private Integer id;
/**
* 视频/文档链接
*/
private String links;
/**
* 存活状态0存在1已删除
*/
private Integer isdel;
/**
* 视频/文档标题
*/
private String title;
}

@ -9,4 +9,6 @@ public interface ClassTeachingService {
ExperimentalTeachingEntity queryInvitationcode(ExperimentalTeachingEntity experimentalTeachingEntity);
PageUtils queryClassRecord(Integer page, Integer size, ProjectRecordVo recordVo);
PageUtils querySimulationPlayList(Integer page,Integer size);
}

@ -5,7 +5,9 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.msdw.tms.common.utils.Constant;
import com.msdw.tms.common.utils.PageUtils;
import com.msdw.tms.dao.ClassTeachingDao;
import com.msdw.tms.entity.BroadcastEntity;
import com.msdw.tms.entity.ExperimentalTeachingEntity;
import com.msdw.tms.entity.ProjectRecordEntity;
import com.msdw.tms.entity.vo.ProjectRecordVo;
import com.msdw.tms.service.ClassTeachingService;
import org.apache.poi.ss.formula.functions.T;
@ -43,4 +45,19 @@ public class ClassTeachingServiceImpl implements ClassTeachingService {
PageUtils pageUtils = new PageUtils(schoolRecord);
return pageUtils;
}
@Override
public PageUtils querySimulationPlayList(Integer page,Integer size){
new BroadcastEntity().setIsdel(Constant.IsDel.NOT_DEL.getType());
//分页对象
Page<T> page1 = new Page<>(page, size);
IPage<BroadcastEntity> broadcastEntity = this.classMapper.querySimulationPlayList(page1);
PageUtils questionsPage = new PageUtils(broadcastEntity);
return questionsPage;
}
}

@ -11,7 +11,7 @@ spring:
# url: jdbc:mysql://localhost:3306/msdw_tms?useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai
# username: root
# password: root
driver-class-name: com.mysql.jdbc.Driver
driver-class-name: com.mysql.cj.jdbc.Driver
# redis:
# host: www.liuwanr.cn
# port: 6379

@ -43,4 +43,7 @@
AND is_del=0
</update>
<select id="querySimulationPlayList" resultType="com.msdw.tms.entity.BroadcastEntity">
SELECT id,title,links,isdel FROM tms_broadcast
</select>
</mapper>
Loading…
Cancel
Save