import i18n from '../../../locale/index';
import Config from '../../../config/index';

const $t = (name) => {
  let text = i18n.vm.messages['zh-CN'][name];
  if (!text) {
    text = name
  }
  return text;
}

const data = {
  // 角色
  role: {
    // 是否自动查询
    // initSearchFlag:true,
    // 默认页数
    pageSize:200,
    // 接口文件
    service: 'commonService',
    // 下拉的查询方法
    methodsName: 'getRole',
    // 名称列
    labelKey:'roleName',
    // 值列
    valueKey:'roleId',
  },
}


export const setSetting = (services, type) => {
  let setting = data[type];
  setting.service = services[setting.service]
  return setting;
}


export default {
  setSetting: setSetting,
}
