import request from '@/utils/request'

// 表单模板列表
export const pageList = (query) => {
    return request({
      url: '/system/printTemplate/pageList',
      method: 'get',
      params: query
    })
  }
  
  // 添加修改小票模板
  export const saveAndEdit = (data) => {
    return request({
      url: '/system/printTemplate/insertOrUpdate',
      method: 'post',
      data: data
    })
  }

  // ID获取模板信息
export const selectById = (id) => {
    return request({
      url: '/system/printTemplate/selectById',
      method: 'get',
      params: {id:id}
    })
  }

  // 删除模板
export const deleteById = (id) => {
    return request({
      url: '/system/printTemplate/deleteById',
      method: 'delete',
      params: {id:id}
    })
  }