occdb_list.vue 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182
  1. <template>
  2. <div class="prodb_specialtylist1">
  3. <head-component :headinfo=headinfo ref="headinfoRef"></head-component>
  4. <div class="page-content">
  5. <div class="content">
  6. <div class="result-box">
  7. <div class="two-page-result">
  8. <div v-for="(item,index) in data_list.rows"
  9. :class="[item.selected?'item-result-box-active':'item-result-box']"
  10. @click="toDetail(item)">
  11. <div>{{item.name}}</div>
  12. </div>
  13. </div>
  14. </div>
  15. </div>
  16. </div>
  17. <drag_component></drag_component>
  18. </div>
  19. <!-- <pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum"-->
  20. <!-- v-model:limit="queryParams.pageSize" @pagination="list1"/>-->
  21. </template>
  22. <script setup>
  23. import headComponent from '@/views/xjc-integratedmachine/components/head_component.vue'
  24. import Drag_component from "@/views/xjc-integratedmachine/components/drag_component.vue";
  25. import {occupationList} from '@/api/xjc-integratedmachine/environment/occupation.js'
  26. import {ref} from "vue";
  27. const router = useRouter()
  28. const route = useRoute()
  29. const total = ref(0)
  30. const param = route.query
  31. const data_rows = ref([])
  32. const headinfo = ref({})
  33. const headinfoRef = ref(null);
  34. function setHeadinfo() {
  35. headinfo.value = {
  36. title: '职业分类列表',
  37. user: {
  38. avatar: '头像路径',
  39. nickName: '张三'
  40. },
  41. backUrl: '/xjc-integratedmachine/environment/index',
  42. homeUrl: '/xjc-integratedmachine/environment/index',
  43. contrast:true,
  44. contrastType:3
  45. }
  46. }
  47. onMounted(() => {
  48. setHeadinfo()
  49. setTimeout(() => {
  50. if (headinfoRef.value) {
  51. headinfoRef.value.getCompareSizeData(3); // 调用子组件的 sayHello 函数
  52. }
  53. }, 800)
  54. })
  55. const queryParams = ref({
  56. pageNum: 1,
  57. pageSize: 10,
  58. industryparent : param.industryparent
  59. })
  60. const data_list = ref({})
  61. function list() {
  62. occupationList(queryParams.value).then(resp =>{
  63. data_list.value = resp.data_list
  64. total.value = resp.data_list.total
  65. })
  66. }
  67. function toDetail(item){
  68. router.push({
  69. path : '/xjc-integratedmachine/environment/occ_details_video',
  70. query :{
  71. id : item.id
  72. }
  73. })
  74. }
  75. list()
  76. list()
  77. </script>
  78. <style scoped lang="scss">
  79. div,p{
  80. margin: 0;
  81. padding: 0;
  82. }
  83. .prodb_specialtylist1 {
  84. background: url('@/assets/images/login/login-home-background.png') no-repeat;
  85. background-size: 1920px 1080px;
  86. z-index: 10;
  87. width: 100%;
  88. height: 1080px;
  89. .page-content {
  90. width: 100%;
  91. position: absolute;
  92. top: 100px;
  93. bottom: 0;
  94. display: flex;
  95. justify-content: center;
  96. .content{
  97. width: 1832px;
  98. height: 922px;
  99. background: #FFFFFF;
  100. border-radius: 35px 35px 35px 35px;
  101. margin-top:13px;
  102. }
  103. .result-box {
  104. width: 100%;
  105. height: 750px;
  106. overflow: auto;
  107. .two-page-result {
  108. display: flex;
  109. flex-wrap: wrap;
  110. //justify-content: space-between;
  111. align-items: center;
  112. .item-result-box-active {
  113. min-width: 320px;
  114. height: 92px;
  115. background: linear-gradient(180deg, #B6FFEF 0%, #C5EEFF 100%);
  116. box-shadow: inset 0px -2px 7px 0px #1E410E;
  117. border-radius: 5px 5px 5px 5px;
  118. border: 1px solid #A2F57F;
  119. font-weight: 400;
  120. font-size: 30px;
  121. color: #0DE6A1;
  122. line-height: 90px;
  123. text-align: center;
  124. margin-left: 50px;
  125. margin-right: 50px;
  126. margin-top: 32px;
  127. padding-left: 20px;
  128. padding-right: 20px;
  129. }
  130. .item-result-box {
  131. min-width: 320px;
  132. height: 92px;
  133. background: #E0EEF4;
  134. border-radius: 5px 5px 5px 5px;
  135. font-weight: 400;
  136. font-size: 30px;
  137. color: #000000;
  138. line-height: 90px;
  139. text-align: center;
  140. margin-left: 50px;
  141. margin-right: 50px;
  142. margin-top: 32px;
  143. padding-left: 20px;
  144. padding-right: 20px;
  145. }
  146. .item-result-box:hover {
  147. min-width: 320px;
  148. height: 92px;
  149. background: linear-gradient(180deg, #B6FFEF 0%, #C5EEFF 100%);
  150. box-shadow: inset 0px -2px 7px 0px #1E410E;
  151. border-radius: 5px 5px 5px 5px;
  152. border: 1px solid #A2F57F;
  153. font-weight: 400;
  154. font-size: 30px;
  155. color: #000000;
  156. line-height: 90px;
  157. text-align: center;
  158. margin-left: 50px;
  159. margin-top: 32px;
  160. padding-left: 20px;
  161. padding-right: 20px;
  162. }
  163. }
  164. }
  165. }
  166. }
  167. </style>