ソースを参照

fix禅道很多bug

aamin 1 年間 前
コミット
f1e7e020d7

+ 3 - 3
houtai/src/pages/A5Exchange/index.tsx

@@ -99,13 +99,13 @@ function A5Exchange() {
       {
         title: "称呼",
         render: (item: ExchangeTableType) => (
-          <div>{item.prizeName === "公益合伙人证书" || item.name === "" ? "(空)" : item.name}</div>
+          <div>{item.prizeName === "公益合伙人证书" || item.name === "" ? "-" : item.name}</div>
         ),
       },
       {
         title: "联系方式",
         render: (item: ExchangeTableType) => (
-          <div>{item.prizeName === "公益合伙人证书" || item.phone === "" ? "(空)" : item.phone}</div>
+          <div>{item.prizeName === "公益合伙人证书" || item.phone === "" ? "-" : item.phone}</div>
         ),
       },
       {
@@ -113,7 +113,7 @@ function A5Exchange() {
         render: (item: ExchangeTableType) => (
           <div>
             {item.prizeName === "公益合伙人证书" || item.description === ""
-              ? "(空)"
+              ? "-"
               : item.description}
           </div>
         ),

+ 15 - 14
houtai/src/pages/A6IDUser/index.tsx

@@ -42,17 +42,18 @@ function A6IDUser() {
   };
 
   const [inputKey, setInputKey] = useState(1);
+
   // // 重置
-  // const resetFu = () => {
-  //   setInputKey(Date.now());
-  //   setTableSelect({
-  //     searchKey: "",
-  //     pageSize: 10,
-  //     pageNum: 1,
-  //     startTime: "",
-  //     endTime: "",
-  //   });
-  // };
+  const resetFu = () => {
+    setInputKey(Date.now());
+    setSelectKey(null)
+    setTableSelect({
+      searchKey: "",
+      pageSize: 10,
+      pageNum: 1,
+      isEnabled: "",
+    });
+  };
 
   // // 点击跳转
   // const pathCutFu = useCallback((path: string) => {
@@ -96,7 +97,8 @@ function A6IDUser() {
   // 点击重置密码
   const resetPassFu = useCallback(async (id: number) => {
     const res: any = await IDUserPassResetAPI(id);
-    if (res.code === 0) MessageFu.success("用户密码已重置并以邮件形式发送至用户邮箱!");
+    if (res.code === 0)
+      MessageFu.success("用户密码已重置并以邮件形式发送至用户邮箱!");
   }, []);
 
   // 切换表格中的启用停用状态
@@ -240,11 +242,10 @@ function A6IDUser() {
               options={[
                 { value: 0, label: "禁用" },
                 { value: 1, label: "启用" },
-
               ]}
             />
           </div>
-          {/* <Button
+          <Button
             className="reSetBtn"
             size="small"
             type="primary"
@@ -253,7 +254,7 @@ function A6IDUser() {
             }}
           >
             重置
-          </Button> */}
+          </Button>
         </div>
       </div>
 

+ 5 - 5
scene/src/components/info/index.vue

@@ -37,10 +37,10 @@ export default {
     timeA = window.setInterval(() => {
       if (window.DATA) {
         clearInterval(timeA);
+        this.title = window.DATA.name;
+        this.disc = window.DATA.summary;
+        document.title = window.DATA.name;
       }
-      this.title = window.DATA.name;
-      this.disc = window.DATA.summary;
-      document.title = window.DATA.name;
     }, 100);
   },
   beforeCreate() { }, //生命周期 - 创建之前
@@ -54,7 +54,7 @@ export default {
 </script>
 <style lang="less" scoped>
 ::-webkit-scrollbar {
-    display: none
+  display: none
 }
 
 .info-box {
@@ -82,7 +82,7 @@ export default {
     cursor: pointer;
     border-radius: 15px 15px;
     padding: 10px;
-    
+
 
     img {
       width: 20px;

+ 24 - 21
scene/src/views/gui/menu.vue

@@ -214,7 +214,8 @@ export default {
     let timeA = -1;
 
     timeA = window.setInterval(() => {
-      if (window.hotData) {
+      if (window.myHotList.length > 0) {
+        console.log('热点数据准备完毕')
         clearInterval(timeA);
         if (window.parent && window.parent.window.handleRobot) {
           window.parent.window.handleRobot('greeting')
@@ -257,28 +258,30 @@ export default {
     },
     // 跳转到制定热点
     initCamera(locId) {
-      const current = window.myHotList.find((item) => {
-        return item.info.sid == locId;
-      });
-      const c =
-        current.closestPanoTowardTag(
-          window.player.mode,
-          window.player.currentPano
-        ) || window.player.currentPano;
-
       setTimeout(() => {
-        window.player.flyToPano({
-          // 移动到点位
-          pano: c,
-          // 移动视角
-          quaternion: new window.THREE.Quaternion(
-            current.quaternion.x,
-            current.quaternion.y,
-            current.quaternion.z,
-            current.quaternion.w
-          ),
+        const current = window.myHotList.find((item) => {
+          return item.info.sid == locId;
         });
-      });
+        const c =
+          current.closestPanoTowardTag(
+            window.player.mode,
+            window.player.currentPano
+          ) || window.player.currentPano;
+
+        setTimeout(() => {
+          window.player.flyToPano({
+            // 移动到点位
+            pano: c,
+            // 移动视角
+            quaternion: new window.THREE.Quaternion(
+              current.quaternion.x,
+              current.quaternion.y,
+              current.quaternion.z,
+              current.quaternion.w
+            ),
+          });
+        },100);
+      },500)
     },
     hotListChange() {
       if (window.parent.window.hotListShowChangeFu) {

ファイルの差分が大きいため隠しています
+ 1 - 1
zhengquan/public/scene/css/app.8426032f.css


ファイルの差分が大きいため隠しています
+ 1 - 1
zhengquan/public/scene/index.html


ファイルの差分が大きいため隠しています
+ 0 - 1
zhengquan/public/scene/js/app.1f7d0deb.js


ファイルの差分が大きいため隠しています
+ 1 - 0
zhengquan/public/scene/js/app.d52a9c4e.js


+ 10 - 0
zhengquan/src/App.vue

@@ -9,6 +9,16 @@ onMounted(() => {
   // @ts-ignore
   store.dataAll = dataAll;
 
+  // 重置alert标题
+  window.alert = function(name){
+    const iframe = document.createElement("IFRAME");
+    iframe.style.display="none";
+    iframe.setAttribute("src", 'data:text/plain,');
+    document.documentElement.appendChild(iframe);
+    window.frames[0].window.alert(name);
+    iframe.parentNode?.removeChild(iframe);
+  };
+
   const dom: HTMLDivElement | null = document.querySelector("#app");
   if (dom && document.documentElement.clientWidth < 480) {
     dom.style.height = document.documentElement.clientHeight + "px";

+ 2 - 0
zhengquan/src/main.ts

@@ -5,10 +5,12 @@ import { createPinia } from 'pinia'
 
 import App from './App.vue'
 import router from './router'
+import { Toast } from 'vant';
 
 const app = createApp(App)
 
 app.use(createPinia())
 app.use(router)
+app.use(Toast)
 
 app.mount('#app')

+ 1 - 0
zhengquan/src/stores/index.ts

@@ -9,6 +9,7 @@ export const useStore = defineStore('home', {
       // 所有热点列表
       hotspots: [] as any,
       token: '',
+      isFirstTimeGoScene: true,
       userInfo: {} as any,
       currentUnit: {} as any,
       isShowGameThumb: true,

+ 48 - 7
zhengquan/src/views/Scene/ScenePage.vue

@@ -5,6 +5,8 @@ import baseResourceUrl from "@/utils/https";
 import axios from 'axios'
 import { Base64 } from "js-base64"
 import encodeStr from "@/utils/pass"
+// import { Toast } from 'vant';
+
 
 // 为 window 添加属性ts类型
 // gei window 增加函数,让子页面去触发
@@ -154,17 +156,17 @@ const goHotCamarer = (hot: any) => {
   localStorage.setItem('currentUnit', JSON.stringify(currentHotsUnit.value))
   pointInfo.value = ''
   // isShowExperienceGame.value = true
+  isShowHosList.value = false
   setTimeout(() => {
     const iframe = document.getElementById('sceneiframe') as HTMLIFrameElement
     //@ts-ignore
     iframe.contentWindow.initCamera(hot.sid)
-
     currentHot.value = hot
     console.log(currentHot.value)
-
-    clostHotListFu()
+    //@ts-ignore
+    iframe.contentWindow.closeHotListIcon()
     isShowFigure.value = true
-  }, 1500)
+  }, 1000)
 }
 
 const clostHotListFu = () => {
@@ -233,6 +235,29 @@ const checkLoginStatus = async () => {
   }
 }
 
+const Toast = (text: string) => {
+  let toastDom:HTMLElement = document.createElement('div')
+  toastDom.innerText = text
+  toastDom.style.padding = '5px 15px'
+  toastDom.style.display = 'flex'
+  toastDom.style.justifyItems = 'center'
+  toastDom.style.alignItems = 'center'
+  toastDom.style.position = 'fixed'
+  toastDom.style.left = '50%'
+  toastDom.style.top = '5%'
+  toastDom.style.transform = 'translateX(-50%)'
+  toastDom.style.background = '#fff'
+  toastDom.style.zIndex = '99'
+  toastDom.style.borderRadius = '50px'
+  toastDom.style.boxShadow='0px 4px 16px 0px rgba(0, 0, 0, 0.5)'
+  toastDom.style.fontSize = '15px'
+  document.body.appendChild(toastDom);
+  
+  setTimeout(() => {
+    document.body.removeChild(toastDom);
+  }, 2000)
+}
+
 // 内嵌小游戏界面打开
 const openGame = (index: any) => {
   router.push({
@@ -285,9 +310,11 @@ const isPassChange = ref(false)
 
 const changePassword = () => {
   if (oldPass.value == '' || newPass.value == '' || affirmPass.value == '') {
-    alert('密码不能为空')
+    Toast('密码不能为空');
+    // alert('密码不能为空')
   } else if (newPass.value != affirmPass.value) {
-    alert('两次密码不一致')
+    // alert('两次密码不一致')
+    Toast('两次密码不一致')
   } else {
     console.log(oldPass.value, newPass.value, affirmPass.value)
     const pwdNewEncrypted = encodeStr(Base64.encode(newPass.value))
@@ -304,6 +331,7 @@ const changePassword = () => {
       }
     }).then(() => {
       alert('修改成功,请重新进行登录')
+      // Toast)
       logout()
       isLogin.value = false
       isPassChange.value = false
@@ -330,9 +358,13 @@ const changeThemeFu = () => {
   }
 }
 
+const changeXuLeiReady = ref(true)
+
 // 当自主变换主题时候,帧数也对应发生改变
 watch(() => store.customThemeId, () => {
   console.log('主题发生改变')
+  isReady.value = false
+  changeXuLeiReady.value = false
   const newTheme = store.dataAll.sceneList.find((item: any) => {
     return item.id == store.customThemeId
   })
@@ -340,6 +372,15 @@ watch(() => store.customThemeId, () => {
     animalZhenShuNumber.value = newTheme.xuliezhen[animalStat.value].zhenShu
     duration.value = newTheme.xuliezhen[animalStat.value].duration
   }
+  // alert(animalZhenShuNumber.value)
+  // alert(duration.value)
+
+  setTimeout(() => {
+    isReady.value = true
+    changeXuLeiReady.value = true
+  }, 200)
+
+
 })
 
 
@@ -604,7 +645,7 @@ const changePassFu = () => {
           </div>
         </div>
         <!-- 形象切换序列帧 -->
-        <div class="xuliezhen-greeting changing"
+        <div class="xuliezhen-greeting changing" v-show="changeXuLeiReady"
           :style="{ backgroundImage: `url(${baseResourceUrl}/animation/${store.customThemeId != null ? store.customThemeId : currentUnit.id}/greeting.png)`, backgroundSize: 'cover' }">
         </div>
         <div></div>