| | |
| | | <artifactId>jcdm-generator</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- JCDM模å--> |
| | | <dependency> |
| | | <groupId>com.jcdm</groupId> |
| | | <artifactId>jcdm-main</artifactId> |
| | | </dependency> |
| | | |
| | | </dependencies> |
| | | |
| | | <build> |
| | |
| | | druid: |
| | | # 主åºæ°æ®æº |
| | | master: |
| | | url: jdbc:sqlserver://192.168.0.189:1433;DataBaseName=jcdm-mes-vue |
| | | url: jdbc:sqlserver://192.168.0.189:1433;DataBaseName=jcdm-mes |
| | | username: sa |
| | | password: JCDM@2023 |
| | | # ä»åºæ°æ®æº |
| | |
| | | # ä½è
|
| | | author: ruoyi |
| | | # é»è®¤çæå
è·¯å¾ system éæ¹æèªå·±ç模åå称 å¦ system monitor tool |
| | | packageName: com.jcdm.test |
| | | packageName: com.jcdm.main |
| | | # èªå¨å»é¤è¡¨åç¼ï¼é»è®¤æ¯false |
| | | autoRemovePre: false |
| | | # 表åç¼ï¼çæç±»åä¸ä¼å
å«è¡¨åç¼ï¼å¤ä¸ªç¨éå·åéï¼ |
| | | tablePrefix: bs_ |
| | | tablePrefix: sys_,bs_ |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <project xmlns="http://maven.apache.org/POM/4.0.0" |
| | | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| | | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| | | <modelVersion>4.0.0</modelVersion> |
| | | <parent> |
| | | <groupId>com.jcdm</groupId> |
| | | <artifactId>jcdm</artifactId> |
| | | <version>3.8.6</version> |
| | | </parent> |
| | | |
| | | <artifactId>jcdm-main</artifactId> |
| | | |
| | | <properties> |
| | | <maven.compiler.source>17</maven.compiler.source> |
| | | <maven.compiler.target>17</maven.compiler.target> |
| | | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| | | </properties> |
| | | |
| | | <dependencies> |
| | | <dependency> |
| | | <groupId>com.jcdm</groupId> |
| | | <artifactId>jcdm-common</artifactId> |
| | | </dependency> |
| | | </dependencies> |
| | | |
| | | </project> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.jcdm.main.bs.controller; |
| | | |
| | | import java.util.List; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.PutMapping; |
| | | import org.springframework.web.bind.annotation.DeleteMapping; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | import com.jcdm.common.annotation.Log; |
| | | import com.jcdm.common.core.controller.BaseController; |
| | | import com.jcdm.common.core.domain.AjaxResult; |
| | | import com.jcdm.common.enums.BusinessType; |
| | | import com.jcdm.main.bs.domain.BsWorkshopInfo; |
| | | import com.jcdm.main.bs.service.IBsWorkshopInfoService; |
| | | import com.jcdm.common.utils.poi.ExcelUtil; |
| | | import com.jcdm.common.core.page.TableDataInfo; |
| | | |
| | | /** |
| | | * 车é´ä¿¡æ¯Controller |
| | | * |
| | | * @author ruoyi |
| | | * @date 2023-12-06 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/bs/workshop") |
| | | public class BsWorkshopInfoController extends BaseController |
| | | { |
| | | @Autowired |
| | | private IBsWorkshopInfoService bsWorkshopInfoService; |
| | | |
| | | /** |
| | | * æ¥è¯¢è½¦é´ä¿¡æ¯å表 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('bs:workshop:list')") |
| | | @GetMapping("/list") |
| | | public TableDataInfo list(BsWorkshopInfo bsWorkshopInfo) |
| | | { |
| | | startPage(); |
| | | List<BsWorkshopInfo> list = bsWorkshopInfoService.selectBsWorkshopInfoList(bsWorkshopInfo); |
| | | return getDataTable(list); |
| | | } |
| | | |
| | | /** |
| | | * 导åºè½¦é´ä¿¡æ¯å表 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('bs:workshop:export')") |
| | | @Log(title = "车é´ä¿¡æ¯", businessType = BusinessType.EXPORT) |
| | | @PostMapping("/export") |
| | | public void export(HttpServletResponse response, BsWorkshopInfo bsWorkshopInfo) |
| | | { |
| | | List<BsWorkshopInfo> list = bsWorkshopInfoService.selectBsWorkshopInfoList(bsWorkshopInfo); |
| | | ExcelUtil<BsWorkshopInfo> util = new ExcelUtil<BsWorkshopInfo>(BsWorkshopInfo.class); |
| | | util.exportExcel(response, list, "车é´ä¿¡æ¯æ°æ®"); |
| | | } |
| | | |
| | | /** |
| | | * è·å车é´ä¿¡æ¯è¯¦ç»ä¿¡æ¯ |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('bs:workshop:query')") |
| | | @GetMapping(value = "/{id}") |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) |
| | | { |
| | | return success(bsWorkshopInfoService.selectBsWorkshopInfoById(id)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢è½¦é´ä¿¡æ¯ |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('bs:workshop:add')") |
| | | @Log(title = "车é´ä¿¡æ¯", businessType = BusinessType.INSERT) |
| | | @PostMapping |
| | | public AjaxResult add(@RequestBody BsWorkshopInfo bsWorkshopInfo) |
| | | { |
| | | return toAjax(bsWorkshopInfoService.insertBsWorkshopInfo(bsWorkshopInfo)); |
| | | } |
| | | |
| | | /** |
| | | * ä¿®æ¹è½¦é´ä¿¡æ¯ |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('bs:workshop:edit')") |
| | | @Log(title = "车é´ä¿¡æ¯", businessType = BusinessType.UPDATE) |
| | | @PutMapping |
| | | public AjaxResult edit(@RequestBody BsWorkshopInfo bsWorkshopInfo) |
| | | { |
| | | return toAjax(bsWorkshopInfoService.updateBsWorkshopInfo(bsWorkshopInfo)); |
| | | } |
| | | |
| | | /** |
| | | * å é¤è½¦é´ä¿¡æ¯ |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('bs:workshop:remove')") |
| | | @Log(title = "车é´ä¿¡æ¯", businessType = BusinessType.DELETE) |
| | | @DeleteMapping("/{ids}") |
| | | public AjaxResult remove(@PathVariable Long[] ids) |
| | | { |
| | | return toAjax(bsWorkshopInfoService.deleteBsWorkshopInfoByIds(ids)); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.jcdm.main.bs.domain; |
| | | |
| | | import org.apache.commons.lang3.builder.ToStringBuilder; |
| | | import org.apache.commons.lang3.builder.ToStringStyle; |
| | | import com.jcdm.common.annotation.Excel; |
| | | import com.jcdm.common.core.domain.BaseEntity; |
| | | |
| | | /** |
| | | * 车é´ä¿¡æ¯å¯¹è±¡ bs_workshop_info |
| | | * |
| | | * @author ruoyi |
| | | * @date 2023-12-06 |
| | | */ |
| | | public class BsWorkshopInfo extends BaseEntity |
| | | { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** id */ |
| | | private Long id; |
| | | |
| | | /** 车é´ç¼ç */ |
| | | @Excel(name = "车é´ç¼ç ") |
| | | private String workshopCode; |
| | | |
| | | /** 车é´å称 */ |
| | | @Excel(name = "车é´å称") |
| | | private String workshopName; |
| | | |
| | | /** å¤ç¨å段1 */ |
| | | private String spareField1; |
| | | |
| | | /** å¤ç¨å段2 */ |
| | | private String spareField2; |
| | | |
| | | /** å¤æ³¨ */ |
| | | @Excel(name = "å¤æ³¨") |
| | | private String remarks; |
| | | |
| | | /** å建人 */ |
| | | @Excel(name = "å建人") |
| | | private String createUser; |
| | | |
| | | /** æ´æ°äºº */ |
| | | @Excel(name = "æ´æ°äºº") |
| | | private String updateUser; |
| | | |
| | | public void setId(Long id) |
| | | { |
| | | this.id = id; |
| | | } |
| | | |
| | | public Long getId() |
| | | { |
| | | return id; |
| | | } |
| | | public void setWorkshopCode(String workshopCode) |
| | | { |
| | | this.workshopCode = workshopCode; |
| | | } |
| | | |
| | | public String getWorkshopCode() |
| | | { |
| | | return workshopCode; |
| | | } |
| | | public void setWorkshopName(String workshopName) |
| | | { |
| | | this.workshopName = workshopName; |
| | | } |
| | | |
| | | public String getWorkshopName() |
| | | { |
| | | return workshopName; |
| | | } |
| | | public void setSpareField1(String spareField1) |
| | | { |
| | | this.spareField1 = spareField1; |
| | | } |
| | | |
| | | public String getSpareField1() |
| | | { |
| | | return spareField1; |
| | | } |
| | | public void setSpareField2(String spareField2) |
| | | { |
| | | this.spareField2 = spareField2; |
| | | } |
| | | |
| | | public String getSpareField2() |
| | | { |
| | | return spareField2; |
| | | } |
| | | public void setRemarks(String remarks) |
| | | { |
| | | this.remarks = remarks; |
| | | } |
| | | |
| | | public String getRemarks() |
| | | { |
| | | return remarks; |
| | | } |
| | | public void setCreateUser(String createUser) |
| | | { |
| | | this.createUser = createUser; |
| | | } |
| | | |
| | | public String getCreateUser() |
| | | { |
| | | return createUser; |
| | | } |
| | | public void setUpdateUser(String updateUser) |
| | | { |
| | | this.updateUser = updateUser; |
| | | } |
| | | |
| | | public String getUpdateUser() |
| | | { |
| | | return updateUser; |
| | | } |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) |
| | | .append("id", getId()) |
| | | .append("workshopCode", getWorkshopCode()) |
| | | .append("workshopName", getWorkshopName()) |
| | | .append("spareField1", getSpareField1()) |
| | | .append("spareField2", getSpareField2()) |
| | | .append("remarks", getRemarks()) |
| | | .append("createUser", getCreateUser()) |
| | | .append("createTime", getCreateTime()) |
| | | .append("updateUser", getUpdateUser()) |
| | | .append("updateTime", getUpdateTime()) |
| | | .toString(); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.jcdm.main.bs.mapper; |
| | | |
| | | import java.util.List; |
| | | import com.jcdm.main.bs.domain.BsWorkshopInfo; |
| | | |
| | | /** |
| | | * 车é´ä¿¡æ¯Mapperæ¥å£ |
| | | * |
| | | * @author ruoyi |
| | | * @date 2023-12-06 |
| | | */ |
| | | public interface BsWorkshopInfoMapper |
| | | { |
| | | /** |
| | | * æ¥è¯¢è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param id 车é´ä¿¡æ¯ä¸»é® |
| | | * @return 车é´ä¿¡æ¯ |
| | | */ |
| | | public BsWorkshopInfo selectBsWorkshopInfoById(Long id); |
| | | |
| | | /** |
| | | * æ¥è¯¢è½¦é´ä¿¡æ¯å表 |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return 车é´ä¿¡æ¯éå |
| | | */ |
| | | public List<BsWorkshopInfo> selectBsWorkshopInfoList(BsWorkshopInfo bsWorkshopInfo); |
| | | |
| | | /** |
| | | * æ°å¢è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return ç»æ |
| | | */ |
| | | public int insertBsWorkshopInfo(BsWorkshopInfo bsWorkshopInfo); |
| | | |
| | | /** |
| | | * ä¿®æ¹è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return ç»æ |
| | | */ |
| | | public int updateBsWorkshopInfo(BsWorkshopInfo bsWorkshopInfo); |
| | | |
| | | /** |
| | | * å é¤è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param id 车é´ä¿¡æ¯ä¸»é® |
| | | * @return ç»æ |
| | | */ |
| | | public int deleteBsWorkshopInfoById(Long id); |
| | | |
| | | /** |
| | | * æ¹éå é¤è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param ids éè¦å é¤çæ°æ®ä¸»é®éå |
| | | * @return ç»æ |
| | | */ |
| | | public int deleteBsWorkshopInfoByIds(Long[] ids); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.jcdm.main.bs.service; |
| | | |
| | | import java.util.List; |
| | | import com.jcdm.main.bs.domain.BsWorkshopInfo; |
| | | |
| | | /** |
| | | * 车é´ä¿¡æ¯Serviceæ¥å£ |
| | | * |
| | | * @author ruoyi |
| | | * @date 2023-12-06 |
| | | */ |
| | | public interface IBsWorkshopInfoService |
| | | { |
| | | /** |
| | | * æ¥è¯¢è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param id 车é´ä¿¡æ¯ä¸»é® |
| | | * @return 车é´ä¿¡æ¯ |
| | | */ |
| | | public BsWorkshopInfo selectBsWorkshopInfoById(Long id); |
| | | |
| | | /** |
| | | * æ¥è¯¢è½¦é´ä¿¡æ¯å表 |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return 车é´ä¿¡æ¯éå |
| | | */ |
| | | public List<BsWorkshopInfo> selectBsWorkshopInfoList(BsWorkshopInfo bsWorkshopInfo); |
| | | |
| | | /** |
| | | * æ°å¢è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return ç»æ |
| | | */ |
| | | public int insertBsWorkshopInfo(BsWorkshopInfo bsWorkshopInfo); |
| | | |
| | | /** |
| | | * ä¿®æ¹è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return ç»æ |
| | | */ |
| | | public int updateBsWorkshopInfo(BsWorkshopInfo bsWorkshopInfo); |
| | | |
| | | /** |
| | | * æ¹éå é¤è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param ids éè¦å é¤ç车é´ä¿¡æ¯ä¸»é®éå |
| | | * @return ç»æ |
| | | */ |
| | | public int deleteBsWorkshopInfoByIds(Long[] ids); |
| | | |
| | | /** |
| | | * å é¤è½¦é´ä¿¡æ¯ä¿¡æ¯ |
| | | * |
| | | * @param id 车é´ä¿¡æ¯ä¸»é® |
| | | * @return ç»æ |
| | | */ |
| | | public int deleteBsWorkshopInfoById(Long id); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.jcdm.main.bs.service.impl; |
| | | |
| | | import java.util.List; |
| | | import com.jcdm.common.utils.DateUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import com.jcdm.main.bs.mapper.BsWorkshopInfoMapper; |
| | | import com.jcdm.main.bs.domain.BsWorkshopInfo; |
| | | import com.jcdm.main.bs.service.IBsWorkshopInfoService; |
| | | |
| | | /** |
| | | * 车é´ä¿¡æ¯Serviceä¸å¡å±å¤ç |
| | | * |
| | | * @author ruoyi |
| | | * @date 2023-12-06 |
| | | */ |
| | | @Service |
| | | public class BsWorkshopInfoServiceImpl implements IBsWorkshopInfoService |
| | | { |
| | | @Autowired |
| | | private BsWorkshopInfoMapper bsWorkshopInfoMapper; |
| | | |
| | | /** |
| | | * æ¥è¯¢è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param id 车é´ä¿¡æ¯ä¸»é® |
| | | * @return 车é´ä¿¡æ¯ |
| | | */ |
| | | @Override |
| | | public BsWorkshopInfo selectBsWorkshopInfoById(Long id) |
| | | { |
| | | return bsWorkshopInfoMapper.selectBsWorkshopInfoById(id); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢è½¦é´ä¿¡æ¯å表 |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return 车é´ä¿¡æ¯ |
| | | */ |
| | | @Override |
| | | public List<BsWorkshopInfo> selectBsWorkshopInfoList(BsWorkshopInfo bsWorkshopInfo) |
| | | { |
| | | return bsWorkshopInfoMapper.selectBsWorkshopInfoList(bsWorkshopInfo); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return ç»æ |
| | | */ |
| | | @Override |
| | | public int insertBsWorkshopInfo(BsWorkshopInfo bsWorkshopInfo) |
| | | { |
| | | bsWorkshopInfo.setCreateTime(DateUtils.getNowDate()); |
| | | return bsWorkshopInfoMapper.insertBsWorkshopInfo(bsWorkshopInfo); |
| | | } |
| | | |
| | | /** |
| | | * ä¿®æ¹è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param bsWorkshopInfo 车é´ä¿¡æ¯ |
| | | * @return ç»æ |
| | | */ |
| | | @Override |
| | | public int updateBsWorkshopInfo(BsWorkshopInfo bsWorkshopInfo) |
| | | { |
| | | bsWorkshopInfo.setUpdateTime(DateUtils.getNowDate()); |
| | | return bsWorkshopInfoMapper.updateBsWorkshopInfo(bsWorkshopInfo); |
| | | } |
| | | |
| | | /** |
| | | * æ¹éå é¤è½¦é´ä¿¡æ¯ |
| | | * |
| | | * @param ids éè¦å é¤ç车é´ä¿¡æ¯ä¸»é® |
| | | * @return ç»æ |
| | | */ |
| | | @Override |
| | | public int deleteBsWorkshopInfoByIds(Long[] ids) |
| | | { |
| | | return bsWorkshopInfoMapper.deleteBsWorkshopInfoByIds(ids); |
| | | } |
| | | |
| | | /** |
| | | * å é¤è½¦é´ä¿¡æ¯ä¿¡æ¯ |
| | | * |
| | | * @param id 车é´ä¿¡æ¯ä¸»é® |
| | | * @return ç»æ |
| | | */ |
| | | @Override |
| | | public int deleteBsWorkshopInfoById(Long id) |
| | | { |
| | | return bsWorkshopInfoMapper.deleteBsWorkshopInfoById(id); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.jcdm.main.bs.mapper.BsWorkshopInfoMapper"> |
| | | |
| | | <resultMap type="BsWorkshopInfo" id="BsWorkshopInfoResult"> |
| | | <result property="id" column="id" /> |
| | | <result property="workshopCode" column="workshop_code" /> |
| | | <result property="workshopName" column="workshop_name" /> |
| | | <result property="spareField1" column="spare_field_1" /> |
| | | <result property="spareField2" column="spare_field_2" /> |
| | | <result property="remarks" column="remarks" /> |
| | | <result property="createUser" column="create_user" /> |
| | | <result property="createTime" column="create_time" /> |
| | | <result property="updateUser" column="update_user" /> |
| | | <result property="updateTime" column="update_time" /> |
| | | </resultMap> |
| | | |
| | | <sql id="selectBsWorkshopInfoVo"> |
| | | select id, workshop_code, workshop_name, spare_field_1, spare_field_2, remarks, create_user, create_time, update_user, update_time from bs_workshop_info |
| | | </sql> |
| | | |
| | | <select id="selectBsWorkshopInfoList" parameterType="BsWorkshopInfo" resultMap="BsWorkshopInfoResult"> |
| | | <include refid="selectBsWorkshopInfoVo"/> |
| | | <where> |
| | | <if test="workshopCode != null and workshopCode != ''"> and workshop_code like concat('%', #{workshopCode}, '%')</if> |
| | | <if test="workshopName != null and workshopName != ''"> and workshop_name like concat('%', #{workshopName}, '%')</if> |
| | | </where> |
| | | </select> |
| | | |
| | | <select id="selectBsWorkshopInfoById" parameterType="Long" resultMap="BsWorkshopInfoResult"> |
| | | <include refid="selectBsWorkshopInfoVo"/> |
| | | where id = #{id} |
| | | </select> |
| | | |
| | | <insert id="insertBsWorkshopInfo" parameterType="BsWorkshopInfo"> |
| | | insert into bs_workshop_info |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">id,</if> |
| | | <if test="workshopCode != null">workshop_code,</if> |
| | | <if test="workshopName != null">workshop_name,</if> |
| | | <if test="spareField1 != null">spare_field_1,</if> |
| | | <if test="spareField2 != null">spare_field_2,</if> |
| | | <if test="remarks != null">remarks,</if> |
| | | <if test="createUser != null">create_user,</if> |
| | | <if test="createTime != null">create_time,</if> |
| | | <if test="updateUser != null">update_user,</if> |
| | | <if test="updateTime != null">update_time,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">#{id},</if> |
| | | <if test="workshopCode != null">#{workshopCode},</if> |
| | | <if test="workshopName != null">#{workshopName},</if> |
| | | <if test="spareField1 != null">#{spareField1},</if> |
| | | <if test="spareField2 != null">#{spareField2},</if> |
| | | <if test="remarks != null">#{remarks},</if> |
| | | <if test="createUser != null">#{createUser},</if> |
| | | <if test="createTime != null">#{createTime},</if> |
| | | <if test="updateUser != null">#{updateUser},</if> |
| | | <if test="updateTime != null">#{updateTime},</if> |
| | | </trim> |
| | | </insert> |
| | | |
| | | <update id="updateBsWorkshopInfo" parameterType="BsWorkshopInfo"> |
| | | update bs_workshop_info |
| | | <trim prefix="SET" suffixOverrides=","> |
| | | <if test="workshopCode != null">workshop_code = #{workshopCode},</if> |
| | | <if test="workshopName != null">workshop_name = #{workshopName},</if> |
| | | <if test="spareField1 != null">spare_field_1 = #{spareField1},</if> |
| | | <if test="spareField2 != null">spare_field_2 = #{spareField2},</if> |
| | | <if test="remarks != null">remarks = #{remarks},</if> |
| | | <if test="createUser != null">create_user = #{createUser},</if> |
| | | <if test="createTime != null">create_time = #{createTime},</if> |
| | | <if test="updateUser != null">update_user = #{updateUser},</if> |
| | | <if test="updateTime != null">update_time = #{updateTime},</if> |
| | | </trim> |
| | | where id = #{id} |
| | | </update> |
| | | |
| | | <delete id="deleteBsWorkshopInfoById" parameterType="Long"> |
| | | delete from bs_workshop_info where id = #{id} |
| | | </delete> |
| | | |
| | | <delete id="deleteBsWorkshopInfoByIds" parameterType="String"> |
| | | delete from bs_workshop_info where id in |
| | | <foreach item="id" collection="array" open="(" separator="," close=")"> |
| | | #{id} |
| | | </foreach> |
| | | </delete> |
| | | </mapper> |
ÎļþÃû´Ó jcdm-ui/src/api/test/workshop.js ÐÞ¸Ä |
| | |
| | | // æ¥è¯¢è½¦é´ä¿¡æ¯å表 |
| | | export function listWorkshop(query) { |
| | | return request({ |
| | | url: '/test/workshop/list', |
| | | url: '/bs/workshop/list', |
| | | method: 'get', |
| | | params: query |
| | | }) |
| | |
| | | // æ¥è¯¢è½¦é´ä¿¡æ¯è¯¦ç» |
| | | export function getWorkshop(id) { |
| | | return request({ |
| | | url: '/test/workshop/' + id, |
| | | url: '/bs/workshop/' + id, |
| | | method: 'get' |
| | | }) |
| | | } |
| | |
| | | // æ°å¢è½¦é´ä¿¡æ¯ |
| | | export function addWorkshop(data) { |
| | | return request({ |
| | | url: '/test/workshop', |
| | | url: '/bs/workshop', |
| | | method: 'post', |
| | | data: data |
| | | }) |
| | |
| | | // ä¿®æ¹è½¦é´ä¿¡æ¯ |
| | | export function updateWorkshop(data) { |
| | | return request({ |
| | | url: '/test/workshop', |
| | | url: '/bs/workshop', |
| | | method: 'put', |
| | | data: data |
| | | }) |
| | |
| | | // å é¤è½¦é´ä¿¡æ¯ |
| | | export function delWorkshop(id) { |
| | | return request({ |
| | | url: '/test/workshop/' + id, |
| | | url: '/bs/workshop/' + id, |
| | | method: 'delete' |
| | | }) |
| | | } |
ÎļþÃû´Ó jcdm-ui/src/views/test/workshop/index.vue ÐÞ¸Ä |
| | |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="å¤ç¨å段1" prop="spareField1"> |
| | | <el-input |
| | | v-model="queryParams.spareField1" |
| | | placeholder="请è¾å
¥å¤ç¨å段1" |
| | | clearable |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="å¤ç¨å段2" prop="spareField2"> |
| | | <el-input |
| | | v-model="queryParams.spareField2" |
| | | placeholder="请è¾å
¥å¤ç¨å段2" |
| | | clearable |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="å¤æ³¨" prop="remarks"> |
| | | <el-input |
| | | v-model="queryParams.remarks" |
| | | placeholder="请è¾å
¥å¤æ³¨" |
| | | clearable |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="å建人" prop="createUser"> |
| | | <el-input |
| | | v-model="queryParams.createUser" |
| | | placeholder="请è¾å
¥å建人" |
| | | clearable |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="æ´æ°äºº" prop="updateUser"> |
| | | <el-input |
| | | v-model="queryParams.updateUser" |
| | | placeholder="请è¾å
¥æ´æ°äºº" |
| | | clearable |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æç´¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">éç½®</el-button> |
| | |
| | | icon="el-icon-plus" |
| | | size="mini" |
| | | @click="handleAdd" |
| | | v-hasPermi="['test:workshop:add']" |
| | | v-hasPermi="['bs:workshop:add']" |
| | | >æ°å¢</el-button> |
| | | </el-col> |
| | | <el-col :span="1.5"> |
| | |
| | | size="mini" |
| | | :disabled="single" |
| | | @click="handleUpdate" |
| | | v-hasPermi="['test:workshop:edit']" |
| | | v-hasPermi="['bs:workshop:edit']" |
| | | >ä¿®æ¹</el-button> |
| | | </el-col> |
| | | <el-col :span="1.5"> |
| | |
| | | size="mini" |
| | | :disabled="multiple" |
| | | @click="handleDelete" |
| | | v-hasPermi="['test:workshop:remove']" |
| | | v-hasPermi="['bs:workshop:remove']" |
| | | >å é¤</el-button> |
| | | </el-col> |
| | | <el-col :span="1.5"> |
| | |
| | | icon="el-icon-download" |
| | | size="mini" |
| | | @click="handleExport" |
| | | v-hasPermi="['test:workshop:export']" |
| | | v-hasPermi="['bs:workshop:export']" |
| | | >导åº</el-button> |
| | | </el-col> |
| | | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| | |
| | | |
| | | <el-table v-loading="loading" :data="workshopList" @selection-change="handleSelectionChange"> |
| | | <el-table-column type="selection" width="55" align="center" /> |
| | | <el-table-column label="id" align="center" prop="id" /> |
| | | <!-- <el-table-column label="id" align="center" prop="id" />--> |
| | | <el-table-column label="车é´ç¼ç " align="center" prop="workshopCode"> |
| | | <!-- <template slot-scope="scope">--> |
| | | <!-- <dict-tag :options="dict.type.${column.dictType}" :value="scope.row.workshopCode"/>--> |
| | |
| | | <!-- <dict-tag :options="dict.type.${column.dictType}" :value="scope.row.createUser"/>--> |
| | | <!-- </template>--> |
| | | </el-table-column> |
| | | <el-table-column label="å建æ¶é´" align="center" prop="createTime" width="180"> |
| | | <!-- <template slot-scope="scope">--> |
| | | <!-- <span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>--> |
| | | <!-- </template>--> |
| | | </el-table-column> |
| | | <el-table-column label="æ´æ°äºº" align="center" prop="updateUser"> |
| | | <!-- <template slot-scope="scope">--> |
| | | <!-- <dict-tag :options="dict.type.${column.dictType}" :value="scope.row.updateUser"/>--> |
| | | <!-- </template>--> |
| | | </el-table-column> |
| | | <el-table-column label="æ´æ°æ¶é´" align="center" prop="updateTime" width="180"> |
| | | <!-- <template slot-scope="scope">--> |
| | | <!-- <span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d}') }}</span>--> |
| | | <!-- </template>--> |
| | | </el-table-column> |
| | | <el-table-column label="æä½" align="center" class-name="small-padding fixed-width"> |
| | |
| | | type="text" |
| | | icon="el-icon-edit" |
| | | @click="handleUpdate(scope.row)" |
| | | v-hasPermi="['test:workshop:edit']" |
| | | v-hasPermi="['bs:workshop:edit']" |
| | | >ä¿®æ¹</el-button> |
| | | <el-button |
| | | size="mini" |
| | | type="text" |
| | | icon="el-icon-delete" |
| | | @click="handleDelete(scope.row)" |
| | | v-hasPermi="['test:workshop:remove']" |
| | | v-hasPermi="['bs:workshop:remove']" |
| | | >å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { listWorkshop, getWorkshop, delWorkshop, addWorkshop, updateWorkshop } from "@/api/test/workshop"; |
| | | import { listWorkshop, getWorkshop, delWorkshop, addWorkshop, updateWorkshop } from "@/api/main/bs/workshop"; |
| | | |
| | | export default { |
| | | name: "Workshop", |
| | |
| | | pageSize: 10, |
| | | workshopCode: null, |
| | | workshopName: null, |
| | | spareField1: null, |
| | | spareField2: null, |
| | | remarks: null, |
| | | createUser: null, |
| | | updateUser: null, |
| | | }, |
| | | // 表ååæ° |
| | | form: {}, |
| | |
| | | }, |
| | | /** 导åºæé®æä½ */ |
| | | handleExport() { |
| | | this.download('test/workshop/export', { |
| | | this.download('bs/workshop/export', { |
| | | ...this.queryParams |
| | | }, `workshop_${new Date().getTime()}.xlsx`) |
| | | } |
| | |
| | | <version>${jcdm.version}</version> |
| | | </dependency> |
| | | |
| | | <!-- JCDM模å--> |
| | | <dependency> |
| | | <groupId>com.jcdm</groupId> |
| | | <artifactId>jcdm-main</artifactId> |
| | | <version>${jcdm.version}</version> |
| | | </dependency> |
| | | |
| | | </dependencies> |
| | | </dependencyManagement> |
| | | |
| | |
| | | <module>jcdm-quartz</module> |
| | | <module>jcdm-generator</module> |
| | | <module>jcdm-common</module> |
| | | <module>jcdm-main</module> |
| | | </modules> |
| | | <packaging>pom</packaging> |
| | | |