Package com.secondstack.training.spring.extjs.domain

Examples of com.secondstack.training.spring.extjs.domain.Lecture


    @RequestMapping(params = {"id"}, method = RequestMethod.GET)
    @ResponseBody
    public Lecture findById(@RequestParam("id")Integer id){
        logger.debug("Received rest request to get data lecture");
        Lecture lecture = lectureRepository.findOne(id);
        return lecture;
    }
View Full Code Here


        entityManager.persist(lecture);
    }

    @Override
    public Lecture update(Integer id, Lecture lecture) {
        Lecture oldLecture = findById(id);
        oldLecture.setSemester(lecture.getSemester());
        oldLecture.setSubject(lecture.getSubject());
        oldLecture.setTeacher(lecture.getTeacher());
        oldLecture.setYear(lecture.getYear());
        return entityManager.merge(oldLecture);
    }
View Full Code Here

TOP

Related Classes of com.secondstack.training.spring.extjs.domain.Lecture

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.