国家/地区、省份等相关表增加真实ID字段,防止数据表被用户修改时无法对应

This commit is contained in:
GoEdgeLab
2023-07-07 09:52:46 +08:00
parent 1b70824e0d
commit 33100dd53f
22 changed files with 13071 additions and 6183 deletions

View File

@@ -48,7 +48,7 @@ func (this *RegionTownService) FindAllRegionTowns(ctx context.Context, req *pb.F
}
pbCity = &pb.RegionCity{
Id: int64(city.Id),
Id: int64(city.ValueId),
Name: city.Name,
Codes: city.DecodeCodes(),
CustomName: city.CustomName,
@@ -58,7 +58,7 @@ func (this *RegionTownService) FindAllRegionTowns(ctx context.Context, req *pb.F
}
pbTowns = append(pbTowns, &pb.RegionTown{
Id: int64(town.Id),
Id: int64(town.ValueId),
Name: town.Name,
Codes: town.DecodeCodes(),
RegionCityId: int64(town.CityId),
@@ -95,7 +95,7 @@ func (this *RegionTownService) FindAllRegionTownsWithRegionCityId(ctx context.Co
var pbCity = &pb.RegionCity{Id: cityId}
pbTowns = append(pbTowns, &pb.RegionTown{
Id: int64(town.Id),
Id: int64(town.ValueId),
Name: town.Name,
Codes: town.DecodeCodes(),
RegionCityId: int64(town.CityId),
@@ -131,7 +131,7 @@ func (this *RegionTownService) FindRegionTown(ctx context.Context, req *pb.FindR
return &pb.FindRegionTownResponse{
RegionTown: &pb.RegionTown{
Id: int64(town.Id),
Id: int64(town.ValueId),
Name: town.Name,
Codes: town.DecodeCodes(),
RegionCityId: int64(town.CityId),