follow-up-list.js 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. Vue.component('follow-list', {
  2. template: '<ul class="followup-list">\
  3. <li v-for="(list,index) in followUpList" class="consultation-list-item" @click="viewDetail(list)">\
  4. <p class="follow-up-doctor"><span class="start-time pull-right">开始时间:{{list.createTime}}</span>随访医生:{{list.doctorName}}<span v-if="list.prescriptionCode" class="fu-tag">长处方</span></p>\
  5. <div class="follow-user-info">\
  6. <span class="follow-status" :data-status="list.status" desc="3进行2计划中1完成"></span>\
  7. <p class="act-type">方式/类型:{{list.followupTypeName}}{{list.followupClassName?"/"+list.followupClassName:""}}</p>\
  8. <p v-if="list.status==1" class="completion-time">完成时间:{{list.followupDate.substr(0,16)}}</p>\
  9. <p v-else class="completion-time">计划时间:{{list.followupPlanDate.substr(0,16)}}</p>\
  10. </div>\
  11. </li>\
  12. </ul>',
  13. data: function() {
  14. return {
  15. followUpList:[],
  16. curPage:1
  17. }
  18. },
  19. props:["followUpData"],
  20. methods: {
  21. viewDetail: function(list) {
  22. // if(list.status == 1){
  23. if(list.followupClass =="5" || list.followupClass =="6" ||list.followupClass =="7" ||list.followupClass =="8" ||list.followupClass =="9"){
  24. window.location.href = "../index.html?id="+list.id+"&type="+list.followupClass+"&isEdit=0"
  25. }else{
  26. window.open('../../followup/html/lay_followUp_detail.html?id='+list.id)
  27. // top.layer.open({
  28. // type: 2,
  29. // maxmin: true,
  30. // title:"随访详情",
  31. // area: ['1000px', '650px'],
  32. // shadeClose: false,
  33. // content: '../../followup/html/lay_followUp_detail.html?id='+list.id,
  34. // end: function () {
  35. // location.reload();
  36. // }
  37. // });
  38. }
  39. // }else{
  40. // top.toastr.warning("请在手机上完成随访才能查看详情")
  41. // }
  42. }
  43. },
  44. watch:{
  45. followUpData:function(val){
  46. this.followUpList=this.followUpData;
  47. }
  48. },
  49. mounted: function() {
  50. var divH = $("#tab-iframe",parent.document).height() - 75;
  51. $(".followup-list").slimScroll({ height: divH,color: '#666'});
  52. }
  53. })