# WalkRoomAddressConfigServiceImpl.java

    package cloud.wconnect.frontoffice.service.walkroomrequest.impl;

    import cloud.wconnect.frontoffice.entity.walkroomrequest.WalkRoomAddressConfig;
    import cloud.wconnect.frontoffice.mapper.walkroomrequest.WalkRoomAddressConfigMapper;
    import cloud.wconnect.frontoffice.service.walkroomrequest.IWalkRoomAddressConfigService;
    import com.baomidou.dynamic.datasource.annotation.DS;
    import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
    import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
    import org.springframework.beans.factory.annotation.Autowired;
    import org.springframework.stereotype.Service;

    /**
     * <p>
     * walk room资产地址配置表 服务实现类
     * </p>
     *
     * @author lichen
     * @since 2023-08-04
     */
    @Service
    @DS("logbook")
    public class WalkRoomAddressConfigServiceImpl extends ServiceImpl<WalkRoomAddressConfigMapper, WalkRoomAddressConfig> implements IWalkRoomAddressConfigService {

        @Autowired
        private WalkRoomAddressConfigMapper walkRoomAddressConfigMapper;

        /**
         * 保存或修改资产地址
         *
         * @param propertyId 资产id
         * @param address    地址
         * @return void
         * @author lichen
         * @date 2023/8/4
         */
        @Override
        public void saveOrUpdateByUnique(Integer propertyId, String address) {
            walkRoomAddressConfigMapper.saveOrUpdateByUnique(propertyId, address);
        }

        /**
         * 根据资产id查询资产地址
         *
         * @param propertyId 资产id
         * @return cloud.wconnect.frontoffice.entity.walkroomrequest.WalkRoomAddressConfig
         * @author lichen
         * @date 2025/12/30
         */
        @Override
        public WalkRoomAddressConfig getByPropertyId(Integer propertyId) {
            return getOne(new LambdaQueryWrapper<WalkRoomAddressConfig>()
                    .eq(WalkRoomAddressConfig::getPropertyId, propertyId));
        }
    }