index1.vue 930 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <template>
  2. <div>
  3. <el-button size="small" type="text" @click="onShow" >详 情</el-button>
  4. </div>
  5. </template>
  6. <script>
  7. export default {
  8. props:['data','detailPath','idName'],
  9. components:{
  10. },
  11. computed:{
  12. },
  13. data () {
  14. return {
  15. }
  16. },
  17. methods:{
  18. onShow () {
  19. let key = ''
  20. if (this.idName instanceof Array) {
  21. key = this.idName[1]
  22. } else {
  23. key = this.idName
  24. }
  25. let query = {id:this.data[key],rowindex:this.data.rowindex - 1,sa_project_contactsid:this.data.sa_project_contactsid,contactsid:this.data.contactsid}
  26. this.$router.push({path:this.detailPath.path,query:Object.assign({},query,this.detailPath.param)})
  27. this.$store.dispatch('changeDetailDrawer',true)
  28. },
  29. },
  30. watch:{
  31. }
  32. }
  33. </script>
  34. <style>
  35. </style>
  36. <style scoped>
  37. .detail__panel{
  38. background:#f1f2f3;
  39. overflow-y: scroll;
  40. font-size: 14px;
  41. color:#666;
  42. height:100vh;
  43. }
  44. </style>