createrole.field.php 1.0 KB

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. /**
  3. * The createRole view file of approval flow module of ZenTaoPMS.
  4. * @copyright Copyright 2009-2023 禅道软件(青岛)有限公司(ZenTao Software (Qingdao) Co., Ltd. www.zentao.net)
  5. * @license ZPL(https://zpl.pub/page/zplv12.html) or AGPL(https://www.gnu.org/licenses/agpl-3.0.en.html)
  6. * @author Guangming Sun <sunguangming@easycorp.ltd>
  7. * @package approvalflow
  8. * @link https://www.zentao.net
  9. */
  10. namespace zin;
  11. global $lang;
  12. $fields = defineFieldList('approvalflow.createRole');
  13. $fields->field('name')
  14. ->width('full')
  15. ->control('input')
  16. ->label($lang->approvalflow->role->name)
  17. ->required();
  18. $fields->field('code')
  19. ->width('full')
  20. ->label($lang->approvalflow->role->code)
  21. ->control('input');
  22. $fields->field('users')
  23. ->width('full')
  24. ->control('picker')
  25. ->multiple(true)
  26. ->label($lang->approvalflow->role->member)
  27. ->items(data('users'));
  28. $fields->field('desc')
  29. ->width('full')
  30. ->label($lang->approvalflow->role->desc)
  31. ->control('textarea');