test(){
console.log("111")
}
var name = "小红";
window['extendObj'].printPdf(it.result, function (el) {
if (!el) {
this.test();
} else {
this.name = "黄小明";
}
}, it.printerName, 60, it.printType);
在回调函数中,调用test方法找不到,这是为什么呢?
你代码的问题比较多,所以可能性其实不少。
姑且不论那个,
this.test()
就很没有必要。