soobin 1 год назад
Родитель
Сommit
85416a2d7b
55 измененных файлов с 1055 добавлено и 619 удалено
  1. 7 4
      src/App.vue
  2. BIN
      src/assets/device/diyFlowers/S01.png
  3. BIN
      src/assets/device/diyFlowers/S02.png
  4. BIN
      src/assets/device/diyFlowers/S03.png
  5. BIN
      src/assets/device/diyFlowers/S04.png
  6. BIN
      src/assets/device/diyFlowers/S05.png
  7. BIN
      src/assets/device/diyFlowers/S06.png
  8. BIN
      src/assets/device/diyFlowers/S07.png
  9. BIN
      src/assets/device/diyFlowers/S08.png
  10. BIN
      src/assets/device/diyFlowers/S09.png
  11. BIN
      src/assets/device/diyFlowers/T01.png
  12. BIN
      src/assets/device/diyFlowers/T02.png
  13. BIN
      src/assets/device/diyFlowers/T03.png
  14. BIN
      src/assets/device/diyFlowers/T04.png
  15. BIN
      src/assets/device/operIcon/diyFlower.png
  16. BIN
      src/assets/device/operIcon/ic_onOff.png
  17. BIN
      src/assets/device/operIcon/ic_openDoor.png
  18. BIN
      src/assets/device/operIcon/ic_password.png
  19. BIN
      src/assets/device/operIcon/ic_restart.png
  20. BIN
      src/assets/device/operIcon/ic_sleep.png
  21. BIN
      src/assets/device/operIcon/ic_商品调价@3x.png
  22. BIN
      src/assets/device/operIcon/ic_报警历史@3x.png
  23. BIN
      src/assets/device/operIcon/ic_查看位置@3x.png
  24. 13 1
      src/assets/language/en.json
  25. 12 0
      src/assets/language/zh.json
  26. 3 1
      src/main.js
  27. 18 11
      src/router/index.js
  28. 23 8
      src/service/device/index.js
  29. 400 400
      src/styles/alarmClock/index.less
  30. 17 9
      src/styles/device/index.less
  31. 5 5
      src/styles/deviceOper/index.less
  32. 3 3
      src/styles/deviceSet/index.less
  33. 2 2
      src/styles/doSugar/index.less
  34. 2 2
      src/styles/modifyPrice/index.less
  35. 94 94
      src/styles/modulation/index.less
  36. 3 3
      src/styles/orderExport/index.less
  37. 2 2
      src/styles/paramsSet/index.less
  38. 2 2
      src/styles/recharge/index.less
  39. 4 3
      src/styles/robotRanking/index.less
  40. 2 2
      src/styles/showGoods/index.less
  41. 3 3
      src/styles/user/index.less
  42. 2 2
      src/styles/viewLogs/index.less
  43. 25 3
      src/views/accountPer/add.vue
  44. 23 1
      src/views/device/deviceOper.vue
  45. 15 11
      src/views/device/deviceSet.vue
  46. 256 0
      src/views/device/diyFlower/index.vue
  47. 43 7
      src/views/device/index.vue
  48. 5 5
      src/views/device/paramsSet/paramsSetInfo.vue
  49. 17 1
      src/views/login.vue
  50. 8 3
      src/views/merchantManage/index.vue
  51. 27 16
      src/views/register.vue
  52. 4 4
      src/views/robotRanking.vue
  53. 1 1
      src/views/role/add.vue
  54. 2 2
      src/views/taskMessage/index.vue
  55. 12 8
      src/views/user.vue

+ 7 - 4
src/App.vue

@@ -4,8 +4,11 @@
       <transition :name="transitionName">
         <!-- 缓存组件,但是进入编辑页面就会有问题 -->
         <!-- <keep-alive include="device,deviceSet,role"><component :is="Component" /></keep-alive> -->
-        <component :is="Component" />
+        <component :is="Component" v-if="!$route.meta.keepAlive" />
       </transition>
+      <keep-alive>
+        <component :is="Component" v-if="$route.meta.keepAlive" />
+      </keep-alive>
     </router-view>
   </div>
 </template>
@@ -95,13 +98,13 @@ p {
 
 html {
   height: 100%;
-  overflow: hidden;
+  // overflow: hidden;
 }
 
 body {
   height: 100%;
-  overflow-x: hidden;
-  overflow-y: auto;
+  // overflow-x: hidden;
+  // overflow-y: auto;
 }
 
 #app {

BIN
src/assets/device/diyFlowers/S01.png


BIN
src/assets/device/diyFlowers/S02.png


BIN
src/assets/device/diyFlowers/S03.png


BIN
src/assets/device/diyFlowers/S04.png


BIN
src/assets/device/diyFlowers/S05.png


BIN
src/assets/device/diyFlowers/S06.png


BIN
src/assets/device/diyFlowers/S07.png


BIN
src/assets/device/diyFlowers/S08.png


BIN
src/assets/device/diyFlowers/S09.png


BIN
src/assets/device/diyFlowers/T01.png


BIN
src/assets/device/diyFlowers/T02.png


BIN
src/assets/device/diyFlowers/T03.png


BIN
src/assets/device/diyFlowers/T04.png


BIN
src/assets/device/operIcon/diyFlower.png


BIN
src/assets/device/operIcon/ic_onOff.png


BIN
src/assets/device/operIcon/ic_openDoor.png


BIN
src/assets/device/operIcon/ic_password.png


BIN
src/assets/device/operIcon/ic_restart.png


BIN
src/assets/device/operIcon/ic_sleep.png


BIN
src/assets/device/operIcon/ic_商品调价@3x.png


BIN
src/assets/device/operIcon/ic_报警历史@3x.png


BIN
src/assets/device/operIcon/ic_查看位置@3x.png


+ 13 - 1
src/assets/language/en.json

@@ -1,6 +1,6 @@
 {
   "public": {
-    "sysName": "Sunzee Technology",
+    "sysName": "Sevencloud Technology",
     "requestFailed": "Request failed, click to reload",
     "noMore": "No more"
   },
@@ -56,6 +56,7 @@
     "usernamePlaceholder": "Please enter the account number",
     "passwordLabel": "password",
     "passwordPlaceholder": "Please input a password",
+    "editPasswordPlaceholder": "If it's empty, it stays the same by default",
     "nameLabel": "full name",
     "namePlaceholder": "Please enter your name",
     "phoneLabel": "Telephone",
@@ -420,6 +421,7 @@
     "showGoods": "Block or display goods",
     "editCheck": "Are you sure about the change?",
     "unknownError": "Unknown error!",
+    "diyFlower": "DIY flower",
     "degree": "℃",
     "humidity": "%RH",
     "volume": "volume",
@@ -1206,6 +1208,7 @@
     "phonePlaceholder": "Please enter your mobile number",
     "phoneRequired": "Please enter the correct mobile number",
     "seedVerCode": "Send verification code",
+    "sending": "Sending...",
     "codeLabel": "verification code",
     "codePlaceholder": "Please enter SMS verification code",
     "codeRequired": "Please enter SMS verification code",
@@ -1383,6 +1386,15 @@
     "merchantManagement": "Merchant management",
     "labelMan": "Label management"
   },
+  "DIYFlower": {
+    "openStatus": "DIY pattern function switch status: On",
+    "closeStatus": "DIY pattern function switch status: Off",
+    "shape": "Shape",
+    "sugar": "Sugar",
+    "tips": "Remind",
+    "content": "Do you want to switch?",
+    "successfully": "Successfully sent, please wait a few seconds and re-enter"
+  },
   "Account operation": "Account operation",
   "Discount code": "Discount code",
   "Alarm history": "Alarm history",

+ 12 - 0
src/assets/language/zh.json

@@ -56,6 +56,7 @@
     "usernamePlaceholder": "请输入账号",
     "passwordLabel": "密码",
     "passwordPlaceholder": "请输入密码",
+    "editPasswordPlaceholder": "为空默认不修改",
     "nameLabel": "姓名",
     "namePlaceholder": "请输入姓名",
     "phoneLabel": "电话",
@@ -420,6 +421,7 @@
     "showGoods": "屏蔽/显示商品",
     "editCheck": "是否确认更改?",
     "unknownError": "未知错误!",
+    "diyFlower": "DIY花型",
     "degree": "℃",
     "humidity": "%RH",
     "volume": "音量",
@@ -1220,6 +1222,7 @@
     "emailWordSpan": "输入注册海外账户邮箱",
     "emailWordSpanChina": "输入注册时的国内邮箱",
     "seedVerCode": "发送验证码",
+    "sending": "发送中",
     "codeLabel": "短信验证码",
     "codePlaceholder": "请输入短信验证码",
     "codeRequired": "请输入短信验证码",
@@ -1397,6 +1400,15 @@
     "merchantManagement": "商户管理",
     "labelMan": "标签管理"
   },
+  "DIYFlower": {
+    "openStatus": "DIY花型功能开关状态:开启",
+    "closeStatus": "DIY花型功能开关状态:关闭",
+    "shape": "形状",
+    "sugar": "糖",
+    "tips": "提醒",
+    "content": "是否切换开关?",
+    "successfully": "发送成功,请等待几秒后重新进入查看"
+  },
   "wechat": {
     "headerName": "绑定微信"
   },

+ 3 - 1
src/main.js

@@ -4,7 +4,7 @@ import {
   AddressList, Field, CellGroup, Cell, SwipeCell, Icon, Stepper, Card, Checkbox, CheckboxGroup, Button, Swipe, SwipeItem,
   PullRefresh, List, Tab, Tabs, SubmitBar, Toast, Skeleton, RadioGroup, Radio, NoticeBar, ActionSheet, Cascader, Col, Row,
   Slider, DatetimePicker, Switch, Calendar, Picker, Uploader, Tag, DropdownMenu, DropdownItem, Notify, ConfigProvider, NavBar,
-  Area, Popover
+  Area, Popover, Collapse, CollapseItem
 } from 'vant';
 import { Image as VanImage } from 'vant';
 import App from './App.vue'
