V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
444683462
V2EX  ›  问与答

thinkphp 自动验证的 require 无效

  •  
  •   444683462 · 2015-03-16 02:16:37 +08:00 · 1626 次点击
    这是一个创建于 3349 天前的主题,其中的信息可能已经有所发展或是发生改变。

    array('department_name','require','名称必须'),
    array('department_name','require','部门名称不能为空',1,'regex',3),
    这两种方式都无效,其他

    array('department_name','1,8','部门名称最多8个字',1,'length',3),
    array('department_name','','该部门名称已经存在,不要重复',1,'unique',1),
    array('department_sort','/^([1-9]\d*|[0]{1,1})$/','部门排序只能是正整数或者0',2,'regex',3),
    都是有效的

    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   6219 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 02:55 · PVG 10:55 · LAX 19:55 · JFK 22:55
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.