ProjectSetting.js 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440
  1. MWF.xApplication.TeamWork = MWF.xApplication.TeamWork || {};
  2. MWF.xApplication.TeamWork.ProjectSetting = new Class({
  3. Extends: MWF.xApplication.TeamWork.Common.Popup,
  4. options:{
  5. "closeByClickMask" : false
  6. },
  7. open: function (e) {
  8. //设置css 和 lp等
  9. var css = this.css;
  10. this.cssPath = "/x_component_TeamWork/$ProjectSetting/"+this.options.style+"/css.wcss";
  11. this._loadCss();
  12. if(css) this.css = Object.merge( css, this.css );
  13. this.rootActions = this.app.rootActions;
  14. this.actions = this.rootActions.ProjectAction;
  15. this.lp = this.app.lp.projectSetting;
  16. this.fireEvent("queryOpen");
  17. this.isNew = false;
  18. this.isEdited = false;
  19. this._open();
  20. this.fireEvent("postOpen");
  21. },
  22. _createTableContent: function () {
  23. this.projectInfor(function(rs){
  24. this.groups = rs.groups;
  25. this.groupsArr = [];
  26. this.projectSettingTop = new Element("div.projectSettingTop",{styles:this.css.projectSettingTop}).inject(this.formTableArea);
  27. this.projectSettingTopText = new Element("div.projectSettingTopText",{styles:this.css.projectSettingTopText,text:this.lp.title}).inject(this.projectSettingTop);
  28. this.projectSettingTopClose = new Element("div.projectSettingTopClose",{styles:this.css.projectSettingTopClose}).inject(this.projectSettingTop);
  29. this.projectSettingTopClose.addEvents({
  30. click:function(){this.close()}.bind(this)
  31. });
  32. this.projectSettingContent = new Element("div.projectSettingContent",{styles:this.css.projectSettingContent}).inject(this.formTableArea);
  33. this.projectSettingNaviLayout = new Element("div.projectSettingNaviLayout",{styles:this.css.projectSettingNaviLayout}).inject(this.projectSettingContent);
  34. this.projectSettingLayout = new Element("div.projectSettingLayout",{styles:this.css.projectSettingLayout}).inject(this.projectSettingContent);
  35. this.createNavi();
  36. }.bind(this));
  37. },
  38. createNavi:function(){
  39. var _self = this;
  40. this.projectSettingNaviLayout.empty();
  41. //概况
  42. this.naviGeneral = new Element("div.naviGeneral",{styles:this.css.naviItem}).inject(this.projectSettingNaviLayout);
  43. this.naviGeneralHover = new Element("div.naviItemHover",{styles:this.css.naviItemHover}).inject(this.naviGeneral);
  44. this.naviGeneralHover.setStyles({"height":"58px","margin-top":"2px"});
  45. this.naviGeneralIcon = new Element("div.naviItemIcon",{styles:this.css.naviItemIcon}).inject(this.naviGeneral);
  46. this.naviGeneralIcon.setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_general.png)"});
  47. this.naviGeneralText = new Element("div.naviItemText",{styles:this.css.naviItemText,text:this.lp.general}).inject(this.naviGeneral);
  48. this.naviGeneral.addEvents({
  49. mouseover:function(){
  50. if(_self.curNavi == "general") return;
  51. this.getElements(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_general_click.png)"});
  52. this.getElements(".naviItemText").setStyles({"color":"#4a90e2"});
  53. },
  54. mouseout:function(){
  55. if(_self.curNavi == "general") return;
  56. this.getElement(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_general.png)"});
  57. this.getElement(".naviItemText").setStyles({"color":""});
  58. },
  59. click:function(){
  60. _self.curNavi = "general";
  61. _self.changeNavi(this);
  62. _self.loadGeneral();
  63. }
  64. });
  65. //自定义字段
  66. this.naviCustom = new Element("div.naviCustom",{styles:this.css.naviItem}).inject(this.projectSettingNaviLayout);
  67. this.naviCustomHover = new Element("div.naviItemHover",{styles:this.css.naviItemHover}).inject(this.naviCustom);
  68. this.naviCustomIcon = new Element("div.naviItemIcon",{styles:this.css.naviItemIcon}).inject(this.naviCustom);
  69. this.naviCustomIcon.setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom.png)"});
  70. this.naviCustomText = new Element("div.naviItemText",{styles:this.css.naviItemText,text:this.lp.customField}).inject(this.naviCustom);
  71. this.naviCustom.addEvents({
  72. mouseover:function(){
  73. if(_self.curNavi == "custom") return;
  74. this.getElements(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom_click.png)"});
  75. this.getElements(".naviItemText").setStyles({"color":"#4a90e2"});
  76. },
  77. mouseout:function(){
  78. if(_self.curNavi == "custom") return;
  79. this.getElement(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom.png)"});
  80. this.getElement(".naviItemText").setStyles({"color":""});
  81. },
  82. click:function(){
  83. _self.curNavi = "custom";
  84. _self.changeNavi(this);
  85. _self.loadCustom()
  86. }
  87. });
  88. this.naviCustom = new Element("div.naviCustom",{styles:this.css.naviItem}).inject(this.projectSettingNaviLayout);
  89. this.naviCustomHover = new Element("div.naviItemHover",{styles:this.css.naviItemHover}).inject(this.naviCustom);
  90. this.naviCustomIcon = new Element("div.naviItemIcon",{styles:this.css.naviItemIcon}).inject(this.naviCustom);
  91. this.naviCustomIcon.setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom.png)"});
  92. this.naviCustomText = new Element("div.naviItemText",{styles:this.css.naviItemText,text:"任务设置"}).inject(this.naviCustom);
  93. this.naviCustom.addEvents({
  94. mouseover:function(){
  95. if(_self.curNavi == "custom") return;
  96. this.getElements(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom_click.png)"});
  97. this.getElements(".naviItemText").setStyles({"color":"#4a90e2"});
  98. },
  99. mouseout:function(){
  100. if(_self.curNavi == "custom") return;
  101. this.getElement(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom.png)"});
  102. this.getElement(".naviItemText").setStyles({"color":""});
  103. },
  104. click:function(){
  105. _self.curNavi = "custom";
  106. _self.changeNavi(this);
  107. _self.loadCustom()
  108. }
  109. });
  110. this.naviCustom = new Element("div.naviCustom",{styles:this.css.naviItem}).inject(this.projectSettingNaviLayout);
  111. this.naviCustomHover = new Element("div.naviItemHover",{styles:this.css.naviItemHover}).inject(this.naviCustom);
  112. this.naviCustomIcon = new Element("div.naviItemIcon",{styles:this.css.naviItemIcon}).inject(this.naviCustom);
  113. this.naviCustomIcon.setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom.png)"});
  114. this.naviCustomText = new Element("div.naviItemText",{styles:this.css.naviItemText,text:"更多设置"}).inject(this.naviCustom);
  115. this.naviCustom.addEvents({
  116. mouseover:function(){
  117. if(_self.curNavi == "custom") return;
  118. this.getElements(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom_click.png)"});
  119. this.getElements(".naviItemText").setStyles({"color":"#4a90e2"});
  120. },
  121. mouseout:function(){
  122. if(_self.curNavi == "custom") return;
  123. this.getElement(".naviItemIcon").setStyles({"background-image":"url(/x_component_TeamWork/$ProjectSetting/default/icon/icon_custom.png)"});
  124. this.getElement(".naviItemText").setStyles({"color":""});
  125. },
  126. click:function(){
  127. _self.curNavi = "custom";
  128. _self.changeNavi(this);
  129. _self.loadCustom()
  130. }
  131. });
  132. this.naviGeneral.click()
  133. },
  134. changeNavi:function(obj){
  135. this.projectSettingNaviLayout.getElements(".naviItemHover").setStyles({"background-color":"#ffffff"});
  136. this.projectSettingNaviLayout.getElements(".naviItemText").setStyles({"color":""});
  137. this.projectSettingNaviLayout.getElements(".naviItemIcon").each(function(dom){
  138. var bgurl = dom.getStyle("background-image");
  139. if(bgurl.indexOf("_click")>-1){
  140. bgurl = bgurl.replace("_click","");
  141. }
  142. dom.setStyles({"background-image":bgurl});
  143. }.bind(this));
  144. obj.getElement(".naviItemHover").setStyles({"background-color":"#4a90e2"});
  145. obj.getElement(".naviItemIcon").setStyles({"background-image":obj.getElement(".naviItemIcon").getStyle("background-image").replace(".png","_click.png")});
  146. obj.getElement(".naviItemText").setStyles({"color":"#4a90e2"});
  147. },
  148. loadCustom:function(){
  149. this.projectSettingLayout.empty();
  150. this.customTopLayout = new Element("div.customTopLayout",{styles:this.css.customTopLayout}).inject(this.projectSettingLayout);
  151. this.customTopText = new Element("div.customTopText",{styles:this.css.customTopText,text:this.lp.customTip}).inject(this.customTopLayout);
  152. this.customTopNew = new Element("div.customTopNew",{styles:this.css.customTopNew,text:this.lp.customNew}).inject(this.customTopLayout);
  153. this.customTopNew.addEvents({
  154. mouseover:function(){this.setStyles({"opacity":"0.7"})},
  155. mouseout:function(){this.setStyles({"opacity":"1"})},
  156. click:function(){
  157. MWF.xDesktop.requireApp("TeamWork", "ExtField", function(){
  158. var pc = new MWF.xApplication.TeamWork.ExtField(this,this.container, this.customTopNew, this.app, {projectId:this.data.id}, {
  159. axis : "x",
  160. position : { //node 固定的位置
  161. x : "left",
  162. y : "middle"
  163. },
  164. nodeStyles : {
  165. "min-width":"200px",
  166. "width":"300px",
  167. "padding":"2px",
  168. "border-radius":"5px",
  169. "box-shadow":"0px 0px 4px 0px #999999",
  170. "z-index" : "201"
  171. },
  172. onPostLoad:function(){
  173. pc.node.setStyles({"opacity":"0","top":(pc.node.getStyle("top").toInt())+"px"});
  174. var fx = new Fx.Tween(pc.node,{duration:400});
  175. fx.start(["opacity"] ,"0", "1");
  176. },
  177. onClose:function(rd){
  178. if(!rd) return;
  179. if(rd.value && rd.value !=""){
  180. this.chatTextarea.set("value",this.chatTextarea.get("value")+"["+rd.value+"]")
  181. }
  182. }.bind(this)
  183. });
  184. pc.load();
  185. }.bind(this));
  186. }.bind(this)
  187. });
  188. this.customContent = new Element("div.customContent",{styles:this.css.customContent}).inject(this.projectSettingLayout);
  189. this.createExtFieldList();
  190. },
  191. createExtFieldList:function(){
  192. this.customContent.empty();
  193. this.app.setLoading(this.customContent);
  194. this.rootActions.ProjectExtFieldReleAction.listFieldsWithProject(this.data.id,function(json){
  195. this.customContent.empty();
  196. json.data.each(function(data){
  197. this.createExtFieldItem(data);
  198. }.bind(this));
  199. }.bind(this))
  200. },
  201. createExtFieldItem:function(data){
  202. var _self = this;
  203. var customExtItem = new Element("div.customExtItem",{styles:this.css.customExtItem,id:data.id}).inject(this.customContent);
  204. customExtItem.addEvents({
  205. mouseover:function(){
  206. this.setStyles({"background-color":"#f5f5f5"});
  207. customExitItemRemove.show();
  208. customExitItemEdit.show();
  209. },
  210. mouseout:function(){
  211. this.setStyles({"background-color":""});
  212. customExitItemRemove.hide();
  213. customExitItemEdit.hide();
  214. }
  215. });
  216. var customExtItemTop = new Element("div.customExtItemTop",{styles:this.css.customExtItemTop}).inject(customExtItem);
  217. var customExtName = new Element("div.customExtName",{styles:this.css.customExtName,text:data.displayName}).inject(customExtItemTop);
  218. var customExitItemRemove = new Element("div.customExitItemRemove",{styles:this.css.customExitItemAction,text:this.lp.remove}).inject(customExtItemTop);
  219. customExitItemRemove.addEvents({
  220. click:function(e){
  221. _self.app.confirm("warn",e,_self.app.lp.common.confirm.removeTitle,_self.app.lp.common.confirm.removeContent,300,120,function(){
  222. _self.actions.projectExtFieldRemove(data.id,function(json){
  223. customExtItem.destroy();
  224. this.close();
  225. }.bind(this))
  226. },function(){
  227. this.close();
  228. });
  229. }
  230. });
  231. var customExitItemEdit = new Element("div.customExitItemEdit",{styles:this.css.customExitItemAction,text:this.lp.edit}).inject(customExtItemTop);
  232. customExitItemEdit.addEvents({
  233. click:function(){
  234. MWF.xDesktop.requireApp("TeamWork", "ExtField", function(){
  235. var pc = new MWF.xApplication.TeamWork.ExtField(this,this.container, this.customTopNew, this.app, {projectId:this.data.id,id:data.id}, {
  236. axis : "x",
  237. position : { //node 固定的位置
  238. x : "left",
  239. y : "middle"
  240. },
  241. nodeStyles : {
  242. "min-width":"200px",
  243. "width":"300px",
  244. "padding":"2px",
  245. "border-radius":"5px",
  246. "box-shadow":"0px 0px 4px 0px #999999",
  247. "z-index" : "201"
  248. },
  249. onPostLoad:function(){
  250. pc.node.setStyles({"opacity":"0","top":(pc.node.getStyle("top").toInt())+"px"});
  251. var fx = new Fx.Tween(pc.node,{duration:400});
  252. fx.start(["opacity"] ,"0", "1");
  253. },
  254. onClose:function(rd){
  255. if(!rd) return;
  256. if(rd.value && rd.value !=""){
  257. this.chatTextarea.set("value",this.chatTextarea.get("value")+"["+rd.value+"]")
  258. }
  259. }.bind(this)
  260. });
  261. pc.load();
  262. }.bind(this));
  263. }.bind(this)
  264. });
  265. var customExtValueList = new Element("div.customExtValueList",{styles:this.css.customExtValueList}).inject(customExtItem);
  266. new Element("span.customExtCreator",{styles:this.customExtText,text:this.lp.description+":"+data.description}).inject(customExtValueList);
  267. customExtValueList = new Element("div.customExtValueList",{styles:this.css.customExtValueList}).inject(customExtItem);
  268. new Element("span.customExtCreator",{styles:this.customExtText,text:this.lp.option + ":"+data.optionsData}).inject(customExtValueList);
  269. },
  270. loadGeneral:function(){
  271. this.projectSettingLayout.empty();
  272. this.groupsArr = [];
  273. this.projectSettingBgText = new Element("div.projectSettingBgText",{styles:this.css.projectSettingBgText,"text":this.lp.projectSettingBgText}).inject(this.projectSettingLayout);
  274. this.projectSettingBgContainer = new Element("div.projectSettingBgContainer",{styles:this.css.projectSettingBgContainer}).inject(this.projectSettingLayout);
  275. this.projectSettingBgImg = new Element("div.projectSettingBgImg",{styles:this.css.projectSettingBgImg}).inject(this.projectSettingBgContainer);
  276. if(this.data.icon && this.data.icon!=""){
  277. this.projectSettingBgImg.setStyles({
  278. "background-image":"url('"+MWF.xDesktop.getImageSrc( this.data.icon )+"')"
  279. });
  280. }
  281. this.projectSettingBgUpload = new Element("div.projectSettingBgUpload",{styles:this.css.projectSettingBgUpload,text:this.lp.upload}).inject(this.projectSettingBgContainer);
  282. this.projectSettingBgUpload.addEvents({
  283. click:function(){
  284. var data = {};
  285. MWF.xDesktop.requireApp("TeamWork", "UploadImage", function(){
  286. var ui = new MWF.xApplication.TeamWork.UploadImage(this, data, {
  287. documentId : this.data.id ||"",
  288. onPostOk : function( id ){
  289. this.data.icon = id;
  290. this.projectSettingBgImg.setStyles({
  291. "background-image":"url('"+MWF.xDesktop.getImageSrc( id )+"')"
  292. });
  293. }.bind(this)
  294. });
  295. ui.open()
  296. }.bind(this));
  297. }.bind(this)
  298. });
  299. this.projectSettingContainer = new Element("div.projectSettingContainer",{styles:this.css.projectSettingContainer}).inject(this.projectSettingLayout);
  300. this.projectSettingTitleContainer = new Element("div.projectSettingTitleContainer",{styles:this.css.projectSettingTitleContainer}).inject(this.projectSettingContainer);
  301. this.projectSettingTitleText = new Element("div.projectSettingTitleText",{styles:this.css.projectSettingTitleText,text:this.lp.projectTitle}).inject(this.projectSettingTitleContainer);
  302. this.projectSettingTitleDiv = new Element("div.projectSettingTitleDiv",{styles:this.css.projectSettingTitleDiv}).inject(this.projectSettingTitleContainer);
  303. this.projectSettingTitleIn = new Element("input.projectSettingTitleIn",{styles:this.css.projectSettingTitleIn,value:this.projectData.title || ""}).inject(this.projectSettingTitleDiv);
  304. // this.projectSettingContainer = new Element("div.projectSettingContainer",{styles:this.css.projectSettingContainer}).inject(this.formTableArea);
  305. this.projectSettingGroupContainer = new Element("div.projectSettingGroupContainer",{styles:this.css.projectSettingGroupContainer}).inject(this.projectSettingContainer);
  306. this.projectSettingGroupText = new Element("div.projectSettingGroupText",{styles:this.css.projectSettingGroupText,text:this.lp.projectGroup}).inject(this.projectSettingGroupContainer);
  307. this.projectSettingGroupDiv = new Element("div.projectSettingGroupDiv",{styles:this.css.projectSettingGroupDiv}).inject(this.projectSettingGroupContainer);
  308. this.projectSettingGroupDiv.addEvents({
  309. click:function(){
  310. var data = {groups:this.groups};
  311. MWF.xDesktop.requireApp("TeamWork", "GroupSelect", function(){
  312. var gs = new MWF.xApplication.TeamWork.GroupSelect(this.container, this.projectSettingGroupDiv, this.app, data, {
  313. axis : "y",
  314. nodeStyles : {
  315. "min-width":"190px",
  316. "z-index" : "102"
  317. },
  318. onClose:function(d){
  319. if(d){
  320. this.rootActions.ProjectGroupAction.listWithIds({ids:d},function(json){
  321. this.groups = json.data;
  322. var tmp = [];
  323. json.data.each(function(ddd){
  324. tmp.push(ddd.name);
  325. });
  326. this.projectSettingGroupValue.set("text",tmp.join());
  327. this.projectSettingGroupValue.set("title",tmp.join())
  328. }.bind(this));
  329. }else{
  330. this.groups = [];
  331. }
  332. //this.newProjectGroupValue.set("text",d)
  333. }.bind(this)
  334. });
  335. gs.load()
  336. }.bind(this));
  337. }.bind(this)
  338. });
  339. this.projectSettingGroupValue = new Element("div.projectSettingGroupValue",{styles:this.css.projectSettingGroupValue}).inject(this.projectSettingGroupDiv);
  340. this.projectSettingGroupIcon = new Element("div.projectSettingGroupIcon",{styles:this.css.projectSettingGroupIcon}).inject(this.projectSettingGroupDiv);
  341. if(this.groups){
  342. this.groups.each(function(data){
  343. this.groupsArr.push(data.name);
  344. }.bind(this));
  345. }
  346. this.projectSettingGroupValue.set("text",this.groupsArr.join());
  347. this.projectSettingGroupValue.set("title",this.groupsArr.join());
  348. this.projectSettingContainer = new Element("div.projectSettingContainer",{styles:this.css.projectSettingContainer}).inject(this.projectSettingLayout);
  349. this.projectSettingContainer.setStyles({"height":"120px"});
  350. this.projectSettingDesText = new Element("div.projectSettingDesText",{styles:this.css.projectSettingDesText,text:this.lp.projectDes}).inject(this.projectSettingContainer);
  351. this.projectSettingDesContainer = new Element("div.projectSettingDesContainer",{styles:this.css.projectSettingDesContainer}).inject(this.projectSettingContainer);
  352. this.projectSettingDesIn = new Element("textarea.projectSettingDesIn",{styles:this.css.projectSettingDesIn,value:this.projectData.description||""}).inject(this.projectSettingDesContainer);
  353. this.projectSettingContainer = new Element("div.projectSettingContainer",{styles:this.css.projectSettingContainer}).inject(this.projectSettingLayout);
  354. this.projectSettingConfirm = new Element("div.projectSettingConfirm",{styles:this.css.projectSettingConfirm,text:this.lp.confirm}).inject(this.projectSettingContainer);
  355. this.projectSettingConfirm.addEvents({
  356. click:function(){
  357. if(this.projectSettingTitleIn.get("value").trim()=="") return;
  358. var groups = [];
  359. if(this.groups){
  360. this.groups.each(function(d){
  361. groups.push(d.id);
  362. });
  363. }
  364. var data = {
  365. "id":this.data.id,
  366. "icon":this.data.icon || "",
  367. "title":this.projectSettingTitleIn.get("value").trim(),
  368. "description":this.projectSettingDesIn.get("value"),
  369. "groups":groups
  370. };
  371. this.actions.save(data,function(json){
  372. this.projectSettingLayout.empty();
  373. this.app.setLoading(this.projectSettingLayout);
  374. this.projectInfor(function(json){
  375. this.loadGeneral(json);
  376. if(this.explorer.currentListType == "block"){
  377. this.explorer.loadSingleBlockItem(this.explorer.container.getElementById(json.id),json)
  378. }else if(this.explorer.currentListType == "list"){
  379. this.explorer.loadSingleListItem(this.explorer.container.getElementById(json.id),json)
  380. }
  381. }.bind(this));
  382. }.bind(this));
  383. }.bind(this)
  384. });
  385. // this.projectSettingClose = new Element("div.projectSettingClose",{styles:this.css.projectSettingClose,text:this.lp.close}).inject(this.projectSettingContainer);
  386. // this.projectSettingClose.addEvents({
  387. // click:function(){
  388. // this.close();
  389. // }.bind(this)
  390. // });
  391. //this.projectSettingAction = new Element("div.projectSettingAction",{styles:this.css.projectSettingAction,text:this.lp.confirm}).inject(this.formTableArea);
  392. },
  393. projectInfor:function(callback){
  394. if(this.data.id){
  395. this.actions.get(this.data.id,function(json){
  396. this.projectData = json.data;
  397. if(callback)callback(json.data)
  398. }.bind(this));
  399. }
  400. },
  401. groupInfor:function(ids){
  402. if(!ids) return;
  403. var resGroups = [];
  404. ids.each(function(data){
  405. this.rootActions.ProjectGroupAction.get(data,function(json){
  406. }.bind(this))
  407. }.bind(this))
  408. }
  409. });