RemoveTeam.vue 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <template>
  2. <div class="remove">
  3. <img src="@/assets/remove_btn.png" alt="" @click.stop="dialogVisible=true" slot="icon">
  4. <el-dialog title="提示" :visible.sync="dialogVisible" width="30%" :before-close="handleClose">
  5. <span>该角色已授权,是否确认删除?</span>
  6. <span slot="footer" class="dialog-footer">
  7. <el-button @click="dialogVisible = false">取 消</el-button>
  8. <el-button type="primary" @click="removeTarget()">确 定</el-button>
  9. </span>
  10. </el-dialog>
  11. </div>
  12. </template>
  13. <script>
  14. export default {
  15. name: '',
  16. data () {
  17. return {
  18. dialogVisible:false
  19. };
  20. },
  21. props:['teamData'],
  22. computed: {
  23. },
  24. watch: {
  25. },
  26. methods: {
  27. async removeTarget() {
  28. let res = await this.$api.requested({
  29. "classname": "sale.team.team",
  30. "method": "deleteHr",
  31. "content": {
  32. "sys_enterprise_hrid": this.teamData.sys_enterprise_hrid
  33. }
  34. })
  35. this.tool.showMessage(res,() => {
  36. this.$parent.$parent.$parent.$parent.getTeamData()
  37. this.dialogVisible = false
  38. })
  39. },
  40. handleClose() {
  41. this.dialogVisible = false
  42. }
  43. },
  44. };
  45. </script>
  46. <style scoped>
  47. </style>