UNPKG

react-app-shell

Version:

react打包脚本和example, 这里的版本请忽略

32 lines (28 loc) 818 B
import {fetchUtils} from '../utils'; import {appConfig} from '../config'; const mobileDomain = appConfig.domain.baseDomain; /** * 兑换专题课 * @param exchangeId, exchangeNum * @returns {self|Promise<T | never>} */ export const exchangeSpecial = (studentId, exchangeNum) => { const url = mobileDomain.concat('/customer/info/exchange/special'); const data = { studentId, exchangeNum: exchangeNum.join() }; return fetchUtils.post(url, data).then(res => res.data); }; /** * 用户信息查询 * @param exchangeId * @returns {self|Promise<T | never>} */ export const getStudentMsg = (studentId) => { const url = mobileDomain.concat('/customer/info/student/name'); const data = { studentId }; return fetchUtils.get(url, data).then(res => res.data); };