import request from '@/utils/request'

/** 接口 */
const Api = {
	palletDetailUnBind: '/api/wms/pda/palletDetailUnBind',
	queryPalletInfo: '/api/wms/pda/queryPalletInfo',
	unBindRack: '/api/wms/pda/unBindRack',
	queryLinePalletInfo: '/api/wms/pda/queryLinePalletInfo',
	queryAreaByLocCode: '/api/wms/pda/queryAreaByLocCode',
}

/** 托盘明细查询 */
export const queryPalletInfo = data => {
	return request({
		url: Api.queryPalletInfo,
		params: data,
		method: 'GET'
	})
}

/** 单据组盘表单提交 */
export const palletDetailUnBind = data => {
	return request({
		url: Api.palletDetailUnBind,
		data: data,
		method: 'POST'
	})
}

/** 站点库位托盘解绑 */
export const unBindRack = data => {
	return request({
		url: Api.unBindRack,
		data: data,
		method: 'POST'
	})
}

/** 线边托盘信息查询 */
export const queryLinePalletInfo = data => {
	return request({
		url: Api.queryLinePalletInfo,
		params: data,
		method: 'GET'
	})
}

/** 根据入库站台物料类别查询可到的库区 */
export const queryAreaByLocCode = data => {
	return request({
		url: Api.queryAreaByLocCode,
		params: data,
		method: 'GET'
	})
}