|
@@ -4,15 +4,14 @@ $(function(){
|
|
|
var colorArr=['#e22e2e','#2542ef','#10d4f1','#f9750b','#0bf964'];
|
|
|
//获取id
|
|
|
var https=window.location.href;
|
|
|
- var indexs = https.indexOf('=');
|
|
|
- var ids=https.substr(indexs+1,https.length);
|
|
|
+ var indexs = https.indexOf('id=');
|
|
|
+ var ids=https.substr(indexs+3,https.length);
|
|
|
//数据获取
|
|
|
function DataList(){
|
|
|
$.ajax({
|
|
|
type:"get",
|
|
|
dataType:'json',
|
|
|
url: globalConfig.context + "/portal/Service/ProjectDetail",
|
|
|
- //url: "http://192.168.1.100:8080/portal/Service/ProjectDetail",
|
|
|
data:{
|
|
|
id:ids
|
|
|
},
|
|
@@ -23,20 +22,23 @@ $(function(){
|
|
|
var specificationList=[]; //服务规格
|
|
|
var promiseLsit=[];
|
|
|
if(data.data.length){
|
|
|
- console.log(theData[0])
|
|
|
describeList.push([
|
|
|
- "<div><p>"+theData[0].introduce+"</p></div>",
|
|
|
+ "<div><p>"+theData[0].introduce!='null'?theData[0].introduce:''+"</p></div>",
|
|
|
].join(','));
|
|
|
dataList.push([
|
|
|
- "<div><p>"+theData[0].valueEffect+"</p></div>",
|
|
|
+ "<div><p>"+theData[0].valueEffect!='null'?theData[0].valueEffect:''+"</p></div>",
|
|
|
].join(','));
|
|
|
- for (var i=0;i<theData[1].length;i++){
|
|
|
- specificationList.push([
|
|
|
- "<div>"+theData[1][i]+"</div>",
|
|
|
- ].join(','));
|
|
|
- };
|
|
|
+ if(theData[1].length){
|
|
|
+ for (var i=0;i<theData[1].length;i++){
|
|
|
+ specificationList.push([
|
|
|
+ "<div>"+theData[1][i]+"</div>",
|
|
|
+ ].join(','));
|
|
|
+ };
|
|
|
+ }else{
|
|
|
+ specificationList=[];
|
|
|
+ }
|
|
|
promiseLsit.push([
|
|
|
- "<div><p>"+theData[0].clientSize+"</p></div>",
|
|
|
+ "<div><p>"+theData[0].clientSize!='null'?theData[0].clientSize:''+"</p></div>",
|
|
|
].join(','));
|
|
|
$('#describe').html(describeList);
|
|
|
$('#data').html(dataList);
|