This commit is contained in:
caishi 2022-01-18 10:18:21 +08:00
parent 7e71b5f036
commit a05700ed5d
5 changed files with 14 additions and 18 deletions

View File

@ -32,7 +32,7 @@ export function initAxiosInterceptors(props) {
// 判断网络是否连接
initOnlineOfflineListener();
var proxy = "https://forge.osredm.com";
var proxy = "http://192.168.1.40:3000";
//响应前的设置
axios.interceptors.request.use(
config => {

View File

@ -8,10 +8,7 @@ const isDev = window.location.port == 3007;
const isdev2= window.location.hostname ==='www.educoder.net'
export const TEST_HOST = "http://39.105.176.215:49999"
export function getImageUrl(path) {
// https://www.educoder.net
// https://testbdweb.trustie.net
// const local = 'http://localhost:3000'
const local = 'http://39.105.176.215:49999';
const local = 'http://192.168.1.40:3000';
if (isDev) {
return `${local}/${path}`

View File

@ -33,12 +33,12 @@ function SiderBar() {
},[])
function getFAQ(){
// const url = `/faqs.json`;
// axios.get(url).then(result=>{
// if(result && result.data){
// setData(result.data);
// }
// }).catch(error=>{})
const url = `/faqs.json`;
axios.get(url).then(result=>{
if(result && result.data){
setData(result.data);
}
}).catch(error=>{})
}
//获取当前登录账号信息->用于建议反馈

View File

@ -295,14 +295,14 @@ class NewHeader extends Component {
{...this.props}
{...this.state}
/> : ""}
<div style={{width:"78px"}}>
{/* <div style={{width:"78px"}}>
{
publicNav &&
<a href={'https://www.ccf.org.cn/'} className={"fl"}>
<img src={MainLogo} alt="ccf" />
</a>
}
</div>
</div> */}
{
settings && settings.nav_logo_url ?
<a href={settings && settings.new_course.default_url} className={"fl mr50"}>

View File

@ -325,7 +325,6 @@ class comments extends Component {
} = this.state;
const { current_user, only_show_content } = this.props;
const { projectsId ,owner } = this.props.match.params;
const new_comment = (is_reply, item_id) => {
return (
<div className="grid-item-top pb10">
@ -501,9 +500,9 @@ class comments extends Component {
<img
className="radius"
src={
current_user && current_user.image_url
current_user && (current_user.image_url && current_user.image_url !== 'null')
? getImageUrl(`/${current_user.image_url}`)
: "images/avatars/User/b"
: "/images/avatars/User/b"
}
alt=""
width="30"
@ -558,9 +557,9 @@ class comments extends Component {
<img
className="radius"
src={
current_user && current_user.image_url
(current_user && current_user.image_url && current_user.image_url!== 'null')
? getImageUrl(`/${current_user.image_url}`)
: "images/avatars/User/b"
: "/images/avatars/User/b"
}
alt=""
width="30"