Merge branch 'dev_aliyun' into dev_tj

merge aliyun
dev_new_shixunsrepository
tangjiang 5 years ago
commit 983815b9e7

@ -46,7 +46,7 @@ class GotoQQgroup extends Component {
> >
<div className="educouddiv intermediatecenter verticallayout"> <div className="educouddiv intermediatecenter verticallayout">
<div className="tabeltext-alignleft mt10"><p>您可以在QQ服务群向管理员申请获得继续操作的权限</p></div> <div className="tabeltext-alignleft mt10"><p>您可以在QQ服务群向管理员申请获得继续操作的权限</p></div>
<img className="mt10" src={getImageUrl("images/educoder/qqqun20191230.png")}/> <img width={"200px"} className="mt10" src={getImageUrl("images/educoder/qqqun20191230.png")}/>
<div className="tabeltext-alignleft mt10"><p>群号612934990</p></div> <div className="tabeltext-alignleft mt10"><p>群号612934990</p></div>
<div className="clearfix mt30 edu-txt-center"> <div className="clearfix mt30 edu-txt-center">

@ -7,6 +7,8 @@ import Addshixuns from './Addshixuns';
import '../ShixunPaths.css'; import '../ShixunPaths.css';
import axios from 'axios'; import axios from 'axios';
import NewShixunModel from '../../courses/coursesPublic/NewShixunModel'; import NewShixunModel from '../../courses/coursesPublic/NewShixunModel';
import GotoQQgroup from "../../../modal/GotoQQgroup";
const $ = window.$; const $ = window.$;
const Search = Input.Search; const Search = Input.Search;
@ -54,8 +56,10 @@ class DetailCardsEditAndAdd extends Component{
ChooseShixunListshixun_list:undefined, ChooseShixunListshixun_list:undefined,
stage_nametype:false, stage_nametype:false,
descriptiontype:false, descriptiontype:false,
Addshixunstype:false Addshixunstype:false,
} goshowqqgtounp:false,
}
this.onDragEnd = this.onDragEnd.bind(this); this.onDragEnd = this.onDragEnd.bind(this);
} }
//选择实训弹框 //选择实训弹框
@ -315,6 +319,12 @@ class DetailCardsEditAndAdd extends Component{
} }
Addshixuns=()=>{ Addshixuns=()=>{
// debugger
// console.log("点击了新建实训Addshixuns");
if(this.props&&this.props.current_user&&this.props.current_user.is_shixun_marker===false){
this.setgoshowqqgtounp(true);
return;
}
this.setState({ this.setState({
Addshixunstype:true, Addshixunstype:true,
}) })
@ -349,7 +359,12 @@ class DetailCardsEditAndAdd extends Component{
console.log(error) console.log(error)
}); });
} }
// 处理弹框
setgoshowqqgtounp=(bool)=>{
this.setState({
goshowqqgtounp:bool
})
}
render(){ render(){
let {selectShixun, let {selectShixun,
@ -368,11 +383,19 @@ class DetailCardsEditAndAdd extends Component{
Modalsbottomval, Modalsbottomval,
ChooseShixunListshixun_list, ChooseShixunListshixun_list,
stage_nametype, stage_nametype,
descriptiontype} = this.state descriptiontype,
goshowqqgtounp
} = this.state
return( return(
<div> <div>
{
goshowqqgtounp===true?
<GotoQQgroup {...this.state} {...this.props} setgoshowqqgtounp={(bool)=>this.setgoshowqqgtounp(bool)}></GotoQQgroup>
:
""
}
<Modals <Modals
modalsType={Modalstype} modalsType={Modalstype}
modalsTopval={Modalstopval} modalsTopval={Modalstopval}

@ -5,6 +5,8 @@ import { DragDropContext,Draggable, Droppable} from 'react-beautiful-dnd';
import Modals from '../../modals/Modals'; import Modals from '../../modals/Modals';
import Addshixuns from './Addshixuns'; import Addshixuns from './Addshixuns';
import NewShixunModel from '../../courses/coursesPublic/NewShixunModel'; import NewShixunModel from '../../courses/coursesPublic/NewShixunModel';
import GotoQQgroup from "../../../modal/GotoQQgroup";
import '../ShixunPaths.css'; import '../ShixunPaths.css';
import axios from 'axios'; import axios from 'axios';
const $ = window.$; const $ = window.$;
@ -56,7 +58,8 @@ class DetailCardsEditAndEdit extends Component{
ChooseShixunListshixun_list:undefined, ChooseShixunListshixun_list:undefined,
stage_nametype:false, stage_nametype:false,
descriptiontype:false, descriptiontype:false,
Addshixunstype:false Addshixunstype:false,
goshowqqgtounp:false,
} }
this.onDragEnd = this.onDragEnd.bind(this); this.onDragEnd = this.onDragEnd.bind(this);
} }
@ -77,6 +80,10 @@ class DetailCardsEditAndEdit extends Component{
} }
Addshixuns=()=>{ Addshixuns=()=>{
if(this.props&&this.props.current_user&&this.props.current_user.is_shixun_marker===false){
this.setgoshowqqgtounp(true);
return;
}
this.setState({ this.setState({
Addshixunstype:true, Addshixunstype:true,
}) })
@ -349,7 +356,12 @@ class DetailCardsEditAndEdit extends Component{
console.log(error) console.log(error)
}); });
} }
// 处理弹框
setgoshowqqgtounp=(bool)=>{
this.setState({
goshowqqgtounp:bool
})
}
render(){ render(){
let {selectShixun, let {selectShixun,
@ -369,11 +381,18 @@ class DetailCardsEditAndEdit extends Component{
delectfunvalue, delectfunvalue,
ChooseShixunListshixun_list, ChooseShixunListshixun_list,
stage_nametype, stage_nametype,
descriptiontype descriptiontype,
goshowqqgtounp
} = this.state } = this.state
return( return(
<div> <div>
{
goshowqqgtounp===true?
<GotoQQgroup {...this.state} {...this.props} setgoshowqqgtounp={(bool)=>this.setgoshowqqgtounp(bool)}></GotoQQgroup>
:
""
}
<Modals <Modals
modalsType={Modalstype} modalsType={Modalstype}
modalsTopval={Modalstopval} modalsTopval={Modalstopval}

@ -656,7 +656,7 @@ submittojoinclass=(value)=>{
if(this.props&&this.props.current_user&&this.props.current_user.is_shixun_marker===true){ if(this.props&&this.props.current_user&&this.props.current_user.is_shixun_marker===false){
this.setgoshowqqgtounp(true); this.setgoshowqqgtounp(true);
return; return;
} }
@ -924,8 +924,8 @@ submittojoinclass=(value)=>{
}) })
} }
console.log("newHeadersnewHeaders"); // console.log("newHeadersnewHeaders");
console.log(this.props); // console.log(this.props);
// this.props.current_user.is_shixun_marker // this.props.current_user.is_shixun_marker
return ( return (

@ -12,6 +12,7 @@ import classNames from 'classnames'
import 'antd/lib/switch/style/index.css' import 'antd/lib/switch/style/index.css'
import './shixunCss/ShixunCardList.css'; import './shixunCss/ShixunCardList.css';
import GotoQQgroup from '../../../modal/GotoQQgroup'
import { on, off } from 'educoder' import { on, off } from 'educoder'
@ -33,6 +34,7 @@ class ShixunCardList extends Component {
shixunid:"", shixunid:"",
upcircle:false, upcircle:false,
typekeyid:undefined, typekeyid:undefined,
goshowqqgtounp:false,
} }
} }
@ -171,6 +173,10 @@ class ShixunCardList extends Component {
this.props.showProfileCompleteDialog() this.props.showProfileCompleteDialog()
return return
} }
if(this.props&&this.props.current_user&&this.props.current_user.is_shixun_marker===false){
this.setgoshowqqgtounp(true);
return;
}
if(url !== undefined || url!==""){ if(url !== undefined || url!==""){
window.location.href = url; window.location.href = url;
@ -178,8 +184,15 @@ class ShixunCardList extends Component {
} }
// 处理弹框
setgoshowqqgtounp=(bool)=>{
this.setState({
goshowqqgtounp:bool
})
}
render(){ render(){
let {mine,InputValue,upcircle}=this.state; let {mine,InputValue,upcircle,goshowqqgtounp}=this.state;
// console.log("NewHeadermygetHelmetapi123123123123"); // console.log("NewHeadermygetHelmetapi123123123123");
let shixuntype=false; let shixuntype=false;
@ -196,10 +209,19 @@ class ShixunCardList extends Component {
} }
}) })
} }
return ( return (
<div className="educontent mt20"> <div className="educontent mt20">
<div className="clearfix"> <div className="clearfix">
{
goshowqqgtounp===true?
<GotoQQgroup {...this.state} {...this.props} setgoshowqqgtounp={(bool)=>this.setgoshowqqgtounp(bool)}></GotoQQgroup>
:
""
}
{/*<div className="fl mr20 font-16 bestChoose shixun_repertoire active"*/} {/*<div className="fl mr20 font-16 bestChoose shixun_repertoire active"*/}
{/*id={"all"}*/} {/*id={"all"}*/}
{/*onClick={(e)=>this.latestHot(e,1)}>全部*/} {/*onClick={(e)=>this.latestHot(e,1)}>全部*/}

@ -9,6 +9,7 @@ import { setImagesUrl } from 'educoder';
import "./usersInfo.css" import "./usersInfo.css"
import Create from './publicCreatNew' import Create from './publicCreatNew'
import GotoQQgroup from "../../../modal/GotoQQgroup";
class InfosShixun extends Component{ class InfosShixun extends Component{
constructor(props){ constructor(props){
@ -22,7 +23,8 @@ class InfosShixun extends Component{
sort_by: "updated_at", sort_by: "updated_at",
sort_direction: "desc", sort_direction: "desc",
totalCount:undefined, totalCount:undefined,
data:undefined data:undefined,
goshowqqgtounp:false,
} }
} }
@ -144,6 +146,13 @@ class InfosShixun extends Component{
this.getCourses(category, status, sort_by, page, sort_directiony); this.getCourses(category, status, sort_by, page, sort_directiony);
} }
// 处理弹框
setgoshowqqgtounp=(bool)=>{
this.setState({
goshowqqgtounp:bool
})
}
render(){ render(){
let{ let{
@ -154,7 +163,8 @@ class InfosShixun extends Component{
data, data,
totalCount, totalCount,
sort_direction, sort_direction,
isSpin isSpin,
goshowqqgtounp
} = this.state; } = this.state;
let is_current=this.props.is_current; let is_current=this.props.is_current;
@ -171,6 +181,12 @@ class InfosShixun extends Component{
); );
return( return(
<div className="educontent"> <div className="educontent">
{
goshowqqgtounp===true?
<GotoQQgroup {...this.state} {...this.props} setgoshowqqgtounp={(bool)=>this.setgoshowqqgtounp(bool)}></GotoQQgroup>
:
""
}
<Spin size="large" spinning={isSpin}> <Spin size="large" spinning={isSpin}>
<style> <style>
{ {
@ -368,7 +384,7 @@ class InfosShixun extends Component{
{/* 298 */} {/* 298 */}
{ {
page == 1 && is_current && !category ? page == 1 && is_current && !category ?
<Create href={"/shixuns/new"} name={"新建实训"} index="2"></Create>:"" <Create href={"/shixuns/new"} name={"新建实训"} index="2" {...this.props} {...this.state} setgoshowqqgtounp={(bool)=>this.setgoshowqqgtounp(bool)}></Create>:""
} }
{ {
(!data || (data && data.shixuns.length==0)) && category && <NoneData></NoneData> (!data || (data && data.shixuns.length==0)) && category && <NoneData></NoneData>

@ -7,37 +7,65 @@ import Loading from '../../../Loading';
import axios from 'axios'; import axios from 'axios';
import {getImageUrl} from 'educoder'; import {getImageUrl} from 'educoder';
import { TPMIndexHOC } from '../../tpm/TPMIndexHOC'; import { TPMIndexHOC } from '../../tpm/TPMIndexHOC';
import { CNotificationHOC } from '../../courses/common/CNotificationHOC' import { CNotificationHOC } from '../../courses/common/CNotificationHOC';
import GotoQQgroup from '../../../modal/GotoQQgroup';
import "./usersInfo.css" import "./usersInfo.css"
class publicCreateNew extends Component{ class publicCreateNew extends Component{
constructor(props){ constructor(props){
super(props); super(props);
this.state={
}
} }
//头部获取是否已经登录了 //头部获取是否已经登录了
getUser=(url)=> { getUser=(url,name)=> {
if (this.props.user&&this.props.user.email===undefined||this.props.user&&this.props.user.email===null||this.props.user&&this.props.user.email==="") { if (this.props.user&&this.props.user.email===undefined||this.props.user&&this.props.user.email===null||this.props.user&&this.props.user.email==="") {
this.props.showNotification("请先绑定邮箱,谢谢"); this.props.showNotification("请先绑定邮箱,谢谢");
return return
} }
if(name==="新建实训"){
if(this.props&&this.props.current_user&&this.props.current_user.is_shixun_marker===false){
this.props.setgoshowqqgtounp(true);
return;
}
}
if(url !== undefined || url!==""){ if(url !== undefined || url!==""){
window.location.href = url; window.location.href = url;
} }
} }
getUsers=(url,name)=> {
if(name==="新建实训"){
if(this.props&&this.props.current_user&&this.props.current_user.is_shixun_marker===false){
this.props.setgoshowqqgtounp(true);
return;
}
}
if(url !== undefined || url!==""){
window.location.href = url;
}
}
render() { render() {
let {href,name,index}=this.props; let {href,name,index}=this.props;
return ( return (
<div className="square-Item" style={{"height":`${index=="1"?"289":index=="2"?"298":index=="3"?"295":"289"}px`}}> <div className="square-Item" style={{"height":`${index=="1"?"289":index=="2"?"298":index=="3"?"295":"289"}px`}}>
<div className="substance substancepad"> <div className="substance substancepad">
{this.props.Createtype==="projects"?<a onClick={()=>this.getUser(href)}> {this.props.Createtype==="projects"?<a onClick={()=>this.getUser(href,name)}>
<div className="substancenenew"> <div className="substancenenew">
<div className="leftten"></div> <div className="leftten"></div>
<div className="topten"></div> <div className="topten"></div>
</div> </div>
</a>: <a href={`${href}`}> </a>: <a onClick={()=>this.getUsers(href,name)}>
<div className="substancenenew"> <div className="substancenenew">
<div className="leftten"></div> <div className="leftten"></div>
<div className="topten"></div> <div className="topten"></div>

Loading…
Cancel
Save