diff --git a/src/api/productionSchedulingPlan/scheduling.js b/src/api/productionSchedulingPlan/scheduling.js new file mode 100644 index 0000000..1c4dd38 --- /dev/null +++ b/src/api/productionSchedulingPlan/scheduling.js @@ -0,0 +1,23 @@ +import request from '@/axios'; + +// 排产看板数据 +export const getData = row => { + return request({ + url: '/blade-scheduling/workOrder/schedulingBoard', + method: 'post', + data: row, + }); +}; + +// 排产异常数据 +export const getYieldOrderList = (current, size, params) => { + return request({ + url: '/blade-scheduling/yieldOrder/page', + method: 'get', + params: { + ...params, + current, + size, + }, + }); +}; \ No newline at end of file diff --git a/src/axios.js b/src/axios.js index ce674c0..49c06fd 100644 --- a/src/axios.js +++ b/src/axios.js @@ -25,7 +25,7 @@ let isErrorShown = false; let isRefreshing = false; // 标记当前是否正在刷新token let refreshTokenPromise = null; // 刷新token的Promise,避免重复请求 -axios.defaults.timeout = 10000; +axios.defaults.timeout = 60000; //返回其他状态码 axios.defaults.validateStatus = function (status) { return status >= 200 && status <= 500; // 默认的 @@ -40,6 +40,7 @@ NProgress.configure({ //http request拦截 axios.interceptors.request.use( config => { + console.log('请求拦截器',config) // start progress bar NProgress.start(); // 初始化错误提示状态 @@ -49,7 +50,7 @@ axios.interceptors.request.use( config.url = baseUrl + config.url; } //安全请求header - config.headers['Blade-Requested-With'] = 'BladeHttpRequest'; + // config.headers['Blade-Requested-With'] = 'BladeHttpRequest'; //headers判断是否需要 const authorization = config.authorization === false; if (!authorization) { @@ -86,9 +87,9 @@ axios.interceptors.request.use( config.headers['Content-Type'] = 'text/plain'; } //headers中配置serialize为true开启序列化 - if (config.method === 'post' && meta.isSerialize === true) { - config.data = serialize(config.data); - } + // if (config.method === 'post' && meta.isSerialize === true) { + // config.data = serialize(config.data); + // } return config; }, error => { diff --git a/src/views/productionSchedulingPlan/schedulingDashboard/index.vue b/src/views/productionSchedulingPlan/schedulingDashboard/index.vue index 15746a0..92c7861 100644 --- a/src/views/productionSchedulingPlan/schedulingDashboard/index.vue +++ b/src/views/productionSchedulingPlan/schedulingDashboard/index.vue @@ -1,11 +1,50 @@