yee 7 vuotta sitten
vanhempi
commit
dc139de9a6

+ 255 - 0
js/component/manageCenter/idea/bigShot/lecture.jsx

@@ -0,0 +1,255 @@
+import React from 'react';
+import { Icon, Button, Spin, message, Table, Cascader, Input } from 'antd';
+import { techFieldList } from '../../../DicTechFieldList';
+import ajax from 'jquery/src/ajax/xhr.js';
+import $ from 'jquery/src/ajax';
+
+const Star = React.createClass({
+    loadData(pageNo) {
+        this.setState({
+            loading: true
+        });
+        $.ajax({
+            method: "get",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + '/api/admin/star/list',
+            data: {
+            },
+            success: function (data) {
+                let theArr = [];
+                if (!data.data || !data.data.list) {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    };
+                } else {
+                    for (let i = 0; i < data.data.list.length; i++) {
+                        let thisdata = data.data.list[i];
+                        theArr.push({
+                            key: i,
+                            uid: thisdata.uid,
+                            engagedField: thisdata.engagedField,
+                            username: thisdata.username,
+                            professionalTitle: thisdata.professionalTitle,
+                            workUnit: thisdata.workUnit,
+                            number: thisdata.number,
+                            achievementNums: thisdata.achievementNums,
+                        });
+                    };
+                };
+                this.setState({
+                    dataSource: theArr
+                });
+            }.bind(this),
+        }).always(function () {
+            this.setState({
+                loading: false
+            });
+        }.bind(this));
+    },
+    getInitialState() {
+        return {
+            loading: false,
+            hotSelectedRowKeys: [],
+            hotSelectedRows: [],
+            starSelectedRowKeys: [],
+            starSelectedRows: [],
+            columns: [{
+                title: '活动标题',
+                dataIndex: 'title',
+                key: 'title',
+                render: (text, record, index) => {
+                    return <Input value={record.title} onChange={(e) => { record.title = e.target.value; this.setState({ data: this.state.data }); }} />
+                }
+            }, {
+                title: '活动简介',
+                dataIndex: 'dis',
+                key: 'dis',
+                render: (text, record, index) => {
+                    return <Input type="area" span={4} value={record.url} onChange={(e) => { record.url = e.target.value; this.setState({ data: this.state.data }); }} />
+                }
+            }],
+            dataSource: [],
+            hotTableData: [],
+            starTableData: []
+        };
+    },
+    addIndex(record) {
+        let theBool = true;
+        this.state.hotTableData.map((item, i) => {
+            if (item.uid == record.uid) {
+                message.warning('该条记录已经存在于大咖列表中!');
+                theBool = false;
+                return;
+            };
+            if (i == 4) {
+                message.warning('大咖列表最多只能显示4条记录!');
+                theBool = false;
+                return;
+            };
+        });
+        if (theBool) {
+            this.state.hotTableData.push(record);
+            this.setState({ hotTableData: this.state.hotTableData });
+        };
+    },
+    addStar(record) {
+        let theBool = true;
+        this.state.starTableData.map(item => {
+            if (item.uid == record.uid) {
+                message.warning('该条记录已经存在于明星列表中!');
+                theBool = false;
+                return;
+            };
+            if (i == 6) {
+                message.warning('明星列表最多只能显示6条记录!');
+                theBool = false;
+                return;
+            };
+        });
+        if (theBool) {
+            this.state.starTableData.push(record);
+            this.setState({ starTableData: this.state.starTableData });
+        };
+    },
+    hotDelectRow() {
+        let deletedArr = this.state.hotTableData.concat();
+        for (let idx = 0; idx < this.state.hotSelectedRows.length; idx++) {
+            let deleteIndex = this.state.hotSelectedRows[idx];
+            if (deleteIndex.uid) {
+                for (let n = 0; n < deletedArr.length; n++) {
+                    if (deleteIndex.uid == deletedArr[n].uid) {
+                        deletedArr.splice(n, 1);
+                    };
+                };
+            };
+        };
+        this.setState({
+            hotTableData: deletedArr,
+            hotSelectedRowKeys: []
+        });
+    },
+    starDelectRow() {
+        let deletedArr = this.state.starTableData.concat();
+        for (let idx = 0; idx < this.state.starSelectedRows.length; idx++) {
+            let deleteIndex = this.state.starSelectedRows[idx];
+            if (deleteIndex.uid) {
+                for (let n = 0; n < deletedArr.length; n++) {
+                    if (deleteIndex.uid == deletedArr[n].uid) {
+                        deletedArr.splice(n, 1);
+                    };
+                };
+            };
+        };
+        this.setState({
+            starTableData: deletedArr,
+            starSelectedRowKeys: []
+        });
+    },
+    componentWillMount() {
+        this.loadData();
+    },
+    submit() {
+        let hotArr = [], starArr = [];
+        for (let i = 0; i < this.state.hotTableData.length; i++) {
+            let hotUid = this.state.hotTableData[i].uid;
+            if (hotUid) {
+                hotArr.push(hotUid);
+            };
+        };
+        for (let n = 0; n < this.state.starTableData.length; n++) {
+            let starUid = this.state.starTableData[n].uid;
+            if (starUid) {
+                starArr.push({
+                    uid: starUid,
+                    star: 1
+                });
+            };
+        };
+        this.setState({
+            loading: true
+        });
+        $.ajax({
+            method: "post",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + '/api/admin/star/save',
+            data: {
+                star: starArr,
+                hot: hotArr
+            },
+            success: function (data) {
+                let theArr = [];
+                if (!data.data || !data.data.list) {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    };
+                } else {
+                    message.success('保存成功!')
+                };
+            }.bind(this),
+        }).always(function () {
+            this.setState({
+                loading: false
+            });
+        }.bind(this));
+    },
+    render() {
+        const hotRowSelection = {
+            selectedRowKeys: this.state.hotSelectedRowKeys,
+            onChange: (selectedRowKeys, selectedRows) => {
+                this.setState({
+                    hotSelectedRows: selectedRows,
+                    hotSelectedRowKeys: selectedRowKeys
+                });
+            }
+        };
+        const starRowSelection = {
+            selectedRowKeys: this.state.starSelectedRowKeys,
+            onChange: (selectedRowKeys, selectedRows) => {
+                this.setState({
+                    starSelectedRows: selectedRows,
+                    starSelectedRowKeys: selectedRowKeys
+                });
+            }
+        };
+        const hotHasSelected = this.state.hotSelectedRowKeys.length > 0;
+        const starHasSelected = this.state.starSelectedRowKeys.length > 0;
+        return (
+            <div className="admin-content" >
+                <div className="admin-content-title">科技讲堂管理</div>
+                <div className="admin-content-warp">
+                    <div className="admin-content-header">
+                        <span>大咖显示列表</span>
+                        <Button type='danger' disabled={!hotHasSelected} onClick={this.hotDelectRow}>
+                            删除<Icon type="minus" />
+                        </Button>
+                    </div>
+                    <Spin spinning={this.state.loading}>
+                        <Table columns={this.state.columns}
+                            dataSource={this.state.hotTableData}
+                            rowSelection={hotRowSelection}
+                            pagination={false} />
+                    </Spin>
+                </div>
+                <div className="admin-content-warp">
+                    <div className="admin-content-header">
+                        <span>明星显示列表</span>
+                        <Button type='danger' disabled={!starHasSelected} onClick={this.starDelectRow}>
+                            删除<Icon type="minus" />
+                        </Button>
+                    </div>
+                    <Spin spinning={this.state.loading}>
+                        <Table columns={this.state.columns}
+                            dataSource={this.state.starTableData}
+                            rowSelection={starRowSelection}
+                            pagination={false} />
+                    </Spin>
+                </div>
+                <Button onClick={this.submit} type="primary" style={{ marginTop: '20px' }}>保存</Button>
+            </div >
+        );
+    }
+});
+
+export default Star;

+ 374 - 30
js/component/manageCenter/idea/bigShot/star.jsx

@@ -1,10 +1,11 @@
 import React from 'react';
 import React from 'react';
-import { Icon, Button, Spin, message, Table } from 'antd';
+import { Icon, Button, Spin, message, Table, Cascader, Input } from 'antd';
+import { techFieldList } from '../../../DicTechFieldList';
 import ajax from 'jquery/src/ajax/xhr.js';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import $ from 'jquery/src/ajax';
 
 
 const Star = React.createClass({
 const Star = React.createClass({
-    loadData() {
+    loadData(pageNo) {
         this.setState({
         this.setState({
             loading: true
             loading: true
         });
         });
@@ -12,11 +13,123 @@ const Star = React.createClass({
             method: "get",
             method: "get",
             dataType: "json",
             dataType: "json",
             crossDomain: false,
             crossDomain: false,
-            url: globalConfig.context + '',
+            url: globalConfig.context + '/api/admin/star/list',
             data: {
             data: {
+                pageNo: pageNo || 1,
+                pageSize: this.state.pagination.pageSize,
+                number: this.state.searchNumber, //编号
+                username: this.state.searchName, //名称
+                engagedField: this.state.searchField ? this.state.searchField.join(',') : undefined,
+                professionalTitle: this.state.searchPfs,
+                workUnit: this.state.searchUnit
             },
             },
             success: function (data) {
             success: function (data) {
                 let theArr = [];
                 let theArr = [];
+                if (!data.data || !data.data.list) {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    };
+                } else {
+                    for (let i = 0; i < data.data.list.length; i++) {
+                        let thisdata = data.data.list[i];
+                        theArr.push({
+                            key: i,
+                            uid: thisdata.uid,
+                            engagedField: thisdata.engagedField,
+                            username: thisdata.username,
+                            professionalTitle: thisdata.professionalTitle,
+                            workUnit: thisdata.workUnit,
+                            number: thisdata.number,
+                            achievementNums: thisdata.achievementNums,
+                        });
+                    };
+                    this.state.pagination.current = data.data.pageNo;
+                    this.state.pagination.total = data.data.totalCount;
+                };
+                this.setState({
+                    dataSource: theArr,
+                    pagination: this.state.pagination
+                });
+            }.bind(this),
+        }).always(function () {
+            this.setState({
+                loading: false
+            });
+        }.bind(this));
+    },
+    loadHotData() {
+        this.setState({
+            loading: true
+        });
+        $.ajax({
+            method: "get",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + '/api/admin/star/hotList',
+            success: function (data) {
+                let theArr = [];
+                if (!data.data) {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    };
+                } else {
+                    for (let i = 0; i < data.data.length; i++) {
+                        let thisdata = data.data[i];
+                        theArr.push({
+                            key: i,
+                            uid: thisdata.uid,
+                            engagedField: thisdata.engagedField,
+                            username: thisdata.username,
+                            professionalTitle: thisdata.professionalTitle,
+                            workUnit: thisdata.workUnit,
+                            number: thisdata.number,
+                            achievementNums: thisdata.achievementNums,
+                        });
+                    };
+                };
+                this.setState({
+                    hotTableData: theArr
+                });
+            }.bind(this),
+        }).always(function () {
+            this.setState({
+                loading: false
+            });
+        }.bind(this));
+    },
+    loadStarData() {
+        this.setState({
+            loading: true
+        });
+        $.ajax({
+            method: "get",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + '/api/admin/star/starList',
+            success: function (data) {
+                let theArr = [];
+                if (!data.data) {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    };
+                } else {
+                    for (let i = 0; i < data.data.length; i++) {
+                        let thisdata = data.data[i];
+                        theArr.push({
+                            key: i,
+                            uid: thisdata.uid,
+                            engagedField: thisdata.engagedField,
+                            username: thisdata.username,
+                            professionalTitle: thisdata.professionalTitle,
+                            workUnit: thisdata.workUnit,
+                            number: thisdata.number,
+                            achievementNums: thisdata.achievementNums,
+                        });
+                    };
+                };
+                this.setState({
+                    starTableData: theArr
+                });
             }.bind(this),
             }.bind(this),
         }).always(function () {
         }).always(function () {
             this.setState({
             this.setState({
@@ -27,64 +140,264 @@ const Star = React.createClass({
     getInitialState() {
     getInitialState() {
         return {
         return {
             loading: false,
             loading: false,
-            selectedRowKeys: [],
-            selectedRows: [],
+            hotSelectedRowKeys: [],
+            hotSelectedRows: [],
+            starSelectedRowKeys: [],
+            starSelectedRows: [],
+            pagination: {
+                defaultCurrent: 1,
+                defaultPageSize: 10,
+                showQuickJumper: true,
+                pageSize: 10,
+                onChange: function (page) {
+                    this.loadData(page);
+                }.bind(this),
+                showTotal: function (total) {
+                    return '共' + total + '条数据';
+                }
+            },
             columns: [
             columns: [
                 {
                 {
+                    title: '编号',
+                    dataIndex: 'number',
+                    key: 'number',
+                }, {
                     title: '姓名',
                     title: '姓名',
-                    dataIndex: 'name',
-                    key: 'name',
+                    dataIndex: 'username',
+                    key: 'username',
                 }, {
                 }, {
                     title: '从事领域',
                     title: '从事领域',
-                    dataIndex: 'field',
-                    key: 'field',
+                    dataIndex: 'engagedField',
+                    key: 'engagedField',
                 }, {
                 }, {
                     title: '职称名字',
                     title: '职称名字',
-                    dataIndex: 'keyword',
-                    key: 'keyword',
+                    dataIndex: 'professionalTitle',
+                    key: 'professionalTitle',
                 }, {
                 }, {
                     title: '工作单位',
                     title: '工作单位',
-                    dataIndex: 'unit',
-                    key: 'unit',
+                    dataIndex: 'workUnit',
+                    key: 'workUnit',
+                }, {
+                    title: '成果数量',
+                    dataIndex: 'achievementNums',
+                    key: 'achievementNums',
+                }, {
+                    title: '操作',
+                    dataIndex: 'action',
+                    key: 'action',
+                    render: (text, record, index) => {
+                        return <div>
+                            <Button onClick={() => { this.addIndex(record) }} type="primary" style={{ marginRight: '10px' }}>添加到大咖说</Button>
+                            <Button onClick={() => { this.addStar(record) }} type="primary">添加到明星页</Button>
+                        </div>
+                    }
                 }
                 }
             ],
             ],
-            dataSource: []
+            otherColumns: [
+                {
+                    title: '编号',
+                    dataIndex: 'number',
+                    key: 'number',
+                }, {
+                    title: '姓名',
+                    dataIndex: 'username',
+                    key: 'username',
+                }, {
+                    title: '从事领域',
+                    dataIndex: 'engagedField',
+                    key: 'engagedField',
+                }, {
+                    title: '职称名字',
+                    dataIndex: 'professionalTitle',
+                    key: 'professionalTitle',
+                }, {
+                    title: '工作单位',
+                    dataIndex: 'workUnit',
+                    key: 'workUnit',
+                }, {
+                    title: '成果数量',
+                    dataIndex: 'achievementNums',
+                    key: 'achievementNums',
+                }
+            ],
+            dataSource: [],
+            hotTableData: [],
+            starTableData: []
         };
         };
     },
     },
+    addIndex(record) {
+        let theBool = true;
+        this.state.hotTableData.map((item, i) => {
+            if (item.uid == record.uid) {
+                message.warning('该条记录已经存在于大咖列表中!');
+                theBool = false;
+                return;
+            };
+            if (i == 4) {
+                message.warning('大咖列表最多只能显示4条记录!');
+                theBool = false;
+                return;
+            };
+        });
+        if (theBool) {
+            this.state.hotTableData.push(record);
+            this.setState({ hotTableData: this.state.hotTableData });
+        };
+    },
+    addStar(record) {
+        let theBool = true;
+        this.state.starTableData.map((item, i) => {
+            if (item.uid == record.uid) {
+                message.warning('该条记录已经存在于明星列表中!');
+                theBool = false;
+                return;
+            };
+            if (i == 6) {
+                message.warning('明星列表最多只能显示6条记录!');
+                theBool = false;
+                return;
+            };
+        });
+        if (theBool) {
+            this.state.starTableData.push(record);
+            this.setState({ starTableData: this.state.starTableData });
+        };
+    },
+    hotDelectRow() {
+        let deletedArr = this.state.hotTableData.concat();
+        for (let idx = 0; idx < this.state.hotSelectedRows.length; idx++) {
+            let deleteIndex = this.state.hotSelectedRows[idx];
+            if (deleteIndex.uid) {
+                for (let n = 0; n < deletedArr.length; n++) {
+                    if (deleteIndex.uid == deletedArr[n].uid) {
+                        deletedArr.splice(n, 1);
+                    };
+                };
+            };
+        };
+        this.setState({
+            hotTableData: deletedArr,
+            hotSelectedRowKeys: []
+        });
+    },
+    starDelectRow() {
+        let deletedArr = this.state.starTableData.concat();
+        for (let idx = 0; idx < this.state.starSelectedRows.length; idx++) {
+            let deleteIndex = this.state.starSelectedRows[idx];
+            if (deleteIndex.uid) {
+                for (let n = 0; n < deletedArr.length; n++) {
+                    if (deleteIndex.uid == deletedArr[n].uid) {
+                        deletedArr.splice(n, 1);
+                    };
+                };
+            };
+        };
+        this.setState({
+            starTableData: deletedArr,
+            starSelectedRowKeys: []
+        });
+    },
     componentWillMount() {
     componentWillMount() {
         this.loadData();
         this.loadData();
+        this.loadHotData();
+        this.loadStarData();
     },
     },
-    componentWillReceiveProps(nextProps) {
+    submit() {
+        let hotArr = [], starArr = [];
+        for (let i = 0; i < this.state.hotTableData.length; i++) {
+            let hotUid = this.state.hotTableData[i].uid;
+            if (hotUid) {
+                hotArr.push(hotUid);
+            };
+        };
+        for (let n = 0; n < this.state.starTableData.length; n++) {
+            let starUid = this.state.starTableData[n].uid;
+            if (starUid) {
+                starArr.push({
+                    uid: starUid,
+                    star: 1
+                });
+            };
+        };
+        this.setState({
+            loading: true
+        });
+        $.ajax({
+            method: "post",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + '/api/admin/star/save',
+            data: {
+                data: JSON.stringify(starArr),
+                hot: hotArr
+            },
+            success: function (data) {
+                if (data.error && data.error.length) {
+                    message.warning(data.error[0].message);
+                } else {
+                    message.success('保存成功!')
+                };
+            }.bind(this),
+        }).always(function () {
+            this.setState({
+                loading: false
+            });
+        }.bind(this));
+    },
+    search() {
+        this.loadData();
+    },
+    reset() {
+        this.state.searchPfs = undefined;
+        this.state.searchUnit = undefined;
+        this.state.searchNumber = undefined;
+        this.state.searchName = undefined;
+        this.state.searchField = [];
+        this.loadData();
     },
     },
     render() {
     render() {
-        const rowSelection = {
-            selectedRowKeys: this.state.selectedRowKeys,
+        const hotRowSelection = {
+            selectedRowKeys: this.state.hotSelectedRowKeys,
+            onChange: (selectedRowKeys, selectedRows) => {
+                this.setState({
+                    hotSelectedRows: selectedRows,
+                    hotSelectedRowKeys: selectedRowKeys
+                });
+            }
+        };
+        const starRowSelection = {
+            selectedRowKeys: this.state.starSelectedRowKeys,
             onChange: (selectedRowKeys, selectedRows) => {
             onChange: (selectedRowKeys, selectedRows) => {
                 this.setState({
                 this.setState({
-                    selectedRows: selectedRows.slice(-1),
-                    selectedRowKeys: selectedRowKeys.slice(-1)
+                    starSelectedRows: selectedRows,
+                    starSelectedRowKeys: selectedRowKeys
                 });
                 });
             }
             }
         };
         };
-        const hasSelected = this.state.selectedRowKeys.length > 0;
+        const hotHasSelected = this.state.hotSelectedRowKeys.length > 0;
+        const starHasSelected = this.state.starSelectedRowKeys.length > 0;
         return (
         return (
             <div className="admin-content" >
             <div className="admin-content" >
                 <div className="admin-content-title">科技明星管理</div>
                 <div className="admin-content-title">科技明星管理</div>
                 <div className="admin-content-warp">
                 <div className="admin-content-warp">
-                    <div>专家列表</div>
-                    <div className="user-search">
-                        <Input placeholder="编号"
+                    <div className="admin-content-header">专家列表</div>
+                    <div className="admin-content-search">
+                        <Input placeholder="编号" style={{ width: 100 }}
                             value={this.state.searchNumber}
                             value={this.state.searchNumber}
                             onChange={(e) => { this.setState({ searchNumber: e.target.value }); }} />
                             onChange={(e) => { this.setState({ searchNumber: e.target.value }); }} />
-                        <Input placeholder="用户名"
-                            value={this.state.username}
-                            onChange={(e) => { this.setState({ username: e.target.value }); }} />
-                        <Input placeholder="职称名字"
-                            value={this.state.keyword}
-                            onChange={(e) => { this.setState({ keyword: e.target.value }); }} />
-                        <Input placeholder="工作单位"
+                        <Input placeholder="用户名" style={{ width: 160 }}
                             value={this.state.searchName}
                             value={this.state.searchName}
                             onChange={(e) => { this.setState({ searchName: e.target.value }); }} />
                             onChange={(e) => { this.setState({ searchName: e.target.value }); }} />
+                        <Cascader placeholder="请选择一个行业" style={{ width: 300 }}
+                            options={techFieldList}
+                            value={this.state.searchField}
+                            onChange={(e) => { this.setState({ searchField: e }) }} />
+                        <Input placeholder="职称名字" style={{ width: 160 }}
+                            value={this.state.searchPfs}
+                            onChange={(e) => { this.setState({ searchPfs: e.target.value }); }} />
+                        <Input placeholder="工作单位" style={{ width: 160 }}
+                            value={this.state.searchUnit}
+                            onChange={(e) => { this.setState({ searchUnit: e.target.value }); }} />
                         <Button type="primary" onClick={this.search}>搜索</Button>
                         <Button type="primary" onClick={this.search}>搜索</Button>
                         <Button onClick={this.reset}>重置</Button>
                         <Button onClick={this.reset}>重置</Button>
                     </div>
                     </div>
@@ -94,6 +407,37 @@ const Star = React.createClass({
                             pagination={this.state.pagination} />
                             pagination={this.state.pagination} />
                     </Spin>
                     </Spin>
                 </div>
                 </div>
+                <div className="clearfix">
+                    <div className="admin-content-warp" style={{ width: '50%', float: 'left' }}>
+                        <div className="admin-content-header">
+                            <span>大咖显示列表</span>
+                            <Button type='danger' disabled={!hotHasSelected} onClick={this.hotDelectRow}>
+                                删除<Icon type="minus" />
+                            </Button>
+                        </div>
+                        <Spin spinning={this.state.loading}>
+                            <Table columns={this.state.otherColumns}
+                                dataSource={this.state.hotTableData}
+                                rowSelection={hotRowSelection}
+                                pagination={false} />
+                        </Spin>
+                    </div>
+                    <div className="admin-content-warp" style={{ width: '50%', float: 'left' }}>
+                        <div className="admin-content-header">
+                            <span>明星显示列表</span>
+                            <Button type='danger' disabled={!starHasSelected} onClick={this.starDelectRow}>
+                                删除<Icon type="minus" />
+                            </Button>
+                        </div>
+                        <Spin spinning={this.state.loading}>
+                            <Table columns={this.state.otherColumns}
+                                dataSource={this.state.starTableData}
+                                rowSelection={starRowSelection}
+                                pagination={false} />
+                        </Spin>
+                    </div>
+                </div>
+                <Button onClick={this.submit} type="primary" style={{ marginTop: '20px' }}>保存</Button>
             </div >
             </div >
         );
         );
     }
     }

+ 12 - 0
js/component/manageCenter/idea/content.jsx

@@ -1,5 +1,6 @@
 import React, { Component } from 'react';
 import React, { Component } from 'react';
 import '../content.less';
 import '../content.less';
+import './content.less';
 import LeftTab from './leftTab';
 import LeftTab from './leftTab';
 
 
 
 
@@ -23,6 +24,17 @@ class Content extends Component {
             case 'star':
             case 'star':
                 require.ensure([], () => {
                 require.ensure([], () => {
                     const Star = require('./bigShot/star').default;
                     const Star = require('./bigShot/star').default;
+                    this.setState({
+                        component: Star
+                    });
+                });
+                break;
+            case 'lecture':
+                require.ensure([], () => {
+                    const Lecture = require('./bigShot/lecture').default;
+                    this.setState({
+                        component: Lecture
+                    });
                 });
                 });
                 break;
                 break;
         };
         };

+ 28 - 0
js/component/manageCenter/idea/content.less

@@ -0,0 +1,28 @@
+.admin-content {
+    background: #fff;
+    padding: 20px;
+    color: #666;
+    .admin-content-title {
+        font-size: 16px;
+    }
+    .admin-content-warp {
+        padding: 10px;
+        .admin-content-header {
+            margin-bottom: 10px;
+            line-height: 28px;
+            >span {
+                font-size: 14px
+            }
+            >button {
+                float: right;
+            }
+        }
+        .admin-content-search {
+            margin-bottom: 10px;
+            >* {
+                margin-top: 10px;
+                margin-right: 10px;
+            }
+        }
+    }
+}

+ 7 - 7
js/component/manageCenter/servicesManage/highTech/fosterDesc/annualReport.jsx

@@ -92,16 +92,16 @@ const AnnualReportDescFrom = Form.create()(React.createClass({
                         </div>
                         </div>
                         <div className="half-item">
                         <div className="half-item">
                             <p className="item-title">上市时间: </p>
                             <p className="item-title">上市时间: </p>
-                            <p>{theData.listedDateFormattedDate}</p>
+                            <p>{theData.listedDate}</p>
                         </div>
                         </div>
                         <div className="half-item">
                         <div className="half-item">
                             <p className="item-title">上市类型: </p>
                             <p className="item-title">上市类型: </p>
                             <p>
                             <p>
                                 {(() => {
                                 {(() => {
                                     switch (theData.listedType) {
                                     switch (theData.listedType) {
-                                        case 0:
+                                        case '0':
                                             return "股票型上市公司";
                                             return "股票型上市公司";
-                                        case 1:
+                                        case '1':
                                             return "债券型上市公司";
                                             return "债券型上市公司";
                                         default:
                                         default:
                                             return "";
                                             return "";
@@ -322,7 +322,7 @@ const AnnualReportDescFrom = Form.create()(React.createClass({
 }));
 }));
 
 
 const AnnualReportDesc = React.createClass({
 const AnnualReportDesc = React.createClass({
-    loadData(v) {
+    loadData(v, year, uid) {
         this.setState({
         this.setState({
             loading: true
             loading: true
         });
         });
@@ -332,8 +332,8 @@ const AnnualReportDesc = React.createClass({
             crossDomain: false,
             crossDomain: false,
             url: globalConfig.context + "/api/admin/annualReportDetail",
             url: globalConfig.context + "/api/admin/annualReportDetail",
             data: {
             data: {
-                year: this.props.data ? this.props.data.year : (new Date().getFullYear() - 1),
-                uid: this.props.uid
+                year: year ? year : (new Date().getFullYear() - 1),
+                uid: uid ? uid : this.props.data.uid
             }
             }
         }).done((data) => {
         }).done((data) => {
             if (!data.data) {
             if (!data.data) {
@@ -398,7 +398,7 @@ const AnnualReportDesc = React.createClass({
     },
     },
     componentWillReceiveProps(nextProps) {
     componentWillReceiveProps(nextProps) {
         if (nextProps.showDesc) {
         if (nextProps.showDesc) {
-            this.loadData(nextProps.showDesc);
+            this.loadData(nextProps.showDesc, nextProps.data.year, nextProps.data.uid);
         };
         };
     },
     },
     showModal() {
     showModal() {

+ 2 - 2
js/component/manageCenter/servicesManage/highTech/highTechInfo.jsx

@@ -1111,7 +1111,7 @@ const highTechInfo = React.createClass({
                             </div>
                             </div>
                             <div className="half-item">
                             <div className="half-item">
                                 <span className="item-title">注册时间</span>
                                 <span className="item-title">注册时间</span>
-                                <span>{theData.registrationTime}</span>
+                                <span>{theData.registrationTimeFormattedDate}</span>
                             </div>
                             </div>
                             <div className="half-item">
                             <div className="half-item">
                                 <span className="item-title">企业规模</span>
                                 <span className="item-title">企业规模</span>
@@ -1216,7 +1216,7 @@ const highTechInfo = React.createClass({
                             </div>
                             </div>
                             <div className="half-item">
                             <div className="half-item">
                                 <span className="item-title">上市时间</span>
                                 <span className="item-title">上市时间</span>
-                                <span>{theData.listedDate}</span>
+                                <span>{theData.listedDateFormattedDate}</span>
                             </div>
                             </div>
                             <div className="half-item">
                             <div className="half-item">
                                 <span className="item-title">股票代码</span>
                                 <span className="item-title">股票代码</span>

+ 1 - 1
js/component/portal/top.jsx

@@ -112,7 +112,7 @@ const LoginTop = React.createClass({
                                     </ul>
                                     </ul>
                                 </li>
                                 </li>
                                 <li>
                                 <li>
-                                    <a href={globalConfig.context + '/portal/entrepreneurship/entrepreneurshipIndex.html'}>创圈</a>
+                                    <a href={globalConfig.context + '/portal/entrepreneurship/entrepreneurshipIndex.html'}>创圈</a>
                                     <ul className="secondary_navigation_nav" style={{ 'width': (3 * 75) + 'px', left: '-' + (3 * 75 / 2 - 74.25 / 2) + 'px' }}>
                                     <ul className="secondary_navigation_nav" style={{ 'width': (3 * 75) + 'px', left: '-' + (3 * 75 / 2 - 74.25 / 2) + 'px' }}>
                                         <li><a href={globalConfig.context + '/portal/entrepreneurship/entrepreneurshipIndex.html'}>项目圈</a></li>
                                         <li><a href={globalConfig.context + '/portal/entrepreneurship/entrepreneurshipIndex.html'}>项目圈</a></li>
                                         <li><a href={globalConfig.context + '/portal/entrepreneurship/entrepreneurshipIndex.html#chuangke'}>创客圈</a></li>
                                         <li><a href={globalConfig.context + '/portal/entrepreneurship/entrepreneurshipIndex.html#chuangke'}>创客圈</a></li>