follow-up-list.js 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  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.id)">
  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(id) {
  22. top.layer.open({
  23. type: 2,
  24. maxmin: true,
  25. title:"随访详情",
  26. area: ['800px', '600px'],
  27. shadeClose: false,
  28. content: '../html/lay_followUp_detail.html?id='+id
  29. });
  30. }
  31. },
  32. watch:{
  33. followUpData:function(val){
  34. this.followUpList=this.followUpData;
  35. }
  36. },
  37. mounted: function() {
  38. var divH = $("#tab-iframe",parent.document).height() - 75;
  39. $(".followup-list").slimScroll({ height: divH,color: '#666'});
  40. }
  41. })