caipin 5 роки тому
батько
коміт
a999a9ee17

+ 35 - 4
app/cloudRouter.js

@@ -5,14 +5,45 @@ var express = require('express');
 var router = express.Router();
 var cloudController=require('./controller/cloudEditionController');
 
+/**
+ * 养护云版
+ */
 router.get('/cloud/curing/edition', function(req, res, next) {
+	
+	
+	
+	//测试服务器
+	//global.CLOUDURL= ="https://yhuat.smartcost.com.cn/cld"; 
+	//正式服务器
+	//global.CLOUDURL= ='https://yhyun.smartcost.com.cn/cld';
+	//本地跑
+	setCloudUrl("http://qa.smartcost.com.cn:2060/cld");
+	
+	
+	
     cloudController.curingEdition(req, res);
 });
-
-router.get('/cloud/test', function(req, res, next) {
-    res.render('ui_alerts');
+/**
+ * 大司空云计价
+ */
+router.get('/cloud/building/edition', function(req, res, next) {
+	
+	//测试服务器
+	//global.CLOUDURL= ="https://yhuat.smartcost.com.cn/cld"; 
+	//正式服务器
+	//global.CLOUDURL= ='https://yhyun.smartcost.com.cn/cld';
+	//本地跑
+	setCloudUrl("http://qa.smartcost.com.cn:6060/cld");
+	
+	cloudController.curingEdition(req, res);
 });
 
+module.exports = router;
 
 
-module.exports = router;
+/**
+ * 设置云版接口地址
+ */
+function setCloudUrl(url){
+	global.CLOUDURL =url; 
+}

+ 2 - 0
app/config/common.config.js

@@ -6,6 +6,8 @@ global.WEB_SITE_GLOBAL='/cloud/';
 global.CRYPTO_KEY='CLDV2_CP';
 
 global.STAFF='';
+//云版接口
+global.CLOUDURL='';
 //global.curingInterfaceConfig={'sort':['latest_login','desc']};
 
 var d = new Date();

+ 2 - 2
app/service/cloudEditionService.js

@@ -7,13 +7,13 @@ const hash=require('../class/hash');
 const urlObj=require("url");
 
 //测试服务器
-var curingUrl ="https://yhuat.smartcost.com.cn/cld"; 
+var curingUrl =global.CLOUDURL; 
 //正式服务器
 //var curingUrl ='https://yhyun.smartcost.com.cn/cld';
 //本地跑
 //var curingUrl ="http://qa.smartcost.com.cn:2060/cld";
 
-var buildUrl = 'https://yun.smartcost.com.cn/cld';
+//var buildUrl = 'https://yun.smartcost.com.cn/cld';
 
 
 

+ 7 - 0
views/cloud/cloudMenu.html

@@ -20,6 +20,13 @@
                         <span class="nav-link-text">养护云造价</span>
                     </a>
                 </li>
+                <li  >
+                    <a href="/cloud/building/edition" title="Marketing Dashboard" data-filter-tags="application intel marketing dashboard">
+                        <span class="nav-link-text">大司空云计价</span>
+                    </a>
+                </li>
+                
+                
 <!--
                 <li class="active" >
                     <a href="/cloud/test" title="Analytics Dashboard" data-filter-tags="application intel analytics dashboard">