| 123456789101112131415161718192021222324252627282930313233343536 |
- import host from "./config.js"
- import api from "./request.js"
- const user = uni.getStorageSync('systemUserInfo');
- export function get(url, params, baseURL) {
- return api({
- url,
- params,
- method: "GET",
- baseURL,
- })
- }
- export function post(url, params, baseURL) {
- return api({
- url,
- params,
- method: "POST",
- header: { "Content-Type": "application/x-www-form-urlencoded" },
- baseURL,
- })
- }
- export function u_post(url, params, baseURL) {
- params = {
- ...params,
- userId: user.userId
- }
- return api({
- url,
- params,
- method: "POST",
- header: { "Content-Type": "application/x-www-form-urlencoded" },
- baseURL,
- })
- }
|