roletemplates.html.php 1.8 KB

1234567891011121314151617181920212223242526
  1. <?php
  2. /**
  3. * The role template list component file of AI module of ZenTaoPMS.
  4. *
  5. * @copyright Copyright 2009-2023 禅道软件(青岛)有限公司(ZenTao Software (Qingdao) Co., Ltd. www.zentao.net)
  6. * @license ZPL(https://zpl.pub/page/zplv12.html) or AGPL(https://www.gnu.org/licenses/agpl-3.0.en.html)
  7. * @author Jianyu Chen <chenjianyu@easycorp.ltd>
  8. * @package ai
  9. * @link https://www.zentao.net
  10. */
  11. ?>
  12. <div id="roleList" style="display: flex; flex-direction: column; gap:8px;">
  13. <?php foreach($roleTemplates as $role):?>
  14. <div id="role-template-<?php echo $role->id;?>" data-id="<?php echo $role->id;?>" class="role-template-card" style="border: 1px solid #D8DBDE; border-radius: 4px; padding: 12px; width: 100%;">
  15. <div style="display: flex; justify-content: space-between; align-items: center; gap: 16px;">
  16. <p id="role-<?php echo $role->id;?>" class="role" style="overflow: hidden; white-space: nowrap; text-overflow: clip;" title="<?php echo $role->role; ?>"><?php echo $role->role; ?></p>
  17. <div style="display: flex; gap: 2px;">
  18. <?php echo html::commonButton("<span class='text-primary'>{$lang->ai->apply}</span>", "data-action='apply'", 'btn btn-link'); ?>
  19. <?php echo html::commonButton("<i class='icon icon-edit icon-sm text-primary'></i>", "data-action='edit'", 'btn btn-link'); ?>
  20. <?php echo html::commonButton("<i class='icon icon-trash icon-sm text-primary'></i>", "data-action='del'", 'btn btn-link'); ?>
  21. </div>
  22. </div>
  23. <p id="characterization-<?php echo $role->id;?>" class="characterization text-gray" style="overflow: hidden; white-space: nowrap; text-overflow: clip; padding: 4px 0;" title="<?php echo $role->characterization;?>"><?php echo $role->characterization; ?></p>
  24. </div>
  25. <?php endforeach;?>
  26. </div>