diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwClassificationBean.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwClassificationBean.java new file mode 100644 index 0000000..95d58c8 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwClassificationBean.java @@ -0,0 +1,109 @@ +package org.jeecg.modules.demo.officialWebsite.api.bean; + +import org.springframework.format.annotation.DateTimeFormat; + +import java.util.Date; + +public class ApiOwClassificationBean { + private String id; + private String createBy; + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") + private Date createTime; + private String updateBy; + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") + private Date updateTime; + private String sysOrgCode; + private String pid; + private String hasChild; + private String name; + + //无参构造 + public ApiOwClassificationBean() { + } + + //有参构造 + public ApiOwClassificationBean(String id, String createBy, Date createTime, String updateBy, Date updateTime, String sysOrgCode, String pid, String hasChild, String name) { + this.id = id; + this.createBy = createBy; + this.createTime = createTime; + this.updateBy = updateBy; + this.updateTime = updateTime; + this.sysOrgCode = sysOrgCode; + this.pid = pid; + this.hasChild = hasChild; + this.name = name; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getCreateBy() { + return createBy; + } + + public void setCreateBy(String createBy) { + this.createBy = createBy; + } + + public Date getCreateTime() { + return createTime; + } + + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + public String getUpdateBy() { + return updateBy; + } + + public void setUpdateBy(String updateBy) { + this.updateBy = updateBy; + } + + public Date getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + public String getSysOrgCode() { + return sysOrgCode; + } + + public void setSysOrgCode(String sysOrgCode) { + this.sysOrgCode = sysOrgCode; + } + + public String getPid() { + return pid; + } + + public void setPid(String pid) { + this.pid = pid; + } + + public String getHasChild() { + return hasChild; + } + + public void setHasChild(String hasChild) { + this.hasChild = hasChild; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwImageBean.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwImageBean.java new file mode 100644 index 0000000..c8c7c3d --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwImageBean.java @@ -0,0 +1,142 @@ +package org.jeecg.modules.demo.officialWebsite.api.bean; + +import org.springframework.format.annotation.DateTimeFormat; + +import java.util.Date; + +public class ApiOwImageBean{ + + private String id; //图片id + private String createBy; //创建人 + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") + private Date createTime; //创建时间 + private String updateBy; //更新人 + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") + private Date updateTime; //更新时间 + private String sysOrgCode; //所属部门 + private String imageAddress; //图片地址 + private String imagePosition; //图片坐标 + private String imageTitle; //图片标题 + private String imageShortTitle; //图片短标题 + private String imageDescribe; //图片描述 + private String classificationId; //图片父级编号 + + //无参构造 + public ApiOwImageBean() { + } + + //有参构造 + public ApiOwImageBean(String id, String createBy, Date createTime, String updateBy, Date updateTime, String sysOrgCode, String imageAddress, String imagePosition, String imageTitle, String imageShortTitle, String imageDescribe, String classificationId) { + this.id = id; + this.createBy = createBy; + this.createTime = createTime; + this.updateBy = updateBy; + this.updateTime = updateTime; + this.sysOrgCode = sysOrgCode; + this.imageAddress = imageAddress; + this.imagePosition = imagePosition; + this.imageTitle = imageTitle; + this.imageShortTitle = imageShortTitle; + this.imageDescribe = imageDescribe; + this.classificationId = classificationId; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getCreateBy() { + return createBy; + } + + public void setCreateBy(String createBy) { + this.createBy = createBy; + } + + public Date getCreateTime() { + return createTime; + } + + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + public String getUpdateBy() { + return updateBy; + } + + public void setUpdateBy(String updateBy) { + this.updateBy = updateBy; + } + + public Date getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + public String getSysOrgCode() { + return sysOrgCode; + } + + public void setSysOrgCode(String sysOrgCode) { + this.sysOrgCode = sysOrgCode; + } + + public String getImageAddress() { + return imageAddress; + } + + public void setImageAddress(String imageAddress) { + this.imageAddress = imageAddress; + } + + public String getImagePosition() { + return imagePosition; + } + + public void setImagePosition(String imagePosition) { + this.imagePosition = imagePosition; + } + + public String getImageTitle() { + return imageTitle; + } + + public void setImageTitle(String imageTitle) { + this.imageTitle = imageTitle; + } + + public String getImageShortTitle() { + return imageShortTitle; + } + + public void setImageShortTitle(String imageShortTitle) { + this.imageShortTitle = imageShortTitle; + } + + public String getImageDescribe() { + return imageDescribe; + } + + public void setImageDescribe(String imageDescribe) { + this.imageDescribe = imageDescribe; + } + + public String getClassificationId() { + return classificationId; + } + + public void setClassification_id(String classificationId) { + this.classificationId = classificationId; + } + + + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwParamBean.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwParamBean.java new file mode 100644 index 0000000..0745e1f --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwParamBean.java @@ -0,0 +1,108 @@ +package org.jeecg.modules.demo.officialWebsite.api.bean; + +import org.springframework.format.annotation.DateTimeFormat; + +public class ApiOwParamBean { + + private String id; + private String createBy; + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private String createTime; + private String updateBy; + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private String updateTime; + private String sysOrgCode; + private String paramCode; + private String paramValue; + private String paramDesc; + + //无参构造 + public ApiOwParamBean() { + } + + //有参构造 + public ApiOwParamBean(String id, String createBy, String createTime, String updateBy, String updateTime, String sysOrgCode, String paramCode, String paramValue, String paramDesc) { + this.id = id; + this.createBy = createBy; + this.createTime = createTime; + this.updateBy = updateBy; + this.updateTime = updateTime; + this.sysOrgCode = sysOrgCode; + this.paramCode = paramCode; + this.paramValue = paramValue; + this.paramDesc = paramDesc; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getCreateBy() { + return createBy; + } + + public void setCreateBy(String createBy) { + this.createBy = createBy; + } + + public String getCreateTime() { + return createTime; + } + + public void setCreateTime(String createTime) { + this.createTime = createTime; + } + + public String getUpdateBy() { + return updateBy; + } + + public void setUpdateBy(String updateBy) { + this.updateBy = updateBy; + } + + public String getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(String updateTime) { + this.updateTime = updateTime; + } + + public String getSysOrgCode() { + return sysOrgCode; + } + + public void setSysOrgCode(String sysOrgCode) { + this.sysOrgCode = sysOrgCode; + } + + public String getParamCode() { + return paramCode; + } + + public void setParamCode(String paramCode) { + this.paramCode = paramCode; + } + + public String getParamValue() { + return paramValue; + } + + public void setParamValue(String paramValue) { + this.paramValue = paramValue; + } + + public String getParamDesc() { + return paramDesc; + } + + public void setParamDesc(String paramDesc) { + this.paramDesc = paramDesc; + } + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwProductBean.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwProductBean.java new file mode 100644 index 0000000..021d09e --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/bean/ApiOwProductBean.java @@ -0,0 +1,169 @@ +package org.jeecg.modules.demo.officialWebsite.api.bean; + +import org.springframework.format.annotation.DateTimeFormat; + +import java.util.Date; + +public class ApiOwProductBean { + + private String id; + private String createBy; + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private Date createTime; + private String updateBy; + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private Date updateTime; + private String sysOrgCode; + private String productImageAddress; + private String productImagePosition; + private String productTitle; + private String productShortTitle; + private String productDescribe; + private String classificationId; + private String isHot; + private String productAddressMc; + private String productAddressNet; + + //无参构造 + public ApiOwProductBean() { + } + + //有参构造 + public ApiOwProductBean(String id, String createBy, Date createTime, String updateBy, Date updateTime, String sysOrgCode, String productImageAddress, String productImagePosition, String productTitle, String productShortTitle, String productDescribe, String classificationId, String isHot, String productAddressMc, String productAddressNet) { + this.id = id; + this.createBy = createBy; + this.createTime = createTime; + this.updateBy = updateBy; + this.updateTime = updateTime; + this.sysOrgCode = sysOrgCode; + this.productImageAddress = productImageAddress; + this.productImagePosition = productImagePosition; + this.productTitle = productTitle; + this.productShortTitle = productShortTitle; + this.productDescribe = productDescribe; + this.classificationId = classificationId; + this.isHot = isHot; + this.productAddressMc = productAddressMc; + this.productAddressNet = productAddressNet; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getCreateBy() { + return createBy; + } + + public void setCreateBy(String createBy) { + this.createBy = createBy; + } + + public Date getCreateTime() { + return createTime; + } + + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + public String getUpdateBy() { + return updateBy; + } + + public void setUpdateBy(String updateBy) { + this.updateBy = updateBy; + } + + public Date getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + public String getSysOrgCode() { + return sysOrgCode; + } + + public void setSysOrgCode(String sysOrgCode) { + this.sysOrgCode = sysOrgCode; + } + + public String getProductImageAddress() { + return productImageAddress; + } + + public void setProductImageAddress(String productImageAddress) { + this.productImageAddress = productImageAddress; + } + + public String getProductImagePosition() { + return productImagePosition; + } + + public void setProductImagePosition(String productImagePosition) { + this.productImagePosition = productImagePosition; + } + + public String getProductTitle() { + return productTitle; + } + + public void setProductTitle(String productTitle) { + this.productTitle = productTitle; + } + + public String getProductShortTitle() { + return productShortTitle; + } + + public void setProductShortTitle(String productShortTitle) { + this.productShortTitle = productShortTitle; + } + + public String getProductDescribe() { + return productDescribe; + } + + public void setProductDescribe(String productDescribe) { + this.productDescribe = productDescribe; + } + + public String getClassificationId() { + return classificationId; + } + + public void setClassificationId(String classificationId) { + this.classificationId = classificationId; + } + + public String getIsHot() { + return isHot; + } + + public void setIsHot(String isHot) { + this.isHot = isHot; + } + + public String getProductAddressMc() { + return productAddressMc; + } + + public void setProductAddressMc(String productAddressMc) { + this.productAddressMc = productAddressMc; + } + + public String getProductAddressNet() { + return productAddressNet; + } + + public void setProductAddressNet(String productAddressNet) { + this.productAddressNet = productAddressNet; + } +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwClassificationController.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwClassificationController.java new file mode 100644 index 0000000..53dbaf3 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwClassificationController.java @@ -0,0 +1,80 @@ +package org.jeecg.modules.demo.officialWebsite.api.controller; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import lombok.extern.slf4j.Slf4j; +import org.jeecg.common.aspect.annotation.AutoLog; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwClassificationBean; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwClassificationService; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import java.util.List; + +@Api(tags="图片分类表") +@RestController +@RequestMapping("/apiOwClassification") +@Slf4j +public class ApiOwClassificationController { + + @Resource + private ApiOwClassificationService apiOwClassificationService; + + //查询所有分类 + @AutoLog(value = "图片分类表-查询所有") + @ApiOperation(value="图片分类表-查询所有", notes="根据传入的参数进行条件查询") + @GetMapping(value = "/queryAllClassification") + public List queryAllClassification(ApiOwClassificationBean apiOwClassificationBean){ + return apiOwClassificationService.queryAllClassification(apiOwClassificationBean); + } + + //新增分类 + @AutoLog(value = "图片分类表-新增") + @ApiOperation(value="图片分类表-新增", notes="新增分类") + @PostMapping(value = "/addClassification") + public String addClassification(ApiOwClassificationBean apiOwClassificationBean){ + String massage = "添加失败!"; + //执行新增操作 + int result = apiOwClassificationService.addClassification(apiOwClassificationBean); + //判断新增操作是否成功 + if(result > 0){ + massage = "添加成功!"; + } + + return massage; + } + + //删除分类 + @AutoLog(value = "图片分类表-删除") + @ApiOperation(value="图片分类表-删除", notes="删除分类") + @DeleteMapping(value = "/deleteClassification") + public String deleteClassification(String id){ + String massage = "删除失败!"; + //执行删除操作 + int result = apiOwClassificationService.deleteClassification(id); + //判断删除操作是否成功 + if(result > 0){ + massage = "删除成功!"; + } + + return massage; + } + + //修改分类 + @AutoLog(value = "图片分类表-修改") + @ApiOperation(value="图片分类表-修改", notes="修改分类") + @RequestMapping(value = "/updateClassification", method = {RequestMethod.PUT,RequestMethod.POST}) + public String updateClassification(ApiOwClassificationBean apiOwClassificationBean){ + String massage = "修改失败!"; + //执行修改操作 + int result = apiOwClassificationService.updateClassification(apiOwClassificationBean); + //判断修改操作是否成功 + if(result > 0){ + massage = "修改成功!"; + } + + return massage; + } + + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwImageController.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwImageController.java new file mode 100644 index 0000000..3dd7d5b --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwImageController.java @@ -0,0 +1,83 @@ +package org.jeecg.modules.demo.officialWebsite.api.controller; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import lombok.extern.slf4j.Slf4j; +import org.jeecg.common.aspect.annotation.AutoLog; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwImageBean; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwImageService; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import java.util.List; + +@Api(tags="图片信息表") +@RestController +@RequestMapping("/apiOwImage") +@Slf4j +public class ApiOwImageController { + + @Resource + private ApiOwImageService apiOwImageService; + + @AutoLog(value = "图片信息表-查询所有") + @ApiOperation(value="图片信息表-查询所有", notes="根据传入的参数进行条件查询") + @GetMapping(value = "/queryAll") + public List queryAll(ApiOwImageBean apiOwImageBean){ + List list = apiOwImageService.queryAll(apiOwImageBean); + return list; + } + + @AutoLog(value = "图片信息表-添加") + @ApiOperation(value="图片信息表-添加", notes="图片信息表-添加") + @PostMapping(value = "/addImage") + public String addImage(ApiOwImageBean apiOwImageBean){ + String massage = "添加失败!"; + //执行新增操作 + int result = apiOwImageService.addImage(apiOwImageBean); + //判断新增操作是否成功 + if(result > 0){ + massage = "添加成功!"; + } + + return massage; + } + + /** + * 图片信息表-通过id删除 + * @param id + * @return + */ + @AutoLog(value = "图片信息表-通过id删除") + @ApiOperation(value="图片信息表-通过id删除", notes="图片信息表-通过id删除") + @DeleteMapping(value = "/deleteImage") + public String deleteImage(String id){ + String message = "删除失败!"; + //执行删除操作 + int result = apiOwImageService.deleteImage(id); + //判断删除操作是否成功 + if(result > 0){ + message = "删除成功!"; + } + + return message; + + } + + //修改图片信息 + @AutoLog(value = "图片信息表-修改") + @ApiOperation(value="图片信息表-修改", notes="图片信息表-修改") + @RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST}) + public String updateImage(ApiOwImageBean apiOwImageBean){ + String message = "修改失败!"; + //执行修改操作 + int result = apiOwImageService.updateImage(apiOwImageBean); + //判断修改操作是否成功 + if(result > 0){ + message = "修改成功!"; + } + + return message; + } + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwParamController.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwParamController.java new file mode 100644 index 0000000..775ad1b --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwParamController.java @@ -0,0 +1,81 @@ +package org.jeecg.modules.demo.officialWebsite.api.controller; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import lombok.extern.slf4j.Slf4j; +import org.jeecg.common.aspect.annotation.AutoLog; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwParamBean; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwParamService; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestMethod; +import org.springframework.web.bind.annotation.RestController; + +import javax.annotation.Resource; +import java.util.List; + +@Api(tags = "参数配置表") +@RestController +@RequestMapping("/apiOwParam") +@Slf4j +public class ApiOwParamController { + + @Resource + private ApiOwParamService apiOwParamService; + + //查询所有 + @AutoLog(value = "参数配置表-查询所有") + @ApiOperation(value = "参数配置表-查询所有", notes = "根据传入参数进行查询") + @RequestMapping(value = "/queryAll", method = {RequestMethod.GET}) + public List queryAll(ApiOwParamBean apiOwParamBean){ + return apiOwParamService.queryAll(apiOwParamBean); + } + + //新增参数 + @AutoLog(value = "参数配置表-新增参数") + @ApiOperation(value = "参数配置表-新增参数", notes = "新增参数") + @RequestMapping(value = "/addParam", method = {RequestMethod.POST}) + public String addParam(ApiOwParamBean apiOwParamBean){ + String massage = "添加失败!"; + //执行新增操作 + int result = apiOwParamService.addParam(apiOwParamBean); + //判断新增操作是否成功 + if(result > 0){ + massage = "添加成功!"; + } + + return massage; + } + + //删除参数 + @AutoLog(value = "参数配置表-删除参数") + @ApiOperation(value = "参数配置表-删除参数", notes = "删除参数") + @RequestMapping(value = "/deleteParam", method = {RequestMethod.DELETE}) + public String deleteParam(String id){ + String massage = "删除失败!"; + //执行删除操作 + int result = apiOwParamService.deleteParam(id); + //判断删除操作是否成功 + if(result > 0){ + massage = "删除成功!"; + } + + return massage; + } + + //修改参数 + @AutoLog(value = "参数配置表-修改参数") + @ApiOperation(value = "参数配置表-修改参数", notes = "修改参数") + @RequestMapping(value = "/updateParam", method = {RequestMethod.PUT,RequestMethod.POST}) + public String updateParam(ApiOwParamBean apiOwParamBean){ + String massage = "修改失败!"; + //执行修改操作 + int result = apiOwParamService.updateParam(apiOwParamBean); + //判断修改操作是否成功 + if(result > 0){ + massage = "修改成功!"; + } + + return massage; + } + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwProductController.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwProductController.java new file mode 100644 index 0000000..4f1817a --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/controller/ApiOwProductController.java @@ -0,0 +1,82 @@ +package org.jeecg.modules.demo.officialWebsite.api.controller; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import lombok.extern.slf4j.Slf4j; +import org.jeecg.common.aspect.annotation.AutoLog; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwProductBean; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwProductService; +import org.springframework.stereotype.Controller; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestMethod; +import org.springframework.web.bind.annotation.RestController; + +import javax.annotation.Resource; +import java.util.List; + +@Api(tags = "产品信息表") +@RestController +@RequestMapping(value = "/apiOwProduct") +@Slf4j +public class ApiOwProductController { + + @Resource + private ApiOwProductService apiOwProductService; + + //查询所有 + @AutoLog(value = "产品信息表-查询所有") + @ApiOperation(value = "产品信息表-查询所有", notes = "查询所有") + @RequestMapping(value = "/queryAll", method = {RequestMethod.GET}) + public List queryAll(ApiOwProductBean apiOwProductBean){ + return apiOwProductService.queryAll(apiOwProductBean); + } + + //新增产品信息 + @AutoLog(value = "产品信息表-新增产品信息") + @ApiOperation(value = "产品信息表-新增产品信息", notes = "新增产品信息") + @RequestMapping(value = "/addProduct", method = {RequestMethod.POST}) + public String addProduct(ApiOwProductBean apiOwProductBean){ + String massage = "添加失败!"; + //执行新增操作 + int result = apiOwProductService.addProduct(apiOwProductBean); + //判断新增操作是否成功 + if(result > 0){ + massage = "添加成功!"; + } + + return massage; + } + + //删除产品信息 + @AutoLog(value = "产品信息表-删除产品信息") + @ApiOperation(value = "产品信息表-删除产品信息", notes = "删除产品信息") + @RequestMapping(value = "/deleteProduct", method = {RequestMethod.DELETE}) + public String deleteProduct(String id){ + String massage = "删除失败!"; + //执行删除操作 + int result = apiOwProductService.deleteProduct(id); + //判断删除操作是否成功 + if(result > 0){ + massage = "删除成功!"; + } + + return massage; + } + + //修改产品信息 + @AutoLog(value = "产品信息表-修改产品信息") + @ApiOperation(value = "产品信息表-修改产品信息", notes = "修改产品信息") + @RequestMapping(value = "/updateProduct", method = {RequestMethod.PUT,RequestMethod.POST}) + public String updateProduct(ApiOwProductBean apiOwProductBean){ + String massage = "修改失败!"; + //执行修改操作 + int result = apiOwProductService.updateProduct(apiOwProductBean); + //判断修改操作是否成功 + if(result > 0){ + massage = "修改成功!"; + } + + return massage; + } + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwClassificationMapper.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwClassificationMapper.java new file mode 100644 index 0000000..d5077ef --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwClassificationMapper.java @@ -0,0 +1,23 @@ +package org.jeecg.modules.demo.officialWebsite.api.mapper; + +import org.apache.ibatis.annotations.Mapper; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwClassificationBean; + +import java.util.List; + +@Mapper +public interface ApiOwClassificationMapper { + + //查询所有 + public List queryAllClassification(ApiOwClassificationBean apiOwClassificationBean); + + //新增分类 + public int addClassification(ApiOwClassificationBean apiOwClassificationBean); + + //删除分类 + public int deleteClassification(String id); + + //修改分类 + public int updateClassification(ApiOwClassificationBean apiOwClassificationBean); + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwImageMapper.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwImageMapper.java new file mode 100644 index 0000000..f311943 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwImageMapper.java @@ -0,0 +1,22 @@ +package org.jeecg.modules.demo.officialWebsite.api.mapper; + +import org.apache.ibatis.annotations.Mapper; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwImageBean; + +import java.util.List; + +@Mapper +public interface ApiOwImageMapper { + + //查询所有 + public List queryAll(ApiOwImageBean apiOwImageBean); + + //新增图片信息 + public int addImage(ApiOwImageBean apiOwImageBean); + + //删除图片信息 + public int deleteImage(String id); + + //修改图片信息 + public int updateImage(ApiOwImageBean apiOwImageBean); +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwParamMapper.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwParamMapper.java new file mode 100644 index 0000000..69a77ac --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwParamMapper.java @@ -0,0 +1,23 @@ +package org.jeecg.modules.demo.officialWebsite.api.mapper; + +import org.apache.ibatis.annotations.Mapper; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwParamBean; + +import java.util.List; + +@Mapper +public interface ApiOwParamMapper { + + //查询所有 + public List queryAll(ApiOwParamBean apiOwParamBean); + + //新增参数 + public int addParam(ApiOwParamBean apiOwParamBean); + + //删除参数 + public int deleteParam(String id); + + //修改参数 + public int updateParam(ApiOwParamBean apiOwParamBean); + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwProductMapper.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwProductMapper.java new file mode 100644 index 0000000..17aa921 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/ApiOwProductMapper.java @@ -0,0 +1,22 @@ +package org.jeecg.modules.demo.officialWebsite.api.mapper; + +import org.apache.ibatis.annotations.Mapper; +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwProductBean; + +import java.util.List; + +@Mapper +public interface ApiOwProductMapper { + + //查询所有 + public List queryAll(ApiOwProductBean apiOwProductBean); + + //新增产品信息 + public int addProduct(ApiOwProductBean apiOwProductBean); + + //删除产品信息 + public int deleteProduct(String id); + + //修改产品信息 + public int updateProduct(ApiOwProductBean apiOwProductBean); +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwClassificationMapper.xml b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwClassificationMapper.xml new file mode 100644 index 0000000..abfc5f3 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwClassificationMapper.xml @@ -0,0 +1,47 @@ + + + + + + + + + + insert into ow_classification (id,create_by,create_time,update_by,update_time,sys_org_code,has_child,pid,name) + values + (#{id},#{createBy},#{createTime},#{updateBy},#{updateTime},#{sysOrgCode},#{hasChild},#{pid},#{name}); + + + + + delete from ow_classification where id = #{id} + + + + + update ow_classification + + create_by = #{createBy} + update_by = #{updateBy} + sys_org_code = #{sysOrgCode} + has_child = #{hasChild} + pid = #{pid} + name = #{name} + + where id = #{id} + + + \ No newline at end of file diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwImageMapper.xml b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwImageMapper.xml new file mode 100644 index 0000000..28a81ca --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwImageMapper.xml @@ -0,0 +1,54 @@ + + + + + + + + + + insert into ow_image (id,create_by,create_time,update_by,update_time,sys_org_code,image_address,image_position,image_title,image_short_title,image_describe,classification_id) + values + (#{id},#{createBy},#{createTime},#{updateBy},#{updateTime},#{sysOrgCode},#{imageAddress},#{imagePosition},#{imageTitle},#{imageShortTitle},#{imageDescribe},#{classificationId}) + + + + + delete from ow_image where id = #{id} + + + + + update ow_image + + create_by = #{createBy} + update_by = #{updateBy} + sys_org_code = #{sysOrgCode} + image_address = #{imageAddress} + image_position = #{imagePosition} + image_title = #{imageTitle} + image_short_title = #{imageShortTitle} + image_describe = #{imageDescribe} + classification_id = #{classificationId} + + where id = #{id} + + + + \ No newline at end of file diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwParamMapper.xml b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwParamMapper.xml new file mode 100644 index 0000000..939fd21 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwParamMapper.xml @@ -0,0 +1,52 @@ + + + + + + + + + + insert into ow_param (id,create_by,create_time,update_by,update_time,sys_org_code,param_code,param_value,param_desc) + values + (#{id},#{createBy},#{createTime},#{updateBy},#{updateTime},#{sysOrgCode},#{paramCode},#{paramValue},#{paramDesc}) + + + + + delete from ow_param where id = #{id} + + + + + update ow_param + + create_by = #{createBy} + create_time = #{createTime} + update_by = #{updateBy} + update_time = #{updateTime} + sys_org_code = #{sysOrgCode} + param_code = #{paramCode} + param_value = #{paramValue} + param_desc = #{paramDesc} + + where id = #{id} + + + + \ No newline at end of file diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwProductMapper.xml b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwProductMapper.xml new file mode 100644 index 0000000..ebb3847 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/mapper/xml/ApiOwProductMapper.xml @@ -0,0 +1,64 @@ + + + + + + + + + + insert into ow_product (id,create_by,create_time,update_by,update_time,sys_org_code,product_image_address,product_image_position,product_title,product_short_title,product_describe,classification_id,is_hot,product_address_mc,product_address_net) + values + (#{id},#{createBy},#{createTime},#{updateBy},#{updateTime},#{sysOrgCode},#{productImageAddress},#{productImagePosition},#{productTitle},#{productShortTitle},#{productDescribe},#{classificationId},#{isHot},#{productAddressMc},#{productAddressNet}) + + + + + delete from ow_product where id = #{id} + + + + + update ow_product + + create_by = #{createBy} + create_time = #{createTime} + update_by = #{updateBy} + + sys_org_code = #{sysOrgCode} + product_image_address = #{productImageAddress} + product_image_position = #{productImagePosition} + product_title = #{productTitle} + product_short_title = #{productShortTitle} + product_describe = #{productDescribe} + classification_id = #{classificationId} + is_hot = #{isHot} + product_address_mc = #{productAddressMc} + product_address_net = #{productAddressNet} + + where id = #{id} + + + + \ No newline at end of file diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwClassificationService.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwClassificationService.java new file mode 100644 index 0000000..d261328 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwClassificationService.java @@ -0,0 +1,21 @@ +package org.jeecg.modules.demo.officialWebsite.api.service; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwClassificationBean; + +import java.util.List; + +public interface ApiOwClassificationService { + + //查询所有 + public List queryAllClassification(ApiOwClassificationBean apiOwClassificationBean); + + //新增分类 + public int addClassification(ApiOwClassificationBean apiOwClassificationBean); + + //删除分类 + public int deleteClassification(String id); + + //修改分类 + public int updateClassification(ApiOwClassificationBean apiOwClassificationBean); + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwImageService.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwImageService.java new file mode 100644 index 0000000..bfcbd22 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwImageService.java @@ -0,0 +1,22 @@ +package org.jeecg.modules.demo.officialWebsite.api.service; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwImageBean; +import org.springframework.stereotype.Service; + +import java.util.List; + +public interface ApiOwImageService { + + //查询所有 + public List queryAll(ApiOwImageBean apiOwImageBean); + + //新增图片信息 + public int addImage(ApiOwImageBean apiOwImageBean); + + //删除图片信息 + public int deleteImage(String id); + + //修改图片信息 + public int updateImage(ApiOwImageBean apiOwImageBean); + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwParamService.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwParamService.java new file mode 100644 index 0000000..0ffa17d --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwParamService.java @@ -0,0 +1,21 @@ +package org.jeecg.modules.demo.officialWebsite.api.service; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwParamBean; + +import java.util.List; + +public interface ApiOwParamService { + + //查询所有 + public List queryAll(ApiOwParamBean apiOwParamBean); + + //新增参数 + public int addParam(ApiOwParamBean apiOwParamBean); + + //删除参数 + public int deleteParam(String id); + + //修改参数 + public int updateParam(ApiOwParamBean apiOwParamBean); + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwProductService.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwProductService.java new file mode 100644 index 0000000..d4d3da0 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/ApiOwProductService.java @@ -0,0 +1,21 @@ +package org.jeecg.modules.demo.officialWebsite.api.service; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwProductBean; + +import java.util.List; + +public interface ApiOwProductService { + + //查询所有 + public List queryAll(ApiOwProductBean apiOwProductBean); + + //新增产品信息 + public int addProduct(ApiOwProductBean apiOwProductBean); + + //删除产品信息 + public int deleteProduct(String id); + + //修改产品信息 + public int updateProduct(ApiOwProductBean apiOwProductBean); + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwClassificationServiceImpl.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwClassificationServiceImpl.java new file mode 100644 index 0000000..d765a14 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwClassificationServiceImpl.java @@ -0,0 +1,50 @@ +package org.jeecg.modules.demo.officialWebsite.api.service.impl; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwClassificationBean; +import org.jeecg.modules.demo.officialWebsite.api.mapper.ApiOwClassificationMapper; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwClassificationService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +@Service +public class ApiOwClassificationServiceImpl implements ApiOwClassificationService { + + @Resource + private ApiOwClassificationMapper apiOwClassificationMapper; + + //查询所有 + @Override + public List queryAllClassification(ApiOwClassificationBean apiOwClassificationBean) { + return apiOwClassificationMapper.queryAllClassification(apiOwClassificationBean); + } + + //新增分类 + @Override + public int addClassification(ApiOwClassificationBean apiOwClassificationBean) { + return apiOwClassificationMapper.addClassification(apiOwClassificationBean); + } + + //删除分类 + @Override + public int deleteClassification(String id) { + return apiOwClassificationMapper.deleteClassification(id); + } + + //修改分类 + @Override + public int updateClassification(ApiOwClassificationBean apiOwClassificationBean) { + return apiOwClassificationMapper.updateClassification(apiOwClassificationBean); + } + + + + + + + + + + +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwImageServiceImpl.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwImageServiceImpl.java new file mode 100644 index 0000000..e4d0dd7 --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwImageServiceImpl.java @@ -0,0 +1,40 @@ +package org.jeecg.modules.demo.officialWebsite.api.service.impl; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwImageBean; +import org.jeecg.modules.demo.officialWebsite.api.mapper.ApiOwImageMapper; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwImageService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +@Service +public class ApiOwImageServiceImpl implements ApiOwImageService { + + @Resource + private ApiOwImageMapper apiOwImageMapper; + + //查询所有 + @Override + public List queryAll(ApiOwImageBean apiOwImageBean) { + return apiOwImageMapper.queryAll(apiOwImageBean); + } + + //新增图片信息 + @Override + public int addImage(ApiOwImageBean apiOwImageBean) { + return apiOwImageMapper.addImage(apiOwImageBean); + } + + //删除图片信息 + @Override + public int deleteImage(String id) { + return apiOwImageMapper.deleteImage(id); + } + + //修改图片信息 + @Override + public int updateImage(ApiOwImageBean apiOwImageBean) { + return apiOwImageMapper.updateImage(apiOwImageBean); + } +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwParamServiceImpl.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwParamServiceImpl.java new file mode 100644 index 0000000..465ed4a --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwParamServiceImpl.java @@ -0,0 +1,40 @@ +package org.jeecg.modules.demo.officialWebsite.api.service.impl; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwParamBean; +import org.jeecg.modules.demo.officialWebsite.api.mapper.ApiOwParamMapper; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwParamService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +@Service +public class ApiOwParamServiceImpl implements ApiOwParamService { + + @Resource + private ApiOwParamMapper apiOwParamMapper; + + //查询所有 + @Override + public List queryAll(ApiOwParamBean apiOwParamBean) { + return apiOwParamMapper.queryAll(apiOwParamBean); + } + + //新增参数 + @Override + public int addParam(ApiOwParamBean apiOwParamBean) { + return apiOwParamMapper.addParam(apiOwParamBean); + } + + //删除参数 + @Override + public int deleteParam(String id) { + return apiOwParamMapper.deleteParam(id); + } + + //修改参数 + @Override + public int updateParam(ApiOwParamBean apiOwParamBean) { + return apiOwParamMapper.updateParam(apiOwParamBean); + } +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwProductServiceImpl.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwProductServiceImpl.java new file mode 100644 index 0000000..d89ee6e --- /dev/null +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/api/service/impl/ApiOwProductServiceImpl.java @@ -0,0 +1,40 @@ +package org.jeecg.modules.demo.officialWebsite.api.service.impl; + +import org.jeecg.modules.demo.officialWebsite.api.bean.ApiOwProductBean; +import org.jeecg.modules.demo.officialWebsite.api.mapper.ApiOwProductMapper; +import org.jeecg.modules.demo.officialWebsite.api.service.ApiOwProductService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +@Service +public class ApiOwProductServiceImpl implements ApiOwProductService { + + @Resource + private ApiOwProductMapper apiOwProductMapper; + + //查询所有 + @Override + public List queryAll(ApiOwProductBean apiOwProductBean) { + return apiOwProductMapper.queryAll(apiOwProductBean); + } + + //新增产品信息 + @Override + public int addProduct(ApiOwProductBean apiOwProductBean) { + return apiOwProductMapper.addProduct(apiOwProductBean); + } + + //删除产品信息 + @Override + public int deleteProduct(String id) { + return apiOwProductMapper.deleteProduct(id); + } + + //修改产品信息 + @Override + public int updateProduct(ApiOwProductBean apiOwProductBean) { + return apiOwProductMapper.updateProduct(apiOwProductBean); + } +} diff --git a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/owImage/entity/OwImage.java b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/owImage/entity/OwImage.java index 06812a4..4f6d536 100644 --- a/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/owImage/entity/OwImage.java +++ b/jeecg-module-officialWebsit/src/main/java/org/jeecg/modules/demo/officialWebsite/owImage/entity/OwImage.java @@ -58,7 +58,7 @@ public class OwImage implements Serializable { /**图片地址*/ @Excel(name = "图片地址", width = 15) @ApiModelProperty(value = "图片地址") - private java.lang.String imagegAddress; + private java.lang.String imageAddress; /**图片坐标*/ @Excel(name = "图片坐标", width = 15) @ApiModelProperty(value = "图片坐标") @@ -70,7 +70,7 @@ public class OwImage implements Serializable { /**图片短标题*/ @Excel(name = "图片短标题", width = 15) @ApiModelProperty(value = "图片短标题") - private java.lang.String imageeShortTitle; + private java.lang.String imageShortTitle; /**图片描述*/ @Excel(name = "图片描述", width = 15) @ApiModelProperty(value = "图片描述")