Browse Source

高企认定修改、下载增加-到费用详情

yee 8 years ago
parent
commit
7cfb7080c2
34 changed files with 361 additions and 134 deletions
  1. 5 3
      css/sign.less
  2. 7 3
      js/component/account/services/achievement.jsx
  3. 21 10
      js/component/account/services/activity.jsx
  4. 18 9
      js/component/account/services/activityCostList.jsx
  5. 4 2
      js/component/account/services/cognizance.jsx
  6. 6 1
      js/component/account/services/finance.jsx
  7. 6 1
      js/component/account/services/honorList.jsx
  8. 7 2
      js/component/account/services/intellectualDesc.jsx
  9. 14 4
      js/component/account/services/orgTechCenter.jsx
  10. 1 1
      js/component/account/services/patentAdd.jsx
  11. 6 1
      js/component/account/services/ratepay.jsx
  12. 7 2
      js/component/account/services/techProduct.jsx
  13. 12 2
      js/component/account/set/hrSituation.jsx
  14. 1 0
      js/component/login/login.less
  15. 15 5
      js/component/manageCenter/servicesManage/highTech/HighTechApply.jsx
  16. 6 1
      js/component/manageCenter/servicesManage/highTech/fosterDesc/achievement.jsx
  17. 21 9
      js/component/manageCenter/servicesManage/highTech/fosterDesc/activity.jsx
  18. 28 19
      js/component/manageCenter/servicesManage/highTech/fosterDesc/activityCostList.jsx
  19. 6 1
      js/component/manageCenter/servicesManage/highTech/fosterDesc/finance.jsx
  20. 6 1
      js/component/manageCenter/servicesManage/highTech/fosterDesc/honorList.jsx
  21. 12 2
      js/component/manageCenter/servicesManage/highTech/fosterDesc/hrSituation.jsx
  22. 8 3
      js/component/manageCenter/servicesManage/highTech/fosterDesc/intellectualDesc.jsx
  23. 12 2
      js/component/manageCenter/servicesManage/highTech/fosterDesc/orgTechCenter.jsx
  24. 6 1
      js/component/manageCenter/servicesManage/highTech/fosterDesc/ratepay.jsx
  25. 6 1
      js/component/manageCenter/servicesManage/highTech/fosterDesc/techProduct.jsx
  26. 17 5
      js/component/manageCenter/servicesManage/highTech/highTechFoster.jsx
  27. 10 4
      js/component/manageCenter/servicesManage/patent/applyFee.jsx
  28. 9 5
      js/component/manageCenter/servicesManage/patent/clientInputPatent.jsx
  29. 10 12
      js/component/manageCenter/servicesManage/patent/comPatentAdd.jsx
  30. 55 18
      js/component/manageCenter/servicesManage/patent/comprehensive.jsx
  31. 8 2
      js/component/manageCenter/servicesManage/patent/payment.jsx
  32. 4 1
      js/component/sign/groupAccount.jsx
  33. 6 0
      js/component/tools.js
  34. 1 1
      js/user/signIn.js

+ 5 - 3
css/sign.less

