import { $post } from '@/lu/axios.js' import $config from '@/config.js' const url_ = $config.url; export const yo = async (data) => await $post({ url: 'YO', data }) export const $image = (path) => { if (path.indexOf('data:image/') !== -1) return path if (path.indexOf('http') !== -1) return path return `${url_}${path}` } export const $response = (response, then, error = () => {}) => { if (response) { if (response.code != 200) { uni.$lu.toast(response.message); error() return } then() } }