dcs 11 mesi fa
parent
commit
05ca01ae25

+ 125 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/controller/MeetingMinutesController.java

@@ -0,0 +1,125 @@
+package com.bosshand.virgo.api.controller;
+
+import com.bosshand.virgo.api.model.MeetingMinutes;
+import com.bosshand.virgo.api.model.MeetingPlace;
+import com.bosshand.virgo.api.model.MeetingType;
+import com.bosshand.virgo.api.service.MeetingMinutesService;
+import com.bosshand.virgo.core.response.Response;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+@RestController
+@RequestMapping({"meetingMinutes"})
+@Api(tags = {"会议纪要管理"})
+public class MeetingMinutesController {
+
+    @Autowired
+    MeetingMinutesService meetingMinutesService;
+
+    @ApiOperation("保存")
+    @RequestMapping(value = "", method = RequestMethod.POST)
+    public Response insert(@RequestBody MeetingMinutes meetingMinutes) {
+        meetingMinutesService.insert(meetingMinutes);
+        return Response.ok();
+    }
+
+    @ApiOperation("获取")
+    @RequestMapping(value = "/{currPage}/{pageSize}", method = RequestMethod.POST)
+    public Response list(@RequestBody MeetingMinutes meetingMinutes, @PathVariable int currPage, @PathVariable int pageSize) {
+        int totalCount = meetingMinutesService.getTotalCount(meetingMinutes);
+        List<MeetingMinutes> dataList = meetingMinutesService.getLimit(meetingMinutes, currPage, pageSize);
+        Map<String, Object> result = new HashMap<>();
+        result.put("dataList", dataList);
+        result.put("totalCount", totalCount);
+        return Response.ok(result);
+    }
+
+    @ApiOperation("更新")
+    @RequestMapping(value = "", method = RequestMethod.PUT)
+    public Response update(@RequestBody MeetingMinutes meetingMinutes) {
+        meetingMinutesService.update(meetingMinutes);
+        return Response.ok();
+    }
+
+    @ApiOperation("删除")
+    @RequestMapping(value = "/{id}", method = RequestMethod.DELETE)
+    public Response delete(@PathVariable long id) {
+        meetingMinutesService.delete(id);
+        return Response.ok();
+    }
+
+    @ApiOperation("详情")
+    @RequestMapping(value = "/{id}", method = RequestMethod.GET)
+    public Response get(@PathVariable long id) {
+        return Response.ok(meetingMinutesService.get(id));
+    }
+
+    /**
+     * 会议场所
+     */
+    @ApiOperation("保存会议场所")
+    @RequestMapping(value = "/place", method = RequestMethod.POST)
+    public Response insertMeetingPlace(@RequestBody MeetingPlace meetingPlace) {
+        meetingMinutesService.insertMeetingPlace(meetingPlace);
+        return Response.ok();
+    }
+
+    @ApiOperation("获取会议场所")
+    @RequestMapping(value = "/place/query", method = RequestMethod.POST)
+    public Response getMeetingPlaceList(@RequestBody MeetingPlace meetingPlace) {
+        return Response.ok(meetingMinutesService.getMeetingPlaceList(meetingPlace));
+    }
+
+    @ApiOperation("更新会议场所")
+    @RequestMapping(value = "/place", method = RequestMethod.PUT)
+    public Response updateMeetingPlace(@RequestBody MeetingPlace meetingPlace) {
+        meetingMinutesService.updateMeetingPlace(meetingPlace);
+        return Response.ok();
+    }
+
+    @ApiOperation("删除会议场所")
+    @RequestMapping(value = "/place/{id}", method = RequestMethod.DELETE)
+    public Response deleteMeetingPlace(@PathVariable long id) {
+        meetingMinutesService.deleteMeetingPlace(id);
+        return Response.ok();
+    }
+
+
+    /**
+     * 会议类别
+     */
+    @ApiOperation("保存会议类别")
+    @RequestMapping(value = "/type", method = RequestMethod.POST)
+    public Response insertMeetingPlace(@RequestBody MeetingType meetingType) {
+        meetingMinutesService.insertMeetingType(meetingType);
+        return Response.ok();
+    }
+
+    @ApiOperation("获取会议类别")
+    @RequestMapping(value = "/type/query", method = RequestMethod.POST)
+    public Response getMeetingPlaceList(@RequestBody MeetingType meetingType) {
+        return Response.ok(meetingMinutesService.getMeetingTypeList(meetingType));
+    }
+
+    @ApiOperation("更新会议类别")
+    @RequestMapping(value = "/type", method = RequestMethod.PUT)
+    public Response updateMeetingPlace(@RequestBody MeetingType meetingType) {
+        meetingMinutesService.updateMeetingType(meetingType);
+        return Response.ok();
+    }
+
+    @ApiOperation("删除会议类别")
+    @RequestMapping(value = "/type/{id}", method = RequestMethod.DELETE)
+    public Response deleteMeetingType(@PathVariable long id) {
+        meetingMinutesService.deleteMeetingType(id);
+        return Response.ok();
+    }
+
+
+}

+ 24 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/dao/MeetingMinutesDao.java

@@ -0,0 +1,24 @@
+package com.bosshand.virgo.api.dao;
+
+import com.bosshand.virgo.api.model.MeetingMinutes;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+@Mapper
+public interface MeetingMinutesDao {
+
+    int insert(MeetingMinutes meetingMinutes);
+
+    int update(MeetingMinutes meetingMinutes);
+
+    int delete(long id);
+
+    MeetingMinutes get(long id);
+
+    int getTotalCount(MeetingMinutes meetingMinutes);
+
+    List<MeetingMinutes> getLimit(@Param("p") MeetingMinutes p, @Param("currIndex") int currIndex, @Param("pageSize") int pageSize);
+
+}

+ 19 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/dao/MeetingPlaceDao.java

@@ -0,0 +1,19 @@
+package com.bosshand.virgo.api.dao;
+
+import com.bosshand.virgo.api.model.MeetingPlace;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+@Mapper
+public interface MeetingPlaceDao {
+
+    int insert (MeetingPlace meetingPlace);
+
+    int update(MeetingPlace meetingPlace);
+
+    int delete(long id);
+
+    List<MeetingPlace> getList(MeetingPlace meetingPlace);
+
+}

+ 19 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/dao/MeetingTypeDao.java

@@ -0,0 +1,19 @@
+package com.bosshand.virgo.api.dao;
+
+import com.bosshand.virgo.api.model.MeetingType;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+@Mapper
+public interface MeetingTypeDao {
+
+    int insert (MeetingType meetingType);
+
+    int update(MeetingType meetingType);
+
+    int delete(long id);
+
+    List<MeetingType> getList(MeetingType meetingType);
+
+}

+ 35 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/model/JoinUser.java

