fix: sale create fields
CI / changes (push) Successful in 14s
CI / docker-bff (push) Successful in 3s
CI / docker-product (push) Successful in 24s
CI / docker-admin (push) Has been skipped
CI / docker-user (push) Has been skipped
CI / docker-ad (push) Has been skipped
CI / docker-chore (push) Successful in 25s
CI / docker-express (push) Has been skipped
CI / docker-sale (push) Successful in 26s
CI / changes (push) Successful in 14s
CI / docker-bff (push) Successful in 3s
CI / docker-product (push) Successful in 24s
CI / docker-admin (push) Has been skipped
CI / docker-user (push) Has been skipped
CI / docker-ad (push) Has been skipped
CI / docker-chore (push) Successful in 25s
CI / docker-express (push) Has been skipped
CI / docker-sale (push) Successful in 26s
This commit is contained in:
@@ -16,6 +16,9 @@ import (
|
||||
type (
|
||||
DecryptMobileReq = chore.DecryptMobileReq
|
||||
PolicyReq = chore.PolicyReq
|
||||
RegionItem = chore.RegionItem
|
||||
RegionsByIdsData = chore.RegionsByIdsData
|
||||
RegionsByIdsReq = chore.RegionsByIdsReq
|
||||
RegionsReq = chore.RegionsReq
|
||||
Response = chore.Response
|
||||
TestReq = chore.TestReq
|
||||
@@ -25,6 +28,8 @@ type (
|
||||
Test(ctx context.Context, in *TestReq, opts ...grpc.CallOption) (*Response, error)
|
||||
DecryptMobile(ctx context.Context, in *DecryptMobileReq, opts ...grpc.CallOption) (*Response, error)
|
||||
Regions(ctx context.Context, in *RegionsReq, opts ...grpc.CallOption) (*Response, error)
|
||||
// 服务间调用:按 id 批量查地区名称
|
||||
RegionsByIds(ctx context.Context, in *RegionsByIdsReq, opts ...grpc.CallOption) (*RegionsByIdsData, error)
|
||||
}
|
||||
|
||||
defaultChore struct {
|
||||
@@ -57,3 +62,9 @@ func (m *defaultChore) Regions(ctx context.Context, in *RegionsReq, opts ...grpc
|
||||
client := chore.NewChoreClient(m.cli.Conn())
|
||||
return client.Regions(ctx, in, opts...)
|
||||
}
|
||||
|
||||
// 服务间调用:按 id 批量查地区名称
|
||||
func (m *defaultChore) RegionsByIds(ctx context.Context, in *RegionsByIdsReq, opts ...grpc.CallOption) (*RegionsByIdsData, error) {
|
||||
client := chore.NewChoreClient(m.cli.Conn())
|
||||
return client.RegionsByIds(ctx, in, opts...)
|
||||
}
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
package logic
|
||||
|
||||
import (
|
||||
"context"
|
||||
"strconv"
|
||||
|
||||
"lone-services/pkg/modelbase"
|
||||
"lone-services/pkg/utils"
|
||||
chore "lone-services/rpc/chore/pb"
|
||||
"lone-services/services/chore/internal/dao"
|
||||
"lone-services/services/chore/internal/model"
|
||||
"lone-services/services/chore/internal/svc"
|
||||
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
"google.golang.org/grpc/codes"
|
||||
"google.golang.org/grpc/status"
|
||||
)
|
||||
|
||||
type RegionsByIdsLogic struct {
|
||||
ctx context.Context
|
||||
svcCtx *svc.ServiceContext
|
||||
logx.Logger
|
||||
}
|
||||
|
||||
func NewRegionsByIdsLogic(ctx context.Context, svcCtx *svc.ServiceContext) *RegionsByIdsLogic {
|
||||
return &RegionsByIdsLogic{
|
||||
ctx: ctx,
|
||||
svcCtx: svcCtx,
|
||||
Logger: logx.WithContext(ctx),
|
||||
}
|
||||
}
|
||||
|
||||
// 服务间调用:按 id 批量查地区名称
|
||||
func (l *RegionsByIdsLogic) RegionsByIds(in *chore.RegionsByIdsReq) (*chore.RegionsByIdsData, error) {
|
||||
if len(in.GetIds()) < utils.NumberOne {
|
||||
return nil, status.Error(codes.InvalidArgument, utils.ErrorParams.Msg)
|
||||
}
|
||||
|
||||
seen := make(map[int64]struct{}, len(in.GetIds()))
|
||||
ids := make([]string, 0, len(in.GetIds()))
|
||||
for _, id := range in.GetIds() {
|
||||
if id < utils.NumberOne {
|
||||
continue
|
||||
}
|
||||
if _, ok := seen[id]; ok {
|
||||
continue
|
||||
}
|
||||
seen[id] = struct{}{}
|
||||
ids = append(ids, strconv.FormatInt(id, 10))
|
||||
}
|
||||
if len(ids) < utils.NumberOne {
|
||||
return nil, status.Error(codes.InvalidArgument, utils.ErrorParams.Msg)
|
||||
}
|
||||
|
||||
var list []dao.Region
|
||||
if err := (model.RegionModel{}.Init().Items(modelbase.Params{
|
||||
In: map[string][]string{"id in ?": ids},
|
||||
}, &list)); err != nil {
|
||||
l.Errorf("regions by ids: %v", err)
|
||||
return nil, status.Error(codes.Internal, utils.Fail.Msg)
|
||||
}
|
||||
|
||||
items := make([]*chore.RegionItem, 0, len(list))
|
||||
for _, row := range list {
|
||||
items = append(items, &chore.RegionItem{
|
||||
Id: int64(row.Id),
|
||||
Name: row.Name,
|
||||
})
|
||||
}
|
||||
return &chore.RegionsByIdsData{Items: items}, nil
|
||||
}
|
||||
@@ -42,3 +42,9 @@ func (s *ChoreServer) Regions(ctx context.Context, in *chore.RegionsReq) (*chore
|
||||
l := logic.NewRegionsLogic(ctx, s.svcCtx)
|
||||
return l.Regions(in)
|
||||
}
|
||||
|
||||
// 服务间调用:按 id 批量查地区名称
|
||||
func (s *ChoreServer) RegionsByIds(ctx context.Context, in *chore.RegionsByIdsReq) (*chore.RegionsByIdsData, error) {
|
||||
l := logic.NewRegionsByIdsLogic(ctx, s.svcCtx)
|
||||
return l.RegionsByIds(in)
|
||||
}
|
||||
|
||||
@@ -59,6 +59,28 @@ func (l *CreateLogic) Create(in *sale.CreateReq) (*sale.Response, error) {
|
||||
return failResponse(utils.ErrorDataIsExist), nil
|
||||
}
|
||||
|
||||
names, nErr := fetchRegionNames(l.ctx, l.svcCtx.ChoreSvcName, req.TerritoryId, req.ProvinceId, req.CityId, req.DistrictId)
|
||||
if nErr != nil {
|
||||
l.Errorf("sale regions: %v", nErr)
|
||||
return failResponse(utils.Fail), nil
|
||||
}
|
||||
territoryName := names[req.TerritoryId]
|
||||
if territoryName == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择地域"), nil
|
||||
}
|
||||
province := names[req.ProvinceId]
|
||||
if province == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择省份"), nil
|
||||
}
|
||||
city := names[req.CityId]
|
||||
if city == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择城市"), nil
|
||||
}
|
||||
district := names[req.DistrictId]
|
||||
if district == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择区县"), nil
|
||||
}
|
||||
|
||||
data := dao.SaleCreate{
|
||||
SaleId: req.SaleId,
|
||||
Mobile: encryptMobile,
|
||||
@@ -66,12 +88,12 @@ func (l *CreateLogic) Create(in *sale.CreateReq) (*sale.Response, error) {
|
||||
IdCardFront: req.IdCardFront,
|
||||
IdCardBack: req.IdCardBack,
|
||||
BusinessLicense: req.BusinessLicense,
|
||||
Region: buildRegion(req.RegionProvince, req.RegionCity, req.RegionDistrict),
|
||||
Region: buildRegion(province, city, district),
|
||||
ProvinceId: req.ProvinceId,
|
||||
CityId: req.CityId,
|
||||
DistrictId: req.DistrictId,
|
||||
TerritoryId: req.TerritoryId,
|
||||
TerritoryName: req.TerritoryName,
|
||||
TerritoryName: territoryName,
|
||||
GroupId: req.GroupId,
|
||||
Address: req.Address,
|
||||
Status: dao.SaleStatusApproved,
|
||||
|
||||
@@ -73,12 +73,33 @@ func (l *EditLogic) Edit(in *sale.EditReq) (*sale.Response, error) {
|
||||
info.IdCardFront = req.IdCardFront
|
||||
info.IdCardBack = req.IdCardBack
|
||||
info.BusinessLicense = req.BusinessLicense
|
||||
info.Region = buildRegion(req.RegionProvince, req.RegionCity, req.RegionDistrict)
|
||||
names, nErr := fetchRegionNames(l.ctx, l.svcCtx.ChoreSvcName, req.TerritoryId, req.ProvinceId, req.CityId, req.DistrictId)
|
||||
if nErr != nil {
|
||||
l.Errorf("sale regions: %v", nErr)
|
||||
return failResponse(utils.Fail), nil
|
||||
}
|
||||
territoryName := names[req.TerritoryId]
|
||||
if territoryName == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择地域"), nil
|
||||
}
|
||||
province := names[req.ProvinceId]
|
||||
if province == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择省份"), nil
|
||||
}
|
||||
city := names[req.CityId]
|
||||
if city == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择城市"), nil
|
||||
}
|
||||
district := names[req.DistrictId]
|
||||
if district == utils.StringEmpty {
|
||||
return outResponse(utils.ErrorParams, "请选择区县"), nil
|
||||
}
|
||||
info.Region = buildRegion(province, city, district)
|
||||
info.ProvinceId = req.ProvinceId
|
||||
info.CityId = req.CityId
|
||||
info.DistrictId = req.DistrictId
|
||||
info.TerritoryId = req.TerritoryId
|
||||
info.TerritoryName = req.TerritoryName
|
||||
info.TerritoryName = territoryName
|
||||
info.GroupId = req.GroupId
|
||||
info.Address = req.Address
|
||||
info.Type = uint8(req.Type)
|
||||
|
||||
@@ -1,10 +1,13 @@
|
||||
package logic
|
||||
|
||||
import (
|
||||
"context"
|
||||
"strconv"
|
||||
|
||||
"lone-services/pkg/modelbase"
|
||||
"lone-services/pkg/rpcclient"
|
||||
"lone-services/pkg/utils"
|
||||
chore "lone-services/rpc/chore/pb"
|
||||
"lone-services/services/sale/internal/dao"
|
||||
"lone-services/services/sale/internal/model"
|
||||
"lone-services/services/sale/validator"
|
||||
@@ -26,6 +29,38 @@ func buildRegion(province, city, district string) dao.RegionNames {
|
||||
}
|
||||
}
|
||||
|
||||
func fetchRegionNames(ctx context.Context, choreSvcName string, ids ...int64) (map[int64]string, error) {
|
||||
seen := make(map[int64]struct{}, len(ids))
|
||||
reqIds := make([]int64, 0, len(ids))
|
||||
for _, id := range ids {
|
||||
if id < utils.NumberOne {
|
||||
continue
|
||||
}
|
||||
if _, ok := seen[id]; ok {
|
||||
continue
|
||||
}
|
||||
seen[id] = struct{}{}
|
||||
reqIds = append(reqIds, id)
|
||||
}
|
||||
result := make(map[int64]string, len(reqIds))
|
||||
if len(reqIds) < utils.NumberOne {
|
||||
return result, nil
|
||||
}
|
||||
|
||||
cli, err := rpcclient.Get(choreSvcName)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
res, err := chore.NewChoreClient(cli.Conn()).RegionsByIds(ctx, &chore.RegionsByIdsReq{Ids: reqIds})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
for _, item := range res.GetItems() {
|
||||
result[item.GetId()] = item.GetName()
|
||||
}
|
||||
return result, nil
|
||||
}
|
||||
|
||||
func querySaleNames(req validator.NamesValidator) ([]dao.SaleNameItem, error) {
|
||||
w := modelbase.Params{
|
||||
Eq: map[string]string{"status": strconv.Itoa(int(dao.SaleStatusApproved))},
|
||||
|
||||
@@ -70,12 +70,6 @@ func (s *SaleServer) Info(ctx context.Context, in *sale.InfoReq) (*sale.Response
|
||||
return l.Info(in)
|
||||
}
|
||||
|
||||
// 服务间调用:销售详情(含分组;mobile 脱敏,origin_mobile 为加密串)
|
||||
func (s *SaleServer) InfoInternal(ctx context.Context, in *sale.InfoReq) (*sale.InfoData, error) {
|
||||
l := logic.NewInfoInternalLogic(ctx, s.svcCtx)
|
||||
return l.InfoInternal(in)
|
||||
}
|
||||
|
||||
func (s *SaleServer) Items(ctx context.Context, in *sale.ItemsReq) (*sale.Response, error) {
|
||||
l := logic.NewItemsLogic(ctx, s.svcCtx)
|
||||
return l.Items(in)
|
||||
@@ -85,3 +79,9 @@ func (s *SaleServer) Status(ctx context.Context, in *sale.StatusReq) (*sale.Resp
|
||||
l := logic.NewStatusLogic(ctx, s.svcCtx)
|
||||
return l.Status(in)
|
||||
}
|
||||
|
||||
// 销售详情
|
||||
func (s *SaleServer) InfoInternal(ctx context.Context, in *sale.InfoReq) (*sale.InfoData, error) {
|
||||
l := logic.NewInfoInternalLogic(ctx, s.svcCtx)
|
||||
return l.InfoInternal(in)
|
||||
}
|
||||
|
||||
@@ -4,19 +4,27 @@ import (
|
||||
"lone-services/pkg/utils"
|
||||
"lone-services/services/sale/internal/config"
|
||||
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
"gorm.io/gorm"
|
||||
)
|
||||
|
||||
type ServiceContext struct {
|
||||
Config config.Config
|
||||
DB *gorm.DB
|
||||
Prefix string
|
||||
Config config.Config
|
||||
DB *gorm.DB
|
||||
Prefix string
|
||||
ChoreSvcName string
|
||||
}
|
||||
|
||||
func NewServiceContext(c config.Config, db *gorm.DB) *ServiceContext {
|
||||
choreSvc := utils.GetConfigString("services.chore")
|
||||
if choreSvc == utils.StringEmpty {
|
||||
logx.Error("config services.chore empty")
|
||||
}
|
||||
|
||||
return &ServiceContext{
|
||||
Config: c,
|
||||
DB: db,
|
||||
Prefix: utils.GetConfigString("mysql.prefix"),
|
||||
Config: c,
|
||||
DB: db,
|
||||
Prefix: utils.GetConfigString("mysql.prefix"),
|
||||
ChoreSvcName: choreSvc,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
login_out_time=43200 #api接口超时时间分
|
||||
login_refresh_out_time=83200
|
||||
name = "sale-service"
|
||||
listenOn = "0.0.0.0:10900"
|
||||
listenOn = "0.0.0.0:10300"
|
||||
mode = "dev"
|
||||
[log]
|
||||
path = "logs"
|
||||
@@ -52,4 +52,7 @@
|
||||
db = 0
|
||||
|
||||
[encrypt]
|
||||
data_key = "u2t9T3luZtoRfhBstkFN6TiIMW38BA8a"
|
||||
data_key = "u2t9T3luZtoRfhBstkFN6TiIMW38BA8a"
|
||||
|
||||
[services]
|
||||
chore = "chore-service"
|
||||
@@ -42,10 +42,10 @@ type (
|
||||
Create(ctx context.Context, in *CreateReq, opts ...grpc.CallOption) (*Response, error)
|
||||
Edit(ctx context.Context, in *EditReq, opts ...grpc.CallOption) (*Response, error)
|
||||
Info(ctx context.Context, in *InfoReq, opts ...grpc.CallOption) (*Response, error)
|
||||
// 服务间调用:销售详情(含分组;mobile 脱敏,origin_mobile 为加密串)
|
||||
InfoInternal(ctx context.Context, in *InfoReq, opts ...grpc.CallOption) (*InfoData, error)
|
||||
Items(ctx context.Context, in *ItemsReq, opts ...grpc.CallOption) (*Response, error)
|
||||
Status(ctx context.Context, in *StatusReq, opts ...grpc.CallOption) (*Response, error)
|
||||
// 销售详情
|
||||
InfoInternal(ctx context.Context, in *InfoReq, opts ...grpc.CallOption) (*InfoData, error)
|
||||
}
|
||||
|
||||
defaultSale struct {
|
||||
@@ -106,12 +106,6 @@ func (m *defaultSale) Info(ctx context.Context, in *InfoReq, opts ...grpc.CallOp
|
||||
return client.Info(ctx, in, opts...)
|
||||
}
|
||||
|
||||
// 服务间调用:销售详情(含分组;mobile 脱敏,origin_mobile 为加密串)
|
||||
func (m *defaultSale) InfoInternal(ctx context.Context, in *InfoReq, opts ...grpc.CallOption) (*InfoData, error) {
|
||||
client := sale.NewSaleClient(m.cli.Conn())
|
||||
return client.InfoInternal(ctx, in, opts...)
|
||||
}
|
||||
|
||||
func (m *defaultSale) Items(ctx context.Context, in *ItemsReq, opts ...grpc.CallOption) (*Response, error) {
|
||||
client := sale.NewSaleClient(m.cli.Conn())
|
||||
return client.Items(ctx, in, opts...)
|
||||
@@ -121,3 +115,9 @@ func (m *defaultSale) Status(ctx context.Context, in *StatusReq, opts ...grpc.Ca
|
||||
client := sale.NewSaleClient(m.cli.Conn())
|
||||
return client.Status(ctx, in, opts...)
|
||||
}
|
||||
|
||||
// 销售详情
|
||||
func (m *defaultSale) InfoInternal(ctx context.Context, in *InfoReq, opts ...grpc.CallOption) (*InfoData, error) {
|
||||
client := sale.NewSaleClient(m.cli.Conn())
|
||||
return client.InfoInternal(ctx, in, opts...)
|
||||
}
|
||||
|
||||
@@ -56,44 +56,36 @@ type CreateValidator struct {
|
||||
SaleId int64 `validate:"omitempty,gte=0"`
|
||||
Type uint32 `validate:"required,oneof=1 2 3"`
|
||||
TerritoryId int64 `validate:"required,gt=0"`
|
||||
TerritoryName string `validate:"required,max=255"`
|
||||
ProvinceId int64 `validate:"required,gt=0"`
|
||||
CityId int64 `validate:"required,gt=0"`
|
||||
DistrictId int64 `validate:"required,gt=0"`
|
||||
RegionProvince string `validate:"required,max=64"`
|
||||
RegionCity string `validate:"required,max=64"`
|
||||
RegionDistrict string `validate:"required,max=64"`
|
||||
Address string `validate:"required,max=255"`
|
||||
}
|
||||
|
||||
func (p CreateValidator) GetMessage() validate.ValidatorMessages {
|
||||
return validate.ValidatorMessages{
|
||||
"Mobile.required": "手机号不能为空",
|
||||
"Name.required": "姓名不能为空",
|
||||
"IdCardFront.required": "身份证正面不能为空",
|
||||
"IdCardFront.max": "身份证正面地址过长",
|
||||
"IdCardBack.required": "身份证反面不能为空",
|
||||
"IdCardBack.max": "身份证反面地址过长",
|
||||
"BusinessLicense.max": "营业执照地址过长",
|
||||
"Password.required": "密码不能为空",
|
||||
"Password.min": "密码长度不能小于6位",
|
||||
"GroupId.required": "请选择销售分组",
|
||||
"GroupId.gt": "请选择销售分组",
|
||||
"Type.required": "请选择类型",
|
||||
"Type.oneof": "类型不对",
|
||||
"TerritoryId.required": "请选择地域",
|
||||
"TerritoryId.gt": "请选择地域",
|
||||
"TerritoryName.required": "地域名称不能为空",
|
||||
"ProvinceId.required": "请选择省份",
|
||||
"ProvinceId.gt": "请选择省份",
|
||||
"CityId.required": "请选择城市",
|
||||
"CityId.gt": "请选择城市",
|
||||
"DistrictId.required": "请选择区县",
|
||||
"DistrictId.gt": "请选择区县",
|
||||
"RegionProvince.required": "地区省份不能为空",
|
||||
"RegionCity.required": "地区城市不能为空",
|
||||
"RegionDistrict.required": "地区区县不能为空",
|
||||
"Address.required": "详细地址不能为空",
|
||||
"Mobile.required": "手机号不能为空",
|
||||
"Name.required": "姓名不能为空",
|
||||
"IdCardFront.required": "身份证正面不能为空",
|
||||
"IdCardFront.max": "身份证正面地址过长",
|
||||
"IdCardBack.required": "身份证反面不能为空",
|
||||
"IdCardBack.max": "身份证反面地址过长",
|
||||
"BusinessLicense.max": "营业执照地址过长",
|
||||
"Password.required": "密码不能为空",
|
||||
"Password.min": "密码长度不能小于6位",
|
||||
"GroupId.required": "请选择销售分组",
|
||||
"GroupId.gt": "请选择销售分组",
|
||||
"Type.required": "请选择类型",
|
||||
"Type.oneof": "类型不对",
|
||||
"TerritoryId.required": "请选择地域",
|
||||
"TerritoryId.gt": "请选择地域",
|
||||
"ProvinceId.required": "请选择省份",
|
||||
"ProvinceId.gt": "请选择省份",
|
||||
"CityId.required": "请选择城市",
|
||||
"CityId.gt": "请选择城市",
|
||||
"DistrictId.required": "请选择区县",
|
||||
"DistrictId.gt": "请选择区县",
|
||||
"Address.required": "详细地址不能为空",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -111,44 +103,36 @@ type EditValidator struct {
|
||||
SaleId int64 `validate:"omitempty,gte=0"`
|
||||
Type uint32 `validate:"required,oneof=1 2 3"`
|
||||
TerritoryId int64 `validate:"required,gt=0"`
|
||||
TerritoryName string `validate:"required,max=255"`
|
||||
ProvinceId int64 `validate:"required,gt=0"`
|
||||
CityId int64 `validate:"required,gt=0"`
|
||||
DistrictId int64 `validate:"required,gt=0"`
|
||||
RegionProvince string `validate:"required,max=64"`
|
||||
RegionCity string `validate:"required,max=64"`
|
||||
RegionDistrict string `validate:"required,max=64"`
|
||||
Address string `validate:"required,max=255"`
|
||||
}
|
||||
|
||||
func (p EditValidator) GetMessage() validate.ValidatorMessages {
|
||||
return validate.ValidatorMessages{
|
||||
"Id.required": "ID不能为空",
|
||||
"Id.gt": "ID必须大于0",
|
||||
"Mobile.required": "手机号不能为空",
|
||||
"Name.required": "姓名不能为空",
|
||||
"IdCardFront.required": "身份证正面不能为空",
|
||||
"IdCardFront.max": "身份证正面地址过长",
|
||||
"IdCardBack.required": "身份证反面不能为空",
|
||||
"IdCardBack.max": "身份证反面地址过长",
|
||||
"BusinessLicense.max": "营业执照地址过长",
|
||||
"GroupId.required": "请选择销售分组",
|
||||
"GroupId.gt": "请选择销售分组",
|
||||
"Type.required": "请选择类型",
|
||||
"Type.oneof": "类型不对",
|
||||
"TerritoryId.required": "请选择地域",
|
||||
"TerritoryId.gt": "请选择地域",
|
||||
"TerritoryName.required": "地域名称不能为空",
|
||||
"ProvinceId.required": "请选择省份",
|
||||
"ProvinceId.gt": "请选择省份",
|
||||
"CityId.required": "请选择城市",
|
||||
"CityId.gt": "请选择城市",
|
||||
"DistrictId.required": "请选择区县",
|
||||
"DistrictId.gt": "请选择区县",
|
||||
"RegionProvince.required": "地区省份不能为空",
|
||||
"RegionCity.required": "地区城市不能为空",
|
||||
"RegionDistrict.required": "地区区县不能为空",
|
||||
"Address.required": "详细地址不能为空",
|
||||
"Id.required": "ID不能为空",
|
||||
"Id.gt": "ID必须大于0",
|
||||
"Mobile.required": "手机号不能为空",
|
||||
"Name.required": "姓名不能为空",
|
||||
"IdCardFront.required": "身份证正面不能为空",
|
||||
"IdCardFront.max": "身份证正面地址过长",
|
||||
"IdCardBack.required": "身份证反面不能为空",
|
||||
"IdCardBack.max": "身份证反面地址过长",
|
||||
"BusinessLicense.max": "营业执照地址过长",
|
||||
"GroupId.required": "请选择销售分组",
|
||||
"GroupId.gt": "请选择销售分组",
|
||||
"Type.required": "请选择类型",
|
||||
"Type.oneof": "类型不对",
|
||||
"TerritoryId.required": "请选择地域",
|
||||
"TerritoryId.gt": "请选择地域",
|
||||
"ProvinceId.required": "请选择省份",
|
||||
"ProvinceId.gt": "请选择省份",
|
||||
"CityId.required": "请选择城市",
|
||||
"CityId.gt": "请选择城市",
|
||||
"DistrictId.required": "请选择区县",
|
||||
"DistrictId.gt": "请选择区县",
|
||||
"Address.required": "详细地址不能为空",
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user