阿里云
发表主题 回复主题
  • 954阅读
  • 1回复

[技术开发]dd.config和dd.error不执行

级别: 新人
发帖
3
云币
10
viJP6fh  
从后台请求参数成功, dd.config,dd.erroe  ,dd. ready 全部不执行,  代码放在服务,在钉钉客户端运行,依旧不运行,   EMDYeXpV  
Pj_*,L`mZ  
f`iDF+h<6  
<script type="text/javascript" src="https://g.alicdn.com/dingding/open-develop/1.6.9/dingtalk.js"> </script> |D_4 iFC  
+.gj/uy*  
y#= j{  
sgClient.getDingdingSign(data, function(rs) { =&<d4'(Qk  
                            if (rs && rs.state == 1) { Ro;I%j  
                                alert("请求成功"); |7Qe{  
                                dd.config({ ]<K"`q2  
                                    agentId: rs.data.agentId, bz1AmNZG  
                                    corpId: rs.data.corpId, < FY%QB)h  
                                    timeStamp: rs.data.timestamp, R\<d&+q@  
                                    nonceStr: rs.data.nonceStr, yMC6 Gvp  
                                    signature: rs.data.signature, DS_0p|2  
                                    jsApiList: [ yF1p^>*ak&  
                                        'runtime.info', =\mJ5v"hA  
                                        'biz.contact.choose', u\"/EaQ{  
                                        'device.notification.confirm', IVVX3RI  
                                        'device.notification.alert', $<"I*l@  
                                        'device.notification.prompt', h lSav?V_  
                                        'biz.ding.post', LB[?kpy  
                                        'biz.util.openLink' s< Fp17  
                                    ] //必填,需要使用的jsapi列表 %xKZ" #Z#K  
                                }); 3`)ej`  
                                 dd.error(function(err) { //验证失败   MTq/  
                                    alert("进入到error中"); p/G9P +?  
                                    document.getElementById("userName").innerHTML = "验证出错"; H7k@Br  
                                    alert('dd error: ' + JSON.stringify(err)); dk"@2%xJ2d  
                                }) c]i;0j? Dl  
))nTd=  
                                dd.ready(function() { k3KT':*  
                                    console.log('dd.ready rocks!') "rfBYl`  
                                    dd.runtime.info({ s%8,'3&  
                                        onSuccess: function(info) { OmK4 \_.  
                                        }, fwlicbs'  
                                        onFail: function(err) { kB%.i%9\\  
                                        } <_]W1V:0  
                                    }); TKiYEh  
                                    dd.runtime.permission.requestAuthCode({ PS=q):R|  
                                        corpId: rs.data.corpId, ;*ni%|K  
                                        onSuccess: function(result) { @1' Y/dCyD  
                                        }, [=tIgMmz  
                                        onFail: function(err) { Rg+# (y  
                                        } 1=C<aRZ b^  
                                    }); id" l"  
3(nnN[?N,5  
级别: 新人
发帖
3
云币
10
只看该作者 沙发  发表于: 2017-09-15
Redd.config和dd.error不执行
经过两天的挣扎,终于得出结论,在钉钉上开发移动应用,测试的时候一定要上传服务器,在钉钉内部来执行,同时还要保证你连的网是可以访问钉钉的,要不然ready不会执行!
发表主题 回复主题
« 返回列表上一主题下一主题

限100 字节
批量上传需要先选择文件,再选择上传
 
验证问题: 阿里云官网域名是什么? 正确答案:www.aliyun.com
上一个 下一个