@@ -1,6 +1,8 @@
 .wrap {
-    .accounnt-form {
-        margin-top: 120px;
+    min-height: 1000px;
+    .signIn-form {
+        width: 1000px;
+        margin: 20px auto;
         //antd
         .ant-tabs-bar {
             height: 60px;
@@ -19,7 +21,7 @@
                             text-align: center;
                             border: none;
                             background: #f0f0f0;
-                            margin-bottom: 0;
+                            margin: 0;
                             padding: 0;
                         }
                         .ant-tabs-tab-active {

+ 7 - 3
js/component/account/services/achievement.jsx

@@ -163,8 +163,12 @@ const AchievementDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
-                                this.state.enclosureUrl = info.file.response.data;
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                    this.state.enclosureUrl = info.file.response.data;
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                };
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);
                             }
@@ -269,7 +273,7 @@ const Achievement = React.createClass({
                 let thisdata = data.data.list[i];
                 this.state.data.push({
                     key: i,
-                    id:thisdata.id,
+                    id: thisdata.id,
                     uid: thisdata.uid,
                     achievementName: thisdata.achievementName,
                     source: thisdata.source,

+ 21 - 10
js/component/account/services/activity.jsx

@@ -1,7 +1,7 @@
 import React from 'react';
 import { Icon, Button, Upload, Input, Spin, Table, message, Select, Modal, DatePicker, Cascader, Transfer, InputNumber } from 'antd';
 import { techFieldList, technicalSourceList } from '../../dataDic.js';
-import { getTechField, getTechnicalSource, beforeUploadFile } from '../../tools.js';
+import { getTechField, getTechnicalSource, beforeUploadFile, downloadFile } from '../../tools.js';
 import './activity.less';
 import moment from 'moment';
 import ajax from 'jquery/src/ajax/xhr.js';
@@ -71,14 +71,14 @@ const ActivityDesc = React.createClass({
     },
     componentWillReceiveProps(nextProps) {
         this.state.visible = nextProps.showDesc;
-        if (nextProps.data) {
+        if (!this.props.showDesc && nextProps.showDesc) {
             this.state.activityName = nextProps.data.activityName;
             this.state.activityNumber = nextProps.data.activityNumber;
             this.state.startDateFormattedDate = nextProps.data.startDateFormattedDate;
             this.state.endDateFormattedDate = nextProps.data.endDateFormattedDate;
             this.state.techField = nextProps.data.techField;
             this.state.technicalSource = nextProps.data.technicalSource;
-            this.state.targetKeys = nextProps.data.intellectualPropertyNumber;
+            this.state.targetKeys = nextProps.data.intellectualPropertyNumber || [];
             this.state.budget = nextProps.data.budget;
             this.state.firstYearExpenditure = nextProps.data.firstYearExpenditure;
             this.state.secondYearExpenditure = nextProps.data.secondYearExpenditure;
@@ -87,7 +87,9 @@ const ActivityDesc = React.createClass({
             this.state.technologyInnovation = nextProps.data.technologyInnovation;
             this.state.achievement = nextProps.data.achievement;
             this.state.mockData = nextProps.data.mockData;
-            this.state.projectMode = String(nextProps.data.projectMode);
+            this.state.projectMode = nextProps.data.projectMode ? String(nextProps.data.projectMode) : undefined;
+            this.state.proofUrl = nextProps.data.proofUrl;
+            this.state.proofDownloadFileName = nextProps.data.proofDownloadFileName;
         };
     },
     intellectualChange(nextTargetKeys, direction, moveKeys) {
@@ -137,7 +139,7 @@ const ActivityDesc = React.createClass({
                                 options={techFieldList}
                                 value={this.state.techField}
                                 onChange={(value, selectedOptions) => { this.setState({ techField: value }); console.log(value) }}
-                                placeholder="Please select"
+                                placeholder="选择技术领域"
                                 showSearch
                             />,
                         </div>
@@ -242,21 +244,27 @@ const ActivityDesc = React.createClass({
                             placeholder='请选择立项类型'
                             value={this.state.projectMode}
                             onChange={(e) => { this.setState({ projectMode: e }); }}>
-                            <Select.Option value='0'>内部立项</Select.Option>
-                            <Select.Option value='1'>外部立项</Select.Option>
+                            <Select.Option value='1'>内部立项</Select.Option>
+                            <Select.Option value='2'>外部立项</Select.Option>
                         </Select>
                         <div style={{ width: '50%' }}>
                             <Upload
                                 name="ratepay"
                                 action={globalConfig.context + "/techservice/cognizance/upload"}
-                                data={{ 'sign': this.props.year + 'proof' }}
+                                data={{ 'sign': 'proof' }}
                                 beforeUpload={beforeUploadFile}
+                                showUploadList={false}
                                 onChange={(info) => {
                                     if (info.file.status !== 'uploading') {
                                         console.log(info.file, info.fileList);
                                     }
                                     if (info.file.status === 'done') {
-                                        message.success(`${info.file.name} 文件上传成功!`);
+                                        if (!info.file.response.error.length) {
+                                            message.success(`${info.file.name} 文件上传成功!`);
+                                        } else {
+                                            message.warning(info.file.response.error[0].message);
+                                            return;
+                                        };
                                         this.state.proofUrl = info.file.response.data;
                                     } else if (info.file.status === 'error') {
                                         message.error(`${info.file.name} 文件上传失败。`);
@@ -265,6 +273,7 @@ const ActivityDesc = React.createClass({
                             >
                                 <Button><Icon type="upload" /> 上传立项证明材料 </Button>
                             </Upload>
+                            <p>{this.state.proofUrl ? <a onClick={downloadFile.bind(null, this.state.proofUrl, this.state.proofDownloadFileName)}>{this.state.proofDownloadFileName}</a> : <span>未上传!</span>}</p>
                         </div>
                     </Modal>
                 </div>
@@ -363,7 +372,9 @@ const Activity = React.createClass({
                     sortNumber: thisdata.sortNumber,
                     startDateFormattedDate: thisdata.startDateFormattedDate,
                     endDateFormattedDate: thisdata.endDateFormattedDate,
-                    projectMode:thisdata.projectMode
+                    projectMode: thisdata.projectMode,
+                    proofUrl: thisdata.proofUrl,
+                    proofDownloadFileName: thisdata.proofDownloadFileName
                 });
             };
             this.state.pagination.current = data.data.pageNo;

+ 18 - 9
js/component/account/services/activityCostList.jsx

@@ -1,7 +1,7 @@
 import React from 'react';
 import { Icon, Form, Upload, Button, Input, Spin, Table, message, Select, Modal, DatePicker, InputNumber } from 'antd';
 import './activityCostList.less';
-import { beforeUploadFile } from '../../tools.js';
+import { beforeUploadFile,downloadFile } from '../../tools.js';
 import moment from 'moment';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
@@ -68,7 +68,7 @@ const ActivityDescFrom = Form.create()(React.createClass({
                         enterpriseFiller: values.enterpriseFiller,
                         signDateFormattedDate: values.signDate.format('YYYY-MM-DD'),
                         sortNumber: values.sortNumber,
-                        accountUrl:this.state.accountUrl
+                        accountUrl: this.state.accountUrl
                     }
                 }).done(function (data) {
                     if (!data.error.length) {
@@ -264,26 +264,33 @@ const ActivityDescFrom = Form.create()(React.createClass({
                             )}
                     </FormItem>
                 </div>
-                <div style={{ marginTop:'20px',width: '50%' }}>
+                <div style={{ width: '50%', marginTop: '20px' }}>
                     <Upload
                         name="ratepay"
                         action={globalConfig.context + "/techservice/cognizance/upload"}
-                        data={{ 'sign': this.props.year + 'proof' }}
+                        data={{ 'sign': 'activity_cost_account' }}
                         beforeUpload={beforeUploadFile}
+                        showUploadList={false}
                         onChange={(info) => {
                             if (info.file.status !== 'uploading') {
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.accountUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);
                             }
                         }}
                     >
-                        <Button><Icon type="upload" /> 上传台账 </Button>
+                        <Button><Icon type="upload" /> 上传研发费用台账 </Button>
                     </Upload>
+                    <p>{theData.accountUrl ? <a onClick={downloadFile.bind(null, theData.accountUrl, theData.accountDownloadFileName)}>{theData.accountDownloadFileName}</a> : <span>未上传!</span>}</p>
                 </div>
                 <FormItem style={{ marginTop: '20px' }}>
                     <Button className="set-submit" type="primary" htmlType="submit">保存</Button>
@@ -330,7 +337,7 @@ const ActivityDesc = React.createClass({
         return (
             <div className="patent-addNew">
                 <Spin spinning={this.state.loading} className='spin-box'>
-                    <Modal title="企业年度研究开发费用结构明细" visible={this.state.visible}
+                    <Modal title="企业研究开发费用结构明细" visible={this.state.visible}
                         onOk={this.handleOk} onCancel={this.handleCancel}
                         width='800px'
                         footer=''
@@ -417,7 +424,9 @@ const Activity = React.createClass({
                     sortNumber: thisdata.sortNumber,
 
                     startDateFormattedDate: thisdata.startDateFormattedDate,
-                    endDateFormattedDate: thisdata.endDateFormattedDate
+                    endDateFormattedDate: thisdata.endDateFormattedDate,
+                    accountDownloadFileName: thisdata.accountDownloadFileName,
+                    accountUrl: thisdata.accountUrl
                 });
             };
             this.state.activityNumberList = activityNumber.data;
@@ -584,7 +593,7 @@ const Activity = React.createClass({
         return (
             <div className="user-content" >
                 <div className="content-title">
-                    <span>企业研究开发活动情况表</span>
+                    <span>企业研究开发费用结构明细</span>
                 </div>
                 <div className="user-search">
                     <Input placeholder="研发活动编号" value={this.state.activityNumber}

+ 4 - 2
js/component/account/services/cognizance.jsx

@@ -215,9 +215,11 @@ const CognizanceDescFrom = Form.create()(React.createClass({
                         </div>
                     </div>
                     <FormItem style={{ width: '50%' }}
-                        {...formItemLayout}
+                        labelCol={{ span: 0 }}
+                        wrapperCol={{ span: 24 }}
                         label="技术领域"
                     >
+                        <span className="item-title">技术领域: </span>
                         {getFieldDecorator('technicalField', {
                             rules: [{ type: 'array', required: true, message: '此项为必填项!' }],
                             initialValue: [Number(theData.technicalField1), Number(theData.technicalField2), Number(theData.technicalField3)]
@@ -708,7 +710,7 @@ const Cognizance = React.createClass({
                     <p>
                         <Button style={{ background: "#ea0862", border: "none", color: "#fff" }}
                             onClick={this.addClick}>添加<Icon type="plus" /></Button>
-                        <Button style={{ background: "#3fcf9e", border: "none", color: "#fff",display:'none' }}
+                        <Button style={{ background: "#3fcf9e", border: "none", color: "#fff", display: 'none' }}
                             disabled={!hasSelected}
                             onClick={this.delectRow}>删除<Icon type="minus" /></Button>
                     </p>

+ 6 - 1
js/component/account/services/finance.jsx

@@ -218,7 +218,12 @@ const FinanceDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.financeUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 6 - 1
js/component/account/services/honorList.jsx

@@ -100,7 +100,12 @@ const HonorListDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.enclosureUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 7 - 2
js/component/account/services/intellectualDesc.jsx

@@ -1,5 +1,5 @@
 import React from 'react';
-import { Icon, Modal, Button, Form, message, Input, Spin, Select, DatePicker,Upload } from 'antd';
+import { Icon, Modal, Button, Form, message, Input, Spin, Select, DatePicker, Upload } from 'antd';
 import './patent.less';
 import { intellectualGetList, catagoryList } from '../../dataDic.js';
 import { beforeUploadFile } from '../../tools.js';
@@ -175,7 +175,12 @@ const IntellectualDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.propertyRightUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 14 - 4
js/component/account/services/orgTechCenter.jsx

@@ -112,7 +112,12 @@ const CenterListDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.protocolUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);
@@ -360,7 +365,7 @@ const CenterList = React.createClass({
             crossDomain: false,
             url: globalConfig.context + "/techservice/cognizance/disposeCenter",
             data: {
-                id:this.state.cid,
+                id: this.state.cid,
                 principal: this.state.principal,
                 systemUrl: this.state.systemUrl,
                 systemCatalog: this.state.systemCatalog,
@@ -407,7 +412,7 @@ const CenterList = React.createClass({
                         <DatePicker
                             value={moment(this.state.foundingTime)}
                             allowClear={false}
-                            onChange={(date, dateString) => {this.setState({ foundingTime: dateString }); }}
+                            onChange={(date, dateString) => { this.setState({ foundingTime: dateString }); }}
                         />
                         <span>负责人: </span>
                         <Input
@@ -442,7 +447,12 @@ const CenterList = React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.systemUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 1 - 1
js/component/account/services/patentAdd.jsx

@@ -208,7 +208,7 @@ const PatentAddFrom = Form.create()(React.createClass({
                     {getFieldDecorator('avatar')(
                         <Avatar urlData={this.avatarUrl} name='patent_prory_statement' />
                     )}
-                    <span>请上传专利代理委托书</span><a onClick={() => { window.open(globalConfig.context + "/techservice/patent/downloadTemplate") }}>模板下载</a>
+                    <span>请上传专利代理委托书</span><a onClick={() => { window.open(globalConfig.context + "/open/downloadTemplateFile?sign=patent_prory_statement") }}>模板下载</a>
                 </FormItem>
                 <FormItem>
                     <Button className="set-submit" type="primary" htmlType="submit">保存</Button>

+ 6 - 1
js/component/account/services/ratepay.jsx

@@ -196,7 +196,12 @@ const RatepayDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.ratepayUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 7 - 2
js/component/account/services/techProduct.jsx

@@ -54,7 +54,7 @@ const TechProductDescFrom = Form.create()(React.createClass({
                         keyTechnology: values.keyTechnology,
                         competitiveEdge: values.competitiveEdge,
                         conditionEffect: values.conditionEffect,
-                        accountUrl:this.state.accountUrl
+                        accountUrl: this.state.accountUrl
                     }
                 }).done(function (data) {
                     if (!data.error.length) {
@@ -236,7 +236,12 @@ const TechProductDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.accountUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 12 - 2
js/component/account/set/hrSituation.jsx

@@ -452,7 +452,12 @@ const HrSituationDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.socialSecurityUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);
@@ -473,7 +478,12 @@ const HrSituationDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.rosterUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 1 - 0
js/component/login/login.less

@@ -5,6 +5,7 @@
     margin: 0 auto;
     position: relative;
     background-image: url(../../../image/bg.jpg);
+    background-size: 100%;
     .login-header {
         background: #fff;
         box-shadow: 0 2px 6px 0px #ccc;

+ 15 - 5
js/component/manageCenter/servicesManage/highTech/HighTechApply.jsx

@@ -1,7 +1,7 @@
 import React from 'react';
 import { Icon, InputNumber, Form, Button, Input, Radio, Select, Spin, Table, DatePicker, message, Cascader, Modal } from 'antd';
 import { techFieldList, provinceArr, cognizanceStateList } from '../../../dataDic.js';
-import { getTime, getCognizanceState } from '../../../tools.js';
+import { getTime, getCognizanceState, companySearch } from '../../../tools.js';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import moment from 'moment';
@@ -227,9 +227,11 @@ const CognizanceDescFrom = Form.create()(React.createClass({
                         </div>
                     </div>
                     <FormItem style={{ width: '50%' }}
-                        {...formItemLayout}
+                        labelCol={{ span: 0 }}
+                        wrapperCol={{ span: 24 }}
                         label="技术领域"
                     >
+                        <span className="item-title">技术领域: </span>
                         {getFieldDecorator('technicalField', {
                             rules: [{ type: 'array', required: true, message: '此项为必填项!' }],
                             initialValue: [Number(theData.technicalField1), Number(theData.technicalField2), Number(theData.technicalField3)]
@@ -310,8 +312,8 @@ const CognizanceDescFrom = Form.create()(React.createClass({
                             initialValue: theData.accident
                         })(
                             <Radio.Group>
-                                <Radio value="0">否</Radio>
-                                <Radio value="1">是</Radio>
+                                <Radio value={0}>否</Radio>
+                                <Radio value={1}>是</Radio>
                             </Radio.Group>
                             )}
                     </FormItem>
@@ -546,7 +548,11 @@ const CognizanceAdd = React.createClass({
                     <div className="clearfix" style={{ marginBottom: '10px' }}>
                         <div className="half-item">
                             <span>选择公司:  </span>
-                            <Select placeholder="请选择公司" style={{ width: 200 }}
+                            <Select
+                                placeholder="请选择公司"
+                                style={{ width: 200 }}
+                                showSearch
+                                filterOption={companySearch}
                                 onSelect={(e, n) => { this.state.uid = e; this.getContactsList(e); }}>
                                 {this.props.companyOption}
                             </Select>
@@ -855,12 +861,16 @@ const Cognizance = React.createClass({
                     <Select placeholder="选择省份"
                         style={{ width: 200 }}
                         value={this.state.province}
+                        showSearch
+                        filterOption={companySearch}
                         onChange={(e) => { this.setState({ province: e }) }}>
                         {this.state.provinceOption}
                     </Select>
                     <Select placeholder="选择公司"
                         style={{ width: 200 }}
                         value={this.state.unitName}
+                        showSearch
+                        filterOption={companySearch}
                         onChange={(e) => { this.setState({ unitName: e }) }}>
                         {this.state.companyOption}
                     </Select>

+ 6 - 1
js/component/manageCenter/servicesManage/highTech/fosterDesc/achievement.jsx

@@ -164,7 +164,12 @@ const AchievementDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.enclosureUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 21 - 9
js/component/manageCenter/servicesManage/highTech/fosterDesc/activity.jsx

@@ -94,14 +94,14 @@ const ActivityDesc = React.createClass({
     },
     componentWillReceiveProps(nextProps) {
         this.state.visible = nextProps.showDesc;
-        if (nextProps.data) {
+        if (!this.props.showDesc && nextProps.showDesc) {
             this.state.activityName = nextProps.data.activityName;
             this.state.activityNumber = nextProps.data.activityNumber;
             this.state.startDateFormattedDate = nextProps.data.startDateFormattedDate;
             this.state.endDateFormattedDate = nextProps.data.endDateFormattedDate;
             this.state.techField = nextProps.data.techField;
             this.state.technicalSource = nextProps.data.technicalSource;
-            this.state.targetKeys = nextProps.data.intellectualPropertyNumber;
+            this.state.targetKeys = nextProps.data.intellectualPropertyNumber || [];
             this.state.budget = nextProps.data.budget;
             this.state.firstYearExpenditure = nextProps.data.firstYearExpenditure;
             this.state.secondYearExpenditure = nextProps.data.secondYearExpenditure;
@@ -109,7 +109,9 @@ const ActivityDesc = React.createClass({
             this.state.implement = nextProps.data.implement;
             this.state.technologyInnovation = nextProps.data.technologyInnovation;
             this.state.achievement = nextProps.data.achievement;
-            this.state.projectMode = nextProps.data.projectMode;
+            this.state.projectMode = nextProps.data.projectMode ? String(nextProps.data.projectMode) : undefined;
+            this.state.proofUrl = nextProps.data.proofUrl;
+            this.state.proofDownloadFileName = nextProps.data.proofDownloadFileName;
             this.state.mockData = nextProps.data.mockData;
         };
     },
@@ -160,7 +162,7 @@ const ActivityDesc = React.createClass({
                                 options={techFieldList}
                                 value={this.state.techField}
                                 onChange={(value, selectedOptions) => { this.setState({ techField: value }); console.log(value) }}
-                                placeholder="Please select"
+                                placeholder="选择技术领域"
                                 showSearch
                             />,
                         </div>
@@ -265,21 +267,27 @@ const ActivityDesc = React.createClass({
                             placeholder='请选择立项类型'
                             value={this.state.projectMode}
                             onChange={(e) => { this.setState({ projectMode: e }); }}>
-                            <Select.Option value='0'>内部立项</Select.Option>
-                            <Select.Option value='1'>外部立项</Select.Option>
+                            <Select.Option value='1'>内部立项</Select.Option>
+                            <Select.Option value='2'>外部立项</Select.Option>
                         </Select>
                         <div style={{ width: '50%' }}>
                             <Upload
                                 name="ratepay"
                                 action={globalConfig.context + "/techservice/cognizance/upload"}
-                                data={{ 'sign': this.props.year + 'proof' }}
+                                data={{ 'sign': 'proof' }}
                                 beforeUpload={beforeUploadFile}
+                                showUploadList={false}
                                 onChange={(info) => {
                                     if (info.file.status !== 'uploading') {
                                         console.log(info.file, info.fileList);
                                     }
                                     if (info.file.status === 'done') {
-                                        message.success(`${info.file.name} 文件上传成功!`);
+                                        if (!info.file.response.error.length) {
+                                            message.success(`${info.file.name} 文件上传成功!`);
+                                        } else {
+                                            message.warning(info.file.response.error[0].message);
+                                            return;
+                                        };
                                         this.state.proofUrl = info.file.response.data;
                                     } else if (info.file.status === 'error') {
                                         message.error(`${info.file.name} 文件上传失败。`);
@@ -288,6 +296,7 @@ const ActivityDesc = React.createClass({
                             >
                                 <Button><Icon type="upload" /> 上传立项证明材料 </Button>
                             </Upload>
+                            <p>{this.state.proofUrl ? <a onClick={downloadFile.bind(null, this.state.proofUrl, this.state.proofDownloadFileName)}>{this.state.proofDownloadFileName}</a> : <span>未上传!</span>}</p>
                         </div>
                     </Modal>
                 </div>
@@ -387,7 +396,10 @@ const Activity = React.createClass({
                     signDate: thisdata.signDate,
                     sortNumber: thisdata.sortNumber,
                     startDateFormattedDate: thisdata.startDateFormattedDate,
-                    endDateFormattedDate: thisdata.endDateFormattedDate
+                    endDateFormattedDate: thisdata.endDateFormattedDate,
+                    projectMode: thisdata.projectMode,
+                    proofUrl: thisdata.proofUrl,
+                    proofDownloadFileName: thisdata.proofDownloadFileName
                 });
             };
             this.state.pagination.current = data.data.pageNo;

+ 28 - 19
js/component/manageCenter/servicesManage/highTech/fosterDesc/activityCostList.jsx

@@ -1,7 +1,7 @@
 import React from 'react';
 import { Icon, Form, Upload, Button, Input, Spin, Table, message, Select, Modal, DatePicker, InputNumber } from 'antd';
 import './activityCostList.less';
-import { beforeUploadFile } from '../../../../tools.js';
+import { beforeUploadFile, downloadFile } from '../../../../tools.js';
 import moment from 'moment';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
@@ -53,7 +53,7 @@ const ActivityDescFrom = Form.create()(React.createClass({
                     data: {
                         id: this.props.data.id,
                         aid: this.state.aid,
-                        uid:this.props.uid,
+                        uid: this.props.uid,
                         activityNumber: this.state.activityNumber,
 
                         internalLaborCost: values.internalLaborCost,
@@ -69,7 +69,7 @@ const ActivityDescFrom = Form.create()(React.createClass({
                         enterpriseFiller: values.enterpriseFiller,
                         signDateFormattedDate: values.signDate.format('YYYY-MM-DD'),
                         sortNumber: values.sortNumber,
-                        accountUrl:this.state.accountUrl
+                        accountUrl: this.state.accountUrl
                     }
                 }).done(function (data) {
                     if (!data.error.length) {
@@ -265,26 +265,33 @@ const ActivityDescFrom = Form.create()(React.createClass({
                             )}
                     </FormItem>
                 </div>
-                <div style={{ marginTop:'20px',width: '50%' }}>
+                <div style={{ width: '50%', marginTop: '20px' }}>
                     <Upload
                         name="ratepay"
                         action={globalConfig.context + "/techservice/cognizance/upload"}
-                        data={{ 'sign': this.props.year + 'proof' }}
+                        data={{ 'sign': 'activity_cost_account' }}
                         beforeUpload={beforeUploadFile}
+                        showUploadList={false}
                         onChange={(info) => {
                             if (info.file.status !== 'uploading') {
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.accountUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);
                             }
                         }}
                     >
-                        <Button><Icon type="upload" /> 上传台账 </Button>
+                        <Button><Icon type="upload" /> 上传研发费用台账 </Button>
                     </Upload>
+                    <p>{theData.accountUrl ? <a onClick={downloadFile.bind(null, theData.accountUrl, theData.accountDownloadFileName)}>{theData.accountDownloadFileName}</a> : <span>未上传!</span>}</p>
                 </div>
                 <FormItem style={{ marginTop: '20px' }}>
                     <Button className="set-submit" type="primary" htmlType="submit">保存</Button>
@@ -331,15 +338,15 @@ const ActivityDesc = React.createClass({
         return (
             <div className="patent-addNew">
                 <Spin spinning={this.state.loading} className='spin-box'>
-                    <Modal title="企业年度研究开发费用结构明细" visible={this.state.visible}
+                    <Modal title="企业研究开发费用结构明细" visible={this.state.visible}
                         onOk={this.handleOk} onCancel={this.handleCancel}
                         width='800px'
                         footer=''
                     >
-                        <ActivityDescFrom 
-                        uid={this.props.uid}
-                        data={this.props.data} 
-                        activityNumberList={this.props.activityNumberList}
+                        <ActivityDescFrom
+                            uid={this.props.uid}
+                            data={this.props.data}
+                            activityNumberList={this.props.activityNumberList}
                             spinState={this.spinChange} closeModal={this.handleCancel} />
                     </Modal>
                 </Spin>
@@ -362,7 +369,7 @@ const Activity = React.createClass({
             data: {
                 pageNo: pageNo || 1,
                 pageSize: this.state.pagination.pageSize,
-                uid:this.props.data.uid,
+                uid: this.props.data.uid,
                 activityNumber: this.state.activityNumber,
                 startDate: this.state.startDateFormattedDate,
                 endDate: this.state.endDateFormattedDate
@@ -372,8 +379,8 @@ const Activity = React.createClass({
             dataType: "json",
             crossDomain: false,
             url: globalConfig.context + "/api/admin/activityNumber",
-            data:{
-                uid:this.props.data.uid
+            data: {
+                uid: this.props.data.uid
             }
         })).done((data1, data2) => {
             let data = data1[0];
@@ -425,7 +432,9 @@ const Activity = React.createClass({
                     sortNumber: thisdata.sortNumber,
 
                     startDateFormattedDate: thisdata.startDateFormattedDate,
-                    endDateFormattedDate: thisdata.endDateFormattedDate
+                    endDateFormattedDate: thisdata.endDateFormattedDate,
+                    accountDownloadFileName: thisdata.accountDownloadFileName,
+                    accountUrl: thisdata.accountUrl
                 });
             };
             this.state.activityNumberList = activityNumber.data;
@@ -593,7 +602,7 @@ const Activity = React.createClass({
         return (
             <div className="user-content" >
                 <div className="content-title">
-                    <span>企业研究开发活动费用详情表</span>
+                    <span>企业研究开发费用结构明细</span>
                 </div>
                 <div className="user-search">
                     <Input placeholder="研发活动编号" value={this.state.activityNumber}
@@ -625,9 +634,9 @@ const Activity = React.createClass({
                             onRowClick={this.tableRowClick} />
                     </Spin>
                 </div>
-                <ActivityDesc 
+                <ActivityDesc
                     uid={this.props.data.uid}
-                data={this.state.RowData}
+                    data={this.state.RowData}
                     activityNumberList={this.state.activityNumberList}
                     showDesc={this.state.showDesc} closeDesc={this.closeDesc} />
             </div >

+ 6 - 1
js/component/manageCenter/servicesManage/highTech/fosterDesc/finance.jsx

@@ -221,7 +221,12 @@ const FinanceDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.financeUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 6 - 1
js/component/manageCenter/servicesManage/highTech/fosterDesc/honorList.jsx

@@ -101,7 +101,12 @@ const HonorListDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.enclosureUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 12 - 2
js/component/manageCenter/servicesManage/highTech/fosterDesc/hrSituation.jsx

@@ -443,7 +443,12 @@ const HrSituationDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.socialSecurityUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);
@@ -464,7 +469,12 @@ const HrSituationDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.rosterUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 8 - 3
js/component/manageCenter/servicesManage/highTech/fosterDesc/intellectualDesc.jsx

@@ -1,5 +1,5 @@
 import React from 'react';
-import { Icon, Modal, Button, Form, message, Input, Spin, Select, DatePicker,Upload } from 'antd';
+import { Icon, Modal, Button, Form, message, Input, Spin, Select, DatePicker, Upload } from 'antd';
 import { intellectualGetList, catagoryList } from '../../../../dataDic.js';
 import { beforeUploadFile } from '../../../../tools.js';
 import ajax from 'jquery/src/ajax/xhr.js'
@@ -39,7 +39,7 @@ const IntellectualDescFrom = Form.create()(React.createClass({
                     url: globalConfig.context + "/api/admin/intellectual",
                     data: {
                         id: this.props.data.id,
-                        uid:this.props.uid,
+                        uid: this.props.uid,
                         intellectualPropertyNumber: values.intellectualPropertyNumber,
                         intellectualPropertyName: values.intellectualPropertyName,
                         catagory: values.catagory,
@@ -175,7 +175,12 @@ const IntellectualDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.propertyRightUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 12 - 2
js/component/manageCenter/servicesManage/highTech/fosterDesc/orgTechCenter.jsx

@@ -113,7 +113,12 @@ const CenterListDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.protocolUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);
@@ -445,7 +450,12 @@ const CenterList = React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.systemUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 6 - 1
js/component/manageCenter/servicesManage/highTech/fosterDesc/ratepay.jsx

@@ -197,7 +197,12 @@ const RatepayDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.ratepayUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 6 - 1
js/component/manageCenter/servicesManage/highTech/fosterDesc/techProduct.jsx

@@ -237,7 +237,12 @@ const TechProductDescFrom = Form.create()(React.createClass({
                                 console.log(info.file, info.fileList);
                             }
                             if (info.file.status === 'done') {
-                                message.success(`${info.file.name} 文件上传成功!`);
+                                if (!info.file.response.error.length) {
+                                    message.success(`${info.file.name} 文件上传成功!`);
+                                } else {
+                                    message.warning(info.file.response.error[0].message);
+                                    return;
+                                };
                                 this.state.accountUrl = info.file.response.data;
                             } else if (info.file.status === 'error') {
                                 message.error(`${info.file.name} 文件上传失败。`);

+ 17 - 5
js/component/manageCenter/servicesManage/highTech/highTechFoster.jsx

@@ -1,7 +1,7 @@
 import React from 'react';
 import { Icon, Button, Input, Select, Spin, Table, DatePicker, message, Cascader } from 'antd';
 import { techFieldList, provinceArr } from '../../../dataDic.js';
-import { getTime, getPatentState } from '../../../tools.js';
+import { getTime, getPatentState, companySearch } from '../../../tools.js';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import './highTechFoster.less';
@@ -122,8 +122,6 @@ const Patent = React.createClass({
             authorOption: [],
             fosterDescDisplay: 'none',
             fosterDisplay: 'block',
-            province: '',
-            unitName: '',
             data: [],
             loading: false,
             pagination: {
@@ -218,8 +216,22 @@ const Patent = React.createClass({
                         <span>高企认定培育</span>
                     </div>
                     <div className="foster-query">
-                        <Select placeholder="选择省份" style={{ width: 200 }} onChange={(e) => { this.state.province = e }}>{this.state.provinceOption}</Select>
-                        <Select placeholder="选择公司" style={{ width: 200 }} onChange={(e) => { this.state.unitName = e }}>{this.state.companyOption}</Select>
+                        <Select placeholder="选择省份"
+                            style={{ width: 200 }}
+                            value={this.state.province}
+                            showSearch
+                            filterOption={companySearch}
+                            onChange={(e) => { this.setState({ province: e }) }}>
+                            {this.state.provinceOption}
+                        </Select>
+                        <Select placeholder="选择公司"
+                            style={{ width: 200 }}
+                            value={this.state.unitName}
+                            showSearch
+                            filterOption={companySearch}
+                            onChange={(e) => { this.setState({ unitName: e }) }}>
+                            {this.state.companyOption}
+                        </Select>
                         <Button type="primary" onClick={this.search}>搜索</Button>
                         <Button onClick={this.reset}>重置</Button>
                     </div>

+ 10 - 4
js/component/manageCenter/servicesManage/patent/applyFee.jsx

@@ -1,7 +1,7 @@
 import React from 'react';
 import { Icon, Button, Select, Spin, Table, message, DatePicker } from 'antd';
 import { provinceArr } from '../../../dataDic.js';
-import { getTime, getPatentType, getPatentState } from '../../../tools.js';
+import { getTime, getPatentType, getPatentState,companySearch } from '../../../tools.js';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import './comprehensive.less';
@@ -200,8 +200,8 @@ const applyFee = React.createClass({
         this.loadData();
     },
     exportApply() {
-        window.open(globalConfig.context + "/techservice/patent/exportApplicationFee?locationProvince=" 
-        + this.state.province + "&patentApplicationDate=" + this.state.searchData);
+        window.open(globalConfig.context + "/techservice/patent/exportApplicationFee?locationProvince="
+            + this.state.province + "&patentApplicationDate=" + this.state.searchData);
     },
     render() {
         const { MonthPicker, RangePicker } = DatePicker;
@@ -211,7 +211,13 @@ const applyFee = React.createClass({
                     <span>专利申请费用管理</span>
                 </div>
                 <div className="patent-query">
-                    <Select placeholder="选择省份" style={{ width: 200 }} onChange={(e) => { this.state.province = e }}>{this.state.provinceOption}</Select>
+                    <Select placeholder="选择省份"
+                        style={{ width: 200 }}
+                        showSearch
+                        filterOption={companySearch}
+                        onChange={(e) => { this.state.province = e }}>
+                        {this.state.provinceOption}
+                    </Select>
                     <span>申请日:<RangePicker onChange={this.searchAuthorizedDate} /></span>
                     <span>
                         <Button type="primary" onClick={this.search}>搜索</Button>

+ 9 - 5
js/component/manageCenter/servicesManage/patent/clientInputPatent.jsx

@@ -2,6 +2,7 @@ import React from 'react';
 import { Icon, Modal, Button, Form, message, Input, Spin, Select, DatePicker } from 'antd';
 import './comprehensive.less';
 import { patentGetList, patentTypeList } from '../../../dataDic.js';
+import { companySearch} from '../../../tools.js';
 import ajax from 'jquery/src/ajax/xhr.js'
 import $ from 'jquery/src/ajax';
 
@@ -11,7 +12,7 @@ const PatentAddFrom = Form.create()(React.createClass({
             loading: false,
             patentGetOption: [],
             patentTypeOption: [],
-            companyOption:[]
+            companyOption: []
         };
     },
     getCompanyList() {
@@ -65,7 +66,7 @@ const PatentAddFrom = Form.create()(React.createClass({
                     crossDomain: false,
                     url: globalConfig.context + "/techservice/patent/managerInputPatent",
                     data: {
-                        "uid":this.state.companyId,
+                        "uid": this.state.companyId,
                         "patentNumber": values.patentNumber,
                         "patentName": values.patentName,
                         "patentCatagory": this.state.patentCatagory,
@@ -112,7 +113,10 @@ const PatentAddFrom = Form.create()(React.createClass({
                     {getFieldDecorator('companyId', {
                         rules: [{ required: true, message: '请选择,公司不能为空!' }]
                     })(
-                        <Select placeholder="请选择公司" style={{ width: 200 }}
+                        <Select placeholder="请选择公司"
+                            showSearch
+                            filterOption={companySearch}
+                            style={{ width: 200 }}
                             onChange={(e) => { this.state.companyId = e; }}>
                             {this.state.companyOption}
                         </Select>
@@ -191,8 +195,8 @@ const PatentAddFrom = Form.create()(React.createClass({
                     {getFieldDecorator('authorizationDate', {
                         rules: [{ required: true, message: '请选择,授权日期不能为空!' }]
                     })(
-                        <DatePicker style={{ width: 200 }} 
-                        onChange={(data,dataString)=>{ this.state.authorizationDate = dataString}}/>
+                        <DatePicker style={{ width: 200 }}
+                            onChange={(data, dataString) => { this.state.authorizationDate = dataString }} />
                         )}
                 </FormItem>
                 <FormItem>

+ 10 - 12
js/component/manageCenter/servicesManage/patent/comPatentAdd.jsx

@@ -3,7 +3,7 @@ import { Icon, Modal, Button, Form, Upload, message, Input, Spin, Checkbox, Sele
 import './comprehensive.less';
 import ajax from 'jquery/src/ajax/xhr.js'
 import $ from 'jquery/src/ajax';
-import { getBase64, beforeUpload } from '../../../tools.js';
+import { getBase64, beforeUpload ,companySearch} from '../../../tools.js';
 
 class Avatar extends React.Component {
     constructor(props) {
@@ -13,7 +13,7 @@ class Avatar extends React.Component {
         }
     }
     handleChange(info) {
-        if ( !this.props.oid || this.props.oid === "") {
+        if (!this.props.oid || this.props.oid === "") {
             message.warning('请先选择公司!');
             return;
         };
@@ -87,7 +87,7 @@ const PatentAddFrom = Form.create()(React.createClass({
     },
     handleSubmit(e) {
         e.preventDefault();
-        if ( !this.state.companyName || this.state.companyName === "") {
+        if (!this.state.companyName || this.state.companyName === "") {
             message.warning('请先选择公司!');
             return;
         };
@@ -100,7 +100,7 @@ const PatentAddFrom = Form.create()(React.createClass({
                     crossDomain: false,
                     url: globalConfig.context + "/techservice/patent/manageApplyPatent",
                     data: {
-                        'uid':this.state.companyName,
+                        'uid': this.state.companyName,
                         'firstInventorIdNumber': values.firstInventorID,
                         'firstInventorName': values.firstInventorName,
                         'patentDes': values.intro,
@@ -159,13 +159,11 @@ const PatentAddFrom = Form.create()(React.createClass({
         const _me = this;
         return (
             <Form horizontal onSubmit={this.handleSubmit} className="person-form">
-                <Select placeholder="选择公司" 
-                filterOption={(input, option) => { 
-                    this.setState({companyId : option.key});
-                    option.props.value.indexOf(input) >= 0;
-                }}
-                onChange={(e)=>{ this.state.companyName = e;}}
-                showSearch={true} style={{ width: 200 }} >{this.state.companyOption}</Select>
+                <Select placeholder="选择公司"
+                    showSearch
+                    filterOption={companySearch}
+                    onChange={(e) => { this.state.companyName = e; }}
+                    showSearch={true} style={{ width: 200 }} >{this.state.companyOption}</Select>
                 <FormItem
                     labelCol={{ span: 24 }}
                     wrapperCol={{ span: 18 }}
@@ -230,7 +228,7 @@ const PatentAddFrom = Form.create()(React.createClass({
                     {getFieldDecorator('avatar')(
                         <Avatar urlData={this.avatarUrl} name='patent_prory_statement' oid={this.state.companyName} />
                     )}
-                    <span>请上传专利代理委托书</span><a onClick={() => { window.open(globalConfig.context + "/techservice/patent/downloadTemplate") }}>模板下载</a>
+                    <span>请上传专利代理委托书</span><a onClick={() => { window.open(globalConfig.context + "/open/downloadTemplateFile?sign=patent_prory_statement") }}>模板下载</a>
                 </FormItem>
                 <FormItem>
                     <Button className="set-submit" type="primary" htmlType="submit">保存</Button>

+ 55 - 18
js/component/manageCenter/servicesManage/patent/comprehensive.jsx

@@ -1,13 +1,12 @@
 import React from 'react';
-import { Icon, Button, Input, Select, Spin, Table, Switch, DatePicker, message } from 'antd';
+import { Icon, Button, Input, Select, Spin, Table, Switch, DatePicker, message, Upload } from 'antd';
 import { patentTypeList, patentStateList, provinceArr } from '../../../dataDic.js';
-import { getTime, getPatentState } from '../../../tools.js';
+import { getTime, getPatentState, beforeUploadFile, companySearch } from '../../../tools.js';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import './comprehensive.less';
 import PatentAdd from './comPatentAdd.jsx';
 import PatentDesc from './comPatentDesc.jsx';
-import ClientInputPatent from './clientInputPatent.jsx';
 
 const Patent = React.createClass({
     loadData(pageNo) {
@@ -63,7 +62,7 @@ const Patent = React.createClass({
                         startTime: thisdata.patentApplicationDate,
                         endTime: thisdata.authorizedDate,
                         orgCode: thisdata.orgCode,
-                        province:thisdata.locationProvince,
+                        province: thisdata.locationProvince,
                         companyAddress: thisdata.locationProvince || thisdata.locationCity || thisdata.locationArea ? thisdata.locationProvince + '/' + thisdata.locationCity + '/' + thisdata.locationArea : '',
                         companyContacts: thisdata.contacts, //联系人
                         firstInventorName: thisdata.firstInventorName,
@@ -272,19 +271,19 @@ const Patent = React.createClass({
         this.loadData();
     },
     reset() {
-        this.state.number = '';
-        this.state.patentNumber = '';
-        this.state.province = '';
-        this.state.unitName = '';
-        this.state.patentType = '';
-        this.state.patentName = '';
-        this.state.patentState = '';
+        this.state.number = undefined;
+        this.state.patentNumber = undefined;
+        this.state.province = undefined;
+        this.state.unitName = undefined;
+        this.state.patentType = undefined;
+        this.state.patentName = undefined;
+        this.state.patentState = undefined;
         this.state.createTime = [];
         this.state.endTime = [];
         this.state.startTime = [];
-        this.state.author = '';
-        this.state.searchKey = '';
-        this.state.searchValue = '';
+        this.state.author = undefined;
+        this.state.searchKey = undefined;
+        this.state.searchValue = undefined;
         this.loadData();
     },
     exportComposite() {
@@ -340,8 +339,34 @@ const Patent = React.createClass({
             <div className="patent-content" >
                 <div className="content-title">
                     <span>专利综合管理</span>
-                    <PatentAdd closeDesc={this.closeDesc}/>
-                    <ClientInputPatent closeDesc={this.closeDesc}/>
+                    <div className="patent-addNew">
+                        <Upload style={{ float: 'right' }}
+                            name="ratepay"
+                            showUploadList={false}
+                            action={globalConfig.context + "/api/admin/uploadTemplate"}
+                            data={{ 'sign': 'patent_prory_statement' }}
+                            beforeUpload={beforeUploadFile}
+                            onChange={(info) => {
+                                if (info.file.status === 'done') {
+                                    if (!info.file.response.error.length) {
+                                        if (!info.file.response.error.length) {
+                                            message.success(`${info.file.name} 文件上传成功!`);
+                                        } else {
+                                            message.warning(info.file.response.error[0].message);
+                                            return;
+                                        };
+                                    } else {
+                                        message.warning(info.file.response.error[0].message);
+                                    };
+                                } else if (info.file.status === 'error') {
+                                    message.error(`${info.file.name} 文件上传失败。`);
+                                }
+                            }}
+                        >
+                            <Button>上传专利代理委托书模板 <Icon type="upload" /></Button>
+                        </Upload>
+                    </div>
+                    <PatentAdd closeDesc={this.closeDesc} />
                 </div>
                 <div className="patent-query">
                     <Select placeholder="请选择" value={this.state.searchKey} style={{ width: 200 }} onChange={(e) => { this.setState({ searchKey: e, searchValue: '' }); }}>
@@ -361,9 +386,21 @@ const Patent = React.createClass({
                             <span>申请日:</span><RangePicker onChange={this.searchstartTime} />
                         </p>
                         <div>
-                            <Select placeholder="选择省份" style={{ width: 200 }} onChange={(e) => { this.state.province = e }}>{this.state.provinceOption}</Select>
+                            <Select placeholder="选择省份"
+                                showSearch
+                                filterOption={companySearch}
+                                style={{ width: 200 }}
+                                onChange={(e) => { this.state.province = e }}>
+                                {this.state.provinceOption}
+                            </Select>
                             <Select placeholder="选择撰写人" style={{ width: 200 }} onChange={(e) => { this.state.author = e }}>{this.state.authorOption}</Select>
-                            <Select placeholder="选择公司" style={{ width: 200 }} onChange={(e) => { this.state.companyName = e }}>{this.state.companyOption}</Select>
+                            <Select placeholder="选择公司"
+                                style={{ width: 200 }}
+                                showSearch
+                                filterOption={companySearch}
+                                onChange={(e) => { this.state.companyName = e }}>
+                                {this.state.companyOption}
+                            </Select>
                         </div>
                     </div>
                 </div>

+ 8 - 2
js/component/manageCenter/servicesManage/patent/payment.jsx

@@ -1,7 +1,7 @@
 import React from 'react';
 import { Icon, Button, Select, Spin, Table, message } from 'antd';
 import { provinceArr } from '../../../dataDic.js';
-import { getTime, getPatentType, getPatentState } from '../../../tools.js';
+import { getTime, getPatentType, getPatentState, companySearch } from '../../../tools.js';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import './comprehensive.less';
@@ -171,7 +171,13 @@ const Payment = React.createClass({
                     <span>代缴年登印费专利管理</span>
                 </div>
                 <div className="patent-query">
-                    <Select placeholder="选择省份" style={{ width: 200 }} onChange={(e) => { this.state.province = e } }>{this.state.provinceOption}</Select>
+                    <Select placeholder="选择省份"
+                        style={{ width: 200 }}
+                        showSearch
+                        filterOption={companySearch}
+                        onChange={(e) => { this.state.province = e }}>
+                        {this.state.provinceOption}
+                    </Select>
                     <Button type="primary" onClick={this.search}>搜索</Button>
                     <Button onClick={this.reset}>重置</Button>
                     <Button type="ghost" onClick={this.exportPending}>导出</Button>

+ 4 - 1
js/component/sign/groupAccount.jsx

@@ -127,6 +127,9 @@ const Group = Form.create()(React.createClass({
         }
         callback();
     },
+    reloadVCode(e) {
+        e.target.src = globalConfig.context + '/open/getVCode?t=' + Math.random();
+    },
     render() {
         const { getFieldDecorator } = this.props.form;
         const formItemLayout = {
@@ -203,7 +206,7 @@ const Group = Form.create()(React.createClass({
                             </Col>
                             <Col span={8}>
                                 <div className="acc-getVcode">
-                                    <img id="VCode" src={globalConfig.context + '/open/getVCode'} alt="" onClick={function (e) { e.target.src = globalConfig.context + '/open/getVcode' + Math.random(); }} />
+                                    <img id="VCode" src={globalConfig.context + '/open/getVCode'} alt="" onClick={this.reloadVCode} />
                                 </div>
                             </Col>
                         </Row>

+ 6 - 0
js/component/tools.js

@@ -262,5 +262,11 @@ module.exports = {
             });
             return theType;
         }
+    },
+    downloadFile: function (path, fileName) {
+        window.open(globalConfig.context + '/open/downloadFile?path=' + path + '&fileName=' + fileName)
+    },
+    companySearch(input, option) {
+        return option.props.children.indexOf(input) >= 0
     }
 }

+ 1 - 1
js/user/signIn.js

@@ -14,7 +14,7 @@ const TabPane = Tabs.TabPane;
 ReactDOM.render(
     <div className="wrap">
         <LoginTop />
-        <Tabs type="card" defaultActiveKey="1" className="accounnt-form">
+        <Tabs type="card" defaultActiveKey="1" className="signIn-form">
             <TabPane tab="个人注册" key="1">
                 <Account />
             </TabPane>