Commit 25984274 authored by daniel's avatar daniel

fix(location): 领物导航开发开发完成

parent a50d6e91
package com.dlbridge.jadp.plugins.cmpt.dao.mapper;
import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationCategory;
import com.dlbridge.jadp.plugins.cmpt.dto.LocationCategoryQueryDTO;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@Mapper
public interface LocationCategoryMapper {
int insert(LocationCategory category);
int update(LocationCategory category);
int delete(Integer id);
LocationCategory getById(Integer id);
List<LocationCategory> page(LocationCategoryQueryDTO queryDTO);
int count(LocationCategoryQueryDTO queryDTO);
}
\ No newline at end of file
<?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.dlbridge.jadp.plugins.cmpt.dao.mapper.LocationCategoryMapper">
<insert id="insert" parameterType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationCategory">
INSERT INTO location_category (cmpt_id, parent_id, name, icon, sort_order)
VALUES (#{cmptId}, #{parentId}, #{name}, #{icon}, #{sortOrder})
</insert>
<update id="update" parameterType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationCategory">
UPDATE location_category
<set>
<if test="cmptId != null">
cmpt_id = #{cmptId},
</if>
<if test="parentId != null">
parent_id = #{parentId},
</if>
<if test="name != null">
name = #{name},
</if>
<if test="icon != null">
icon = #{icon},
</if>
<if test="sortOrder != null">
sort_order = #{sortOrder},
</if>
<if test="status != null">
status = #{status}
</if>
</set>
WHERE id = #{id}
</update>
<update id="delete" parameterType="java.lang.Integer">
UPDATE location_category SET del_flag = 1 WHERE id = #{id}
</update>
<select id="getById" parameterType="java.lang.Integer" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationCategory">
SELECT * FROM location_category WHERE id = #{id}
</select>
<select id="page" parameterType="com.dlbridge.jadp.plugins.cmpt.dto.LocationCategoryQueryDTO" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationCategory">
SELECT * FROM location_category
<where>
<if test="cmptId != null">
AND cmpt_id = #{cmptId}
</if>
<if test="parentId != null">
AND parent_id = #{parentId}
</if>
<if test="name != null and name != ''">
AND name LIKE CONCAT('%', #{name}, '%')
</if>
<if test="status != null">
AND status = #{status}
</if>
AND del_flag = 0
</where>
order by sort_order
</select>
<select id="count" parameterType="com.dlbridge.jadp.plugins.cmpt.dto.LocationCategoryQueryDTO" resultType="java.lang.Integer">
SELECT COUNT(*) FROM location_category
<where>
<if test="cmptId != null">
AND cmpt_id = #{cmptId}
</if>
<if test="parentId != null">
AND parent_id = #{parentId}
</if>
<if test="name != null and name != ''">
AND name LIKE CONCAT('%', #{name}, '%')
</if>
AND del_flag = 0
</where>
</select>
</mapper>
package com.dlbridge.jadp.plugins.cmpt.dao.mapper; package com.dlbridge.jadp.plugins.cmpt.dao.mapper;
import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint; import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPointBak;
import com.dlbridge.jadp.plugins.cmpt.dao.model.PointRecord;
import com.dlbridge.jadp.plugins.cmpt.dao.model.UserPoint;
import com.dlbridge.jadp.plugins.partner.bean.BagDelivery;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import java.util.List; import java.util.List;
...@@ -14,15 +11,15 @@ import java.util.List; ...@@ -14,15 +11,15 @@ import java.util.List;
*/ */
public interface LocationMapper { public interface LocationMapper {
void addLocationCategory(LocationPoint locationPoint); void addLocationCategory(LocationPointBak locationPointBak);
void insertLocationPoint(LocationPoint locationPoint); void insertLocationPoint(LocationPointBak locationPointBak);
int delLocationPoint(@Param("id") Integer id); int delLocationPoint(@Param("id") Integer id);
int delLocationCategory(@Param("catId") Integer catId); int delLocationCategory(@Param("catId") Integer catId);
int updateLocationPoint(LocationPoint locationPoint); int updateLocationPoint(LocationPointBak locationPointBak);
List<LocationPoint> queryLocationList(@Param("cmptId") Integer cmptId, @Param("catId") Integer catId); List<LocationPointBak> queryLocationList(@Param("cmptId") Integer cmptId, @Param("catId") Integer catId);
} }
\ No newline at end of file
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.dlbridge.jadp.plugins.cmpt.dao.mapper.LocationMapper"> <mapper namespace="com.dlbridge.jadp.plugins.cmpt.dao.mapper.LocationMapper">
<select id="addLocationCategory" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint"> <select id="addLocationCategory" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPointBak">
call AddLocationCategory(#{cmptId},#{catId},#{catName},#{icon},#{sortOrder}) call AddLocationCategory(#{cmptId},#{catId},#{catName},#{icon},#{sortOrder})
</select> </select>
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
where id = #{id} where id = #{id}
</update> </update>
<select id="queryLocationList" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint"> <select id="queryLocationList" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPointBak">
SELECT SELECT
c.cmpt_id cmptId, c.cmpt_id cmptId,
c.id AS catId, c.id AS catId,
......
package com.dlbridge.jadp.plugins.cmpt.dao.mapper;
import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint;
import com.dlbridge.jadp.plugins.cmpt.dto.LocationPointQueryDTO;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@Mapper
public interface LocationPointMapper {
int insert(LocationPoint point);
int update(LocationPoint point);
int delete(Integer id);
LocationPoint getById(Integer id);
List<LocationPoint> page(LocationPointQueryDTO queryDTO);
int count(LocationPointQueryDTO queryDTO);
}
\ No newline at end of file
<?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.dlbridge.jadp.plugins.cmpt.dao.mapper.LocationPointMapper">
<insert id="insert" parameterType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint">
INSERT INTO location_point (name,icon, sort_order,description,latitude,altitude,longitude,category_id)
VALUES ( #{name}, #{icon}, #{sortOrder},#{description},#{latitude},#{altitude},#{longitude},#{categoryId})
</insert>
<update id="update" parameterType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint">
UPDATE location_point
<set>
<if test="name != null">
name = #{name},
</if>
<if test="icon != null">
icon = #{icon},
</if>
<if test="sortOrder != null">
sort_order = #{sortOrder},
</if>
<if test="status != null">
status = #{status},
</if>
<if test="latitude != null">
latitude = #{latitude},
</if>
<if test="altitude != null">
altitude = #{altitude},
</if>
<if test="longitude != null">
longitude = #{longitude}
</if>
</set>
WHERE id = #{id}
</update>
<delete id="delete" parameterType="java.lang.Integer">
DELETE FROM location_point WHERE id = #{id}
</delete>
<select id="getById" parameterType="java.lang.Integer" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint">
SELECT * FROM location_point WHERE id = #{id}
</select>
<select id="page" parameterType="com.dlbridge.jadp.plugins.cmpt.dto.LocationPointQueryDTO" resultType="com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint">
SELECT * FROM location_point
<where>
<if test="categoryId != null">
AND category_id = #{categoryId}
</if>
</where>
</select>
<select id="count" parameterType="com.dlbridge.jadp.plugins.cmpt.dto.LocationPointQueryDTO" resultType="java.lang.Integer">
SELECT COUNT(*) FROM location_point
<where>
<if test="categoryId != null">
AND category_id = #{categoryId}
</if>
</where>
</select>
</mapper>
\ No newline at end of file
package com.dlbridge.jadp.plugins.cmpt.dao.model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.io.Serializable;
@Data
@ApiModel(value = "定位分类", description = "定位分类")
public class LocationCategory implements Serializable {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "定位分类id", notes = "定位分类id")
private Integer id;
@ApiModelProperty(value = "赛事id", notes = "赛事id")
private Integer cmptId;
@ApiModelProperty(value = "父分类id", notes = "父分类id")
private Integer parentId;
@ApiModelProperty(value = "定位分类名称", notes = "定位分类名称")
private String name;
@ApiModelProperty(value = "定位分类图标", notes = "定位分类图标")
private String icon;
@ApiModelProperty(value = "排序", notes = "排序")
private Integer sortOrder;
@ApiModelProperty(value = "状态", notes = "状态")
private Integer status;
@ApiModelProperty(value = "是否删除", notes = "是否删除")
private Integer delFlag;
}
\ No newline at end of file
...@@ -3,43 +3,31 @@ package com.dlbridge.jadp.plugins.cmpt.dao.model; ...@@ -3,43 +3,31 @@ package com.dlbridge.jadp.plugins.cmpt.dao.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.Data; import lombok.Data;
import java.math.BigDecimal;
@ApiModel(value = "领物导航实体类", description = "领物导航实体类") import java.io.Serializable;
@Data
public class LocationPoint {
@ApiModelProperty(value = "赛事ID", notes = "赛事ID")
private Integer cmptId;
@ApiModelProperty(value = "所属分类ID", notes = "所属分类ID")
private Integer catId;
@ApiModelProperty(value = "分类名", notes = "分类名")
private String catName;
@ApiModelProperty(value = "层级", notes = "层级")
private Integer level;
@ApiModelProperty(value = "图标URL", notes = "图标URL")
private String icon;
@ApiModelProperty(value = "点位ID", notes = "点位ID")
private Integer pointId;
@ApiModelProperty(value = "点位名", notes = "点位名")
private String pointName;
@Data
@ApiModel(value = "位置点", description = "位置点")
public class LocationPoint implements Serializable {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "位置点id", notes = "位置点id")
private Integer id;
@ApiModelProperty(value = "所属分类id", notes = "所属分类id")
private Integer categoryId;
@ApiModelProperty(value = "点位名称", notes = "点位名称")
private String name;
@ApiModelProperty(value = "经度", notes = "经度") @ApiModelProperty(value = "经度", notes = "经度")
private BigDecimal longitude; private java.math.BigDecimal longitude;
@ApiModelProperty(value = "纬度", notes = "纬度") @ApiModelProperty(value = "纬度", notes = "纬度")
private BigDecimal latitude; private java.math.BigDecimal latitude;
@ApiModelProperty(value = "点位描述", notes = "点位描述")
@ApiModelProperty(value = "描述", notes = "描述")
private String description; private String description;
@ApiModelProperty(value = "海拔", notes = "海拔")
private java.math.BigDecimal altitude;
@ApiModelProperty(value = "图标", notes = "图标")
private String icon;
@ApiModelProperty(value = "状态", notes = "状态")
private Integer status;
@ApiModelProperty(value = "排序", notes = "排序") @ApiModelProperty(value = "排序", notes = "排序")
private Integer sortOrder; private Integer sortOrder;
}
} \ No newline at end of file
package com.dlbridge.jadp.plugins.cmpt.dao.model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.math.BigDecimal;
@ApiModel(value = "领物导航实体类", description = "领物导航实体类")
@Data
public class LocationPointBak {
@ApiModelProperty(value = "赛事ID", notes = "赛事ID")
private Integer cmptId;
@ApiModelProperty(value = "所属分类ID", notes = "所属分类ID")
private Integer catId;
@ApiModelProperty(value = "分类名", notes = "分类名")
private String catName;
@ApiModelProperty(value = "层级", notes = "层级")
private Integer level;
@ApiModelProperty(value = "图标URL", notes = "图标URL")
private String icon;
@ApiModelProperty(value = "点位ID", notes = "点位ID")
private Integer pointId;
@ApiModelProperty(value = "点位名", notes = "点位名")
private String pointName;
@ApiModelProperty(value = "经度", notes = "经度")
private BigDecimal longitude;
@ApiModelProperty(value = "纬度", notes = "纬度")
private BigDecimal latitude;
@ApiModelProperty(value = "描述", notes = "描述")
private String description;
@ApiModelProperty(value = "排序", notes = "排序")
private Integer sortOrder;
}
package com.dlbridge.jadp.plugins.cmpt.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
@EqualsAndHashCode(callSuper = false)
@Data
@ApiModel(value = "定位分类查询参数", description = "定位分类查询参数")
public class LocationCategoryQueryDTO extends PageDTO {
@ApiModelProperty(value = "赛事id", notes = "赛事id")
private Integer cmptId;
@ApiModelProperty(value = "父分类id", notes = "父分类id")
private Integer parentId;
@ApiModelProperty(value = "定位分类名称", notes = "定位分类名称")
private String name;
@ApiModelProperty(value = "定位分类状态", notes = "定位分类状态")
private Integer status;
}
package com.dlbridge.jadp.plugins.cmpt.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
@EqualsAndHashCode(callSuper = false)
@Data
@ApiModel(value = "位置点查询参数", description = "位置点查询参数")
public class LocationPointQueryDTO extends PageDTO {
@ApiModelProperty(value = "所属分类id", notes = "所属分类id")
private Integer categoryId;
}
\ No newline at end of file
...@@ -6,4 +6,6 @@ import lombok.Data; ...@@ -6,4 +6,6 @@ import lombok.Data;
public class PageDTO { public class PageDTO {
private Integer pageNum = 1; private Integer pageNum = 1;
private Integer pageSize = 10; private Integer pageSize = 10;
} }
package com.dlbridge.jadp.plugins.cmpt.service;
import com.dlbridge.jadp.plugins.cmpt.dao.mapper.LocationCategoryMapper;
import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationCategory;
import com.dlbridge.jadp.plugins.cmpt.dto.LocationCategoryQueryDTO;
import com.dlbridge.jadp.plugins.cmpt.utils.Page;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
@Service
public class LocationCategoryService {
@Resource
private LocationCategoryMapper locationCategoryMapper;
/**
* 创建定位分类
* @param category 定位分类
* @return 创建后的定位分类
*/
public LocationCategory create(LocationCategory category) {
locationCategoryMapper.insert(category);
return category;
}
/**
* 根据id查询定位分类
* @param id 定位分类id
* @return 定位分类
*/
public LocationCategory detail(Integer id) {
return locationCategoryMapper.getById(id);
}
/**
* 更新定位分类
* @param category 定位分类
* @return 更新后的定位分类
*/
public LocationCategory update(LocationCategory category) {
locationCategoryMapper.update(category);
return category;
}
/**
* 删除定位分类
* @param id 定位分类id
* @return 删除的结果
*/
public int delete(Integer id) {
return locationCategoryMapper.delete(id);
}
/**
* 分页查询定位分类
* @param queryDTO 查询参数
* @return 定位分类列表
*/
public Page<List<LocationCategory>> page(LocationCategoryQueryDTO queryDTO) {
int pageNum = queryDTO.getPageNum();
int pageSize = queryDTO.getPageSize();
// 计算正确的偏移量
int offset = (pageNum - 1) * pageSize;
queryDTO.setPageNum(offset);
List<LocationCategory> categoryList = locationCategoryMapper.page(queryDTO);
int total = locationCategoryMapper.count(queryDTO);
Page<List<LocationCategory>> page = new Page<>();
page.setTotal(total);
page.setFirst(pageNum == 1);
page.setLast(pageNum * pageSize >= total);
page.setCurrent(pageNum);
page.setSize(pageSize);
page.setContent(categoryList);
return page;
}
}
\ No newline at end of file
package com.dlbridge.jadp.plugins.cmpt.service;
import com.dlbridge.jadp.plugins.cmpt.dao.mapper.LocationPointMapper;
import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint;
import com.dlbridge.jadp.plugins.cmpt.dto.LocationPointQueryDTO;
import com.dlbridge.jadp.plugins.cmpt.utils.Page;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
@Service
public class LocationPointService {
@Resource
private LocationPointMapper locationPointMapper;
/**
* 创建位置点
* @param point 位置点
* @return 创建后的位置点
*/
public LocationPoint create(LocationPoint point) {
locationPointMapper.insert(point);
return point;
}
/**
* 根据id查询位置点
* @param id 位置点id
* @return 位置点
*/
public LocationPoint detail(Integer id) {
return locationPointMapper.getById(id);
}
/**
* 更新位置点
* @param point 位置点
* @return 更新后的位置点
*/
public LocationPoint update(LocationPoint point) {
locationPointMapper.update(point);
return point;
}
/**
* 删除位置点
* @param id 位置点id
* @return 删除的结果
*/
public int delete(Integer id) {
return locationPointMapper.delete(id);
}
/**
* 分页查询位置点
* @param queryDTO 查询参数
* @return 位置点列表
*/
public Page<List<LocationPoint>> page(LocationPointQueryDTO queryDTO) {
int pageNum = queryDTO.getPageNum();
int pageSize = queryDTO.getPageSize();
// 计算正确的偏移量
int offset = (pageNum - 1) * pageSize;
queryDTO.setPageNum(offset);
List<LocationPoint> pointList = locationPointMapper.page(queryDTO);
int total = locationPointMapper.count(queryDTO);
Page<List<LocationPoint>> page = new Page<>();
page.setTotal(total);
page.setFirst(pageNum == 1);
page.setLast(pageNum * pageSize >= total);
page.setCurrent(pageNum);
page.setSize(pageSize);
page.setContent(pointList);
return page;
}
}
\ No newline at end of file
package com.dlbridge.jadp.plugins.cmpt.web;
import com.dlbridge.jadp.common.interceptor.PageView;
import com.dlbridge.jadp.plugins.cmpt.dao.model.Cmpt;
import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationCategory;
import com.dlbridge.jadp.plugins.cmpt.dto.LocationCategoryQueryDTO;
import com.dlbridge.jadp.plugins.cmpt.service.CmptService;
import com.dlbridge.jadp.plugins.cmpt.service.LocationCategoryService;
import com.neusoft.www.utils.web.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
import javax.annotation.Resource;
import java.util.ArrayList;
@RestController
@RequestMapping("/gk/location-category")
@Api(value = "区域分类服务", tags = "区域分类服务")
public class LocationCategoryController {
@Resource
private CmptService cmptService;
@Resource
private LocationCategoryService locationCategoryService;
@RequestMapping("index/{cmptId}")
@PageView
public ModelAndView index(@PathVariable("cmptId") Integer cmptId, ModelAndView mv) {
Cmpt cmpt = cmptService.queryCmptBycmptId(cmptId);
mv.setViewName("cmpt/location");
mv.addObject("cmpt", cmpt);
return mv;
}
@PostMapping
@ApiOperation(value = "创建区域分类", notes = "创建新的区域分类")
public Result<LocationCategory> create(@RequestBody LocationCategory category) {
LocationCategory result = locationCategoryService.create(category);
return Result.success().setContent(result);
}
@GetMapping("/{id}")
@ApiOperation(value = "获取区域分类", notes = "根据ID获取区域分类")
public Result<LocationCategory> detail(@PathVariable Integer id) {
LocationCategory category = locationCategoryService.detail(id);
return Result.success().setContent(category);
}
@PutMapping
@ApiOperation(value = "更新区域分类", notes = "根据ID更新区域分类")
public Result<LocationCategory> update(@RequestBody LocationCategory category) {
LocationCategory result = locationCategoryService.update(category);
return Result.success().setContent(result);
}
@DeleteMapping("/{id}")
@ApiOperation(value = "删除区域分类", notes = "根据ID删除区域分类")
public Result<?> delete(@PathVariable Integer id) {
return Result.success().setContent(locationCategoryService.delete(id));
}
@PostMapping("/page")
@ApiOperation(value = "获取区域分类列表", notes = "根据条件获取区域分类列表")
public Result<?> page(@RequestBody LocationCategoryQueryDTO queryDTO) {
if (queryDTO.getPageNum() == null) {
return Result.success().setContent(new ArrayList<>());
}
return Result.success().setContent(locationCategoryService.page(queryDTO));
}
}
\ No newline at end of file
package com.dlbridge.jadp.plugins.cmpt.web;
import com.dlbridge.jadp.common.interceptor.PageView;
import com.dlbridge.jadp.plugins.cmpt.dao.model.Cmpt;
import com.dlbridge.jadp.plugins.cmpt.dao.model.LocationPoint;
import com.dlbridge.jadp.plugins.cmpt.dto.LocationPointQueryDTO;
import com.dlbridge.jadp.plugins.cmpt.service.CmptService;
import com.dlbridge.jadp.plugins.cmpt.service.LocationPointService;
import com.neusoft.www.utils.web.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
import javax.annotation.Resource;
@RestController
@RequestMapping("/gk/location-point")
@Api(value = "位置点服务", tags = "位置点服务")
public class LocationPointController {
@Resource
private LocationPointService locationPointService;
@Resource
private CmptService cmptService;
@RequestMapping("index/{cmptId}")
@PageView
public ModelAndView index(@PathVariable("cmptId") Integer cmptId, ModelAndView mv) {
Cmpt cmpt = cmptService.queryCmptBycmptId(cmptId);
mv.setViewName("cmpt/locationPoint");
mv.addObject("cmpt", cmpt);
return mv;
}
@PostMapping
@ApiOperation(value = "创建位置点", notes = "创建新的位置点")
public Result<LocationPoint> create(@RequestBody LocationPoint point) {
LocationPoint result = locationPointService.create(point);
return Result.success().setContent(result);
}
@GetMapping("/{id}")
@ApiOperation(value = "获取位置点", notes = "根据ID获取位置点")
public Result<LocationPoint> detail(@PathVariable Integer id) {
LocationPoint point = locationPointService.detail(id);
return Result.success().setContent(point);
}
@PutMapping
@ApiOperation(value = "更新位置点", notes = "根据ID更新位置点")
public Result<LocationPoint> update(@RequestBody LocationPoint point) {
LocationPoint result = locationPointService.update(point);
return Result.success().setContent(result);
}
@DeleteMapping("/{id}")
@ApiOperation(value = "删除位置点", notes = "根据ID删除位置点")
public Result<?> delete(@PathVariable Integer id) {
return Result.success().setContent(locationPointService.delete(id));
}
@PostMapping("/page")
@ApiOperation(value = "获取位置点列表", notes = "根据条件获取位置点列表")
public Result<?> page(@RequestBody LocationPointQueryDTO queryDTO) {
return Result.success().setContent(locationPointService.page(queryDTO));
}
}
...@@ -74,6 +74,14 @@ ...@@ -74,6 +74,14 @@
right: 0; right: 0;
bottom: 0; bottom: 0;
} }
.n-dialog__icon>* {
position: absolute;
left: 0;
top: -2px !important;
right: 0;
bottom: 0;
}
</style> </style>
</head> </head>
......
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
<n-alert title="图片要求" type="warning"> <n-alert title="图片要求" type="warning">
建议1081 x 4174 png格式 1MB以内 建议1081 x 4174 png格式 1MB以内
</n-alert> </n-alert>
<n-upload <n-upload
:max="1" :max="1"
@before-upload="beforeUpload" @before-upload="beforeUpload"
:action="uploadUrl" :action="uploadUrl"
......
...@@ -74,6 +74,14 @@ ...@@ -74,6 +74,14 @@
right: 0; right: 0;
bottom: 0; bottom: 0;
} }
.n-dialog__icon>* {
position: absolute;
left: 0;
top: -2px !important;
right: 0;
bottom: 0;
}
</style> </style>
</head> </head>
...@@ -496,7 +504,6 @@ ...@@ -496,7 +504,6 @@
key: 'header', key: 'header',
width: 250, width: 250,
render: (row) => { render: (row) => {
// const images = row.resolveImageUrl?.split(',') ?? []
return h(NSpace, { return h(NSpace, {
vertical: true, vertical: true,
}, [ }, [
...@@ -504,12 +511,6 @@ ...@@ -504,12 +511,6 @@
h(NText, {}, "纳税人识别号:" + (row.taxPayerId ?? '--')), h(NText, {}, "纳税人识别号:" + (row.taxPayerId ?? '--')),
h(NText, {}, "开户行:" + (row.taxBank ?? '--')), h(NText, {}, "开户行:" + (row.taxBank ?? '--')),
h(NText, {}, "开户行账号:" + (row.taxBankAccount ?? '--')), h(NText, {}, "开户行账号:" + (row.taxBankAccount ?? '--')),
// h(NImageGroup, {}, [
// ...images.map((img) => h(NImage, {
// height: "100",
// src: img
// }))
// ]),
]) ])
} }
}, },
......
...@@ -193,7 +193,7 @@ ...@@ -193,7 +193,7 @@
</div> </div>
</n-form-item> </n-form-item>
<n-form-item label="排除字符" > <n-form-item label="排除字符" >
<n-input v-model:value="markNoRuleValue.excludedChars" placeholder="请输入全局排查的字符集" /> <n-input v-model:value="markNoRuleValue.excludedChars" placeholder="请输入全局排查的字符集,多个字符用逗号隔开" />
</n-form-item> </n-form-item>
<n-form-item label="对应性别" path="gender"> <n-form-item label="对应性别" path="gender">
<n-select v-model:value="markNoRuleValue.gender" :options="GenderEnum.data.map(v=>({label:v.name,value:v.value}))" /> <n-select v-model:value="markNoRuleValue.gender" :options="GenderEnum.data.map(v=>({label:v.name,value:v.value}))" />
...@@ -431,19 +431,22 @@ ...@@ -431,19 +431,22 @@
id: undefined, id: undefined,
type: RuleTypeEnum.DIGIT.value, type: RuleTypeEnum.DIGIT.value,
position: 1, position: 1,
fixedValue: '' fixedValue: '',
// excludedChars: '',
}, },
{ {
id: undefined, id: undefined,
type: RuleTypeEnum.DIGIT.value, type: RuleTypeEnum.DIGIT.value,
position: 2, position: 2,
fixedValue: '' fixedValue: '',
// excludedChars: '',
}, },
{ {
id: undefined, id: undefined,
type: RuleTypeEnum.DIGIT.value, type: RuleTypeEnum.DIGIT.value,
position: 3, position: 3,
fixedValue: '' fixedValue: '',
// excludedChars: '',
}, },
],// 选号规则详情 ],// 选号规则详情
waves: [] // 枪次 waves: [] // 枪次
...@@ -596,6 +599,22 @@ ...@@ -596,6 +599,22 @@
}) })
} }
}, },
// {
// title: '排除字符',
// key: 'excludedChars',
// align: 'center',
// width: 200,
// render(row, index) {
// return h(NInput, {
// placeholder: '请输入排除字符,多个逗号隔开',
// value: row.excludedChars,
// disabled: row.type === RuleTypeEnum.FIXED.value,
// onUpdateValue(v) {
// markNoRuleValue.value.details[index].excludedChars = v
// }
// })
// }
// },
] ]
// 选号长度改变 // 选号长度改变
const changeTotalLength = (v) => { const changeTotalLength = (v) => {
......
...@@ -397,6 +397,13 @@ ...@@ -397,6 +397,13 @@
<span class="menu-txt">免责声明</span> <span class="menu-txt">免责声明</span>
</a> </a>
</li> </li>
<li class="location menu-sub-item">
<a
href="/gk/location-category/index/${cmpt.cmptId}?uId=${uId}&cId=${cId}&timestamp=${timestamp}&sign=${sign}">
<span class="left-arrow"></span>
<span class="menu-txt">领物导航</span>
</a>
</li>
</ul> </ul>
</li> </li>
</ul> </ul>
...@@ -459,7 +466,7 @@ ...@@ -459,7 +466,7 @@
var classes = ['cmptSetting', 'nameList', 'manual', 'contact', 'manage', var classes = ['cmptSetting', 'nameList', 'manual', 'contact', 'manage',
'route', 'road', 'equip', 'photo', 'news', 'cert', 'data', 'route', 'road', 'equip', 'photo', 'news', 'cert', 'data',
'banner', 'score', 'auto', 'scan', 'review', 'customer', 'rule', 'banner', 'score', 'auto', 'scan', 'review', 'customer', 'rule',
'outter-link', 'sure-letter', 'rankSetting', 'service', "module", "swiper", "bag", "invoice", "markNoSelect", "feedback", "markNoRule", "gunRule", "disClaimer"]; 'outter-link', 'sure-letter', 'rankSetting', 'service', "module", "swiper", "bag", "invoice", "markNoSelect", "feedback", "markNoRule", "gunRule", "disClaimer", "location"];
let url = document.location.href; let url = document.location.href;
var done = false; var done = false;
for (var i in classes) { for (var i in classes) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment