parent
19e01cf623
commit
54e581f2ae
@ -1,5 +1,5 @@ |
||||
#TARO_APP_API=https://yjx.dev.yaojiankang.top |
||||
TARO_APP_API=https://mooc.yaojiankang.top |
||||
TARO_APP_API=https://yjx.dev.yaojiankang.top |
||||
#TARO_APP_API=https://mooc.yaojiankang.top |
||||
#TARO_APP_API=https://shopfix.yaojiankang.top |
||||
#TARO_APP_API=https://playedu.yaojiankang.top |
||||
TARO_APP_LGOIN=true |
||||
|
@ -1,25 +0,0 @@ |
||||
import Taro from "@tarojs/taro"; |
||||
|
||||
/** |
||||
* 首页全局事件 |
||||
* 当某个课程看完-触发未完成移动已完成 |
||||
*/ |
||||
const KEY = 'REFRESH_INDEX' |
||||
|
||||
interface RefreshIndex { |
||||
id: number |
||||
} |
||||
|
||||
function on(fn: (arg: RefreshIndex) => void) { |
||||
Taro.eventCenter.on(KEY, fn) |
||||
} |
||||
|
||||
function trigger(data: RefreshIndex) { |
||||
Taro.eventCenter.trigger(KEY, data) |
||||
} |
||||
|
||||
export default { |
||||
on, |
||||
trigger |
||||
} |
||||
|
Loading…
Reference in new issue