@@ -0,0 +1,35 @@
+package com.bosshand.virgo.api.model;
+
+public class JoinUser {
+
+    private long id;
+
+    private String name;
+
+    private String portrait;
+
+    public long getId() {
+        return id;
+    }
+
+    public void setId(long id) {
+        this.id = id;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getPortrait() {
+        return portrait;
+    }
+
+    public void setPortrait(String portrait) {
+        this.portrait = portrait;
+    }
+
+}

+ 214 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/model/MeetingMinutes.java

@@ -0,0 +1,214 @@
+package com.bosshand.virgo.api.model;
+
+import java.util.List;
+
+/**
+ * 会议纪要
+ */
+public class MeetingMinutes {
+
+    private long id;
+
+    /**
+     * 组织id
+     */
+    private long organizationId;
+
+    /**
+     * 项目id
+     */
+    private long projectId;
+
+    /**
+     * 会议日期
+     */
+    private String date;
+
+    /**
+     * 会议名称
+     */
+    private String name;
+
+    /**
+     * 会议时长
+     */
+    private String duration;
+
+    /**
+     * 会议场所id
+     */
+    private long placeId;
+
+    /**
+     * 会议场所名称
+     */
+    private String placeName;
+
+    /**
+     * 会议类别id
+     */
+    private long typeId;
+
+    /**
+     * 会议类别名称
+     */
+    private String typeName;
+
+    /**
+     * 会议类型
+     */
+    private Integer type;
+
+    /**
+     * 附件
+     */
+    private String attachment;
+
+    /**
+     * 参与人员ids
+     */
+    private String joinUserIds;
+
+    /**
+     * 参与人员列表
+     */
+    private List<JoinUser> joinUserList;
+
+    /**
+     * 内容
+     */
+    private String content;
+
+    /**
+     * 状态
+     */
+    private Integer status;
+
+    public long getId() {
+        return id;
+    }
+
+    public void setId(long id) {
+        this.id = id;
+    }
+
+    public long getOrganizationId() {
+        return organizationId;
+    }
+
+    public void setOrganizationId(long organizationId) {
+        this.organizationId = organizationId;
+    }
+
+    public long getProjectId() {
+        return projectId;
+    }
+
+    public void setProjectId(long projectId) {
+        this.projectId = projectId;
+    }
+
+    public String getDate() {
+        return date;
+    }
+
+    public void setDate(String date) {
+        this.date = date;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getDuration() {
+        return duration;
+    }
+
+    public void setDuration(String duration) {
+        this.duration = duration;
+    }
+
+    public long getPlaceId() {
+        return placeId;
+    }
+
+    public void setPlaceId(long placeId) {
+        this.placeId = placeId;
+    }
+
+    public String getPlaceName() {
+        return placeName;
+    }
+
+    public void setPlaceName(String placeName) {
+        this.placeName = placeName;
+    }
+
+    public long getTypeId() {
+        return typeId;
+    }
+
+    public void setTypeId(long typeId) {
+        this.typeId = typeId;
+    }
+
+    public String getTypeName() {
+        return typeName;
+    }
+
+    public void setTypeName(String typeName) {
+        this.typeName = typeName;
+    }
+
+    public Integer getType() {
+        return type;
+    }
+
+    public void setType(Integer type) {
+        this.type = type;
+    }
+
+    public String getAttachment() {
+        return attachment;
+    }
+
+    public void setAttachment(String attachment) {
+        this.attachment = attachment;
+    }
+
+    public String getJoinUserIds() {
+        return joinUserIds;
+    }
+
+    public void setJoinUserIds(String joinUserIds) {
+        this.joinUserIds = joinUserIds;
+    }
+
+    public List<JoinUser> getJoinUserList() {
+        return joinUserList;
+    }
+
+    public void setJoinUserList(List<JoinUser> joinUserList) {
+        this.joinUserList = joinUserList;
+    }
+
+    public String getContent() {
+        return content;
+    }
+
+    public void setContent(String content) {
+        this.content = content;
+    }
+
+    public Integer getStatus() {
+        return status;
+    }
+
+    public void setStatus(Integer status) {
+        this.status = status;
+    }
+}

+ 69 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/model/MeetingPlace.java

@@ -0,0 +1,69 @@
+package com.bosshand.virgo.api.model;
+
+/**
+ * 会议场所
+ */
+public class MeetingPlace {
+
+    private long id;
+
+    /**
+     * 组织id
+     */
+    private long organizationId;
+
+    /**
+     * 项目id
+     */
+    private long projectId;
+
+    /**
+     * 名称
+     */
+    private String name;
+
+    /**
+     * 内容
+     */
+    private String content;
+
+    public long getId() {
+        return id;
+    }
+
+    public void setId(long id) {
+        this.id = id;
+    }
+
+    public long getOrganizationId() {
+        return organizationId;
+    }
+
+    public void setOrganizationId(long organizationId) {
+        this.organizationId = organizationId;
+    }
+
+    public long getProjectId() {
+        return projectId;
+    }
+
+    public void setProjectId(long projectId) {
+        this.projectId = projectId;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getContent() {
+        return content;
+    }
+
+    public void setContent(String content) {
+        this.content = content;
+    }
+}

+ 69 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/model/MeetingType.java

@@ -0,0 +1,69 @@
+package com.bosshand.virgo.api.model;
+
+/**
+ * 会议类别
+ */
+public class MeetingType {
+
+    private long id;
+
+    /**
+     * 组织id
+     */
+    private long organizationId;
+
+    /**
+     * 项目id
+     */
+    private long projectId;
+
+    /**
+     * 名称
+     */
+    private String name;
+
+    /**
+     * 内容
+     */
+    private String content;
+
+    public long getId() {
+        return id;
+    }
+
+    public void setId(long id) {
+        this.id = id;
+    }
+
+    public long getOrganizationId() {
+        return organizationId;
+    }
+
+    public void setOrganizationId(long organizationId) {
+        this.organizationId = organizationId;
+    }
+
+    public long getProjectId() {
+        return projectId;
+    }
+
+    public void setProjectId(long projectId) {
+        this.projectId = projectId;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getContent() {
+        return content;
+    }
+
+    public void setContent(String content) {
+        this.content = content;
+    }
+}

+ 89 - 0
virgo.api/src/main/java/com/bosshand/virgo/api/service/MeetingMinutesService.java

@@ -0,0 +1,89 @@
+package com.bosshand.virgo.api.service;
+
+import com.bosshand.virgo.api.dao.MeetingMinutesDao;
+import com.bosshand.virgo.api.dao.MeetingPlaceDao;
+import com.bosshand.virgo.api.dao.MeetingTypeDao;
+import com.bosshand.virgo.api.model.MeetingMinutes;
+import com.bosshand.virgo.api.model.MeetingPlace;
+import com.bosshand.virgo.api.model.MeetingType;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class MeetingMinutesService {
+
+    @Autowired
+    MeetingMinutesDao meetingMinutesDao;
+
+    @Autowired
+    MeetingPlaceDao meetingPlaceDao;
+
+    @Autowired
+    MeetingTypeDao meetingTypeDao;
+
+    public int insert(MeetingMinutes meetingMinutes) {
+        return meetingMinutesDao.insert(meetingMinutes);
+    }
+
+    public int update(MeetingMinutes meetingMinutes) {
+        return meetingMinutesDao.update(meetingMinutes);
+    }
+
+    public MeetingMinutes get(long id) {
+        return meetingMinutesDao.get(id);
+    }
+
+    public int delete(long id) {
+        return meetingMinutesDao.delete(id);
+    }
+
+    public int getTotalCount(MeetingMinutes meetingMinutes) {
+        return meetingMinutesDao.getTotalCount(meetingMinutes);
+    }
+
+    public List<MeetingMinutes> getLimit(MeetingMinutes meetingMinutes, int currPage, int pageSize) {
+        int currIndex = (currPage - 1) * pageSize;
+        return meetingMinutesDao.getLimit(meetingMinutes, currIndex, pageSize);
+    }
+
+    /**
+     * 会议场所
+     */
+    public int insertMeetingPlace(MeetingPlace meetingPlace) {
+        return meetingPlaceDao.insert(meetingPlace);
+    }
+
+    public int updateMeetingPlace(MeetingPlace meetingPlace) {
+        return meetingPlaceDao.update(meetingPlace);
+    }
+
+    public List<MeetingPlace> getMeetingPlaceList(MeetingPlace meetingPlace) {
+        return meetingPlaceDao.getList(meetingPlace);
+    }
+
+    public int deleteMeetingPlace(long id) {
+        return meetingPlaceDao.delete(id);
+    }
+
+    /**
+     * 会议类别
+     */
+    public int insertMeetingType(MeetingType meetingType) {
+        return meetingTypeDao.insert(meetingType);
+    }
+
+    public int updateMeetingType(MeetingType meetingType) {
+        return meetingTypeDao.update(meetingType);
+    }
+
+    public List<MeetingType> getMeetingTypeList(MeetingType meetingType) {
+        return meetingTypeDao.getList(meetingType);
+    }
+
+    public int deleteMeetingType(long id) {
+        return meetingTypeDao.delete(id);
+    }
+
+}

+ 168 - 0
virgo.api/src/main/resources/mapper/MeetingMinutesMapper.xml

@@ -0,0 +1,168 @@
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+
+<mapper namespace="com.bosshand.virgo.api.dao.MeetingMinutesDao">
+
+    <resultMap type="com.bosshand.virgo.api.model.MeetingMinutes" id="result">
+        <id column="id" property="id"/>
+        <result column="organizationId" property="organizationId"/>
+        <result column="projectId" property="projectId"/>
+        <result column="date" property="date"/>
+        <result column="name" property="name"/>
+        <result column="duration" property="duration"/>
+        <result column="placeId" property="placeId"/>
+        <result column="placeName" property="placeName"/>
+        <result column="typeId" property="typeId"/>
+        <result column="typeName" property="typeName"/>
+        <result column="type" property="type"/>
+        <result column="attachment" property="attachment"/>
+        <result column="joinUserIds" property="joinUserIds"/>
+        <result column="content" property="content"/>
+        <result column="status" property="status"/>
+    </resultMap>
+
+    <resultMap type="com.bosshand.virgo.api.model.MeetingMinutes" id="MeetingMinutesResult">
+        <id column="id" property="id"/>
+        <result column="organizationId" property="organizationId"/>
+        <result column="projectId" property="projectId"/>
+        <result column="date" property="date"/>
+        <result column="name" property="name"/>
+        <result column="duration" property="duration"/>
+        <result column="placeId" property="placeId"/>
+        <result column="placeName" property="placeName"/>
+        <result column="typeId" property="typeId"/>
+        <result column="typeName" property="typeName"/>
+        <result column="type" property="type"/>
+        <result column="attachment" property="attachment"/>
+        <result column="joinUserIds" property="joinUserIds"/>
+        <result column="content" property="content"/>
+        <result column="status" property="status"/>
+        <collection property="joinUserList" ofType="com.bosshand.virgo.api.model.JoinUser">
+            <id property="id" column="joinUser_id"/>
+            <result property="name" column="joinUser_name"/>
+            <result property="portrait" column="joinUser_portrait"/>
+        </collection>
+    </resultMap>
+
+    <sql id="query">
+        select a.*, b.name as placeName, c.name as typeName
+        from meeting_minutes a
+                 LEFT JOIN meeting_place b ON a.placeId = b.id
+                 LEFT JOIN meeting_type c ON a.typeId = c.id
+    </sql>
+
+    <sql id="details">
+        select a.*,
+               b.name     as placeName,
+               c.name     as typeName,
+               d.id       as joinUser_id,
+               d.name     as joinUser_name,
+               d.portrait as joinUser_portrait
+        from meeting_minutes a
+                 LEFT JOIN meeting_place b ON a.placeId = b.id
+                 LEFT JOIN meeting_type c ON a.typeId = c.id
+                 LEFT JOIN mgr_user d ON FIND_IN_SET(d.id, a.joinUserIds)
+    </sql>
+
+    <select id="get" resultMap="MeetingMinutesResult">
+       <include refid="details"/> where a.id = #{id}
+    </select>
+
+    <select id="getTotalCount" parameterType="com.bosshand.virgo.api.model.MeetingMinutes" resultType="Integer">
+        SELECT count(*) FROM meeting_minutes
+        <where>
+            <if test="organizationId != 0">
+                and organizationId = #{organizationId}
+            </if>
+            <if test="projectId != 0">
+                and projectId = #{projectId}
+            </if>
+            <if test="date != null">
+                and date = #{date}
+            </if>
+            <if test="name != null">
+                and name = #{name}
+            </if>
+            <if test="duration != null">
+                and duration = #{duration}
+            </if>
+            <if test="placeId != 0">
+                and placeId = #{placeId}
+            </if>
+            <if test="typeId != 0">
+                and typeId = #{typeId}
+            </if>
+            <if test="type != null">
+                and type = #{type}
+            </if>
+            <if test="status != null">
+                and status = #{status}
+            </if>
+        </where>
+    </select>
+
+    <select id="getLimit" resultMap="result">
+        <include refid="query"/>
+        <where>
+            <if test="p.organizationId != 0">
+                and a.organizationId = #{p.organizationId}
+            </if>
+            <if test="p.projectId != 0">
+                and a.projectId = #{p.projectId}
+            </if>
+            <if test="p.date != null">
+                and a.date = #{p.date}
+            </if>
+            <if test="p.name != null">
+                and a.name = #{p.name}
+            </if>
+            <if test="p.duration != null">
+                and a.duration = #{p.duration}
+            </if>
+            <if test="p.placeId != 0">
+                and a.placeId = #{p.placeId}
+            </if>
+            <if test="p.typeId != 0">
+                and a.typeId = #{p.typeId}
+            </if>
+            <if test="p.type != null">
+                and a.type = #{p.type}
+            </if>
+            <if test="p.status != null">
+                and a.status = #{p.status}
+            </if>
+        </where>
+        limit #{currIndex} , #{pageSize}
+    </select>
+
+
+    <insert id="insert" useGeneratedKeys="true" keyProperty="id">
+        INSERT INTO meeting_minutes (organizationId, projectId, date, name, duration, placeId, typeId, type, status, joinUserIds, attachment, content)
+        VALUES (#{organizationId}, #{projectId}, #{date}, #{name}, #{duration}, #{placeId}, #{typeId}, #{type}, #{status}, #{joinUserIds}, #{attachment}, #{content})
+    </insert>
+
+    <delete id="delete">
+        DELETE FROM meeting_minutes WHERE id=#{id}
+    </delete>
+
+    <update id="update" parameterType="com.bosshand.virgo.api.model.MeetingMinutes">
+        UPDATE meeting_minutes
+        <trim prefix="set" suffixOverrides=",">
+            <if test="organizationId!=0">organizationId=#{organizationId},</if>
+            <if test="projectId!=0">projectId=#{projectId},</if>
+            <if test="date!=null">date=#{date},</if>
+            <if test="name!=null">name=#{name},</if>
+            <if test="duration!=null">duration=#{duration},</if>
+            <if test="placeId!=0">placeId=#{placeId},</if>
+            <if test="typeId!=0">typeId=#{typeId},</if>
+            <if test="type!=null">type=#{type},</if>
+            <if test="status!=null">status=#{status},</if>
+            <if test="attachment!=null">attachment=#{attachment},</if>
+            <if test="joinUserIds!=null">joinUserIds=#{joinUserIds},</if>
+            <if test="content!=null">content=#{content},</if>
+        </trim>
+        WHERE id=#{id}
+    </update>
+
+</mapper>

+ 49 - 0
virgo.api/src/main/resources/mapper/MeetingPlaceMapper.xml

@@ -0,0 +1,49 @@
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+
+<mapper namespace="com.bosshand.virgo.api.dao.MeetingPlaceDao">
+
+    <resultMap type="com.bosshand.virgo.api.model.MeetingPlace" id="result">
+        <id column="id" property="id"/>
+        <result column="organizationId" property="organizationId"/>
+        <result column="projectId" property="projectId"/>
+        <result column="name" property="name"/>
+        <result column="content" property="content"/>
+    </resultMap>
+
+    <select id="getList" resultMap="result">
+        select * from meeting_place
+        <where>
+            <if test="organizationId != 0">
+                and organizationId = #{organizationId}
+            </if>
+            <if test="projectId != 0">
+                and projectId = #{projectId}
+            </if>
+            <if test="name != null">
+                and name = #{name}
+            </if>
+        </where>
+    </select>
+
+    <insert id="insert" useGeneratedKeys="true" keyProperty="id">
+        INSERT INTO meeting_place (organizationId, projectId, name, content) VALUES (#{organizationId}, #{projectId}, #{name}, #{content})
+    </insert>
+
+    <delete id="delete">
+        DELETE FROM meeting_place WHERE id=#{id}
+    </delete>
+
+    <update id="update" parameterType="com.bosshand.virgo.api.model.MeetingPlace">
+        UPDATE meeting_place
+        <trim prefix="set" suffixOverrides=",">
+            <if test="organizationId!=0">organizationId=#{organizationId},</if>
+            <if test="projectId!=0">projectId=#{projectId},</if>
+            <if test="name!=null">name=#{name},</if>
+            <if test="content!=null">content=#{content},</if>
+        </trim>
+        WHERE id=#{id}
+    </update>
+
+</mapper>

+ 49 - 0
virgo.api/src/main/resources/mapper/MeetingTypeMapper.xml

@@ -0,0 +1,49 @@
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+
+<mapper namespace="com.bosshand.virgo.api.dao.MeetingTypeDao">
+
+    <resultMap type="com.bosshand.virgo.api.model.MeetingType" id="result">
+        <id column="id" property="id"/>
+        <result column="organizationId" property="organizationId"/>
+        <result column="projectId" property="projectId"/>
+        <result column="name" property="name"/>
+        <result column="content" property="content"/>
+    </resultMap>
+
+    <select id="getList" resultMap="result">
+        select * from meeting_type
+        <where>
+            <if test="organizationId != 0">
+                and organizationId = #{organizationId}
+            </if>
+            <if test="projectId != 0">
+                and projectId = #{projectId}
+            </if>
+            <if test="name != null">
+                and name = #{name}
+            </if>
+        </where>
+    </select>
+
+    <insert id="insert" useGeneratedKeys="true" keyProperty="id">
+        INSERT INTO meeting_type (organizationId, projectId, name, content) VALUES (#{organizationId}, #{projectId}, #{name}, #{content})
+    </insert>
+
+    <delete id="delete">
+        DELETE FROM meeting_type WHERE id=#{id}
+    </delete>
+
+    <update id="update" parameterType="com.bosshand.virgo.api.model.MeetingType">
+        UPDATE meeting_type
+        <trim prefix="set" suffixOverrides=",">
+            <if test="organizationId!=0">organizationId=#{organizationId},</if>
+            <if test="projectId!=0">projectId=#{projectId},</if>
+            <if test="name!=null">name=#{name},</if>
+            <if test="content!=null">content=#{content},</if>
+        </trim>
+        WHERE id=#{id}
+    </update>
+
+</mapper>