Commit cfe5dfc1 by FE

from param and mask click

parent 7c2550d1
...@@ -17,7 +17,7 @@ class PythonClass extends Component { ...@@ -17,7 +17,7 @@ class PythonClass extends Component {
isWechat: browser.isWeixin, isWechat: browser.isWeixin,
isShare: true, isShare: true,
type: '1', // 1:课后习题,2:课堂习题 type: '1', // 1:课后习题,2:课堂习题
entryMode: 1, // 0:扫码页,1:落地页,2:直接进入 entryMode: 0, // 0:扫码页,1:落地页,2:直接进入
isExecute: false, isExecute: false,
isCopy: false, isCopy: false,
command: '', command: '',
...@@ -103,6 +103,12 @@ class PythonClass extends Component { ...@@ -103,6 +103,12 @@ class PythonClass extends Component {
}); });
} }
handleToHide = () => {
this.setState({
entryMode: 2
});
}
render() { render() {
const { isWechat, isShare, isExecute, type, entryMode, command, isCopy, data } = this.state; const { isWechat, isShare, isExecute, type, entryMode, command, isCopy, data } = this.state;
return ( return (
...@@ -124,6 +130,7 @@ class PythonClass extends Component { ...@@ -124,6 +130,7 @@ class PythonClass extends Component {
handleToExecute={this.handleToExecute} handleToExecute={this.handleToExecute}
handleToSend={this.handleToSend} handleToSend={this.handleToSend}
copyToSuccess={this.copyToSuccess} copyToSuccess={this.copyToSuccess}
handleToHide={this.handleToHide}
/> />
</> </>
); );
...@@ -158,7 +165,8 @@ function PythonContent(props) { ...@@ -158,7 +165,8 @@ function PythonContent(props) {
data: { head_img, nickname, code_lines, code, result, ques_name, course_name, course_id, video_name }, data: { head_img, nickname, code_lines, code, result, ques_name, course_name, course_id, video_name },
handleToSend, handleToSend,
copyToSuccess, copyToSuccess,
handleToExecute handleToExecute,
handleToHide
} = props; } = props;
let labelName = ''; let labelName = '';
if(type === '1') { if(type === '1') {
...@@ -192,7 +200,7 @@ function PythonContent(props) { ...@@ -192,7 +200,7 @@ function PythonContent(props) {
{ {
(entryMode === 1 && isWechat) && (entryMode === 1 && isWechat) &&
<div className="python-popup"> <div className="python-popup" onClick={handleToHide}>
<div className="python-header"> <div className="python-header">
<p className="python-wechat__title">请点击右上角分享</p> <p className="python-wechat__title">请点击右上角分享</p>
<i className="iconfont iconyindao"></i> <i className="iconfont iconyindao"></i>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment