向列布局动态添加F7


 1 function initBuildingEntryF7(sellId){
 2             var comId = "buildingEntry";
 3             var filter = "";
 4             if(sellId!=null){
 5                 filter = "sellproject.id = '"+sellId+"'";
 6             }                
 7 
 8             var options = {
 9                 id: "buildingEntry",
10                 name: "buildingEntry",
11                 width: 200,
12                 height: 26,
13                 disTl: false,
14                 subWidgetName: "wafPromptQuick",
15                 subWidgetOptions: {
16                     url: waf.getContextPath() +'/dynamicPage.do?      inwafpage=true&event=initialize&uipk=com.kingdee.eas.re.sales.fi.CostMarkOutF7Page',
17                     ajaxType: "GET",
18                     query: "com.kingdee.eas.fdc.sales.app.F7BuildingWebQuery",
19                     accessType: "remote",
20                     isMulti:true,
21                     allowAutoComplete: true,
22                     autoChoose:false,
23                     autoCompleteItem: "name",
24                     displayItem:"name",
25                     cu: false,
26                     filteritem:filter,
27                 },
28                 //onchange:_private.buildingEntryOnChange,
29                 fieldSeparator:"/",
30             };
31 
32             var lbOptions = {
33                 id: comId + "Lb",
34                 labelAlign: "right",
35                 caption: "楼栋",
36                 tagClass: "asstlb"
37             };
38             var lbDOM = waf.createDOM("labelContainer", lbOptions);
39             waf.appendDOM(waf("#layoutCol3"), lbDOM);
40             waf.initComponent("labelContainer", lbOptions, lbDOM); 
41 
42             var promptBoxDom = waf.createDOM("promptBox", options);
43             waf("#"+comId + "Lb").wafLabelContainer("append", promptBoxDom);
44             waf.initComponent("promptBox", options, promptBoxDom);
45             waf("#" + comId + "Lb_ctrl .ui-f7-frame").css("width", "300px"); 
46         }​

 

posted @ 2016-10-18 20:16  suruozhong  阅读(457)  评论(0编辑  收藏  举报