|
@@ -76,7 +76,7 @@ const Statistics = React.createClass({
|
|
|
method: "get",
|
|
|
dataType: "json",
|
|
|
crossDomain: false,
|
|
|
- url: globalConfig.context + "/api/admin/statistics/info",
|
|
|
+ url: globalConfig.context + "/api/admin/statistics/consultant/info",
|
|
|
data: {
|
|
|
startTime: releaseDate[0],
|
|
|
endTime: releaseDate[1],
|
|
@@ -108,7 +108,7 @@ const Statistics = React.createClass({
|
|
|
method: "get",
|
|
|
dataType: "json",
|
|
|
crossDomain: false,
|
|
|
- url: globalConfig.context + "/api/admin/statistics/lists",
|
|
|
+ url: globalConfig.context + "/api/admin/statistics/consultant/lists",
|
|
|
success: function (data) {
|
|
|
if (data.error && data.error.length === 0) {
|
|
|
this.setState({
|
|
@@ -149,19 +149,20 @@ const Statistics = React.createClass({
|
|
|
|
|
|
render() {
|
|
|
const { status, info, data } = this.state
|
|
|
+ let array = window.adminData.shiroList.split(",");
|
|
|
const list = [
|
|
|
- { color: "#99FFFF", title: "总项目数:", sum: info.signSum, tit: "项目数", number: info.rangeSignSum, url: this.getNewUrl("/admin/customer.html", "companySign") },
|
|
|
- { color: "#FFFFCC", title: "总进行中数:", sum: info.privateSum, tit: "进行中", number: info.rangePrivateSum, url: this.getNewUrl("/admin/customer.html", "companyIntention") },
|
|
|
- { color: "#FFCCCC", title: "总完成数:", sum: info.channelSum, tit: "完成数", number: info.rangeChannelSum, url: this.getNewUrl("/admin/channelList.html", "channelunit") },
|
|
|
- { color: "#99CCFF", title: "总未启动数:", sum: info.publicReleaseSum, tit: "未启动", number: info.rangePublicReleaseSum, url: "" },
|
|
|
- { color: "#99FFCC", title: "总暂停数:", sum: info.followSum, tit: "暂停数", number: info.rangeFollowSum, url: this.getNewUrl("/admin/customer.html", "followUpSummaryOrdinary") },
|
|
|
- { color: "#CC99CC", title: "总公出数:", sum: info.orderSum, tit: "公出数", number: info.rangeOrderSum, url: this.getNewUrl("/admin/order.html", "billing") },
|
|
|
- { color: "#99CCCC", title: "总协单数:", sum: info.receivables, tit: "协单数", number: info.rangeReceivables, url: this.getNewUrl("/admin/order.html", "press") },
|
|
|
+ { color: "#99FFFF", title: "总项目数:", sum: info.projectCount, tit: "项目数", number: info.rangeProjectCount, url: this.getNewUrl("/admin/project.html", "myTaskZxs"), type: '' },
|
|
|
+ { color: "#FFFFCC", title: "总进行中数:", sum: info.inProgress, tit: "进行中", number: info.rangeInProgress, url: this.getNewUrl("/admin/project.html", "myTaskZxs"), type: '1' },
|
|
|
+ { color: "#FFCCCC", title: "总完成数:", sum: info.complete, tit: "完成数", number: info.rangeComplete, url: this.getNewUrl("/admin/project.html", "myTaskZxs"), type: '4' },
|
|
|
+ { color: "#99CCFF", title: "总未启动数:", sum: info.notStarted, tit: "未启动", number: info.rangeNotStarted, url: this.getNewUrl("/admin/project.html", "myTaskZxs"), type: '0' },
|
|
|
+ { color: "#99FFCC", title: "总暂停数:", sum: info.stop, tit: "暂停数", number: info.rangeStop, url: this.getNewUrl("/admin/project.html", "myTaskZxs"), type: '29' },
|
|
|
+ { color: "#CC99CC", title: "总公出数:", sum: info.countPublicRelease, tit: "公出数", number: info.rangeCountPublicRelease, url: '' },
|
|
|
+ { color: "#99CCCC", title: "总协单数:", sum: info.countAssist, tit: "协单数", number: info.rangeCountAssist, url: '' },
|
|
|
{
|
|
|
color: "#FFCC99", title: "待紧急处理事项",
|
|
|
list: [
|
|
|
- { key: "待变更订单:", value: info.changeSum, url: this.getNewUrl("/admin/order.html", "contractChangeYxy") },
|
|
|
- { key: "待成本付款处理:", value: info.projectCheckSum, url: this.getNewUrl("/admin/project.html", "businessManagement") },]
|
|
|
+ { key: "待变更订单:", value: info.countChange, url: this.getNewUrl('/admin/project.html', array.includes("9") ? "contractChangeJsjl" : "contractChangeJsy"), },
|
|
|
+ { key: "待成本付款处理:", value: info.orderPayment, url: '' },]
|
|
|
},
|
|
|
]
|
|
|
const option = {
|
|
@@ -172,7 +173,7 @@ const Statistics = React.createClass({
|
|
|
trigger: 'axis'
|
|
|
},
|
|
|
legend: {
|
|
|
- data: ['签单客户数', '私有客户数', '私有渠道数', '公出企业数', '跟进客户数', '订单数',]
|
|
|
+ data: ['项目数', '进行中数', '未发起数', '完成数', '暂停数', '公出数', '协单数',]
|
|
|
},
|
|
|
grid: {
|
|
|
left: '3%',
|
|
@@ -196,37 +197,42 @@ const Statistics = React.createClass({
|
|
|
yAxis: {
|
|
|
type: 'value'
|
|
|
},
|
|
|
- color: ['#99FFFF', '#cccca3', '#FFCCCC', '#99CCFF', '#99FFCC', '#CC99CC'],
|
|
|
+ color: ['#99FFFF', '#cccca3', '#FFCCCC', '#99CCFF', '#99FFCC', '#CC99CC', '#CC99CC', '#99CCCC'],
|
|
|
series: [
|
|
|
{
|
|
|
- name: '签单客户数',
|
|
|
+ name: '项目数',
|
|
|
type: 'line',
|
|
|
- data: data.signList,
|
|
|
+ data: data.projectCountList,
|
|
|
},
|
|
|
{
|
|
|
- name: '私有客户数',
|
|
|
+ name: '进行中数',
|
|
|
type: 'line',
|
|
|
- data: data.privateList,
|
|
|
+ data: data.inProgressList,
|
|
|
},
|
|
|
{
|
|
|
- name: '私有渠道数',
|
|
|
+ name: '未发起数',
|
|
|
type: 'line',
|
|
|
- data: data.channelList,
|
|
|
+ data: data.notStartedList,
|
|
|
},
|
|
|
{
|
|
|
- name: '公出企业数',
|
|
|
+ name: '完成数',
|
|
|
type: 'line',
|
|
|
- data: data.publicReleaseList,
|
|
|
+ data: data.completeList,
|
|
|
},
|
|
|
{
|
|
|
- name: '跟进客户数',
|
|
|
+ name: '暂停数',
|
|
|
type: 'line',
|
|
|
- data: data.userFollowList,
|
|
|
+ data: data.stopList,
|
|
|
},
|
|
|
{
|
|
|
- name: '订单数',
|
|
|
+ name: '公出数',
|
|
|
type: 'line',
|
|
|
- data: data.orderList,
|
|
|
+ data: data.publicReleaseCountList,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ name: '协单数',
|
|
|
+ type: 'line',
|
|
|
+ data: data.assistCountList,
|
|
|
}
|
|
|
]
|
|
|
}
|
|
@@ -293,7 +299,11 @@ const Statistics = React.createClass({
|
|
|
<div className='plititle'>
|
|
|
<span style={{ fontWeight: item.title == "待紧急处理事项" && "bold" }}>{item.title}</span>
|
|
|
{/* <span className='plisum'>{item.sum}</span> */}
|
|
|
- <a href={globalConfig.context + item.url}>
|
|
|
+ <a href={globalConfig.context + item.url}
|
|
|
+ onClick={() => {
|
|
|
+ localStorage.setItem('typeZxs', item.type);
|
|
|
+ }}
|
|
|
+ >
|
|
|
<span className='plisum'>{item.sum}</span>
|
|
|
</a>
|
|
|
</div>
|
|
@@ -312,7 +322,11 @@ const Statistics = React.createClass({
|
|
|
}
|
|
|
</div>
|
|
|
: <div className='count'>
|
|
|
- <a href={globalConfig.context + item.url}><div className='plinum'>{item.number}</div></a>
|
|
|
+ <a href={globalConfig.context + item.url}
|
|
|
+ onClick={() => {
|
|
|
+ localStorage.setItem('typeZxs', item.type);
|
|
|
+ }}
|
|
|
+ ><div className='plinum'>{item.number}</div></a>
|
|
|
<div className='plitit'>{item.tit}</div>
|
|
|
</div>
|
|
|
}
|