Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
fe7b406f52
|
@ -25,9 +25,11 @@ public interface CameraOrgenizationMapper extends BaseDao<CameraOrganization> {
|
|||
|
||||
void batchSaveOrgenization(List<Map> list);
|
||||
|
||||
@Select("SELECT name,parent_id,id,path FROM t_camera_organization_cache WHERE id = #{id}")
|
||||
@Select("SELECT name,parent_id,id,path FROM t_camera_organization WHERE id = #{id}")
|
||||
Map selectOrgenizationById(@Param("id") String id);
|
||||
|
||||
Map selectOrgenizationCacheById(@Param("id") String id);
|
||||
|
||||
@Update("UPDATE t_camera_organization SET path = TRIM( TRAILING '->' FROM #{path}) where id = #{id}")
|
||||
void updateOrganizationPaht(@Param("path") String path,@Param("id") String id);
|
||||
|
||||
|
|
|
@ -1251,7 +1251,7 @@ public class MonitorService {
|
|||
|
||||
//更新组织的path
|
||||
public void setOrganizationPath(Map map ,String parentId){
|
||||
Map map2 = cameraOrgenMapper.selectOrgenizationById(parentId);
|
||||
Map map2 = cameraOrgenMapper.selectOrgenizationCacheById(parentId);
|
||||
if(map2 != null){
|
||||
String path = map2.get("name").toString();
|
||||
String newNodeName = path + "->" + (map.get("path")==null?"":map.get("path").toString());
|
||||
|
|
|
@ -65,4 +65,8 @@
|
|||
)
|
||||
SELECT id,name,parent_id,sort,subCount,is_parent,path,is_root,channelCount,count FROM t_camera_organization_cache
|
||||
</insert>
|
||||
|
||||
<select id="selectOrgenizationCacheById" parameterType="java.lang.String" resultType="java.util.Map">
|
||||
SELECT name,parent_id,id,path FROM t_camera_organization_cache WHERE id = #{id}
|
||||
</select>
|
||||
</mapper>
|
Loading…
Reference in New Issue