From c687542483ab9c74be9ea8fb7b9c39a9e67e42cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Fri, 12 Jul 2019 14:56:29 +0800 Subject: [PATCH] b --- public/react/src/index.js | 2 +- .../PackageIndexNEIBannerConcent.js | 14 ++++++++++++-- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/public/react/src/index.js b/public/react/src/index.js index 78f76b68..60cffac0 100644 --- a/public/react/src/index.js +++ b/public/react/src/index.js @@ -40,7 +40,7 @@ window.__useKindEditor = false; var proxy = "http://localhost:3000" // proxy = "http://testbdweb.trustie.net" // proxy = "http://testbdweb.educoder.net" - proxy = 'http://192.168.2.63:3001/' + proxy = 'http://192.168.2.63:3001' // proxy='https://www.educoder.net' const requestMap={}; // 在这里使用requestMap控制,避免用户通过双击等操作发出重复的请求; diff --git a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js index 9523459c..bc8696c5 100644 --- a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js +++ b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js @@ -2,15 +2,24 @@ import React, {Component} from 'react'; import {Link} from "react-router-dom"; import axios from 'axios'; import { Input ,Icon,Button,Pagination,DatePicker} from 'antd'; -import { handleDateString} from 'educoder'; +import { handleDateString,getUrl} from 'educoder'; import locale from 'antd/lib/date-picker/locale/zh_CN'; import MDEditors from '../MDEditors'; import PhoneModel from './PhoneModel'; import moment from 'moment' import '../packageconcnet.css'; const { Search } = Input; +const $ = window.$; +let origin = getUrl(); +// load +if (!window.postUpMsg) { + $.getScript( + `${origin}/javascripts/attachments.js`, + (data, textStatus, jqxhr) => { + }); +} class PackageIndexNEIBannerConcent extends Component { constructor(props) { super(props) @@ -285,7 +294,8 @@ class PackageIndexNEIBannerConcent extends Component { id="_file" multiple="multiple" name="attachments[dummy][file]" onChange={() => { - // debugger; + debugger; + console.log(window.$('.file_selector')[0])) window.addInputFiles(window.$('.file_selector')[0]) }} style={{'display': 'none'}} type="file">