import request from '@/utils/request'
import baseUrl from '@/utils/baseurl.js'

export function assetList() {
	return request.get('/visitor/asset/list')
}

export function assetDetail(barCode) {
	return request.get(`/visitor/asset/detail/${barCode}`)
}

export function getImage(src) {
	if (!src) {
		return;
	}
	let real_src = src.split(",")[0]
	return baseUrl + real_src;
}

export function playerVideo(url) {
  return `${baseUrl}/asset/demoVideo/player?name=${url}`
}