import axios from 'axios';
import config from './config.js';

axios.default.timeout = 500000;
axios.defaults.headers.post['Content-Type'] = "application/json;charset=utf-8";
axios.defaults.baseURL = 'http://192.168.2.236:6060';
// axios.defaults.baseURL = 'http://192.168.2.241';
// axios.defaults.baseURL = 'http://192.168.3.113:6060';


const urls = config.urls;
export default {
  loginMess(data) {
    return axios.post(urls.login,
      {
        'username': data.username,
        'password': data.password
      }
    )
  },
  getAccessdMenu() {
    return axios.post(urls.getAccessdMenu);
  },
  midifyPassword(param) {
    return axios.post(urls.midifyPassword, param);
  },

}