From 1cdf81eb8a5d3d933ba4db2f5c97e20115a12bcb Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Fri, 3 Jul 2020 10:25:07 +0800
Subject: [PATCH] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E8=AF=A6=E6=83=85-=E9=A1=B9?=
=?UTF-8?q?=E7=9B=AE=E7=B1=BB=E5=9E=8B=E6=98=BE=E7=A4=BA?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/forge/Main/Detail.js | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/src/forge/Main/Detail.js b/src/forge/Main/Detail.js
index 32b50161..623aafc7 100644
--- a/src/forge/Main/Detail.js
+++ b/src/forge/Main/Detail.js
@@ -161,8 +161,6 @@ class Detail extends Component {
}
getProject = (num) => {
- const name = window.location.hostname === "localhost" ? "testforgeplus.trustie.net":window.location.hostname;
- console.log(`wss:${name}/cable`);
const { projectsId } = this.props.match.params;
const url = `/projects/${projectsId}/simple.json`;
axios.get(url).then((result) => {
@@ -197,9 +195,8 @@ class Detail extends Component {
}
canvasChannel = () => {
const name = window.location.hostname === "localhost" ? "http://testforgeplus.trustie.net":window.location.hostname;
- console.log(`wss:${name}/cable`);
const actioncable = require("actioncable")
- var project = this.state.project
+ var project = this.state.project;
var cable = actioncable.createConsumer(`wss:${name}/cable`);
this.canvasChannel1 = cable.subscriptions.create({
channel: `MirrorProjectChannel`,
@@ -381,10 +378,14 @@ class Detail extends Component {
: ""
}
{
- projectDetail && checkLogin && projectDetail.type && projectDetail.type === 2 ?
-
-
- : ""
+ projectDetail && checkLogin && projectDetail.type && projectDetail.type !== 0 ?
+ projectDetail.type === 2 ?
+
+
+ :
+
+
+ :""
}