提交 7b594848 编写于 作者: doc_wei's avatar doc_wei

微服务拆分测试

上级 0ef1b32d
...@@ -17,7 +17,7 @@ layui.config({ ...@@ -17,7 +17,7 @@ layui.config({
var params = { var params = {
typeName: $("#typeName").val() typeName: $("#typeName").val()
}; };
AjaxPostUtil.request({url: reqBasePath + "customertype002", params: params, type: 'json', callback: function(json){ AjaxPostUtil.request({url: flowableBasePath + "customertype002", params: params, type: 'json', callback: function(json){
if (json.returnCode == 0){ if (json.returnCode == 0){
parent.layer.close(index); parent.layer.close(index);
parent.refreshCode = '0'; parent.refreshCode = '0';
......
...@@ -12,7 +12,7 @@ layui.config({ ...@@ -12,7 +12,7 @@ layui.config({
showGrid({ showGrid({
id: "showForm", id: "showForm",
url: reqBasePath + "customertype003", url: flowableBasePath + "customertype003",
params: {rowId: parent.rowId}, params: {rowId: parent.rowId},
pagination: false, pagination: false,
template: getFileContent('tpl/customertype/customertypeeditTemplate.tpl'), template: getFileContent('tpl/customertype/customertypeeditTemplate.tpl'),
...@@ -27,7 +27,7 @@ layui.config({ ...@@ -27,7 +27,7 @@ layui.config({
rowId: parent.rowId, rowId: parent.rowId,
typeName: $("#typeName").val() typeName: $("#typeName").val()
}; };
AjaxPostUtil.request({url: reqBasePath + "customertype004", params: params, type: 'json', callback: function(json){ AjaxPostUtil.request({url: flowableBasePath + "customertype004", params: params, type: 'json', callback: function(json){
if (json.returnCode == 0){ if (json.returnCode == 0){
parent.layer.close(index); parent.layer.close(index);
parent.refreshCode = '0'; parent.refreshCode = '0';
......
...@@ -16,7 +16,7 @@ layui.config({ ...@@ -16,7 +16,7 @@ layui.config({
id: 'messageTable', id: 'messageTable',
elem: '#messageTable', elem: '#messageTable',
method: 'post', method: 'post',
url: reqBasePath + 'customertype001', url: flowableBasePath + 'customertype001',
where: {typeName: $("#typeName").val(), state: $("#state").val()}, where: {typeName: $("#typeName").val(), state: $("#state").val()},
even: true, even: true,
page: true, page: true,
...@@ -115,7 +115,7 @@ layui.config({ ...@@ -115,7 +115,7 @@ layui.config({
function del(data, obj){ function del(data, obj){
layer.confirm(systemLanguage["com.skyeye.deleteOperationMsg"][languageType], {icon: 3, title: systemLanguage["com.skyeye.deleteOperation"][languageType]}, function(index){ layer.confirm(systemLanguage["com.skyeye.deleteOperationMsg"][languageType], {icon: 3, title: systemLanguage["com.skyeye.deleteOperation"][languageType]}, function(index){
layer.close(index); layer.close(index);
AjaxPostUtil.request({url: reqBasePath + "customertype005", params: {rowId: data.id}, type: 'json', callback: function(json){ AjaxPostUtil.request({url: flowableBasePath + "customertype005", params: {rowId: data.id}, type: 'json', callback: function(json){
if(json.returnCode == 0){ if(json.returnCode == 0){
winui.window.msg(systemLanguage["com.skyeye.deleteOperationSuccessMsg"][languageType], {icon: 1,time: 2000}); winui.window.msg(systemLanguage["com.skyeye.deleteOperationSuccessMsg"][languageType], {icon: 1,time: 2000});
loadTable(); loadTable();
...@@ -126,12 +126,12 @@ layui.config({ ...@@ -126,12 +126,12 @@ layui.config({
}); });
} }
//上线 // 上线
function up(data, obj){ function up(data, obj){
var msg = obj ? '确认将【' + obj.data.typeName + '】上线吗?' : '确认将选中数据上线吗?'; var msg = obj ? '确认将【' + obj.data.typeName + '】上线吗?' : '确认将选中数据上线吗?';
layer.confirm(msg, {icon: 3, title: '类型上线'}, function (index) { layer.confirm(msg, {icon: 3, title: '类型上线'}, function (index) {
layer.close(index); layer.close(index);
AjaxPostUtil.request({url: reqBasePath + "customertype006", params: {rowId: data.id}, type: 'json', callback: function(json){ AjaxPostUtil.request({url: flowableBasePath + "customertype006", params: {rowId: data.id}, type: 'json', callback: function(json){
if(json.returnCode == 0){ if(json.returnCode == 0){
winui.window.msg("上线成功", {icon: 1, time: 2000}); winui.window.msg("上线成功", {icon: 1, time: 2000});
loadTable(); loadTable();
...@@ -142,12 +142,12 @@ layui.config({ ...@@ -142,12 +142,12 @@ layui.config({
}); });
} }
//下线 // 下线
function down(data, obj){ function down(data, obj){
var msg = obj ? '确认将【' + obj.data.typeName + '】下线吗?' : '确认将选中数据下线吗?'; var msg = obj ? '确认将【' + obj.data.typeName + '】下线吗?' : '确认将选中数据下线吗?';
layer.confirm(msg, {icon: 3, title: '类型下线'}, function (index) { layer.confirm(msg, {icon: 3, title: '类型下线'}, function (index) {
layer.close(index); layer.close(index);
AjaxPostUtil.request({url: reqBasePath + "customertype007", params: {rowId: data.id}, type: 'json', callback: function(json){ AjaxPostUtil.request({url: flowableBasePath + "customertype007", params: {rowId: data.id}, type: 'json', callback: function(json){
if(json.returnCode == 0){ if(json.returnCode == 0){
winui.window.msg("下线成功", {icon: 1, time: 2000}); winui.window.msg("下线成功", {icon: 1, time: 2000});
loadTable(); loadTable();
......
...@@ -47,6 +47,7 @@ var fileBasePath; ...@@ -47,6 +47,7 @@ var fileBasePath;
// 接口请求地址 // 接口请求地址
var reqBasePath; // 总项目 var reqBasePath; // 总项目
var shopBasePath; // 商城项目 var shopBasePath; // 商城项目
var flowableBasePath; // 工作流相关功能的项目
var webSocketPath;//聊天socket-开发 var webSocketPath;//聊天socket-开发
...@@ -56,6 +57,7 @@ function initBaseParams(){ ...@@ -56,6 +57,7 @@ function initBaseParams(){
reqBasePath = sysMainMation.reqBasePath; reqBasePath = sysMainMation.reqBasePath;
shopBasePath = sysMainMation.shopBasePath; shopBasePath = sysMainMation.shopBasePath;
webSocketPath = sysMainMation.webSocketPath; webSocketPath = sysMainMation.webSocketPath;
flowableBasePath = sysMainMation.flowableBasePath;
} }
// 编辑加载自定义的js文件 // 编辑加载自定义的js文件
......
...@@ -99,6 +99,15 @@ var AjaxPostUtil = { ...@@ -99,6 +99,15 @@ var AjaxPostUtil = {
} else { } else {
this.options.callback.call(this); this.options.callback.call(this);
} }
}else if(xmlhttp.readyState == 4 && (xmlhttp.status == 404)) {
// 移除请求遮罩层
layui.$("body").find(".mask-req-str").remove();
returnValue = eval('(' + '{"returnMessage":"接口请求:404","returnCode":-9999,"total":0,"rows":"","bean":""}' + ')');
if(returnValue) {
this.options.callback.call(this, returnValue);
} else {
this.options.callback.call(this);
}
} }
}, },
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册