1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
| /**
| 初始化处理
| **/
| (function(window, undefined){
| "use strict";
| var vc = window.vc || {};
| vc = {
| version:"v0.0.1",
| name:"vue component"
| };
| //通知window对象
| window.vc = vc;
| })(window);
|
| /**
| 异步请求后台
| add by wuxw
| **/
| (function(vc){
| vc.http = {
| call:function(componentCode,componentMethod,param,options,successCallback,errorCallback){
| console.log(successCallback)
| Vue.http.post('/callComponent/'+componentCode +"/"+componentMethod, param, options)
| .then(function(res){
| successCallback(res.bodyText);
| }, function(error){
| errorCallback(error);
| });
| }
|
| };
| })(window.vc);
|
|