adduserrole.php 1.1 KB

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: xiaofeng
  5. * Date: 2018/3/7
  6. * Time: 上午8:56
  7. */
  8. use backend\assets\AppAsset;
  9. AppAsset::addScript($this,Yii::$app->request->baseUrl."/js/user.js");
  10. ?>
  11. <style>
  12. .layui-transfer-header {text-align: left}
  13. .layui-transfer-data {text-align: left}
  14. </style>
  15. <div id="userrolelist" style="display: none">
  16. <?php foreach ($model as $val) {
  17. if (!empty($val['checked'])) { ?>
  18. <li class="c_role y_role" data-id="<?php echo $val['id'] ?>" data-name="<?php echo $val['name'] ?>"></li>
  19. <?php } else { ?>
  20. <li class="y_role" data-id="<?php echo $val['id'] ?>" data-name="<?php echo $val['name'] ?>"></li>
  21. <?php }
  22. } ?>
  23. </div>
  24. <div id="test4" class="demo-transfer" style="text-align: center;margin-top: 30px;"></div>
  25. <div class="layui-btn-container" style="text-align: center;margin-top: 20px;">
  26. <button type="button" class="layui-btn" lay-demotransferactive="getData" data-uid="<?php echo $uid ?>"
  27. data-type="2">提交
  28. </button>
  29. <button type="button" class="layui-btn" lay-demotransferactive="reload">重置</button>
  30. </div>