mirror of
https://github.com/TeaOSLab/EdgeCommon.git
synced 2026-01-01 08:16:41 +08:00
实现IP黑白名单、国家|地区封禁、省份封禁
This commit is contained in:
@@ -32,7 +32,8 @@ type RegionCountry struct {
|
||||
|
||||
Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
|
||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Pinyin []string `protobuf:"bytes,3,rep,name=pinyin,proto3" json:"pinyin,omitempty"`
|
||||
Codes []string `protobuf:"bytes,3,rep,name=codes,proto3" json:"codes,omitempty"`
|
||||
Pinyin []string `protobuf:"bytes,4,rep,name=pinyin,proto3" json:"pinyin,omitempty"`
|
||||
}
|
||||
|
||||
func (x *RegionCountry) Reset() {
|
||||
@@ -81,6 +82,13 @@ func (x *RegionCountry) GetName() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *RegionCountry) GetCodes() []string {
|
||||
if x != nil {
|
||||
return x.Codes
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *RegionCountry) GetPinyin() []string {
|
||||
if x != nil {
|
||||
return x.Pinyin
|
||||
@@ -93,12 +101,14 @@ var File_model_region_country_proto protoreflect.FileDescriptor
|
||||
var file_model_region_country_proto_rawDesc = []byte{
|
||||
0x0a, 0x1a, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x5f, 0x63,
|
||||
0x6f, 0x75, 0x6e, 0x74, 0x72, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x02, 0x70, 0x62,
|
||||
0x22, 0x4b, 0x0a, 0x0d, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x72,
|
||||
0x22, 0x61, 0x0a, 0x0d, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x72,
|
||||
0x79, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69,
|
||||
0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x69, 0x6e, 0x79, 0x69, 0x6e, 0x18,
|
||||
0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x70, 0x69, 0x6e, 0x79, 0x69, 0x6e, 0x42, 0x06, 0x5a,
|
||||
0x04, 0x2e, 0x2f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x64, 0x65, 0x73, 0x18, 0x03,
|
||||
0x20, 0x03, 0x28, 0x09, 0x52, 0x05, 0x63, 0x6f, 0x64, 0x65, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x70,
|
||||
0x69, 0x6e, 0x79, 0x69, 0x6e, 0x18, 0x04, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x70, 0x69, 0x6e,
|
||||
0x79, 0x69, 0x6e, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x2f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
|
||||
Reference in New Issue
Block a user