工单小程序2024-11-20
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

188 lines
3.6 KiB

8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
  1. <template>
  2. <view class="page">
  3. <navbar bgColor="#169bd5"/>
  4. <view class="Carousel-image">
  5. <view class="imgs">
  6. <uv-swiper
  7. :list="bannerList"
  8. indicator indicatorMode="dot"
  9. keyName="image"
  10. circular height="420">
  11. </uv-swiper>
  12. </view>
  13. <view class="search">
  14. <uv-search
  15. placeholder="请输入搜索工单号"
  16. bgColor="#fff"
  17. v-model="queryParams.title"></uv-search>
  18. </view>
  19. </view>
  20. <view class="festival">
  21. <uv-notice-bar
  22. @click="toNotice"
  23. :text="text" direction="column" ></uv-notice-bar>
  24. </view>
  25. <view class="task">
  26. <uv-grid :border="false">
  27. <uv-grid-item
  28. @click="$utils.navigateTo(item.url)"
  29. v-for="(item,index) in baseList" :key="index">
  30. <uv-icon
  31. :name="item.name"
  32. size="50rpx"></uv-icon>
  33. <text style="font-size: 28rpx;">{{item.title}}</text>
  34. </uv-grid-item>
  35. </uv-grid>
  36. </view>
  37. <view class="Urgent-Work-Order">
  38. <view class="Urgent-Work">
  39. 紧急工单
  40. </view>
  41. <WorkOrderitem
  42. v-for="(item,index) in list"
  43. :obj="item"
  44. :key="index"
  45. @click="$utils.navigateTo('/pages_order/order/WorkOrders?id=' + item.id)"
  46. />
  47. </view>
  48. <PrivacyAgreementPoup/>
  49. <tabber select="0"/>
  50. </view>
  51. </template>
  52. <script>
  53. import PrivacyAgreementPoup from '@/components/config/PrivacyAgreementPoup.vue'
  54. import tabber from '@/components/base/tabbar.vue'
  55. import WorkOrderitem from '@/components/work/WorkOrderitem.vue'
  56. import mixinsList from '@/mixins/list.js'
  57. import {
  58. mapGetters
  59. } from 'vuex'
  60. export default {
  61. mixins: [mixinsList],
  62. components: {
  63. tabber,
  64. PrivacyAgreementPoup,
  65. WorkOrderitem,
  66. },
  67. data() {
  68. return {
  69. bannerList: [],
  70. CollectionList:[],
  71. mixinsListApi : 'queryTemplateList',
  72. baseList: [
  73. {
  74. name: 'photo',
  75. title: '全部工单',
  76. url : '/pages_order/order/WorkOrderList',
  77. },
  78. {
  79. name: 'lock',
  80. title: '汇总列表',
  81. url : '/pages_order/order/WorkOrderList',
  82. },
  83. ],
  84. NewsList : [],//公告列表
  85. text : [],//公告列表标题
  86. }
  87. },
  88. computed: {
  89. },
  90. onLoad() {
  91. this.queryBannerList()
  92. this.queryNewsList()
  93. this.queryCollectionList()
  94. },
  95. methods: {
  96. //轮播图
  97. queryBannerList(){
  98. this.$api('queryBannerList', res =>{
  99. if(res.code == 200){
  100. this.bannerList = res.result.records
  101. }
  102. })
  103. },
  104. //公告列表
  105. queryNewsList(){
  106. this.$api('queryNewsList', res =>{
  107. if(res.code == 200){
  108. this.NewsList = res.result.records
  109. res.result.records.forEach(n => {
  110. this.text.push(n.title)
  111. })
  112. }
  113. })
  114. },
  115. //收藏信息-我的收藏
  116. queryCollectionList(){
  117. this.$api('queryCollectionList', res =>{
  118. if(res.code == 200){
  119. this.CollectionList = res.result.records
  120. }
  121. })
  122. },
  123. toNotice(index){
  124. console.log(this.NewsList[index]);
  125. // @click="$utils.navigateTo('/pages_order/order/Worknotice')"
  126. uni.navigateTo({
  127. url: '/pages_order/order/Worknotice?id=' + this.NewsList[index].id
  128. })
  129. },
  130. }
  131. }
  132. </script>
  133. <style scoped lang="scss">
  134. .Carousel-image {
  135. position: relative;
  136. display: inline-block;
  137. width: 100%;
  138. .search {
  139. height: 82rpx;
  140. width: 710rpx;
  141. background: #FFFFFF;
  142. margin: 20rpx auto;
  143. border-radius: 41rpx;
  144. box-sizing: border-box;
  145. padding: 0 15rpx;
  146. display: flex;
  147. align-items: center;
  148. position: absolute;
  149. top: 10px;
  150. left: 10px;
  151. }
  152. }
  153. .Urgent-Work-Order{
  154. padding: 20rpx;
  155. }
  156. .festival {
  157. padding: 20rpx;
  158. }
  159. .task {
  160. padding: 20rpx 0;
  161. background-color: #FFFFFF;
  162. margin: 20rpx;
  163. border-radius: 20rpx;
  164. box-shadow: 0 0 10rpx 10rpx #00000005;
  165. }
  166. </style>