controller.go
func (c *Controller) StrLength(fieldName string, p interface{}, n int) string {
	if p == nil {
		p = ""
	}
	v, ok := p.(string)
	if ok == false {
		panic((&ValidationError{}).New(fieldName + "长度应该为" + strconv.Itoa(n)))
	}
	b := c.Validate.Length(v, n)
	if b == false {
		panic((&ValidationError{}).New(fieldName + "长度应该为" + strconv.Itoa(n)))
	}
	return v
}
func (c *Controller) StrLength(fieldName string, p interface{}, n int) string {
	if p == nil {
		p = ""
	}
	v, ok := p.(string)
	if ok == false {
		panic((&ValidationError{}).New(fieldName + "长度应该为" + strconv.Itoa(n)))
	}
	b := c.Validate.Length(v, n)
	if b == false {
		panic((&ValidationError{}).New(fieldName + "长度应该为" + strconv.Itoa(n)))
	}
	return v
}
// StrLength param is a string, length must be n