@@ -82,6 +82,8 @@ app.use(ActionBarButton)
   .use(NavBar)
   .use(Area)
   .use(Popover)
+  .use(Collapse)
+  .use(CollapseItem)
 
 
 app.use(router)

+ 18 - 11
src/router/index.js

@@ -61,7 +61,7 @@ const router = createRouter({
       path: "/device",
       name: "device",
       component: () => import("@/views/device/index"),
-      meta: { index: 1 },
+      meta: { index: 1, keepAlive: true },
     },
     // 设备详情
     {
@@ -448,6 +448,13 @@ const router = createRouter({
       component: () => import("@/views/device/showGoods/index"),
       meta: { index: 1 },
     },
+    // DIY花型
+    {
+      path: "/diyFlower",
+      name: "diyFlower",
+      component: () => import("@/views/device/diyFlower/index"),
+      meta: { index: 1 },
+    },
     // 修改机器密码
     {
       path: "/devicePassword",
@@ -517,16 +524,16 @@ const router = createRouter({
 // 路由守卫处理
 router.beforeEach((to, from, next) => {
   // 从账户操作页面回到home页面
-  if (from.name === "accountOperation" && to.name === "home") {
-    // router.push("/home");
-    location.reload();
-    // 阻止重定向回 账户操作页
-    if (to.path === '/accountOperation') {
-      next(false);
-    } else {
-      next();
-    }
-  }
+  // if (from.name === "accountOperation" && to.name === "home") {
+  //   // router.push("/home");
+  //   location.reload();
+  //   // 阻止重定向回 账户操作页
+  //   if (to.path === '/accountOperation') {
+  //     next(false);
+  //   } else {
+  //     next();
+  //   }
+  // }
   // 页面带有不需要识别登录状态的跳过登录验证
   if (to.meta.noLogin) {
     next();

+ 23 - 8
src/service/device/index.js

@@ -34,12 +34,12 @@ export function sleepEquipment(params) {
 
 // 远程开门
 export function openDoor(params) {
-  return axios.post(`/SZWL-SERVER/tEquipment/openDoor?${stringToUrl(params)}`, params);
+    return axios.post(`/SZWL-SERVER/tEquipment/openDoor?${stringToUrl(params)}`, params);
 }
 
 // 新版远程开门,包含内门外门
 export function Api_openDoor(params) {
-    return axios.get(`/SZWL-SERVER/tEquipment/openDoors`, {params})
+    return axios.get(`/SZWL-SERVER/tEquipment/openDoors`, { params })
 }
 
 // 系统脱机
@@ -129,27 +129,27 @@ export function saveProportion(params) {
 
 // 单个/批量修改商品价格
 export function Api_getUpdaProdPrice(params) {
-    return axios.get(`/SZWL-SERVER/tProduct/updateProduct`, {params})
+    return axios.get(`/SZWL-SERVER/tProduct/updateProduct`, { params })
 }
 
 // 一键补料
 export function Api_getReplenishment(params) {
-    return axios.get(`/SZWL-SERVER/tEquipment/buliao`, {params})
+    return axios.get(`/SZWL-SERVER/tEquipment/buliao`, { params })
 }
 
 // 远程
 export function Api_getTApkInfo_updateApk(params) {
-    return axios.get(`/SZWL-SERVER/tApkInfo/updateApk`, {params})
+    return axios.get(`/SZWL-SERVER/tApkInfo/updateApk`, { params })
 }
 
 // 修改优惠码开关状态
 export function Api_getDiscCodeStatus(params) {
-    return axios.get(`/SZWL-SERVER/tEquipment/updateCouponStatus`, {params})
+    return axios.get(`/SZWL-SERVER/tEquipment/updateCouponStatus`, { params })
 }
 
 // 修改睡眠描述
 export function changeSleepDesc(params) {
-    return axios.get(`/SZWL-SERVER/tEquipmentDesc/updateSleepDesc`, {params})
+    return axios.get(`/SZWL-SERVER/tEquipmentDesc/updateSleepDesc`, { params })
 }
 
 // 删除设备
@@ -174,5 +174,20 @@ export function customLogo(params) {
 
 // 日志下载
 export function downloadLog(params) {
-    return axios.get(`/SZWL-SERVER/tEquipment/downloadLog?${stringToUrl(params)}`,{responseType:'blob', timeout: 12000});
+    return axios.get(`/SZWL-SERVER/tEquipment/downloadLog?${stringToUrl(params)}`, { responseType: 'blob', timeout: 12000 });
+}
+
+// 获取DIY花型列表信息
+export function selectDIYFlowers(params) {
+    return axios.get(`/SZWL-SERVER/tEquipment/selectDIYFlowers?${stringToUrl(params)}`);
+}
+
+// 修改DIY花型功能开关状态
+export function updateDIYFlowerStatus(params) {
+    return axios.get(`/SZWL-SERVER/tEquipment/updateDIYFlowerStatus?${stringToUrl(params)}`);
+}
+
+// 修改DIY花型的形状或是否显示
+export function updateDIYProductShow(params) {
+    return axios.post(`/SZWL-SERVER/tEquipment/updateDIYProductShow`, params);
 }

+ 400 - 400
src/styles/alarmClock/index.less

@@ -1,204 +1,172 @@
 .clockPage {
-    background-color: rgba(255, 255, 255, 1);
-    position: relative;
+  background-color: rgba(255, 255, 255, 1);
+  // position: relative;
+  width: 100%;
+  height: 100%;
+  overflow: auto;
+  overflow-x: hidden;
+
+  .bd1 {
     width: 100%;
-    height: 100%;
-    overflow: hidden;
-    overflow-y: auto;
-  
-    .bd1 {
+    height: 439px;
+
+    .section5 {
+      background-color: rgba(255, 255, 255, 1);
+      z-index: 91;
+      height: 54px;
+      margin-top: 1px;
       width: 100%;
-      height: 439px;
-  
-      .section5 {
-        background-color: rgba(255, 255, 255, 1);
-        z-index: 91;
-        height: 54px;
-        margin-top: 1px;
-        width: 100%;
-        position: relative;
-  
-        .layer1 {
-          width: 84px;
+      position: relative;
+
+      .layer1 {
+        width: 84px;
+        height: 20px;
+        margin: 17px 0 0 15px;
+
+        .ImageText1 {
           height: 20px;
-          margin: 17px 0 0 15px;
-  
-          .ImageText1 {
-            height: 20px;
+          width: 84px;
+
+          .layer1 {
             width: 84px;
-  
-            .layer1 {
-              width: 84px;
+            height: 20px;
+            margin: 0 auto;
+
+            .bd2 {
+              width: 20px;
               height: 20px;
-              margin: 0 auto;
-  
-              .bd2 {
-                width: 20px;
-                height: 20px;
-                background: url('../../assets/device/add.png');
-                background-size: 100%;
-              }
-  
-              .TextGroup1 {
-                height: 20px;
+              background: url('../../assets/device/add.png');
+              background-size: 100%;
+            }
+
+            .TextGroup1 {
+              height: 20px;
+              width: 56px;
+
+              .word2 {
                 width: 56px;
-  
-                .word2 {
-                  width: 56px;
-                  height: 20px;
-                  overflow-wrap: break-word;
-                  color: rgba(64, 77, 116, 1);
-                  font-size: 14px;
-                  font-family: PingFangSC-Medium;
-                  text-align: left;
-                  white-space: nowrap;
-                  line-height: 20px;
-                  display: block;
-                }
+                height: 20px;
+                overflow-wrap: break-word;
+                color: rgba(64, 77, 116, 1);
+                font-size: 14px;
+                font-family: PingFangSC-Medium;
+                text-align: left;
+                white-space: nowrap;
+                line-height: 20px;
+                display: block;
               }
             }
           }
         }
-  
-        .img2 {
-          z-index: 93;
-          position: absolute;
-          left: 0;
-          top: 53px;
-          width: 100%;
-          height: 2px;
-        }
       }
-  
-      .section6 {
+
+      .img2 {
+        z-index: 93;
+        position: absolute;
+        left: 0;
+        top: 53px;
         width: 100%;
-        padding: 10px 15px;
-  
-        .TextGroup2 {
-          width: 25%;
-  
-          .bd3 {
-            .word3 {
-              width: auto;
-              height: 30px;
-              overflow-wrap: break-word;
-              color: rgba(64, 77, 116, 1);
-              font-size: 22px;
-              font-family: PingFangSC-Medium;
-              text-align: left;
-              white-space: nowrap;
-              line-height: 30px;
-              display: block;
-            }
-  
-            .info2 {
-              width: auto;
-              height: 18px;
-              overflow-wrap: break-word;
-              color: rgba(64, 77, 116, 1);
-              font-size: 13px;
-              text-align: left;
-              // white-space: nowrap;
-              line-height: 18px;
-              display: block;
-              margin: -2px 0 0 2px;
-            }
+        height: 2px;
+      }
+    }
+
+    .section6 {
+      width: 100%;
+      padding: 10px 15px;
+
+      .TextGroup2 {
+        width: 25%;
+
+        .bd3 {
+          .word3 {
+            width: auto;
+            height: 30px;
+            overflow-wrap: break-word;
+            color: rgba(64, 77, 116, 1);
+            font-size: 22px;
+            font-family: PingFangSC-Medium;
+            text-align: left;
+            white-space: nowrap;
+            line-height: 30px;
+            display: block;
+          }
+
+          .info2 {
+            width: auto;
+            height: 18px;
+            overflow-wrap: break-word;
+            color: rgba(64, 77, 116, 1);
+            font-size: 13px;
+            text-align: left;
+            // white-space: nowrap;
+            line-height: 18px;
+            display: block;
+            margin: -2px 0 0 2px;
           }
         }
-  
-        .TextGroup3 {
+      }
+
+      .TextGroup3 {
+        height: 38px;
+        width: 40%;
+
+        .main2 {
+          width: auto;
           height: 38px;
-          width: 40%;
-  
-          .main2 {
+
+          .word4 {
             width: auto;
-            height: 38px;
-  
-            .word4 {
-              width: auto;
-              height: 18px;
-              overflow-wrap: break-word;
-              color: rgba(64, 77, 116, 1);
-              font-size: 13px;
-              text-align: left;
-              white-space: nowrap;
-              line-height: 18px;
-              display: block;
-            }
-  
-            .txt3 {
-              width: auto;
-              height: 18px;
-              overflow-wrap: break-word;
-              color: rgba(64, 77, 116, 1);
-              font-size: 13px;
-              text-align: left;
-              white-space: nowrap;
-              line-height: 18px;
-              margin-top: 2px;
-              display: block;
-            }
+            height: 18px;
+            overflow-wrap: break-word;
+            color: rgba(64, 77, 116, 1);
+            font-size: 13px;
+            text-align: left;
+            white-space: nowrap;
+            line-height: 18px;
+            display: block;
+          }
+
+          .txt3 {
+            width: auto;
+            height: 18px;
+            overflow-wrap: break-word;
+            color: rgba(64, 77, 116, 1);
+            font-size: 13px;
+            text-align: left;
+            white-space: nowrap;
+            line-height: 18px;
+            margin-top: 2px;
+            display: block;
           }
         }
-  
-        .ImageText2 {
+      }
+
+      .ImageText2 {
+        height: 17px;
+        width: 10%;
+        margin: 9px 0 0 20px;
+
+        .group3 {
+          width: 40px;
           height: 17px;
-          width: 10%;
-          margin: 9px 0 0 20px;
-  
-          .group3 {
-            width: 40px;
-            height: 17px;
-  
-            .group4 {
-              width: 13px;
-              height: 14px;
-              background: url(https://lanhu.oss-cn-beijing.aliyuncs.com/SketchPngb70cca70325ff31d341004d9ce7ebf2d5f692bbe3bf755d9d44b36aa78c21c77) top center no-repeat;
-              background-size: 100%;
-              margin-top: 1px;
-            }
-  
-            .TextGroup4 {
-              height: 17px;
-              width: 24px;
-  
-              .info3 {
-                width: 24px;
-                height: 17px;
-                overflow-wrap: break-word;
-                color: rgba(223, 94, 76, 1);
-                font-size: 12px;
-                text-align: left;
-                white-space: nowrap;
-                line-height: 17px;
-                display: block;
-              }
-            }
+
+          .group4 {
+            width: 13px;
+            height: 14px;
+            background: url(https://lanhu.oss-cn-beijing.aliyuncs.com/SketchPngb70cca70325ff31d341004d9ce7ebf2d5f692bbe3bf755d9d44b36aa78c21c77) top center no-repeat;
+            background-size: 100%;
+            margin-top: 1px;
           }
-        }
-  
-        .bd4 {
-          width: 10%;
-          height: 36px;
-          margin: 10px 0 0 15px;
-          
-          .outer1 {
-            width: 41px;
+
+          .TextGroup4 {
             height: 17px;
-  
-            .main3 {
-              width: 15px;
-              height: 15px;
-              background: url('../../assets/edit.png') top center no-repeat;
-              background-size: 100%;
-              margin-top: 1px;
-            }
-  
-            .word5 {
+            width: 24px;
+
+            .info3 {
               width: 24px;
               height: 17px;
               overflow-wrap: break-word;
-              color: #2c87c8;
+              color: rgba(223, 94, 76, 1);
               font-size: 12px;
               text-align: left;
               white-space: nowrap;
@@ -206,258 +174,290 @@
               display: block;
             }
           }
-  
-          .word6 {
-            width: 39px;
-            height: 18px;
+        }
+      }
+
+      .bd4 {
+        width: 10%;
+        height: 36px;
+        margin: 10px 0 0 15px;
+
+        .outer1 {
+          width: 41px;
+          height: 17px;
+
+          .main3 {
+            width: 15px;
+            height: 15px;
+            background: url('../../assets/edit.png') top center no-repeat;
+            background-size: 100%;
+            margin-top: 1px;
+          }
+
+          .word5 {
+            width: 24px;
+            height: 17px;
             overflow-wrap: break-word;
-            color: rgba(77, 193, 147, 1);
-            font-size: 13px;
+            color: #2c87c8;
+            font-size: 12px;
             text-align: left;
             white-space: nowrap;
-            line-height: 18px;
+            line-height: 17px;
             display: block;
-            margin: 1px 0 0 2px;
-  
-            &.close {
-              color: rgba(197, 197, 205, 1);
-            }
+          }
+        }
+
+        .word6 {
+          width: 39px;
+          height: 18px;
+          overflow-wrap: break-word;
+          color: rgba(77, 193, 147, 1);
+          font-size: 13px;
+          text-align: left;
+          white-space: nowrap;
+          line-height: 18px;
+          display: block;
+          margin: 1px 0 0 2px;
+
+          &.close {
+            color: rgba(197, 197, 205, 1);
           }
         }
       }
     }
   }
+}
+
+.alarmClockSetPage {
+  width: 100%;
 
-  .alarmClockSetPage {
+  .alarmClockSetBox {
+    width: 100%;
+    height: calc(100% - 44px);
+    overflow: auto;
+    overflow-x: hidden;
+
+    .equipmentField {
+      .van-field__label {
+        display: flex;
+        align-items: center;
+        line-height: 1;
+
+        &::before {
+          content: '';
+          width: 4px;
+          height: 12px;
+          margin: 0 4px;
+          background-color: #5a9cc8;
+          border-radius: 2px;
+          display: inline-block;
+        }
+      }
+    }
+
+    .repeatTimeBox {
       width: 100%;
+      padding-bottom: 18px;
+      border-bottom: 1px solid var(--van-cell-border-color);
+    }
 
-      .alarmClockSetBox {
-          width: 100%;
-          height: calc(100% - 44px);
-          overflow: auto;
-          overflow-x: hidden;
-
-          .equipmentField {
-              .van-field__label {
-                  display: flex;
-                  align-items: center;
-                  line-height: 1;
-
-                  &::before {
-                      content: '';
-                      width: 4px;
-                      height: 12px;
-                      margin: 0 4px;
-                      background-color: #5a9cc8;
-                      border-radius: 2px;
-                      display: inline-block;
-                  }
-              }
-          }
+    .dayCon {
+      padding: 6px 15px;
 
-          .repeatTimeBox {
-              width: 100%;
-              padding-bottom: 18px;
-              border-bottom: 1px solid var(--van-cell-border-color);
-          }
+      .dayName {
+        padding: 6px 10px;
+        background-color: rgba(223, 223, 229, 1);
+        border-radius: 2px;
+        border: 0.5px solid rgba(185, 186, 208, 1);
+      }
 
-          .dayCon {
-              padding: 6px 15px;
+      .active {
+        background-color: #2c87c8 !important;
+        border-color: #2c87c8 !important;
+        color: #fff !important;
+      }
+    }
 
-              .dayName {
-                  padding: 6px 10px;
-                  background-color: rgba(223, 223, 229, 1);
-                  border-radius: 2px;
-                  border: 0.5px solid rgba(185, 186, 208, 1);
-              }
+    .txt6 {
+      width: 112px;
+      height: 13px;
+      overflow-wrap: break-word;
+      color: rgba(64, 77, 116, 1);
+      font-size: 14px;
+      font-family: PingFangSC-Medium;
+      text-align: left;
+      white-space: nowrap;
+      line-height: 14px;
+      display: block;
+      margin: 18px 0 15px 15px;
+    }
 
-              .active {
-                  background-color: #2c87c8 !important;
-                  border-color: #2c87c8 !important;
-                  color: #fff !important;
-              }
-          }
+    .outer4 {
+      width: 345px;
+      height: 38px;
+      margin: 20px 0 0 15px;
+
+      .mod3 {
+        background-color: rgba(223, 223, 229, 1);
+        border-radius: 2px;
+        height: 38px;
+        border: 0.5px solid rgba(185, 186, 208, 1);
+        width: 119px;
+
+        .word2 {
+          width: 26px;
+          height: 13px;
+          overflow-wrap: break-word;
+          color: rgba(64, 77, 116, 1);
+          font-size: 13px;
+          text-align: left;
+          white-space: nowrap;
+          line-height: 13px;
+          display: block;
+          margin: 13px 0 0 47px;
+        }
+      }
 
-          .txt6 {
-              width: 112px;
-              height: 13px;
-              overflow-wrap: break-word;
-              color: rgba(64, 77, 116, 1);
-              font-size: 14px;
-              font-family: PingFangSC-Medium;
-              text-align: left;
-              white-space: nowrap;
-              line-height: 14px;
-              display: block;
-              margin: 18px 0 15px 15px;
-          }
+      .Button1 {
+        background-color: rgba(223, 223, 229, 1);
+        border-radius: 2px;
+        height: 38px;
+        border: 0.5px solid rgba(185, 186, 208, 1);
+        width: 211px;
+
+        .word3 {
+          width: 117px;
+          height: 13px;
+          overflow-wrap: break-word;
+          color: rgba(64, 77, 116, 1);
+          font-size: 13px;
+          text-align: left;
+          white-space: nowrap;
+          line-height: 13px;
+          display: block;
+          margin: 13px 0 0 47px;
+        }
+      }
+    }
 
-          .outer4 {
-              width: 345px;
-              height: 38px;
-              margin: 20px 0 0 15px;
-
-              .mod3 {
-                  background-color: rgba(223, 223, 229, 1);
-                  border-radius: 2px;
-                  height: 38px;
-                  border: 0.5px solid rgba(185, 186, 208, 1);
-                  width: 119px;
-
-                  .word2 {
-                      width: 26px;
-                      height: 13px;
-                      overflow-wrap: break-word;
-                      color: rgba(64, 77, 116, 1);
-                      font-size: 13px;
-                      text-align: left;
-                      white-space: nowrap;
-                      line-height: 13px;
-                      display: block;
-                      margin: 13px 0 0 47px;
-                  }
-              }
+    .outer5 {
+      width: 345px;
+      height: 38px;
+      margin: 15px 0 0 15px;
+
+      .bd1 {
+        background-color: rgba(223, 223, 229, 1);
+        border-radius: 2px;
+        height: 38px;
+        border: 0.5px solid rgba(185, 186, 208, 1);
+        width: 211px;
+
+        .word4 {
+          width: 117px;
+          height: 13px;
+          overflow-wrap: break-word;
+          color: rgba(64, 77, 116, 1);
+          font-size: 13px;
+          text-align: left;
+          white-space: nowrap;
+          line-height: 13px;
+          display: block;
+          margin: 13px 0 0 47px;
+        }
+      }
 
-              .Button1 {
-                  background-color: rgba(223, 223, 229, 1);
-                  border-radius: 2px;
-                  height: 38px;
-                  border: 0.5px solid rgba(185, 186, 208, 1);
-                  width: 211px;
-
-                  .word3 {
-                      width: 117px;
-                      height: 13px;
-                      overflow-wrap: break-word;
-                      color: rgba(64, 77, 116, 1);
-                      font-size: 13px;
-                      text-align: left;
-                      white-space: nowrap;
-                      line-height: 13px;
-                      display: block;
-                      margin: 13px 0 0 47px;
-                  }
-              }
-          }
+      .bd2 {
+        background-color: rgba(223, 223, 229, 1);
+        border-radius: 2px;
+        height: 38px;
+        border: 0.5px solid rgba(185, 186, 208, 1);
+        width: 119px;
+
+        .word5 {
+          width: 39px;
+          height: 13px;
+          overflow-wrap: break-word;
+          color: rgba(64, 77, 116, 1);
+          font-size: 13px;
+          text-align: left;
+          white-space: nowrap;
+          line-height: 13px;
+          display: block;
+          margin: 13px 0 0 40px;
+        }
+      }
+    }
 
-          .outer5 {
-              width: 345px;
-              height: 38px;
-              margin: 15px 0 0 15px;
-
-              .bd1 {
-                  background-color: rgba(223, 223, 229, 1);
-                  border-radius: 2px;
-                  height: 38px;
-                  border: 0.5px solid rgba(185, 186, 208, 1);
-                  width: 211px;
-
-                  .word4 {
-                      width: 117px;
-                      height: 13px;
-                      overflow-wrap: break-word;
-                      color: rgba(64, 77, 116, 1);
-                      font-size: 13px;
-                      text-align: left;
-                      white-space: nowrap;
-                      line-height: 13px;
-                      display: block;
-                      margin: 13px 0 0 47px;
-                  }
-              }
+    .ImageText1 {
+      height: 18px;
+      width: auto;
+      margin: 23px 0 0 15px;
 
-              .bd2 {
-                  background-color: rgba(223, 223, 229, 1);
-                  border-radius: 2px;
-                  height: 38px;
-                  border: 0.5px solid rgba(185, 186, 208, 1);
-                  width: 119px;
-
-                  .word5 {
-                      width: 39px;
-                      height: 13px;
-                      overflow-wrap: break-word;
-                      color: rgba(64, 77, 116, 1);
-                      font-size: 13px;
-                      text-align: left;
-                      white-space: nowrap;
-                      line-height: 13px;
-                      display: block;
-                      margin: 13px 0 0 40px;
-                  }
-              }
+      .mod4 {
+        width: 109px;
+        height: auto;
+
+        .TextGroup1 {
+          height: 13px;
+          margin-top: 2px;
+          width: auto;
+
+          .info4 {
+            width: auto;
+            height: 13px;
+            overflow-wrap: break-word;
+            color: rgba(64, 77, 116, 1);
+            font-size: 13px;
+            text-align: left;
+            white-space: nowrap;
+            line-height: 13px;
+            display: block;
           }
+        }
+
+        .section1 {
+          background-color: rgba(223, 223, 229, 1);
+          border-radius: 9px;
+          height: 18px;
+          width: 38px;
+
+          .van-switch {
+            width: 38px;
+            height: 18px;
 
-          .ImageText1 {
+            .van-switch__node {
+              width: 18px;
               height: 18px;
-              width: auto;
-              margin: 23px 0 0 15px;
-
-              .mod4 {
-                  width: 109px;
-                  height: auto;
-
-                  .TextGroup1 {
-                      height: 13px;
-                      margin-top: 2px;
-                      width: auto;
-
-                      .info4 {
-                          width: auto;
-                          height: 13px;
-                          overflow-wrap: break-word;
-                          color: rgba(64, 77, 116, 1);
-                          font-size: 13px;
-                          text-align: left;
-                          white-space: nowrap;
-                          line-height: 13px;
-                          display: block;
-                      }
-                  }
-
-                  .section1 {
-                      background-color: rgba(223, 223, 229, 1);
-                      border-radius: 9px;
-                      height: 18px;
-                      width: 38px;
-
-                      .van-switch {
-                          width: 38px;
-                          height: 18px;
-
-                          .van-switch__node {
-                              width: 18px;
-                              height: 18px;
-                          }
-
-                          &.van-switch--on .van-switch__node {
-                              transform: translate(calc(38px - 18px));
-                          }
-                      }
-                  }
-              }
+            }
+
+            &.van-switch--on .van-switch__node {
+              transform: translate(calc(38px - 18px));
+            }
           }
+        }
       }
+    }
+  }
 
-      .van-checkbox__icon--checked .van-icon {
-          background-color: #2c87c8;
-          border-color: #2c87c8;
-      }
+  .van-checkbox__icon--checked .van-icon {
+    background-color: #2c87c8;
+    border-color: #2c87c8;
+  }
 
-      .van-switch--on {
-          background-color: #2c87c8;
-      }
+  .van-switch--on {
+    background-color: #2c87c8;
+  }
 
-      .van-button--primary {
-          background-color: #2c87c8;
-          border-color: #2c87c8;
-      }
+  .van-button--primary {
+    background-color: #2c87c8;
+    border-color: #2c87c8;
+  }
 
-      .van-cascader__option--selected {
-          color: #2c87c8;
-      }
+  .van-cascader__option--selected {
+    color: #2c87c8;
+  }
 
-      .van-tabs__line {
-          background-color: #2c87c8 !important;
-      }
-  }
+  .van-tabs__line {
+    background-color: #2c87c8 !important;
+  }
+}

+ 17 - 9
src/styles/device/index.less

@@ -1,13 +1,13 @@
 .devicePage {
   background-color: rgba(255, 255, 255, 1);
   position: relative;
-  overflow: hidden;
+  // overflow: hidden;
 
   .listBox {
     width: 100%;
-    height: calc(100vh - 100px);
-    overflow: hidden;
-    overflow-y: auto;
+    // height: calc(100vh - 100px);
+    // height: auto;
+    // overflow: auto;
 
     .deviceBox1 {
 
@@ -295,7 +295,9 @@
               text-decoration: underline;
               cursor: pointer;
               font-size: 14px;
+              width: 90%;
             }
+
             // .clickable-link:active {
             //   color: rgb(26, 49, 117);
             // }
@@ -366,13 +368,19 @@
                 background-size: 100%;
                 margin-top: 2px;
               }
+
               .c-text-14 {
-                display: inline-block; /* 将行内文本转为块级元素 */
-                padding: 5px 15px; /* 添加内边距 */
+                display: inline-block;
+                /* 将行内文本转为块级元素 */
+                padding: 5px 15px;
+                /* 添加内边距 */
                 background-color: #df5e4c;
-                border-radius: 14px; /* 添加圆角效果 */
-                color: #fff; /* 设置文本颜色 */
-                cursor: pointer; /* 设置光标样式 */
+                border-radius: 14px;
+                /* 添加圆角效果 */
+                color: #fff;
+                /* 设置文本颜色 */
+                cursor: pointer;
+                /* 设置光标样式 */
               }
             }
 

+ 5 - 5
src/styles/deviceOper/index.less

@@ -125,11 +125,11 @@
 }
 
 .openDoorPage {
-	background-color: rgba(255, 255, 255, 1);
-	position: relative;
-	width: 100%;
-	height: calc(100vh - 44px);
-	overflow: hidden;
+    background-color: rgba(255, 255, 255, 1);
+    // position: relative;
+    width: 100%;
+    height: calc(100vh - 44px);
+    overflow: auto;
 
 
 	.box1 {

+ 3 - 3
src/styles/deviceSet/index.less

@@ -1,10 +1,10 @@
 .deviceSetPage {
     background-color: rgba(255, 255, 255, 1);
-    position: relative;
+    // position: relative;
     width: 100%;
     height: calc(100vh);
-    overflow: hidden;
-    overflow-y: auto;
+    overflow: auto;
+    overflow-x: hidden;
 
     .bd1 {
         width: 100%;

+ 2 - 2
src/styles/doSugar/index.less

@@ -1,9 +1,9 @@
 .sugarPage {
     background-color: rgba(255, 255, 255, 1);
-    position: relative;
+    // position: relative;
     width: 100%;
     height: calc(100vh - 44px);
-    overflow: hidden;
+    overflow: auto;
 
     .van-cell {
         margin-top: 13px;

+ 2 - 2
src/styles/modifyPrice/index.less

@@ -1,7 +1,7 @@
 .modifyPriceIdx {
     height: calc(100%-44px);
-    overflow: hidden;
-    overflow-y: auto;
+    overflow: auto;
+    overflow-x: hidden;
 
     .headerCon {
         .line {

+ 94 - 94
src/styles/modulation/index.less

@@ -1,119 +1,119 @@
 .modulationPage {
-    background-color: rgba(255, 255, 255, 1);
-    position: relative;
-    width: 100%;
-    height: calc(100vh - 44px);
-    overflow: hidden;
-
-    .van-slider {
-      width: 92%;
-      height: 4px;
-      margin: 0 auto;
-      margin-top: 35px;
-      background-color: #dfdfe5;
+  background-color: rgba(255, 255, 255, 1);
+  // position: relative;
+  width: 100%;
+  height: calc(100vh - 44px);
+  overflow: auto;
 
-      .van-slider__bar {
-        background-color: #2c87c8;
-      }
+  .van-slider {
+    width: 92%;
+    height: 4px;
+    margin: 0 auto;
+    margin-top: 35px;
+    background-color: #dfdfe5;
 
-      .van-slider__button {
-        background-color: #2c87c8;
-        width: 16px;
-        height: 16px;
-      }
+    .van-slider__bar {
+      background-color: #2c87c8;
     }
 
-    .volumeChangeButton {
+    .van-slider__button {
       background-color: #2c87c8;
-      width: 220px;
-      height: 34px;
-      margin: 49px auto;
-
-      .van-button__text {
-        font-size: 15px;
-      }
+      width: 16px;
+      height: 16px;
     }
+  }
 
+  .volumeChangeButton {
+    background-color: #2c87c8;
+    width: 220px;
+    height: 34px;
+    margin: 49px auto;
 
-    .wrap1 {
-      width: 100%;
-      height: 274px;
-
-      .box2 {
-        background-color: rgba(255, 255, 255, 1);
-        z-index: 23;
-        height: 54px;
-        margin-top: 1px;
-        width: 100%;
-        position: relative;
-
-        .section3 {
-          width: 162px;
-          height: 20px;
-          margin: 17px 0 0 15px;
+    .van-button__text {
+      font-size: 15px;
+    }
+  }
 
-          .box3 {
-            background-color: #5a9cc8;
-            border-radius: 2px;
-            width: 4px;
-            height: 12px;
-            margin-top: 4px;
-          }
 
-          .info1 {
-            width: 150px;
-            height: 20px;
-            overflow-wrap: break-word;
-            color: rgba(64, 77, 116, 1);
-            font-size: 14px;
-            font-family: PingFangSC-Medium;
-            text-align: left;
-            white-space: nowrap;
-            line-height: 20px;
-            display: block;
-          }
-        }
+  .wrap1 {
+    width: 100%;
+    height: 274px;
 
-        .img1 {
-          z-index: 31;
-          position: absolute;
-          left: 0;
-          top: 53px;
-          width: 100%;
-          height: 2px;
-        }
-      }
+    .box2 {
+      background-color: rgba(255, 255, 255, 1);
+      z-index: 23;
+      height: 54px;
+      margin-top: 1px;
+      width: 100%;
+      position: relative;
 
-      .box4 {
-        width: 45%;
-        height: 14px;
-        margin: 19px 0 0 15px;
+      .section3 {
+        width: 162px;
+        height: 20px;
+        margin: 17px 0 0 15px;
 
-        .word3 {
-          width: auto;
-          height: 13px;
-          overflow-wrap: break-word;
-          color: rgba(64, 77, 116, 1);
-          font-size: 13px;
-          text-align: left;
-          white-space: nowrap;
-          line-height: 13px;
-          margin-top: 1px;
-          display: block;
+        .box3 {
+          background-color: #5a9cc8;
+          border-radius: 2px;
+          width: 4px;
+          height: 12px;
+          margin-top: 4px;
         }
 
-        .word4 {
-          width: auto;
-          height: 13px;
+        .info1 {
+          width: 150px;
+          height: 20px;
           overflow-wrap: break-word;
           color: rgba(64, 77, 116, 1);
-          font-size: 15px;
+          font-size: 14px;
           font-family: PingFangSC-Medium;
           text-align: left;
           white-space: nowrap;
-          line-height: 15px;
+          line-height: 20px;
           display: block;
         }
       }
+
+      .img1 {
+        z-index: 31;
+        position: absolute;
+        left: 0;
+        top: 53px;
+        width: 100%;
+        height: 2px;
+      }
+    }
+
+    .box4 {
+      width: 45%;
+      height: 14px;
+      margin: 19px 0 0 15px;
+
+      .word3 {
+        width: auto;
+        height: 13px;
+        overflow-wrap: break-word;
+        color: rgba(64, 77, 116, 1);
+        font-size: 13px;
+        text-align: left;
+        white-space: nowrap;
+        line-height: 13px;
+        margin-top: 1px;
+        display: block;
+      }
+
+      .word4 {
+        width: auto;
+        height: 13px;
+        overflow-wrap: break-word;
+        color: rgba(64, 77, 116, 1);
+        font-size: 15px;
+        font-family: PingFangSC-Medium;
+        text-align: left;
+        white-space: nowrap;
+        line-height: 15px;
+        display: block;
+      }
     }
-  }
+  }
+}

+ 3 - 3
src/styles/orderExport/index.less

@@ -2,12 +2,12 @@
     background-color: #fff;
     width: 100%;
     height: calc(100%-44px);
-    overflow: hidden;
-    overflow-y: auto;
+    overflow: auto;
+    overflow-x: hidden;
 
     .Body {
         z-index: 22;
-        position: relative;
+        // position: relative;
         width: 100%;
 
         .mod3 {

+ 2 - 2
src/styles/paramsSet/index.less

@@ -1,7 +1,7 @@
 .paramsSetPage {
-    position: relative;
+    // position: relative;
     width: 100%;
-    overflow: hidden;
+    overflow: auto;
 
     .paramsSetBox {
         width: 100%;

+ 2 - 2
src/styles/recharge/index.less

@@ -1,9 +1,9 @@
 .rechargePage {
     background-color: rgba(255, 255, 255, 1);
-    position: relative;
+    // position: relative;
     width: 100%;
     height: calc(100vh - 44px);
-    overflow: hidden;
+    overflow: auto;
 
     .numberInput {
         .van-field__control {

+ 4 - 3
src/styles/robotRanking/index.less

@@ -77,11 +77,12 @@ button:active {
 
 .robotRanking {
     background-color: #fff;
-    position: relative;
+    // position: relative;
     width: 100%;
+    height: calc(100%-50px);
     padding-bottom: 60px;
-    overflow: hidden;
-    overflow-y: auto;
+    overflow: auto;
+    overflow-x: hidden;
 
     .box1 {
         height: 100%;

+ 2 - 2
src/styles/showGoods/index.less

@@ -1,7 +1,7 @@
 .showGoodsIdx {
     // height: calc(100%-44px);
-    overflow: hidden;
-    overflow-y: auto;
+    overflow: auto;
+    overflow-x: hidden;
 
 
     .headerCon {

+ 3 - 3
src/styles/user/index.less

@@ -2,7 +2,7 @@
     width: 100%;
     background: url(../../assets/user/bg.png) top center no-repeat;
     background-size: 100%;
-    position: relative;
+    // position: relative;
 
     .simple-header {
         background: transparent;
@@ -10,9 +10,9 @@
 
     .userPageBox {
         width: 100%;
-        height: calc(100% - 100px);
+        height: calc(100% - 50px);
         height: 100%;
-        margin-bottom: 100px;
+        // margin-bottom: 100px;
         overflow: auto;
         overflow-x: hidden;
     }

+ 2 - 2
src/styles/viewLogs/index.less

@@ -1,9 +1,9 @@
 .viewLogsPage {
 	background-color: rgba(255, 255, 255, 1);
-	position: relative;
+	// position: relative;
 	width: 100%;
 	height: calc(100vh - 44px);
-	overflow: hidden;
+	overflow: auto;
 
 	.volumeChangeButton {
 		background-color: #2c87c8;

+ 25 - 3
src/views/accountPer/add.vue

@@ -9,8 +9,8 @@
             { required: true, message: $t('accountPer.usernamePlaceholder') },
           ]" />
         <van-field v-model="password" name="password" type="password" :label="$t('accountPer.passwordLabel')"
-          :placeholder="$t('accountPer.passwordPlaceholder')" :rules="[
-            { required: true, message: $t('accountPer.passwordPlaceholder') },
+          :placeholder="passwordPlaceholder" :rules="[
+            { required: havePassword, message: $t('accountPer.passwordPlaceholder') },
           ]" />
         <van-field v-model="name" name="name" :label="$t('accountPer.nameLabel')"
           :placeholder="$t('accountPer.namePlaceholder')" :rules="[
@@ -28,7 +28,7 @@
           </div>
           <div class="van-cell__value van-field__value">
             <div class="van-field__body">
-              <van-switch v-model="isEnabled" /><span>{{
+              <van-switch v-model="isEnabled" class="o-mr-10" /><span>{{
                 $t("accountPer.startOrNot")
               }}</span>
             </div>
@@ -104,6 +104,8 @@ export default {
       equipmentIdShow.value = false;
       equipmentIdText.value = selectedOptions[0].text;
     };
+    const passwordPlaceholder = ref("");
+    const havePassword = ref(true);
     let addParams = reactive({
       username: "",
       password: "",
@@ -132,8 +134,13 @@ export default {
         addParams.isEnabled = accoutPerSet.isEnabled;
         addParams.roleList = accoutPerSet.roleList[0];
         addParams.equipmentIds = accoutPerSet.equipmentIds;
+        havePassword.value = false;
+        passwordPlaceholder.value = t('accountPer.editPasswordPlaceholder')
+
       } else {
         pageTitle.value = t("accountPer.addAccount");
+        passwordPlaceholder.value = t('accountPer.passwordPlaceholder');
+        havePassword.value = true;
       }
       getSysRoleListFun();
       getEquipmentListFun();
@@ -165,6 +172,19 @@ export default {
           });
         }
         selEquipOptions.value = data.data;
+        if (addParams.equipmentIds != null) {
+          const list = addParams.equipmentIds.split(',');
+          const listName = [];
+          // 根据id找到对应的name
+          selEquipOptions.value.forEach(item => {
+            list.forEach(item1 => {
+              if (item.id === item1) {
+                listName.push(item.name);
+              }
+            })
+          })
+          cofficentForm.value.equipmentNames = listName.join(",");
+        }
       } else {
         Toast.fail(data.message);
       }
@@ -267,6 +287,8 @@ export default {
       selEquipConfirm,
       cofficentForm,
       busiEquipInpClk,
+      havePassword,
+      passwordPlaceholder
     };
   },
 };

+ 23 - 1
src/views/device/deviceOper.vue

@@ -105,12 +105,22 @@
         </div>
         <div class="operText">{{ $t("device.modifyPrice") }}</div>
       </div>
+      <!-- 屏蔽/展示商品 -->
       <div class="operItem" @click="showGoodsClk()">
         <div class="operIcon">
           <img class="operImg" src="../../assets/device/operIcon/showGoods.png" />
         </div>
         <div class="operText">{{ $t("device.showGoods") }}</div>
       </div>
+      <!-- DIY花型 -->
+      <!-- v-if="device.equimentType == 'MG320' || device.equimentType == 'MG330'" -->
+      <div class="operItem" v-if="user.type < 1" @click="diyFlowerClk()">
+        <div class="operIcon">
+          <img class="operImg" src="../../assets/device/operIcon/diyFlower.png" />
+        </div>
+        <div class="operText">{{ $t("device.diyFlower") }}</div>
+      </div>
+      <!-- 修改机器密码 -->
       <div v-if="user.type < 3" class="operItem" @click="changePasswordClk()">
         <div class="operIcon">
           <img class="operImg" src="../../assets/device/operIcon/password.png" />
@@ -175,7 +185,7 @@ import { useI18n } from "vue-i18n";
 import { getLoginUser, styleUrl } from "@/common/js/utils";
 
 export default {
-  emits: ['operfinish'],  
+  emits: ['operfinish'],
   setup(props, { emit }) {
     // 点击修改价格
     const modifyPriceClk = () => {
@@ -191,6 +201,13 @@ export default {
         query: { deviceId: device.value.id, name: device.value.name },
       });
     };
+    // 点击DIY花型
+    const diyFlowerClk = () => {
+      router.push({
+        path: "diyFlower",
+        query: { deviceId: device.value.id, name: device.value.name, diyFlowerStatus: device.value.diyFlowerStatus, flower: device.value.flowers },
+      });
+    };
     const { t } = useI18n();
     const user = getLoginUser();
     const router = useRouter();
@@ -217,6 +234,9 @@ export default {
         sleepTitle.value = t("device.turnOnSleep");
       }
     };
+    const closeOper = () => {
+      show.value = false;
+    }
     // 重启炉头
     const restartFurnace = () => {
       operType.value = 1;
@@ -405,6 +425,7 @@ export default {
       show,
       operCheckShow,
       showOper,
+      closeOper,
       restartFurnace,
       operCheckClear,
       operCheck,
@@ -422,6 +443,7 @@ export default {
       isRole,
       modifyPriceClk,
       showGoodsClk,
+      diyFlowerClk,
       sleepTitle,
       viewLogs,
       deleteDevice,

+ 15 - 11
src/views/device/deviceSet.vue

@@ -12,8 +12,7 @@
           </div>
           <div class="mod2 flex-col"></div>
         </div>
-        <van-field readonly v-model="deviceDetal.clientId" :label="`${$t('device.equipmentCode')}`"
-          placeholder="" />
+        <van-field readonly v-model="deviceDetal.clientId" :label="`${$t('device.equipmentCode')}`" placeholder="" />
         <div class="cust_vantBorder">
           <van-field required clearable v-model="deviceDetal.name" name="name"
             :label="`${$t('device.equipmentNameLabel')}`" :placeholder="$t('device.equipmentNamePlaceholder')" :rules="[
@@ -58,8 +57,7 @@
             </template>
           </van-field>
         </div> -->
-        <van-field readonly v-model="deviceDetal.equimentType" :label="`${$t('device.machineType')}`"
-          placeholder="" />
+        <van-field readonly v-model="deviceDetal.equimentType" :label="`${$t('device.machineType')}`" placeholder="" />
         <!-- mg280才有到期时间 -->
         <template v-if="deviceDetal?.equimentType?.indexOf('mg280') !== -1">
           <van-field readonly v-model="deviceDetal.lastUseDate" :label="`${$t('device.expirationTime')}`"
@@ -143,14 +141,11 @@
         <div class="custom-line"></div>
         <div class="cust_vantBorder">
           <van-field clearable label-width="32%" v-model="deviceDetal.messageReceiver1"
-            :label="`${$t('device.messageReceiver1')}`"
-            :placeholder="$t('device.equipmentmessageReceiverPlaceholder')" />
+            :label="`${$t('device.messageReceiver1')}`" :placeholder="$t('device.equipmentmessageReceiverPlaceholder')" />
           <van-field clearable label-width="32%" v-model="deviceDetal.messageReceiver2"
-            :label="`${$t('device.messageReceiver2')}`"
-            :placeholder="$t('device.equipmentmessageReceiverPlaceholder')" />
+            :label="`${$t('device.messageReceiver2')}`" :placeholder="$t('device.equipmentmessageReceiverPlaceholder')" />
           <van-field clearable label-width="32%" v-model="deviceDetal.messageReceiver3"
-            :label="`${$t('device.messageReceiver3')}`"
-            :placeholder="$t('device.equipmentmessageReceiverPlaceholder')" />
+            :label="`${$t('device.messageReceiver3')}`" :placeholder="$t('device.equipmentmessageReceiverPlaceholder')" />
         </div>
         <div class="custom-line"></div>
         <!-- <div class="cust_vantBorder">
@@ -257,7 +252,7 @@ import { Api_getGetEquipmentToLabel } from "@/service/labelMan";
 import kCascader from "@/components/commom/kCascader/index.vue";
 import { computed, onMounted, reactive, ref } from "vue";
 import sHeader from "@/components/SimpleHeader";
-import { useRoute, useRouter } from "vue-router";
+import { useRoute, useRouter, onBeforeRouteLeave } from "vue-router";
 import {
   getDeviceDetal,
   updateDevice,
@@ -295,6 +290,7 @@ export default {
     const { t } = useI18n();
     const route = useRoute();
     const router = useRouter();
+    const isUpdate = ref(false);
     const deviceDetal = ref({
       name: "",
       selfName: "",
@@ -311,6 +307,13 @@ export default {
     let tagsList = reactive({
       arr: [],
     });
+    onBeforeRouteLeave((to, from, next) => {
+      if(isUpdate.value) {
+        console.log("to.meta.keepAlive", to.meta.keepAlive);
+        to.meta.keepAlive = false;
+      }
+      next();
+    });
     // 过滤时间
     const filterDate = (date) => {
       if (date) {
@@ -426,6 +429,7 @@ export default {
       console.log(params);
       const { data } = await updateDevice(params);
       if (data.code === "00000") {
+        isUpdate.value = true;
         Toast.success(t("device.modificationSucceeded"));
         router.push({ path: "/device" });
       } else {

+ 256 - 0
src/views/device/diyFlower/index.vue

@@ -0,0 +1,256 @@
+<template>
+  <div class="showGoodsIdx">
+    <s-header :name="$t('device.diyFlower')" :noback="false"></s-header>
+    <div class="headerCon kBordBott o-plr-10 o-ptb-16 l-flex-RC">
+      <div class="line o-mr-6"></div>
+      <div>
+        <span class="c-color c-text-14">{{ $t('device.showGoodsPage.equipmentName') }}:</span>
+        <span class="c-text-color c-text-14">{{ equipmentName }}</span>
+      </div>
+    </div>
+  </div>
+  <van-cell center :title="checked ? $t('DIYFlower.openStatus') : $t('DIYFlower.closeStatus')" size="large"
+    title-style="color: #404d74;">
+    <template #right-icon>
+      <van-switch :model-value="checked" active-color="#2c87c8" @update:model-value="updateStatus" size="24" />
+    </template>
+  </van-cell>
+  <van-collapse v-if="checked" v-model="activeNames">
+    <van-collapse-item :title="$t('DIYFlower.shape')" name="1" size="large" title-style="color: #404d74;">
+      <van-row class="goods">
+        <van-col v-for="(item, index) in shapeData" :key="index" class="goodsCon o-mlr-5 o-mb-20" span="11">
+          <div class="l-flex-RC">
+            <van-image width="50" height="50" fit="contain" :src="showSugerPhoto(item)" />
+            <span class="o-ml-10" style="color: #000;word-wrap: break-word; width: 50px;">{{ item.name }}</span>
+            <van-checkbox class="o-ml-10" checked-color="#2c87c8" shape="square" v-model="shapeStates[index]" @change="shapeChange(index)" />
+          </div>
+        </van-col>
+      </van-row>
+    </van-collapse-item>
+    <van-collapse-item :title="$t('DIYFlower.sugar')" name="2" size="large" title-style="color: #404d74;">
+      <van-row class="goods">
+        <van-col v-for="(item, index) in sugarData" :key="index" class="goodsCon o-mlr-5 o-mb-20" span="11">
+          <div class="l-flex-RC">
+            <van-image width="50" height="50" fit="contain" :src="showSugerPhoto(item)" />
+            <span class="o-ml-10" style="color: #000;word-wrap: break-word; width: 50px;">{{ item.name }}</span>
+            <van-checkbox class="o-ml-10" checked-color="#2c87c8" shape="square" v-model="sugarStates[index]" @change="sugarChange(index)" />
+          </div>
+        </van-col>
+      </van-row>
+    </van-collapse-item>
+  </van-collapse>
+  <div class="l-flex-center" v-if="checked" style="margin: 16px">
+    <van-button round block class="Btn" type="primary" native-type="submit" @click="updateShowGoods()">
+      {{ $t('device.submitAndPushDeviceUpdates') }}
+    </van-button>
+  </div>
+</template>
+
+<script>
+// 导入接口
+import { selectDIYFlowers, updateDIYFlowerStatus, updateDIYProductShow } from '@/service/device/index';
+import sHeader from "@/components/SimpleHeader";
+import { ref, reactive } from "@vue/reactivity";
+import { onMounted } from '@vue/runtime-core';
+import { useRoute, useRouter } from 'vue-router';
+import { Dialog, Toast } from 'vant';
+import { useI18n } from "vue-i18n";
+import { styleUrl } from '../../../common/js/utils';
+export default {
+  components: {
+    sHeader
+  },
+  setup() {
+    // 引入语言
+    const { t } = useI18n();
+    // 路由
+    const route = useRoute();
+    const router = useRouter();
+    // 商品数据
+    const shapeData = ref([]);
+    const sugarData = ref([]);
+
+    const switchStates = ref([]);
+    const shapeStates = ref([]);
+    const sugarStates = ref([]);
+
+    // 设备名称
+    const equipmentName = ref('');
+    const checked = ref(false);
+    // 刚进页面
+    onMounted(() => {
+      // 加载样式
+      styleUrl('showGoods');
+      const id = route.query.deviceId || "";
+      const name = route.query.name || "";
+      const diyFlowerStatus = route.query.diyFlowerStatus || "";
+
+      if (diyFlowerStatus == "1") {
+        checked.value = true;
+        cofficentForm.equipmentId = id;
+        getList();
+      }
+      if (id) {
+        equipmentName.value = name;
+      }
+
+    });
+    const showSugerPhoto = (row) => {
+      let imgId = row.no;
+      if (imgId) {
+        return require(`../../../assets/device/diyFlowers/${imgId}.png`);
+      }
+      return imgId;
+    };
+    // 获取商品列表
+    const getList = () => {
+      const flower = route.query.flower || "";
+      selectDIYFlowers({
+        equipmentId: cofficentForm.equipmentId
+      }).then(res => {
+        console.log('res', res)
+        const {
+          data
+        } = res.data;
+        if (data) {
+          if (data.length > 0) {
+            // 是否修改状态
+            data.forEach(item => {
+              flowerNumber(item, flower);
+              if (item.no.includes('T')) {
+                sugarData.value.push(item);
+                if (item.showType == null || item.showType == '0') {
+                  sugarStates.value.push(false);
+                } else {
+                  sugarStates.value.push(true);
+                }
+              }
+            })
+          }
+        }
+      })
+    }
+    // 修改的价格
+    const cofficentForm = reactive({
+      equipmentId: '',
+    });
+
+    // 判断花型数目
+    const flowerNumber = (item, number) => {
+      var shape = null;
+      if (number == '18') {
+        shape = ['S01', 'S02', 'S03'];
+      } else if (number == '22') {
+        shape = ['S01', 'S02', 'S03', 'S04'];
+      } else if (number == '26') {
+        shape = ['S01', 'S02', 'S03', 'S04', 'S05'];
+      } else if (number == '30') {
+        shape = ['S01', 'S02', 'S03', 'S04', 'S05', 'S06'];
+      } else {
+        shape = ['S01', 'S02', 'S03', 'S04', 'S05', 'S06', 'S07', 'S08', 'S09'];
+      }
+      if (shape.includes(item.no)) {
+        shapeData.value.push(item);
+        if (item.showType == null || item.showType == '0') {
+          shapeStates.value.push(false);
+        } else {
+          shapeStates.value.push(true);
+        }
+      }
+    }
+
+    // 更改状态
+    const shapeChange = (index) => {
+      if (shapeStates.value[index]) {
+        shapeData.value[index].showType = 1;
+      } else {
+        shapeData.value[index].showType = 0;
+      }
+      console.log("形状", shapeData.value[index]);
+    };
+    const sugarChange = (index) => {
+      if (sugarStates.value[index]) {
+        sugarData.value[index].showType = 1;
+      } else {
+        sugarData.value[index].showType = 0;
+      }
+      console.log("糖", sugarData.value[index]);
+    };
+
+    const updateStatus = (newValue) => {
+      const params = {
+        equipmentId: cofficentForm.equipmentId,
+        DIYFlowerStatus: newValue ? '1' : '0',
+      };
+      Dialog.confirm({
+        title: t('DIYFlower.tips'),
+        message: t('DIYFlower.content'),
+      }).then(async () => {
+        const { data } = await updateDIYFlowerStatus(params);
+        if (data.code) {
+          // checked.value = newValue;
+          Toast(t('DIYFlower.successfully'));
+          setTimeout(() => {
+            router.go(-1);
+          }, 1500);
+        } else {
+          Toast.fail(data.message);
+        }
+      }).catch((error) => {
+        console.log(error);
+        Toast.fail(t('device.unknownError'));
+      });
+    }
+
+    // 点击提交
+    const updateShowGoods = () => {
+      Dialog.confirm({
+        title: t('device.openRemind'),
+        message: t('device.editCheck'),
+      }).then(() => {
+        var products = shapeData.value.concat(sugarData.value);
+        var list = JSON.stringify(products);
+        console.log(list);
+
+        updateDIYProductShow({
+          productList: list
+        }).then((res) => {
+          console.log(res.data.message);
+          Dialog.alert({
+            message: t('DIYFlower.successfully'),
+          }).then(() => {
+            //返回上一页
+            router.go(-1);
+          });
+          // setTimeout(() => {
+          //   getList();
+          // }, 1000);
+        }).catch((error) => {
+          console.log(error);
+          Toast.fail(t('device.unknownError'));
+        });
+      });
+    };
+    const activeNames = ref(['1', '2']);
+
+    return {
+      cofficentForm,
+      shapeData,
+      sugarData,
+      equipmentName,
+      updateShowGoods,
+      switchStates,
+      shapeStates,
+      sugarStates,
+      shapeChange,
+      sugarChange,
+      checked,
+      showSugerPhoto,
+      activeNames,
+      updateStatus
+    };
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 43 - 7
src/views/device/index.vue

@@ -4,7 +4,7 @@
     <s-header :name="sys ? sys.title : $t('device.managementCenter')" :noback="true"></s-header>
     <div class="listBox">
       <van-list v-model:loading="loading" v-model:error="error" :error-text="$t('public.requestFailed')"
-        :finished="finished" :finished-text="$t('public.noMore')" offset="300" :immediate-check="false" @load="onLoad">
+        :finished="finished" :finished-text="$t('public.noMore')" :offset="300" :immediate-check="false" @load="onLoad">
         <div class="deviceBox1 flex-col">
           <div class="searchRow flex-row justify-between">
             <div class="flex-col">
@@ -197,8 +197,10 @@
                       </van-col>
                     </van-row>
                     <span class="txt5 o-ptb-7 kBordBott l-flex-RC"><span>{{ $t("device.oneKeyFeed") }}:</span>
-                      <van-button @click="replenishmentClk(item)" type="primary">{{ $t("device.replenishment") }}
-                      </van-button>
+                      <!-- <van-button @click="replenishmentClk(item)" type="primary">{{ $t("device.replenishment") }}
+                      </van-button> -->
+                      <a class="replenishment o-ptb-7" @click="replenishmentClk(item)">{{ $t("device.replenishment")
+                      }}</a>
                     </span>
                   </template>
                   <span class="info1 o-ptb-7 kBordBott">{{ $t("device.lastRefreshTime") }}:{{
@@ -256,11 +258,11 @@
 import {
   Api_postMachineNum,
 } from "../../service/home";
-import { onMounted, reactive, toRefs, ref } from "vue";
+import { onMounted, reactive, toRefs, ref, onActivated } from "vue";
 import { Toast, Dialog } from "vant";
 import navBar from "../../components/NavBar";
 import sHeader from "../../components/SimpleHeader";
-import { getLoginUser, Format_calcuDecial, styleUrl } from "../../common/js/utils";
+import { getLoginUser, Format_calcuDecial } from "../../common/js/utils";
 import {
   getDeviceList,
   eliminate,
@@ -269,9 +271,10 @@ import {
 } from "../../service/device/index";
 import deviceSearch from "./deviceSearch";
 import deviceOper from "./deviceOper";
-import { useRouter } from "vue-router";
+import { onBeforeRouteLeave, useRouter } from "vue-router";
 import dateUtil from "../../utils/dateUtil";
 import { useI18n } from "vue-i18n";
+import { onBeforeUnmount } from "vue";
 
 export default {
   name: "device",
@@ -287,6 +290,38 @@ export default {
     const router = useRouter();
     const sys = ref(null);
     const user = getLoginUser();
+    const verticalScrollPosition = ref(0);
+
+    onActivated(() => {
+      // 当组件被激活时,可能是从 keep-alive 缓存中激活的
+      // 这时重新添加滚动事件监听器
+      document.documentElement.scrollTop = verticalScrollPosition.value;
+      document.body.scrollTop = verticalScrollPosition.value;
+      window.scrollY = verticalScrollPosition.value;
+      // window.addEventListener('scroll', handleScroll);
+    });
+
+
+    onBeforeRouteLeave(() => {
+      verticalScrollPosition.value = document.documentElement.scrollTop || document.body.scrollTop || window.scrollY;
+    })
+
+    // 在组件卸载前清除定时器
+    onBeforeUnmount(() => {
+      clearInterval(updateDataInterval);
+    });
+
+
+    const updateDataInterval = () => {
+      // 每隔5分钟更新数据
+      setInterval(() => {
+        init();
+        if (oprRef.value) {
+          oprRef.value.closeOper();
+        }
+        verticalScrollPosition.value = 0;
+      }, 5 * 60 * 1000); // 3分钟的毫秒数
+    };
     //控制睡眠描述的显示隐藏
     const sleepDescBoxShow = ref(true);
     // 页面列表查询参数
@@ -301,7 +336,8 @@ export default {
     onMounted(() => {
       init();
       //加载样式
-      styleUrl('device');
+      updateDataInterval(); 
+      // styleUrl('device');
     });
     // 初始化
     const init = () => {

+ 5 - 5
src/views/device/paramsSet/paramsSetInfo.vue

@@ -131,20 +131,20 @@ export default {
         Toast.fail(data.message);
       }
     }
-    const onUpdateValue = async (item, key) => {
+    const onUpdateValue = (item, key) => {
       console.log(item);
       const params = {
         id: deviceId,
         name: item.name,
-        val: item.val === '0' ? '1' : '0',
+        val: item.val == '0' ? '1' : '0',
       };
       Dialog.confirm({
         title: '提醒',
         message: '是否切换开关?',
-      }).then(() => {
-        checked.value[key] = !checked.value[key];
-        const { data } = updateParameters(params);
+      }).then(async () => {
+        const { data } = await updateParameters(params);
         if (data.code) {
+          checked.value[key] = !checked.value[key];
           Toast.success(t('device.modificationSucceeded'));
         } else {
           Toast.fail(data.message);

+ 17 - 1
src/views/login.vue

@@ -130,6 +130,13 @@ export default {
       if (route.query.relation_admin_id) {
         getSysFun();
       }
+      const savedCredentials = localStorage.getItem('savedCredentials');
+      if (savedCredentials) {
+        checked.value = true;
+        const { savedUsername, savedPassword } = JSON.parse(savedCredentials);
+        userName.value = savedUsername;
+        userPwd.value = savedPassword;
+      }
     });
     const getSysFun = async () => {
       const {data} = await getSys({
@@ -150,7 +157,16 @@ export default {
       });
       if (data.code === "00000") {
         setLocal("loginUser", JSON.stringify(data.data));
-        console.log('loginUser JSON:', JSON.stringify(data.data));
+        if (checked.value) {
+          const savedCredentials = JSON.stringify({ savedUsername: values.userName, savedPassword: values.userPwd });
+          localStorage.setItem('savedCredentials', savedCredentials);
+        } else {
+          const savedCredentials = localStorage.getItem('savedCredentials');
+          if (savedCredentials) {
+            localStorage.removeItem('savedCredentials', savedCredentials);
+          }
+        }
+        // console.log('loginUser JSON:', JSON.stringify(data.data));
         Toast.success(t('login.loginSucess'));
         // 需要刷新页面,否则 axios.js 文件里的 token 不会被重置
         // window.location.href = '/';

+ 8 - 3
src/views/merchantManage/index.vue

@@ -43,7 +43,8 @@
                 <span class="txt3" v-html="`${$t('merchantManage.creationTime')}:` + Format_time(item.createDate)"></span>
               </div>
               <div class="button-container">
-                <van-button v-if="user.type < 2" class="btn1" round type="success" @click="autoLogin(item.id)">切换登陆</van-button>
+                <van-button v-if="user.type < 2" class="btn1" round type="success"
+                  @click="autoLogin(item.id)">切换登陆</van-button>
                 <van-button class="btn1" round type="primary" @click="merchantSet(item)">详细信息</van-button>
               </div>
             </div>
@@ -121,18 +122,22 @@ export default {
         title: t('merchantManage.tips'),
         message: t('merchantManage.autoLogin'),
       }).then(() => {
-        autoLoginMerchant({ id }).then(res =>{
+        autoLoginMerchant({ id }).then(res => {
           if (res.data.code === "00000") {
             // 获取缓存的语言
             const curLang = localStorage.getItem("curLang");
+            const savedCredentials = localStorage.getItem('savedCredentials');
             // 清空缓存
             localStorage.clear();
             localStorage.setItem("curLang", curLang);
+            if (savedCredentials) {
+              localStorage.setItem('savedCredentials', savedCredentials);
+            }
             setLocal("loginUser", JSON.stringify(res.data.data));
             // console.log('loginUser JSON:', JSON.stringify(data.data));
             Toast.success(t('login.loginSucess'));
             // 需要刷新页面,否则 axios.js 文件里的 token 不会被重置
-            window.location.href = '/sc/';
+            window.location.href = '/shenze/';
             setTimeout(() => {
               router.push("/home");
             }, 200);

+ 27 - 16
src/views/register.vue

@@ -52,7 +52,8 @@
             :rules="[{ required: true, message: $t('register.codeRequired') }]">
             <template #button v-if="ifForeign === '0' && logonMode === '10'">
               <van-button size="small" type="primary" @click="seedVerCode()"
-                :disabled="time !== 0 || phone.length === 0">{{
+                :disabled="time !== 0 || phone.length === 0"
+                :loading=reqApi :loading-text="$t('register.sending')">{{
                   time === 0 ?
                   $t('register.seedVerCode') : time + $t('register.replaysInSeconds')
                 }}
@@ -73,7 +74,8 @@
             :rules="[{ required: true, message: $t('register.emailCodeRequired') }]">
             <template #button v-if="ifForeign === '0' && logonMode === '11'">
               <van-button size="small" type="primary" @click="seedVerCode()"
-                :disabled="time !== 0 || email.length === 0">{{
+                :disabled="time !== 0 || email.length === 0"
+                :loading=reqApi :loading-text="$t('register.sending')">{{
                   time === 0 ?
                   $t('register.seedVerCode') : time + $t('register.replaysInSeconds')
                 }}
@@ -93,8 +95,8 @@
             :placeholder="$t('register.emailCodePlaceholder')"
             :rules="[{ required: true, message: $t('register.emailCodeRequired') }]">
             <template #button v-if="ifForeign === '1'">
-              <van-button size="small" type="primary" @click="seedVerCode()"
-                :disabled="time !== 0 || email.length === 0">{{
+              <van-button size="small" type="primary" @click="seedVerCode()" :disabled="time !== 0 || email.length === 0"
+                :loading=reqApi :loading-text="$t('register.sending')">{{
                   time === 0 ?
                   $t('register.seedVerCode') : time + $t('register.replaysInSeconds')
                 }}
@@ -145,6 +147,7 @@ export default {
     let phoneOrEmailStr = ref('');
 
     const router = useRouter();
+    const reqApi = ref(false);
 
     // 注册点击
     const registerSubmit = async () => {
@@ -174,6 +177,7 @@ export default {
 
     // 发送验证码
     const seedVerCode = async () => {
+      reqApi.value = true;
       if (ifForeign.value === '1') {
         phoneOrEmailStr = email.value;
       } else if (ifForeign.value === '0' && logonMode.value === '10') {
@@ -181,18 +185,24 @@ export default {
       } else {
         phoneOrEmailStr = email.value;
       }
-      const { data } = await sentRegisterCode({
-        ifForeign: ifForeign.value,
-        phoneOrEmail: phoneOrEmailStr
-      });
-      console.log('seedVerCodeSuccess', data);
-      if (data.code === '00000') {
-        Toast(data.data);
-        console.log('seedVerCodeSuccess');
-        verCodeTime.time = 1 * 60;
-        verCodeTimeInterval();
-      } else {
-        Toast.fail(data.message);
+
+      try {
+        const { data } = await sentRegisterCode({
+          ifForeign: ifForeign.value,
+          phoneOrEmail: phoneOrEmailStr,
+          hostName: 'SevenCloud',
+        });
+        if (data.code === '00000') {
+          reqApi.value = false;
+          Toast(data.data);
+          verCodeTime.time = 1 * 60; // 1分钟定时器,60s后可以更换验证方式
+          verCodeTimeInterval();
+        } else {
+          reqApi.value = false;
+          Toast.fail(data.message);
+        }
+      } catch (error) {
+        reqApi.value = false;
       }
     }
     // 验证码发送成功开始1分钟倒计时
@@ -262,6 +272,7 @@ export default {
       signinModel: 'aaabb',
       active,
       logonMode,
+      reqApi,
     }
   },
   components: { sHeader }

+ 4 - 4
src/views/robotRanking.vue

@@ -578,19 +578,19 @@ export default {
         switch (chartType) {
           case "day":
             totalObj.dayData = data.data;
-            console.log("日返回值", data);
+            // console.log("日返回值", data);
             break;
           case "week":
             totalObj.weekData = data.data;
-            console.log("周返回值", data);
+            // console.log("周返回值", data);
             break;
           case "month":
             totalObj.monthData = data.data;
-            console.log("月返回值", data);
+            // console.log("月返回值", data);
             break;
           case "year":
             totalObj.yearData = data.data;
-            console.log("年返回值", data);
+            // console.log("年返回值", data);
             break;
         }
         // 有数据返回则处理

+ 1 - 1
src/views/role/add.vue

@@ -174,7 +174,7 @@ export default {
       if (data.code === "00000") {
         Toast.success(t("role.roleAddedSuccessfully"));
         // router.push("/role");
-        router.replace("/role");
+        router.go(-1);
       } else {
         Toast.fail(`${t("role.failedToAddRole")} ${data.message}`);
       }

+ 2 - 2
src/views/taskMessage/index.vue

@@ -15,12 +15,12 @@
           <div class="taskTitle">{{ $t('taskMessage.distributionApplicationApproval') }}</div>
         </div>
       </div>
-      <div class="taskListRow flex-col" @click="pushPageList('/taskJoinPayMchCheck')">
+      <!-- <div class="taskListRow flex-col" @click="pushPageList('/taskJoinPayMchCheck')">
         <div class="taskIcon withIcon"></div>
         <div class="taskRight">
           <div class="taskTitle">{{ $t('taskMessage.withdrawalAccountApproval') }}</div>
         </div>
-      </div>
+      </div> -->
     </div>
   </div>
 </template>

+ 12 - 8
src/views/user.vue

@@ -479,10 +479,14 @@ export default {
     // 点击右侧按钮
     const confirmClk = () => {
       // 获取缓存的语言
+      const savedCredentials = localStorage.getItem('savedCredentials');
       const curLang = localStorage.getItem("curLang");
       // 清空缓存
       localStorage.clear();
       localStorage.setItem("curLang", curLang);
+      if (savedCredentials) {
+        localStorage.setItem('savedCredentials', savedCredentials);
+      }
       if (sys.value) {
         setTimeout(() => {
           router.push({
@@ -564,14 +568,14 @@ export default {
         chaScPayShow.value = true;
         getSunzeeDetail();
         getSevenCloudDetail();
-      } else if (user.id == 2738) {
-        chaSzPayShow.value = true;
-        getSunzeeDetail();
-      } else if (user.id == 2739) {
-        chaScPayShow.value = true;
-        getSevenCloudDetail();
-      }
-
+      } 
+      // else if (user.id == 2738) {
+      //   chaSzPayShow.value = true;
+      //   getSunzeeDetail();
+      // } else if (user.id == 2739) {
+      //   chaScPayShow.value = true;
+      //   getSevenCloudDetail();
+      // }
     });
     const gettAdminGetRelation = async () => {
       const { data } = await tAdminGetRelation({