test

package
Version: v0.0.0-...-7cf166a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 25, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ByPiece 按件数
	ByPiece = iota
	// ByMoney 按金额
	ByMoney
)
View Source
const (
	// CheckSingle 考核单项
	CheckSingle = iota
	// CheckTwice 考核两项
	CheckTwice
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Compose

type Compose struct {
	ID             int           `orm:"id key auto"`
	Name           string        `orm:"name"`
	Simple         Simple        `orm:"simple"`
	PtrSimple      *Simple       `orm:"ptrSimple"`
	SimpleArray    []Simple      `orm:"simpleArray"`
	SimplePtrArray []*Simple     `orm:"simplePtrArray"`
	PtrSimpleArray *[]Simple     `orm:"ptrSimpleArray"`
	Reference      Reference     `orm:"reference"`
	PtrReference   *Reference    `orm:"ptrReference"`
	RefArray       []Reference   `orm:"refArray"`
	RefPtrArray    []*Reference  `orm:"refPtrArray"`
	PtrRefArray    *[]*Reference `orm:"ptrRefArray"`
	PtrCompose     *Compose      `orm:"ptrCompose"`
}

func (*Compose) IsSame

func (l *Compose) IsSame(r *Compose) bool

type ExtUnit

type ExtUnit struct {
	ID   int   `orm:"id key auto"`
	Unit *Unit `orm:"unit"`
}

ExtUnit ExtUnit

type ExtUnitList

type ExtUnitList struct {
	ID       int    `orm:"id key auto"`
	Unit     Unit   `orm:"unit"`
	UnitList []Unit `orm:"unitlist"`
}

ExtUnitList ExtUnitList

type Goal

type Goal struct {
	ID    int     `json:"id" orm:"id key auto"` // ID
	Type  int     `json:"type" orm:"type"`
	Value float32 `json:"value" orm:"value"`
}

Goal 考核目标

type Group

type Group struct {
	ID     int      `orm:"id key auto"`
	Name   string   `orm:"name"`
	Users  *[]*User `orm:"users"`
	Parent *Group   `orm:"parent"`
}

Group Group

func (*Group) Equal

func (s *Group) Equal(r *Group) bool

Equal Equal

type KPI

type KPI struct {
	ID            int         `json:"id" orm:"id key auto"`              // ID
	Title         string      `json:"title" orm:"title"`                 // 名称
	JoinValue     Goal        `json:"joinValue" orm:"joinValue"`         // 加盟目标
	PerMonthValue Goal        `json:"perMonthValue" orm:"perMonthValue"` // 每月目标
	SpecialValue  SpecialGoal `json:"specialValue" orm:"specialValue"`   // 特殊地区或产品目标
	Default       bool        `json:"default" orm:"default"`
}

KPI 代理商考核指标

type Reference

type Reference struct {
	ID          int        `orm:"id key auto"`
	Name        string     `orm:"name"`
	FValue      *float32   `orm:"value"`
	F64         float64    `orm:"f64"`
	TimeStamp   *time.Time `orm:"ts"`
	Flag        *bool      `orm:"flag"`
	IArray      []int      `orm:"iArray"`
	FArray      []float32  `orm:"fArray"`
	StrArray    []string   `orm:"strArray"`
	BArray      []bool     `orm:"bArray"`
	PtrArray    *[]string  `orm:"ptrArray"`
	StrPtrArray []*string  `orm:"strPtrArray"`
	PtrStrArray *[]*string `orm:"ptrStrArray"`
}

func (*Reference) IsSame

func (l *Reference) IsSame(r *Reference) bool

type RewardPolicy

type RewardPolicy struct {
	ID          int         `json:"id" orm:"id key auto"`
	Name        string      `json:"name" orm:"name"`
	Description string      `json:"description" orm:"description"`
	ValueItem   []ValueItem `json:"item" orm:"item"`
	ValueScope  ValueScope  `json:"scope" orm:"scope"`
	Status      *Status     `json:"status" orm:"status"`
	Creater     int         `json:"creater" orm:"creater"`
	UpdateTime  int64       `json:"updateTime" orm:"updateTime"`
	Namespace   string      `json:"namespace" orm:"namespace"`
}

type Simple

type Simple struct {
	ID        int       `orm:"id key auto"`
	I8        int8      `orm:"i8"`
	I16       int16     `orm:"i16"`
	I32       int32     `orm:"i32"`
	I64       uint64    `orm:"i64"`
	Name      string    `orm:"name"`
	Value     float32   `orm:"value"`
	F64       float64   `orm:"f64"`
	TimeStamp time.Time `orm:"ts"`
	Flag      bool      `orm:"flag"`
}

func (*Simple) IsSame

func (l *Simple) IsSame(r *Simple) bool

type SpecialGoal

type SpecialGoal struct {
	ID            int      `json:"id" orm:"id key auto"` // ID
	CheckDistrict []string `json:"checkDistrict" orm:"checkDistrict"`
	CheckProduct  []string `json:"checkProduct" orm:"checkProduct"`
	CheckType     int      `json:"checkType" orm:"checkType"`
	CheckValue    Goal     `json:"checkValue" orm:"checkValue"`
}

SpecialGoal 特殊目标

type Status

type Status struct {
	ID    int `orm:"id key auto"`
	Value int `orm:"value"`
}

Status status

type System

type System struct {
	ID    int      `orm:"id key auto"`
	Name  string   `orm:"name"`
	Users *[]User  `orm:"users"`
	Tags  []string `orm:"tags"`
}

System System

func (*System) Equal

func (s *System) Equal(r *System) bool

Equal Equal

type Unit

type Unit struct {
	ID        int       `orm:"id key auto"`
	I8        int8      `orm:"i8"`
	I16       int16     `orm:"i16"`
	I32       int32     `orm:"i32"`
	I64       uint64    `orm:"i64"`
	Name      string    `orm:"name"`
	Value     float32   `orm:"value"`
	F64       float64   `orm:"f64"`
	TimeStamp time.Time `orm:"ts"`
	Flag      bool      `orm:"flag"`
	IArray    []int     `orm:"iArray"`
	FArray    []float32 `orm:"fArray"`
	StrArray  []string  `orm:"strArray"`
}

Unit 单元信息

type User

type User struct {
	ID     int      `orm:"id key auto"`
	Name   string   `orm:"name"`
	EMail  string   `orm:"email"`
	Status *Status  `orm:"status"`
	Group  []*Group `orm:"group"`
}

User User

func (*User) Equal

func (s *User) Equal(r *User) bool

Equal check user Equal

type ValueItem

type ValueItem struct {
	ID    int     `json:"id" orm:"id key auto"`
	Level int     `json:"level" orm:"level"`
	Type  int     `json:"type" orm:"type"`
	Value float64 `json:"value" orm:"value"`
}

type ValueScope

type ValueScope struct {
	ID        int     `json:"id" orm:"id key auto"`
	LowValue  float64 `json:"lowValue" orm:"lowValue"`
	HighValue float64 `json:"highValue" orm:"highValue"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL