- 策略广场
- My语言仓位变化推送通知 (Copy)
My语言仓位变化推送通知 (Copy)
Author:
扫地僧, Date: 2021-11-05 09:22:23
Tags:
推送工具My语言
C>HV(H, 10),SPK;
C<LV(L, 15),BPK;
AUTOFILTER;
%%
// 下面代码附加到任何My语言策略最后都可以实现仓位变化推送到手机App与微信
if (typeof(scope._tmp) !== 'number') {
scope._tmp = 0;
}
var pos = scope.get_locals('BKVOL') - scope.get_locals('SKVOL');
if (pos != scope._tmp) {
scope._tmp = pos;
Log('通知仓位变化:', scope.symbol, pos, '@');
}
%%
template: strategy.tpl:40:21: executing "strategy.tpl" at <.api.GetStrategyListByName>: wrong number of args for GetStrategyListByName: want 7 got 6