index.vue 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158
  1. <template>
  2. <div class="box">
  3. <banner></banner>
  4. <p class="list_title">{{ $t("nav.AntibodyDatabase") }}</p>
  5. <div class="article">
  6. <template>
  7. <el-table
  8. :data="overView"
  9. stripe
  10. empty-text="Not Date"
  11. style="width: 100%"
  12. @row-click="gotoArticle">
  13. <el-table-column prop="catalog" :label="$t('AntibodyDatabase.CatNo')" width="100"/>
  14. <el-table-column prop="name" :label="$t('AntibodyDatabase.AntibodyName')" width="400"/>
  15. <el-table-column prop="target" :label="$t('AntibodyDatabase.Target')" >
  16. <template slot-scope="scope">
  17. <!-- <span v-for="(one, i) in scope.row.targetList" :key="i">
  18. {{ one }}
  19. </span> -->
  20. <span>{{ $util.targetDictionaries(scope.row.target) }}</span>
  21. </template>
  22. </el-table-column>
  23. <el-table-column prop="moa" :label="$t('AntibodyDatabase.MOA')" />
  24. <el-table-column prop="company" :label="$t('AntibodyDatabase.Inventor')" />
  25. </el-table>
  26. </template>
  27. </div>
  28. <div class="articleMove">
  29. <template>
  30. <el-table
  31. :data="overView"
  32. stripe
  33. empty-text="Not Date"
  34. style="width: 100%"
  35. @row-click="gotoArticle">
  36. <el-table-column prop="catalog" :label="$t('AntibodyDatabase.CatNo')" />
  37. <el-table-column prop="name" :label="$t('AntibodyDatabase.AntibodyName')" />
  38. <el-table-column prop="target" :label="$t('AntibodyDatabase.Target')" >
  39. <template slot-scope="scope">
  40. <!-- <span v-for="(one, i) in scope.row.targetList" :key="i">
  41. {{ one }}
  42. </span> -->
  43. <span>{{ $util.targetDictionaries(scope.row.target) }}</span>
  44. </template>
  45. </el-table-column>
  46. <el-table-column prop="moa" :label="$t('AntibodyDatabase.MOA')" />
  47. <el-table-column prop="company" :label="$t('AntibodyDatabase.Inventor')" />
  48. </el-table>
  49. </template>
  50. </div>
  51. </div>
  52. </template>
  53. <script>
  54. import banner from "@/components/banner";
  55. export default {
  56. name: "antibody",
  57. components: {
  58. banner
  59. },
  60. data() {
  61. return {
  62. overView: []
  63. };
  64. },
  65. methods: {
  66. changeSearchAll() {
  67. this.$api.post("/basb/searchAll", {
  68. articleFlag: 0
  69. }).then(res => {
  70. console.log(res)
  71. this.overView = res.data
  72. console.log(this.overView)
  73. })
  74. },
  75. gotoArticle(row, column, event) {
  76. console.log(row, column, event)
  77. this.$router.push({
  78. path: "/antibodyDetail",
  79. query: {
  80. id: row.id
  81. }
  82. });
  83. }
  84. },
  85. mounted() {},
  86. created() {
  87. this.changeSearchAll()
  88. }
  89. };
  90. </script>
  91. <style lang="scss">
  92. .site-header-suggestion-select {
  93. .el-autocomplete-suggestion__wrap {
  94. max-height: 380px;
  95. }
  96. }
  97. </style>
  98. <style lang="scss" scoped>
  99. @media screen and (min-width: 751px) and (max-width: 9999px) {
  100. .box {
  101. .list_title{
  102. width: 1200px;
  103. margin: 30px auto 0;
  104. font-size: 18px;
  105. font-weight: 600;
  106. }
  107. .article /deep/{
  108. width: 1200px;
  109. margin: 30px auto 90px;
  110. .cell{
  111. color: #000;
  112. }
  113. .el-table__row td{
  114. background-color: #fff !important;
  115. cursor: pointer;
  116. }
  117. .el-table__row--striped td{
  118. background-color: #F0FAFE !important;
  119. cursor: pointer;
  120. }
  121. }
  122. .articleMove{
  123. display: none;
  124. }
  125. }
  126. }
  127. @media screen and (min-width: 0px) and (max-width: 750px) {
  128. .box {
  129. .list_title{
  130. width: 100%;
  131. padding: 0.15rem 0.2rem;
  132. box-sizing: border-box;
  133. font-size: 16px;
  134. font-weight: 600;
  135. }
  136. .article{
  137. display: none;
  138. }
  139. .articleMove /deep/{
  140. width: 100%;
  141. padding: 0 0.2rem 0.15rem;
  142. box-sizing: border-box;
  143. .cell{
  144. color: #000;
  145. font-size: 0.1rem;
  146. }
  147. .el-table__row td{
  148. background-color: #fff !important;
  149. cursor: pointer;
  150. }
  151. .el-table__row--striped td{
  152. background-color: #F0FAFE !important;
  153. cursor: pointer;
  154. }
  155. }
  156. }
  157. }
  158. </style>