|
@@ -6,7 +6,7 @@ import moment from 'moment';
|
|
|
import TechAchievementDesc from '@/manageCenter/achievement/crmAchievement.jsx';
|
|
|
import { citySelect, provinceList ,areaSelect} from '@/NewDicProvinceList';
|
|
|
import { socialAttribute, industry, auditStatusL, lvl, currentMember ,slcRedit,dataGrade} from '@/dataDic.js';
|
|
|
-import { getSocialAttribute, beforeUploadFile,splitUrl ,getSlcRedit,getDataGrade,getAchievementCategory,getTechAuditStatus,getboutique} from '@/tools.js';
|
|
|
+import { getSocialAttribute, beforeUploadFile,splitUrl ,getSlcRedit,getDataGrade,getAchievementCategory,getTechAuditStatus,getboutique,getXiangmoState} from '@/tools.js';
|
|
|
import './customer.less';
|
|
|
const TabPane = Tabs.TabPane;
|
|
|
//图片组件
|
|
@@ -193,6 +193,109 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
});
|
|
|
}.bind(this));
|
|
|
},
|
|
|
+ loadDatac(pageNo, apiUrl) {
|
|
|
+ this.setState({
|
|
|
+ loading: true,
|
|
|
+ });
|
|
|
+ $.ajax({
|
|
|
+ method: "get",
|
|
|
+ dataType: "json",
|
|
|
+ crossDomain: false,
|
|
|
+ url: globalConfig.context +"/api/admin/customers/selectListOrgAnnual",
|
|
|
+ data: {
|
|
|
+// pageNo: pageNo || 1,
|
|
|
+// pageSize: this.state.pagination.pageSize,
|
|
|
+ uid:this.state.uid,
|
|
|
+ },
|
|
|
+ success: function(data) {
|
|
|
+ let theArr = [];
|
|
|
+ if(data.error.length || 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];
|
|
|
+ let diqu=(thisdata.province==null?"":thisdata.province)+(thisdata.city==null?"":"-"+thisdata.city)+(thisdata.area==null?"":"-"+thisdata.area);
|
|
|
+ theArr.push({
|
|
|
+ key: i,
|
|
|
+ id: thisdata.id,//年报ID
|
|
|
+ year:thisdata.year,//年份
|
|
|
+ salesAmount: thisdata.salesAmount,//营销额
|
|
|
+ researchAmount: thisdata.researchAmount,//研发费用
|
|
|
+ assets: thisdata.assets,//总资产
|
|
|
+ aid: thisdata.aid,//录入人
|
|
|
+ });
|
|
|
+ };
|
|
|
+// this.state.pagination.current = data.data.pageNo;
|
|
|
+// this.state.pagination.total = data.data.totalCount;
|
|
|
+ };
|
|
|
+ if(data.data&&data.data.list&&!data.data.list.length){
|
|
|
+ this.state.pagination.current=0
|
|
|
+ this.state.pagination.total=0
|
|
|
+ }
|
|
|
+ this.setState({
|
|
|
+ dataSourcec: theArr,
|
|
|
+// pageNo: pageNo,
|
|
|
+// pagination: this.state.pagination,
|
|
|
+// selectedRowKeys:[]
|
|
|
+ });
|
|
|
+ }.bind(this),
|
|
|
+ }).always(function() {
|
|
|
+ this.setState({
|
|
|
+ loading: false
|
|
|
+ });
|
|
|
+ }.bind(this));
|
|
|
+ },
|
|
|
+ loadDatax(pageNo, apiUrl) {
|
|
|
+ this.setState({
|
|
|
+ loading: true,
|
|
|
+ });
|
|
|
+ $.ajax({
|
|
|
+ method: "get",
|
|
|
+ dataType: "json",
|
|
|
+ crossDomain: false,
|
|
|
+ url: globalConfig.context +"/api/admin/customers/selectListOrgYearProject",
|
|
|
+ data: {
|
|
|
+ uid:this.state.uid,
|
|
|
+ },
|
|
|
+ success: function(data) {
|
|
|
+ let theArr = [];
|
|
|
+ if(data.error.length || 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];
|
|
|
+ let diqu=(thisdata.province==null?"":thisdata.province)+(thisdata.city==null?"":"-"+thisdata.city)+(thisdata.area==null?"":"-"+thisdata.area);
|
|
|
+ theArr.push({
|
|
|
+ key: i,
|
|
|
+ id: thisdata.id,//用户ID
|
|
|
+ projectName:thisdata.projectName,//项目名称
|
|
|
+ year: thisdata.year,//年份
|
|
|
+ status: thisdata.status?thisdata.status.toString():"",//项目状态
|
|
|
+ remark: thisdata.remark,//备注
|
|
|
+ aid: thisdata.aid,//录入人
|
|
|
+ });
|
|
|
+ };
|
|
|
+// this.state.pagination.current = data.data.pageNo;
|
|
|
+// this.state.pagination.total = data.data.totalCount;
|
|
|
+ };
|
|
|
+ if(data.data&&data.data.list&&!data.data.list.length){
|
|
|
+ this.state.pagination.current=0
|
|
|
+ this.state.pagination.total=0
|
|
|
+ }
|
|
|
+ this.setState({
|
|
|
+ dataSourcex: theArr,
|
|
|
+ });
|
|
|
+ }.bind(this),
|
|
|
+ }).always(function() {
|
|
|
+ this.setState({
|
|
|
+ loading: false
|
|
|
+ });
|
|
|
+ }.bind(this));
|
|
|
+ },
|
|
|
getInitialState() {
|
|
|
return {
|
|
|
addressSearch: [],
|
|
@@ -262,9 +365,7 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
}
|
|
|
],
|
|
|
data: [],
|
|
|
- dataman: [],
|
|
|
dataSource: [],
|
|
|
- visitArrList: [],
|
|
|
columnsDate: [
|
|
|
{
|
|
|
title: '编号',
|
|
@@ -306,6 +407,47 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
},
|
|
|
],
|
|
|
dataSourceDate: [],
|
|
|
+ columnsc: [{
|
|
|
+ title: '年份',
|
|
|
+ dataIndex: 'year',
|
|
|
+ key: 'year',
|
|
|
+ }, {
|
|
|
+ title: '营销额(万)',
|
|
|
+ dataIndex: 'salesAmount',
|
|
|
+ key: 'salesAmount',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '总资产(万)',
|
|
|
+ dataIndex: 'assets',
|
|
|
+ key: 'assets'
|
|
|
+ }, {
|
|
|
+ title: '研发费用(万)',
|
|
|
+ dataIndex: 'researchAmount',
|
|
|
+ key: 'researchAmount',
|
|
|
+ }
|
|
|
+ ],
|
|
|
+ dataSourcec: [],
|
|
|
+ columnsx: [{
|
|
|
+ title: '项目名称',
|
|
|
+ dataIndex: 'projectName',
|
|
|
+ key: 'projectName',
|
|
|
+ },{
|
|
|
+ title: '年份',
|
|
|
+ dataIndex: 'year',
|
|
|
+ key: 'year',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '项目状态',
|
|
|
+ dataIndex: 'status',
|
|
|
+ key: 'status',
|
|
|
+ render: text => { return getXiangmoState(text); }
|
|
|
+ }, {
|
|
|
+ title: '备注',
|
|
|
+ dataIndex: 'remark',
|
|
|
+ key: 'remark',
|
|
|
+ }
|
|
|
+ ],
|
|
|
+ dataSourcex: [],
|
|
|
};
|
|
|
},
|
|
|
componentWillMount() {
|
|
@@ -707,6 +849,18 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
})
|
|
|
this.loadDatas();
|
|
|
}
|
|
|
+ if(e == '2') {
|
|
|
+ this.setState({
|
|
|
+ callnub: e,
|
|
|
+ })
|
|
|
+ this.loadDatac();
|
|
|
+ }
|
|
|
+ if(e == '3') {
|
|
|
+ this.setState({
|
|
|
+ callnub: e,
|
|
|
+ })
|
|
|
+ this.loadDatax();
|
|
|
+ }
|
|
|
},
|
|
|
//发布成果
|
|
|
addClick() {
|
|
@@ -999,20 +1153,6 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
</div>
|
|
|
<div style={{fontSize:'18px',marginLeft:'50px',marginTop:'15px',marginBottom:'10px',color:"red",fontWeight:"bold"}}>重要资料</div>
|
|
|
<div className='clearfix' >
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="上年度销售额"
|
|
|
- >
|
|
|
- <Input ref='consul' placeholder="请输入上年度销售额" value={this.state.yearSalesAmount} style={{width:'95%'}}
|
|
|
- onChange={(e) => {this.setState({yearSalesAmount: e.target.value })}} disabled={true}/>万
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="上年度研发费用"
|
|
|
- >
|
|
|
- <Input ref='consul' placeholder="请输入上年度研发费用" value={this.state.lastYearResearchAmount} style={{width:'95%'}}
|
|
|
- onChange={(e) => {this.setState({lastYearResearchAmount: e.target.value })}} disabled={true}/>万
|
|
|
- </FormItem>
|
|
|
<FormItem className="half-item"
|
|
|
{...formItemLayout}
|
|
|
label="客户信用等级"
|
|
@@ -1026,14 +1166,6 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
}
|
|
|
</Select>
|
|
|
</FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="上年度总资产情况"
|
|
|
- >
|
|
|
- <Input ref='consul' placeholder="上年度总资产情况" value={this.state.assets} style={{width:'95%'}}
|
|
|
- onChange={(e) => {this.setState({assets: e.target.value })}} disabled={true}/>万
|
|
|
- </FormItem>
|
|
|
-
|
|
|
<div className='clearfix'>
|
|
|
<FormItem
|
|
|
labelCol={{ span:4 }}
|
|
@@ -1056,15 +1188,6 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
<FormItem
|
|
|
labelCol={{ span:4 }}
|
|
|
wrapperCol={{ span: 19 }}
|
|
|
- label="客户已做项目" >
|
|
|
- <Input type="textarea" rows={3} value={this.state.accomplishSituation} placeholder="请按如下格式填写:项目类型+主管部门+申报时间+立项情况+验收情况"
|
|
|
- onChange={(e,pre) => { this.setState({ accomplishSituation: e.target.value })}} disabled={true}/>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- <div className='clearfix'>
|
|
|
- <FormItem
|
|
|
- labelCol={{ span:4 }}
|
|
|
- wrapperCol={{ span: 19 }}
|
|
|
label="高企合作情况" >
|
|
|
<Input type="textarea" rows={3} value={this.state.cooperationSituation}
|
|
|
onChange={(e,pre) => { this.setState({ cooperationSituation: e.target.value })}} disabled={true}/>
|
|
@@ -1086,6 +1209,22 @@ const IntentionCustomer = Form.create()(React.createClass({
|
|
|
onRowClick={this.tableRowClickDate} />
|
|
|
</Spin>
|
|
|
</TabPane>
|
|
|
+ <TabPane tab="财务信息" key="2">
|
|
|
+ <Spin spinning={this.state.loading}>
|
|
|
+ <Table columns={this.state.columnsc}
|
|
|
+ dataSource={this.state.dataSourcec}
|
|
|
+ rowSelection={rowSelection}
|
|
|
+ onRowClick={this.tableRowClickDatec} />
|
|
|
+ </Spin>
|
|
|
+ </TabPane>
|
|
|
+ <TabPane tab="项目信息" key="3">
|
|
|
+ <Spin spinning={this.state.loading}>
|
|
|
+ <Table columns={this.state.columnsx}
|
|
|
+ dataSource={this.state.dataSourcex}
|
|
|
+ rowSelection={rowSelection}
|
|
|
+ onRowClick={this.tableRowClickDatex} />
|
|
|
+ </Spin>
|
|
|
+ </TabPane>
|
|
|
</Tabs>
|
|
|
</Modal>
|
|
|
<TechAchievementDesc
|