| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- import {axios} from '../utils/request'
- import {SQUARE_MODULE} from "./_prefix";
- export const getSharedFileList = userId => {
- return axios.get(`${SQUARE_MODULE}/sharedFileList`, {
- params: {
- userId: userId
- }
- }).then(res => {
- return res;
- }
- )
- }
- export const getCollectFileList = userId => {
- return axios.get(`${SQUARE_MODULE}/collectFileList`, {
- params: {
- userId: userId
- }
- }).then(res => {
- return res;
- }
- )
- }
- export const getSharedModelList = userId => {
- return axios.get(`${SQUARE_MODULE}/sharedModelList`, {
- params: {
- userId: userId
- }
- }).then(res => {
- return res;
- }
- )
- }
- export const getCollectModelList = userId => {
- return axios.get(`${SQUARE_MODULE}/collectModelList`, {
- params: {
- userId: userId
- }
- }).then(res => {
- return res;
- }
- )
- }
- export const shareFile = payload => {
- const {userId, fileId} = payload;
- return axios.post(`${SQUARE_MODULE}/shareFile?userId=${userId}&fileId=${fileId}`).then( res => {
- return res;
- });
- }
- export const shareModel = payload => {
- const {userId, modelId} = payload;
- return axios.post(`${SQUARE_MODULE}/shareModel?userId=${userId}&modelId=${modelId}`).then( res => {
- return res;
- });
- }
- export const collectFile = payload => {
- const {userId, fileId} = payload;
- return axios.post(`${SQUARE_MODULE}/collectFile?userId=${userId}&fileId=${fileId}`).then( res => {
- return res;
- });
- }
- export const collectModel = payload => {
- const {userId, modelId} = payload;
- return axios.post(`${SQUARE_MODULE}/collectModel?userId=${userId}&modelId=${modelId}`).then( res => {
- return res;
- });
- }
|