index.vue 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307
  1. <template>
  2. <view class="app-content">
  3. <img src="../../static/beijing.png" alt="" class="tuku">
  4. <Nav :navname.sync="navname" :navtype="false" :navtypes="true"></Nav>
  5. <view class="cont">
  6. <view class="photograph" @tap="upindiv">
  7. <img src="../../static/shuai.png" alt="">
  8. </view>
  9. <view class="details">
  10. <p>Admin</p>
  11. <span>工号:E002</span>
  12. </view>
  13. <view class="detail_list">
  14. <view class="list_child">
  15. <p>分拣</p>
  16. <span>200</span>
  17. </view>
  18. <view class="list_child">
  19. <p>装车</p>
  20. <span>200</span>
  21. </view>
  22. <view class="list_child">
  23. <p>上机</p>
  24. <span>200</span>
  25. </view>
  26. <view class="list_child">
  27. <p>卸机</p>
  28. <span>200</span>
  29. </view>
  30. <view class="list_child">
  31. <p>卸车</p>
  32. <span>200</span>
  33. </view>
  34. </view>
  35. <view class="detail_type">
  36. <view class="list_child">
  37. <view class="log"></view>
  38. <p>我的记录</p>
  39. </view>
  40. <view class="list_child" @tap="uppop">
  41. <view class="log"></view>
  42. <p>扫码开关</p>
  43. </view>
  44. <view class="list_child">
  45. <view class="log"></view>
  46. <p>工作方式</p>
  47. </view>
  48. <view class="list_child">
  49. <view class="log"></view>
  50. <p>帮助</p>
  51. </view>
  52. </view>
  53. </view>
  54. <z-popup v-model="all">
  55. <view class="popup_title">
  56. <p>请选择扫码开关</p>
  57. </view>
  58. <view class="popup_content">
  59. <ul>
  60. <li v-for="(item, index) in list" :key="index" @tap="()=>selectup(index)">
  61. <p>{{item.name}}</p>
  62. <view class="start" v-if="action === index ? true: false">
  63. <img src="../../static/gou.png" alt="">
  64. </view>
  65. </li>
  66. </ul>
  67. <view class="top"></view>
  68. <view class="cancel" @tap="()=>topup()">取消</view>
  69. </view>
  70. </z-popup>
  71. </view>
  72. </template>
  73. <script>
  74. import Nav from '../../components/header/nav.vue'
  75. // import Popup from '../../uni_modules/z-popup/components/z-popup'
  76. export default {
  77. data() {
  78. return {
  79. main: null,
  80. poll: null,
  81. filter:null,
  82. pusher:null,
  83. intentServer:null,
  84. navname: '我的',
  85. all: false,
  86. action: '',
  87. list: [{
  88. name: '相机'
  89. },
  90. {
  91. name: '激光扫描枪'
  92. },
  93. {
  94. name: 'RFID读取器'
  95. }]
  96. }
  97. },
  98. created(option) {
  99. },
  100. onLoad(){
  101. },
  102. onUnload() {
  103. },
  104. onShow() {
  105. // uni.hideTabBar()//关闭导航栏
  106. // uni.showTabBar()//显示导航栏
  107. },
  108. mounted() {
  109. },
  110. components: {
  111. Nav
  112. },
  113. methods: {
  114. fall () {
  115. uni.switchTab({
  116. url: "/pages/index/index"
  117. })
  118. },
  119. upindiv () {
  120. uni.redirectTo({
  121. url: "/pages/individual/index"
  122. })
  123. },
  124. uppop () {
  125. uni.hideTabBar()
  126. this.all = true
  127. },
  128. selectup (index) {
  129. this.action = index
  130. console.log(this.action)
  131. },
  132. topup () {
  133. this.all = false
  134. uni.showTabBar()//显示导航栏
  135. }
  136. },
  137. }
  138. </script>
  139. <style lang="scss" scoped>
  140. .app-content{
  141. // position: relative;
  142. >.tuku{
  143. position: absolute;
  144. z-index: -1;
  145. width: 100%;
  146. top: 0;
  147. }
  148. >.cont{
  149. z-index: 999;
  150. >.photograph{
  151. width: 6rem;
  152. height: 6rem;
  153. // background: red;
  154. border-radius: 50%;
  155. margin: 0 auto;
  156. margin-top: .625rem;
  157. }
  158. >.details{
  159. width: 100%;
  160. height: 3.125rem;
  161. display: flex;
  162. flex-direction: column;
  163. align-items: center;
  164. justify-content: center;
  165. // background: red;
  166. margin-top: .625rem;
  167. >p{
  168. color: rgb(255, 255, 255);
  169. font-family: Noto Sans SC;
  170. font-size: 1rem;
  171. font-weight: 500;
  172. }
  173. >span{
  174. color: rgb(255, 255, 255);
  175. font-family: Noto Sans SC;
  176. font-size: .8125rem;
  177. font-weight: 500;
  178. }
  179. }
  180. >.detail_list{
  181. width: 100%;
  182. // background: red;
  183. display: flex;
  184. flex-wrap: wrap;
  185. margin-top: 1rem;
  186. >.list_child{
  187. width: 33%;
  188. display: flex;
  189. flex-direction: column;
  190. justify-items: center;
  191. align-items: center;
  192. margin-bottom: 1rem;
  193. >p{
  194. color: rgb(255, 255, 255);
  195. font-family: Noto Sans SC;
  196. font-size: .8125rem;
  197. font-weight: 500;
  198. }
  199. >span{
  200. color: rgb(255, 255, 255);
  201. font-family: Helvetica;
  202. font-size: 1rem;
  203. font-weight: 700;
  204. }
  205. }
  206. }
  207. >.detail_type{
  208. height: calc(100vh - 35.875rem);
  209. padding: 0 3.125rem 0 3.125rem;
  210. display: flex;
  211. justify-content: space-around;
  212. flex-wrap: wrap;
  213. flex: 1;
  214. >.list_child{
  215. width: 7.5rem;
  216. height: 7.5rem;
  217. background: rgb(37, 121, 160);
  218. box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
  219. border-radius: 4px;
  220. margin-bottom: 4%;
  221. display: flex;
  222. flex-direction: column;
  223. justify-content: center;
  224. align-items: center;
  225. >.log{
  226. width: 2.25rem;
  227. height: 2.25rem;
  228. background: rgb(196, 196, 196);
  229. margin-bottom: .5rem;
  230. }
  231. >p{
  232. color: rgb(255, 255, 255);
  233. font-family: Noto Sans SC;
  234. font-size: .9375rem;
  235. font-weight: 500;
  236. }
  237. }
  238. }
  239. }
  240. .popup_title{
  241. width: 100%;
  242. height: 4.5rem;
  243. background: rgb(255, 255, 255);
  244. border-radius: 10px 10px 0px 0px;
  245. display: flex;
  246. align-items: center;
  247. color: rgb(16, 17, 22);
  248. font-family: Noto Sans SC;
  249. font-size: 1rem;
  250. font-weight: 700;
  251. >p{
  252. margin-left: 1.5rem;
  253. color: rgb(16, 17, 22);
  254. font-family: Noto Sans SC;
  255. font-size: 1rem;
  256. font-weight: 700;
  257. }
  258. }
  259. .popup_content{
  260. width: 100%;
  261. background: rgb(255, 255, 255);
  262. >ul{
  263. width: 100%;
  264. >li{
  265. width: 82%;
  266. height: 2.6875rem;
  267. display: flex;
  268. align-items: center;
  269. justify-content: space-between;
  270. >p{
  271. color: rgb(0, 0, 0);
  272. font-family: Noto Sans SC;
  273. font-size: .8125rem;
  274. font-weight: 400;
  275. }
  276. >.start{
  277. width: 1rem;
  278. height: 1rem;
  279. background: rgb(37, 121, 160);
  280. display: flex;
  281. align-items: center;
  282. justify-content: center;
  283. border-radius: 50%;
  284. }
  285. }
  286. }
  287. >.top{
  288. width: 100%;
  289. height: .875rem;
  290. background: rgb(249, 249, 249);
  291. }
  292. >.cancel{
  293. width: 100%;
  294. height: 3.3125rem;
  295. display: flex;
  296. align-items: center;
  297. justify-content: center;
  298. color: rgb(0, 0, 0);
  299. font-family: Noto Sans SC;
  300. font-size: .9375rem;
  301. font-weight: 500;
  302. }
  303. }
  304. }
  305. </style>