main.vue 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313
  1. <template>
  2. <view>
  3. <view class="head">
  4. <view class="header-wrap">
  5. <view class="index-header">
  6. <view class="map-wrap"></view>
  7. <view class="input-wrap">
  8. <text class="iconfont">仓库管理</text>
  9. </view>
  10. <view class="map-wrap"></view>
  11. </view>
  12. </view>
  13. <view class="blank"></view>
  14. </view>
  15. <view class="uni-padding-wrap uni-common-mt">
  16. <view class="button-sp-area">
  17. <button type="success" @click="groupDisk()" style="
  18. border-radius: 50%;width: 95px;
  19. height: 95px;margin: auto;text-align: center;
  20. line-height: 95px;background-color: #4bbf73;
  21. color:#ffffff;margin-top:16px;font-size: 15px;" class="button">
  22. 入库
  23. </button>
  24. <br>
  25. <button type="success" @click="TemplateGroup()" style="
  26. border-radius: 50%;width: 95px;
  27. height: 95px;margin: auto;text-align: center;
  28. line-height: 95px;background-color: #4bbf73;
  29. color:#ffffff;margin-top:16px;font-size: 15px;" class="button">
  30. 铁桶入库
  31. </button>
  32. <br>
  33. <button type="success" @click="QuickGroup()" style="
  34. border-radius: 50%;width: 95px;
  35. height: 95px;margin: auto;text-align: center;
  36. line-height: 95px;background-color: #4bbf73;
  37. color:#ffffff;margin-top:16px;font-size: 15px;" class="button">
  38. 木箱入库
  39. </button>
  40. <br>
  41. <!--
  42. <br>
  43. <button type="success" @click="emergencyDisk()" style="
  44. border-radius: 50%;width: 95px;
  45. height: 95px;margin: auto;text-align: center;
  46. line-height: 95px;background-color: #4bbf73;
  47. color:#ffffff;font-size: 16px;" class="button">
  48. 超限整理
  49. </button>
  50. <br>
  51. <button type="success" @click="emptyDisk()" style="
  52. border-radius: 50%;width: 95px;
  53. height: 95px;margin: auto;text-align: center;
  54. line-height: 95px;background-color: #4bbf73;
  55. color:#ffffff;font-size: 16px;" class="button">
  56. 空托入库
  57. </button>
  58. <br>
  59. <button type="success" @click="sortingDisk()" style="
  60. border-radius: 50%;width: 95px;
  61. height: 95px;margin: auto;text-align: center;
  62. line-height: 95px;background-color: #4bbf73;
  63. color:#ffffff;font-size: 16px;" class="button">
  64. 分拣入库
  65. </button>
  66. -->
  67. <br>
  68. <button type="primary" @click="sorting_out()" style="border-radius: 50%;width: 95px;
  69. height: 95px;margin: auto;text-align: center;
  70. line-height: 95px;border-color: #0039a6;font-size: 16px;" class="button">
  71. 出库</button>
  72. <br>
  73. <button type="primary" @click="testing_out()" style="border-radius: 50%;width: 95px;
  74. height: 95px;margin: auto;text-align: center;
  75. line-height: 95px;border-color: #0039a6;font-size: 16px;" class="button">
  76. 质检出库</button>
  77. <!-- <br>
  78. <button type="primary" @click="container()" style="border-radius: 50%;width: 95px;
  79. height: 95px;margin: auto;text-align: center;
  80. line-height: 95px;border-color: #0039a6;font-size: 16px;" class="button">
  81. 容器管理</button> -->
  82. <br>
  83. <button type="primary" @click="batch()" style="border-radius: 50%;width: 95px;
  84. height: 95px;margin: auto;text-align: center;
  85. line-height: 95px;border-color: #0039a6;font-size: 16px;" class="button">
  86. 批次管理</button>
  87. <br>
  88. <button type="primary" @click="task()" style="border-radius: 50%;width: 95px;
  89. height: 95px;margin: auto;text-align: center;
  90. line-height: 95px;border-color: #0039a6;font-size: 16px;" class="button">
  91. 任务管理</button>
  92. </view>
  93. </view>
  94. </view>
  95. </template>
  96. <script>
  97. export default {
  98. data() {
  99. return {
  100. title: 'button',
  101. loading: false
  102. }
  103. },
  104. onLoad() {
  105. this._timer = null;
  106. },
  107. onShow() {
  108. this.clearTimer();
  109. this._timer = setTimeout(() => {
  110. this.loading = true;
  111. }, 300)
  112. },
  113. onUnload() {
  114. this.clearTimer();
  115. this.loading = false;
  116. },
  117. methods: {
  118. openTypeError(error) {
  119. console.error('open-type error:', error);
  120. },
  121. clearTimer() {
  122. if (this._timer != null) {
  123. clearTimeout(this._timer);
  124. }
  125. },
  126. groupDisk: function() {
  127. setTimeout(() => {
  128. uni.vibrateShort();
  129. uni.navigateTo({
  130. url: '/pages/sample/group',
  131. })
  132. }, 500);
  133. },
  134. emergencyDisk: function() {
  135. setTimeout(() => {
  136. uni.vibrateShort();
  137. uni.navigateTo({
  138. url: '/pages/sample/emergency',
  139. })
  140. }, 500);
  141. },
  142. sortingDisk: function() {
  143. setTimeout(() => {
  144. uni.vibrateShort();
  145. uni.navigateTo({
  146. url: '/pages/sample/sorting',
  147. })
  148. }, 500);
  149. },
  150. emptyDisk: function() {
  151. setTimeout(() => {
  152. uni.vibrateShort();
  153. uni.navigateTo({
  154. url: '/pages/sample/empty',
  155. })
  156. }, 500);
  157. },
  158. planGroupDisk: function() {
  159. setTimeout(() => {
  160. uni.vibrateShort();
  161. uni.navigateTo({
  162. url: '/pages/sample/plan_group',
  163. })
  164. }, 500);
  165. },
  166. sorting_out: function(code) {
  167. setTimeout(() => {
  168. uni.vibrateShort();
  169. uni.navigateTo({
  170. // url: '/pages/sample/tts',
  171. url: '/pages/sample/sorting_out',
  172. })
  173. }, 500);
  174. },
  175. testing_out: function(code) {
  176. setTimeout(() => {
  177. uni.vibrateShort();
  178. uni.navigateTo({
  179. // url: '/pages/sample/tts',
  180. url: '/pages/sample/testing_out',
  181. })
  182. }, 500);
  183. },
  184. container: function(code) {
  185. setTimeout(() => {
  186. uni.vibrateShort();
  187. uni.navigateTo({
  188. // url: '/pages/sample/tts',
  189. url: '/pages/sample/container',
  190. })
  191. }, 500);
  192. },
  193. task: function(code) {
  194. setTimeout(() => {
  195. uni.vibrateShort();
  196. uni.navigateTo({
  197. // url: '/pages/sample/tts',
  198. url: '/pages/sample/task',
  199. })
  200. }, 500);
  201. },
  202. batch: function(code) {
  203. setTimeout(() => {
  204. uni.vibrateShort();
  205. uni.navigateTo({
  206. // url: '/pages/sample/tts',
  207. url: '/pages/sample/batch',
  208. })
  209. }, 500);
  210. },
  211. QuickGroup: function(code) {
  212. setTimeout(() => {
  213. uni.vibrateShort();
  214. uni.navigateTo({
  215. url: '/pages/sample/QuickGroup',
  216. })
  217. }, 500);
  218. },
  219. TemplateGroup: function(code) {
  220. setTimeout(() => {
  221. uni.vibrateShort();
  222. uni.navigateTo({
  223. url: '/pages/sample/templateGroup',
  224. })
  225. }, 500);
  226. },
  227. }
  228. }
  229. </script>
  230. <style>
  231. button {
  232. margin-top: 30rpx;
  233. margin-bottom: 30rpx;
  234. }
  235. .button-sp-area {
  236. margin: 0 auto;
  237. width: 60%;
  238. }
  239. .mini-btn {
  240. margin-right: 10rpx;
  241. }
  242. .button {
  243. background-color: #4CAF50;
  244. /* 设置背景色 */
  245. color: white;
  246. /* 设置文字颜色 */
  247. text-align: center;
  248. border-radius: 6px;
  249. /* 添加边角半径 */
  250. box-shadow: 0 8px 16px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
  251. /* 添加阴影效果 */
  252. transition: all 0.3s ease;
  253. /* 过渡动画时间为0.3秒 */
  254. }
  255. .button:hover {
  256. transform: scale(1.1);
  257. /* 当鼠标悬停在按钮上时放大到原始比例的1.1倍 */
  258. }
  259. </style>
  260. <style lang="scss">
  261. $color-base: #0039a6;
  262. $words-color-base: #333333;
  263. $words-color-light: #999999;
  264. .header-wrap {
  265. width: 100%;
  266. position: fixed;
  267. top: 0;
  268. z-index: 999;
  269. .index-header {
  270. height: 88upx;
  271. line-height: 88upx;
  272. padding: 0 30upx;
  273. padding-top: 40upx;
  274. background-color: $color-base;
  275. font-Size: 28upx;
  276. color: #fff;
  277. display: flex;
  278. align-items: center;
  279. justify-content: space-between;
  280. .fanhui {
  281. color: #fff !important;
  282. font-size: 28px;
  283. padding-top: 5px;
  284. font-weight: 700;
  285. }
  286. .lanya {
  287. color: #fff !important;
  288. font-size: 28px;
  289. padding-top: 5px;
  290. }
  291. .map-wrap {
  292. padding-top: 5px;
  293. }
  294. }
  295. }
  296. .blank {
  297. height: 126upx;
  298. }
  299. </style>