home.js 712 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. new Vue({
  2. el: '#app',
  3. data: function () {
  4. return {
  5. searchKey:'',
  6. hotList:[]
  7. }
  8. },
  9. computed: {
  10. },
  11. mounted:function() {
  12. this.getHot()
  13. },
  14. methods: {
  15. getHot:function(){
  16. var vm=this;
  17. bigDataOutApi.hot_words().then(function(res){
  18. vm.hotList=res
  19. }).catch(function(err){
  20. console.err(err)
  21. })
  22. },
  23. setIndexPage:function(key){
  24. GlobalEventBus.$emit('setleftTabUrl', {
  25. key: key
  26. });
  27. },
  28. goSearch:function(value){
  29. if(!value)value=''
  30. url = '../html/search.html?search='+value;
  31. GlobalEventBus.$emit('setIframeUrl', {
  32. history: {url:url,text:'全文病历检索'}
  33. });
  34. }
  35. },
  36. watch: {
  37. }
  38. })