Commit 423d1863 authored by 罗超's avatar 罗超

提交URL

parent 8d8042a3
...@@ -6,20 +6,20 @@ export default { ...@@ -6,20 +6,20 @@ export default {
apiurl: '' apiurl: ''
}, },
install(Vue, options) { install(Vue, options) {
Vue.prototype.isOnline = function() { Vue.prototype.isOnline = function () {
return process.env.NODE_ENV !== 'development'; return process.env.NODE_ENV !== 'development';
}, },
//域名管理对象 //域名管理对象
Vue.prototype.domainManager = function() { Vue.prototype.domainManager = function () {
//CRM API //CRM API
let domainUrl = ""; let domainUrl = "";
domainUrl = "http://192.168.10.36:8098"; domainUrl = "http://192.168.10.46:8500";
//domainUrl = "http://localhost:5003"; //domainUrl = "http://localhost:5003";
let locationName = window.location.hostname; let locationName = window.location.hostname;
//旅游ERPApi //旅游ERPApi
let domainPostUrl = "" let domainPostUrl = ""
domainPostUrl = "http://192.168.10.36:8083"; //domainPostUrl = "http://192.168.10.36:8083";
//domainPostUrl = "http://192.168.10.46"; domainPostUrl = "http://192.168.10.46";
if (this.isOnline()) { if (this.isOnline()) {
if (window.location.host.indexOf('fcrmyx.oytour.com') != -1) { if (window.location.host.indexOf('fcrmyx.oytour.com') != -1) {
domainUrl = "http://crm.oytour.com" domainUrl = "http://crm.oytour.com"
...@@ -48,7 +48,7 @@ export default { ...@@ -48,7 +48,7 @@ export default {
}, },
//消息成功提示 //消息成功提示
Vue.prototype.Success = function(msg) { Vue.prototype.Success = function (msg) {
this.$message({ this.$message({
message: msg, message: msg,
duration: 2000, duration: 2000,
...@@ -56,7 +56,7 @@ export default { ...@@ -56,7 +56,7 @@ export default {
}); });
}, },
//错误提示 //错误提示
Vue.prototype.Error = function(msg) { Vue.prototype.Error = function (msg) {
this.$message({ this.$message({
message: msg, message: msg,
duration: 2000, duration: 2000,
...@@ -65,7 +65,7 @@ export default { ...@@ -65,7 +65,7 @@ export default {
}, },
//一般提示 //一般提示
Vue.prototype.Info = function(msg) { Vue.prototype.Info = function (msg) {
this.$message({ this.$message({
message: msg, message: msg,
duration: 2000, duration: 2000,
...@@ -73,7 +73,7 @@ export default { ...@@ -73,7 +73,7 @@ export default {
}); });
}, },
//警告提示 //警告提示
Vue.prototype.Warning = function(msg) { Vue.prototype.Warning = function (msg) {
this.$message({ this.$message({
message: msg, message: msg,
duration: 2000, duration: 2000,
...@@ -81,7 +81,7 @@ export default { ...@@ -81,7 +81,7 @@ export default {
}); });
}, },
//Confirm //Confirm
Vue.prototype.Confirm = function(msg, callback) { Vue.prototype.Confirm = function (msg, callback) {
this.$confirm(msg, "提示", { this.$confirm(msg, "提示", {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
...@@ -101,7 +101,7 @@ export default { ...@@ -101,7 +101,7 @@ export default {
//type : m_filt 填充 m_w 宽度固定 高度不固定 m_h 高度固定 宽度不固定 //type : m_filt 填充 m_w 宽度固定 高度不固定 m_h 高度固定 宽度不固定
// w : 宽 // w : 宽
// h : 高 // h : 高
Vue.prototype.compressImg = function(path, type, w, h) { Vue.prototype.compressImg = function (path, type, w, h) {
let url = this.domainManager().UploadUrl; let url = this.domainManager().UploadUrl;
let poise = 'width='; let poise = 'width=';
w = w ? w : '' w = w ? w : ''
...@@ -116,7 +116,7 @@ export default { ...@@ -116,7 +116,7 @@ export default {
//旅游ERP接口 //旅游ERP接口
Vue.prototype.apipost2 = function(cmd, msg, successCall, faildCall, isOnline) { Vue.prototype.apipost2 = function (cmd, msg, successCall, faildCall, isOnline) {
if (msg == null || msg == "") { if (msg == null || msg == "") {
msg = {} msg = {}
} }
...@@ -165,7 +165,7 @@ export default { ...@@ -165,7 +165,7 @@ export default {
} }
//CRM接口 //CRM接口
Vue.prototype.apipost = function(cmd, msg, successCall, faildCall) { Vue.prototype.apipost = function (cmd, msg, successCall, faildCall) {
if (msg == null || msg == "") { if (msg == null || msg == "") {
msg = {} msg = {}
} }
...@@ -208,7 +208,7 @@ export default { ...@@ -208,7 +208,7 @@ export default {
}, },
// 自动登录HTTP提交数据 // 自动登录HTTP提交数据
Vue.prototype.apipostLogin = function(cmd, msg, successCall, faildCall) { Vue.prototype.apipostLogin = function (cmd, msg, successCall, faildCall) {
if (msg == null || msg == "") { if (msg == null || msg == "") {
msg = {} msg = {}
} }
...@@ -251,7 +251,7 @@ export default { ...@@ -251,7 +251,7 @@ export default {
}, },
//Java接口 //Java接口
Vue.prototype.apiJavaPost = function(cmd, msg, successCall, faildCall) { Vue.prototype.apiJavaPost = function (cmd, msg, successCall, faildCall) {
if (msg == null || msg == "") { if (msg == null || msg == "") {
msg = {} msg = {}
} }
...@@ -303,7 +303,7 @@ export default { ...@@ -303,7 +303,7 @@ export default {
}, },
//下载文件 //下载文件
Vue.prototype.GetLocalFile = function(cmd, msg, fileName, callBack) { Vue.prototype.GetLocalFile = function (cmd, msg, fileName, callBack) {
if (msg == null || msg == "") { if (msg == null || msg == "") {
msg = {} msg = {}
} }
...@@ -345,7 +345,7 @@ export default { ...@@ -345,7 +345,7 @@ export default {
}; };
callBack(result); callBack(result);
} }
}).catch(function(res) { }).catch(function (res) {
console.log("GetLocalFile", res); console.log("GetLocalFile", res);
}); });
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment