export default {
   URL:'http://36.148.1.253:8901/danger',
   //URL:'http://127.0.0.1:60018/danger',
  //URL:'http://36.148.23.59:8901/danger',
  titleArray: [],
  enterpriseId:'',
  componentUrl: {
    AlarmMg:'Alarm',
    EnseList:'EnseList',
    EnterprisesMg:'Enterprises',
  EnterprisesCheck:'Enterprises',
  EnterprisesInformation:'Enterprises',
    GIS:'GIS',
	EnterprisesQt:'Enterprises',
    HazardsListMg:'Hazards',
    PlansMg:'Plans',
    PlansMgGovernment:'Plans',
    qyMap:'qyMap',
    qystatistics:'qystatistics',
    SafetyDeviceMg:'SafetyDevice',
    statistics:'statistics',
    SystemCode:'SystemCode',
    APIMg: "System",
    BranchMg: "System",
    MenuMg: "System",
    RoleMg: "System",
    UserMg: "System",
    VideoList: "Video",
      guarantee: "guarantee",
      dangerMap: "guarantee",
  },
  deleteFun(that: any, url: any, callback: any) {
    (that as any)
      .$confirm("确定删除此条记录吗?", "提示", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning"
      })
      .then(() => {
        (that as any).$axios
          .get(url)
          .then((res: any) => {
            if (res.code == 0) {
              (that as any).$message({
                type: "success",
                message: "删除成功!"
              });
              callback()
            }
          });
      });
  },
  axiosPost(that: any, url: any,param:any, callback: any) {//post请求
    (that as any).$axios.post(url, param).then((res:any) => {
      callback(res)
    })
  },
  axiosGet(that: any, url: any, callback: any) {//get请求
    (that as any).$axios.get(url).then((res:any) => {
      callback(res)
    })
  },
    
}