
import request from '@/utils/request'
// 人员组织架构接口

// 列表接口及条件查询
export function getPersonnelInfo(data) {
  return request({
    url: `/csc-szls-system-manage/sysPersonnel/authority/getPage`,
    method: 'post',
    data
  })
}

// 新增接口
export function addPersonnelInfo(data) {
  return request({
    url: `/csc-szls-system-manage/sysPersonnel/authority_button/add`,
    method: 'post',
    data
  })
}

// 删除接口

export function deletePersonnelInfo( id) {
  return request({
    url: `/csc-szls-system-manage/sysPersonnel/authority_button/deleteById?id=${id}`,
    method: 'delete',
  })
}

// 修改接口
export function updatePersonnelInfo(data) {
  return request({
    url: `/csc-szls-system-manage/sysPersonnel/authority_button/update`,
    method: 'post',
    data
  })
}

// 查看接口
export function checkPersonnelInfo(id) {
  return request({
    url: `/csc-szls-system-manage/sysPersonnel/authority/getById/${id}`,
    method: 'get'

  })
}

// 查看接口
export function getfilebyname(objectName) {
  return request({
    url: `/csc-szls-system-manage/minio/preViewPicture/${objectName}`,
    method: 'get',
    responseType: 'blob',  
  })
}
