section_tree.js 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583
  1. /**
  2. * Created by Zhong on 2017/12/18.
  3. */
  4. let pageOprObj = {
  5. rationLibName : null,
  6. rationLibId : null,
  7. gljLibId: null,
  8. initPage : function() {
  9. let me = this, rationLibId = getQueryString("repository");
  10. me.getRationLibInfo(rationLibId, function (rstData) {
  11. if(rstData.length > 0){
  12. me.rationLibName = rstData[0].dispName;
  13. me.gljLibId = rstData[0].gljLib;
  14. if(!me.gljLibId || typeof me.gljLibId === 'undefined' || me.gljLibId == -1){
  15. alert("没有引用工料机库!");
  16. window.location.href = "/rationRepository/main";
  17. }
  18. if (me.rationLibName) {
  19. var html = $("#rationname")[0].outerHTML;
  20. html = html.replace("XXX定额库", me.rationLibName);
  21. $("#rationname")[0].outerHTML = html;
  22. me.rationLibId = rationLibId;
  23. sectionTreeObj.getSectionTree(rationLibId);
  24. //job
  25. jobContentOprObj.radiosChange(jobContentOprObj.radios, jobContentOprObj.tableAll, jobContentOprObj.tablePartial);
  26. $('#addConBtn').click(jobContentOprObj.bindAddConBtn());
  27. $('#updateConBtn').click(jobContentOprObj.bindUpdateConBtn());
  28. jobContentOprObj.bindAllEvents($('#txtareaAll'));
  29. //fz
  30. annotationOprObj.radiosChange(annotationOprObj.radios, annotationOprObj.fzTableAll, annotationOprObj.fzTablePartial);
  31. $('#fzAddConBtn').click(annotationOprObj.bindAddConBtn());
  32. $('#fzUpdateConBtn').click(annotationOprObj.bindUpdateConBtn());
  33. annotationOprObj.bindAllEvents($('#fzTxtareaAll'));
  34. }
  35. }
  36. });
  37. },
  38. getRationLibInfo: function (rationLibId, callback) {
  39. CommonAjax.post('api/getRationLib', {libId: rationLibId}, callback);
  40. }
  41. }
  42. let sectionTreeObj = {
  43. cache: null,//ref to tree.items
  44. tree: null,
  45. controller: null,
  46. workBook: null,
  47. sheet: null,
  48. updateType: {new: 'new', update: 'update'},
  49. insertBtn: $('#tree_Insert'),
  50. removeBtn: $('#tree_remove'),
  51. upLevelBtn: $('#tree_upLevel'),
  52. downLevelBtn: $('#tree_downLevel'),
  53. downMoveBtn: $('#tree_downMove'),
  54. upMoveBtn: $('#tree_upMove'),
  55. setting: {
  56. sheet: {
  57. cols:[
  58. {
  59. head: {
  60. titleNames: ['名称'],
  61. spanCols: [1],
  62. spanRows: [2],
  63. vAlign: [1, 1],
  64. hAlign: [1, 1],
  65. font: 'Arial'
  66. },
  67. data: {
  68. field: 'name',
  69. vAlign: 1,
  70. hAlign: 0,
  71. font: 'Arial'
  72. },
  73. width: 400
  74. }
  75. ],
  76. headRows: 1,
  77. headRowHeight: [25],
  78. emptyRows: 0,
  79. treeCol: 0
  80. },
  81. tree: {
  82. id: 'ID',
  83. pid: 'ParentID',
  84. nid: 'NextSiblingID',
  85. rootId: -1
  86. },
  87. options: {
  88. tabStripVisible: false,
  89. allowCopyPasteExcelStyle : false,
  90. allowExtendPasteRange: false,
  91. allowUserDragDrop : false,
  92. allowUserDragFill: false,
  93. scrollbarMaxAlign : true
  94. }
  95. },
  96. isDef: function (v) {
  97. return v !== undefined && v !== null;
  98. },
  99. isFunc: function (v) {
  100. return this.isDef(v) && typeof v === 'function';
  101. },
  102. //sheet things
  103. setOptions: function (workbook, opts) {
  104. for(let opt in opts){
  105. workbook.options[opt] = opts[opt];
  106. }
  107. },
  108. renderFunc: function (sheet, func) {
  109. sheet.suspendPaint();
  110. sheet.suspendEvent();
  111. if(this.isFunc(func)){
  112. func();
  113. }
  114. sheet.resumePaint();
  115. sheet.resumeEvent();
  116. },
  117. buildSheet: function () {
  118. if(!this.isDef(this.workBook)){
  119. this.workBook = new GC.Spread.Sheets.Workbook($('#sectionSpread')[0], {sheetCount: 1});
  120. this.sheet = this.workBook.getActiveSheet();
  121. this.setOptions(this.workBook, this.setting.options);
  122. this.sheet.options.clipBoardOptions = GC.Spread.Sheets.ClipboardPasteOptions.values;
  123. this.bindEvents(this.sheet);
  124. }
  125. },
  126. bindEvents: function (sheet) {
  127. let me = sectionTreeObj;
  128. const Events = GC.Spread.Sheets.Events;
  129. sheet.bind(Events.SelectionChanged, me.onSelectionChanged);
  130. sheet.bind(Events.EditEnded, me.onEditEnded);
  131. sheet.bind(Events.ClipboardPasted, me.onClipboardPasted);
  132. },
  133. onSelectionChanged: function (sender, info) {
  134. let me = sectionTreeObj;
  135. let row = info.newSelections[0].row;
  136. let section = me.cache[row];
  137. me.initSelection(section);
  138. /* if(info.oldSelections.length === 0 && info.newSelections.length > 0 || info.oldSelections[0].row !== info.newSelections[0].row){
  139. }
  140. else {
  141. me.refreshBtn(null);
  142. }*/
  143. },
  144. onEditEnded: function (sender, args) {
  145. let me = sectionTreeObj;
  146. let postData = [];
  147. let v = me.isDef(args.editingText) ? args.editingText.toString().trim() : '';
  148. let node = me.cache[args.row];
  149. if(me.isDef(node) && node.data.name !== v){
  150. let updateObj = me.getUpdateObj(me.updateType.update, node.getID(), null, null, v, null);
  151. postData.push(updateObj);
  152. //ajax
  153. //update
  154. me.sectionTreeAjax(postData, function (rstData) {
  155. node.data.name = v;
  156. }, function () {
  157. args.sheet.setValue(args.row, args.col, node.data.name ? node.data.name : '');
  158. });
  159. }
  160. },
  161. onClipboardPasted: function (sender, info) {
  162. let me = sectionTreeObj;
  163. let items = sheetCommonObj.analyzePasteData({header: [{dataCode: 'name'}]}, info);
  164. let postData = [];
  165. let frontData = [];
  166. for(let i = 0, len = items.length; i < len; i++){
  167. let row = info.cellRange.row + i;
  168. let node = me.cache[row];
  169. if(me.isDef(node) && me.isDef(items[i].name) && node.data.name !== items[i].name){
  170. let updateObj = me.getUpdateObj(me.updateType.update, node.getID(), null, null, items[i].name, null);
  171. postData.push(updateObj);
  172. frontData.push({row: row, name: items[i].name});
  173. node.data.name = items[i].name;
  174. }
  175. }
  176. if(postData.length > 0){
  177. //ajax
  178. me.sectionTreeAjax(postData, function (rstData) {
  179. for(let i = 0, len = frontData.length; i < len; i++){
  180. let node = me.cache[frontData[i]['row']];
  181. if(me.isDef(node)){
  182. node.data.name = frontData[i]['name'];
  183. }
  184. }
  185. }, function () {
  186. for(let i = 0, len = frontData.length; i < len; i++){
  187. let node = me.cache[frontData[i]['row']];
  188. me.sheet.setValue(frontData[i]['row'], 0, me.isDef(node) ? node.data.name : '');
  189. }
  190. });
  191. }
  192. },
  193. getSectionTree: function (repId) {
  194. let me = sectionTreeObj;
  195. let url = 'api/getRationTree';
  196. let postData = {rationLibId: repId};
  197. let sucFunc = function (rstData) {
  198. if(rstData.length > 0){
  199. storageUtil.setSessionCache("RationGrp","repositoryID",rstData[0].rationRepId);
  200. }
  201. //init
  202. me.buildSheet();
  203. me.initTree(rstData);
  204. me.cache = me.tree.items;
  205. me.bindBtn();
  206. me.initController(me.tree, me.sheet, me.setting.sheet);
  207. me.controller.showTreeData();
  208. me.sheet.setFormatter(-1, 0, '@');
  209. me.initSelection(me.tree.selected);
  210. explanatoryOprObj.bindEvents($('#explanationShow'), $('#ruleTextShow'));
  211. };
  212. let errFunc = function () {
  213. };
  214. CommonAjax.post(url, postData, sucFunc, errFunc);
  215. },
  216. initTree: function (datas) {
  217. this.tree = idTree.createNew(this.setting.tree);
  218. this.tree.loadDatas(datas);
  219. this.tree.selected = this.tree.items.length > 0 ? this.tree.items[0] : null;
  220. },
  221. initController: function (tree, sheet, setting) {
  222. this.controller = TREE_SHEET_CONTROLLER.createNew(tree, sheet, setting);
  223. },
  224. refreshBtn: function (selected) {
  225. let me = this;
  226. me.insertBtn.removeClass('disabled');
  227. me.removeBtn.removeClass('disabled');
  228. me.upLevelBtn.removeClass('disabled');
  229. me.downLevelBtn.removeClass('disabled');
  230. me.downMoveBtn.removeClass('disabled');
  231. me.upMoveBtn.removeClass('disabled');
  232. if(!me.isDef(selected)){
  233. me.removeBtn.addClass('disabled');
  234. me.upLevelBtn.addClass('disabled');
  235. me.downLevelBtn.addClass('disabled');
  236. me.downMoveBtn.addClass('disabled');
  237. me.upMoveBtn.addClass('disabled');
  238. }
  239. else {
  240. if(!me.isDef(selected.preSibling)){
  241. me.downLevelBtn.addClass('disabled');
  242. me.upMoveBtn.addClass('disabled');
  243. }
  244. if(!me.isDef(selected.nextSibling)){
  245. me.downMoveBtn.addClass('disabled');
  246. }
  247. if(!me.isDef(selected.parent)){
  248. me.upLevelBtn.addClass('disabled');
  249. }
  250. }
  251. },
  252. bindBtn: function () {
  253. let me = this;
  254. me.insertBtn.click(function () {
  255. me.insert();
  256. });
  257. me.removeBtn.click(function () {
  258. me.remove(me.tree.selected);
  259. });
  260. me.upLevelBtn.click(function () {
  261. me.upLevel(me.tree.selected);
  262. });
  263. me.downLevelBtn.click(function () {
  264. me.downLevel(me.tree.selected);
  265. });
  266. me.downMoveBtn.click(function () {
  267. me.downMove(me.tree.selected);
  268. });
  269. me.upMoveBtn.click(function () {
  270. me.upMove(me.tree.selected);
  271. });
  272. },
  273. insert: function () {
  274. let me = this;
  275. me.insertBtn.addClass('disabled');
  276. let postData = [];
  277. CommonAjax.post('api/getNewRationTreeID', {}, function (newID) {
  278. if(!me.isDef(newID)){
  279. return;
  280. }
  281. me.tree.maxNodeID(newID - 1);
  282. let selected = me.tree.selected;
  283. let insertObj = me.getUpdateObj(me.updateType.new, newID, -1, -1, '', null);
  284. if(me.isDef(selected)) {
  285. let updateObj = me.getUpdateObj(me.updateType.update, selected.getID(), newID, null, null, null);
  286. postData.push(updateObj);
  287. insertObj.updateData.ParentID = selected.getParentID();
  288. if(me.isDef(selected.nextSibling)){
  289. insertObj.updateData.NextSiblingID = selected.getNextSiblingID();
  290. }
  291. }
  292. postData.push(insertObj);
  293. if(postData.length > 0){
  294. //ajax
  295. me.sectionTreeAjax(postData, function (rstData) {
  296. me.controller.insert();
  297. me.refreshBtn(me.tree.selected);
  298. //fresh tools
  299. me.initTools(me.tree.selected);
  300. me.workBook.focus();
  301. });
  302. }
  303. });
  304. },
  305. remove: function (selected) {
  306. let me = this;
  307. me.removeBtn.addClass('disabled');
  308. let postData = [], IDs = [];
  309. if(!selected){
  310. return;
  311. }
  312. getDelIds(selected);
  313. function getDelIds(node){
  314. if(me.isDef(node)){
  315. IDs.push(node.getID());
  316. if(node.children.length > 0){
  317. for(let i = 0, len = node.children.length; i < len; i++){
  318. getDelIds(node.children[i]);
  319. }
  320. }
  321. }
  322. }
  323. if(me.isDef(selected.preSibling)){
  324. let updateObj = me.getUpdateObj(me.updateType.update, selected.preSibling.getID(), selected.getNextSiblingID(), null, null, null);
  325. postData.push(updateObj);
  326. }
  327. if(IDs.length > 0){
  328. for(let i = 0, len = IDs.length; i < len; i++){
  329. let delObj = me.getUpdateObj(me.updateType.update, IDs[i], null, null, null, true);
  330. postData.push(delObj);
  331. }
  332. }
  333. if(postData.length > 0){
  334. //ajax
  335. me.sectionTreeAjax(postData, function (rstData) {
  336. me.controller.delete();
  337. me.refreshBtn(me.tree.selected);
  338. me.initTools(me.tree.selected);
  339. me.workBook.focus();
  340. });
  341. }
  342. },
  343. getSameDepthNodes: function(){
  344. let rst = [];
  345. let sel = this.sheet.getSelections()[0];
  346. let selectedDepth = this.tree.selected.depth();
  347. for(let i = 0; i < sel.rowCount; i++){
  348. let row = sel.row + i;
  349. if(this.cache[row].depth() === selectedDepth){
  350. rst.push(this.cache[row]);
  351. }
  352. }
  353. return rst;
  354. },
  355. upLevel: function (selected) {
  356. let me = this;
  357. me.upLevelBtn.addClass('disabled');
  358. let postData = [];
  359. let selNodes = me.getSameDepthNodes();
  360. if(selNodes.length <= 0){
  361. return ;
  362. }
  363. let firstParent = selNodes[0].parent;
  364. if(!me.isDef(firstParent)){
  365. return;
  366. }
  367. //更新父节点
  368. postData.push(me.getUpdateObj(me.updateType.update, firstParent.getID(), selNodes[0].getID(), null, null, null));
  369. //更新前节点
  370. if(me.isDef(selNodes[0].preSibling)){
  371. postData.push(me.getUpdateObj(me.updateType.update, selNodes[0].preSibling.getID(), -1, null, null, null));
  372. }
  373. //更新选中节点的后兄弟节点
  374. let lastSelNode = selNodes[selNodes.length - 1];
  375. let nextIDs = [];
  376. getNext(lastSelNode);
  377. function getNext(node){
  378. if(me.isDef(node.nextSibling)){
  379. nextIDs.push(node.getNextSiblingID());
  380. getNext(node.nextSibling);
  381. }
  382. }
  383. for(let nextID of nextIDs){
  384. postData.push(me.getUpdateObj(me.updateType.update, nextID, null, lastSelNode.getID(), null, null));
  385. }
  386. //更新选中节点
  387. for(let i = 0; i < selNodes.length; i++){
  388. let selNode = selNodes[i];
  389. let nid = i === selNodes.length - 1 ? firstParent.getNextSiblingID() : selNode.getNextSiblingID();
  390. postData.push(me.getUpdateObj(me.updateType.update, selNode.getID(), nid, firstParent.getParentID(), null, null));
  391. }
  392. if(postData.length > 0){
  393. //ajax
  394. me.sectionTreeAjax(postData, function (rstData) {
  395. for(let selNode of selNodes){
  396. me.controller.setTreeSelected(selNode);
  397. me.controller.upLevel();
  398. }
  399. me.refreshBtn(me.tree.selected);
  400. me.workBook.focus();
  401. });
  402. }
  403. },
  404. downLevel: function (selected) {
  405. let me = this;
  406. me.downLevelBtn.addClass('disabled');
  407. let postData = [];
  408. let selNodes = me.getSameDepthNodes();
  409. if(selNodes.length <= 0 ){
  410. return;
  411. }
  412. let firstPreSibling = selNodes[0].preSibling;
  413. if(!me.isDef(firstPreSibling)){
  414. return;
  415. }
  416. //更新前节点
  417. postData.push(me.getUpdateObj(me.updateType.update, firstPreSibling.getID(), selNodes[selNodes.length - 1].getNextSiblingID(), null, null, null));
  418. //更新前节点最末子节点
  419. if(firstPreSibling.children.length > 0){
  420. postData.push(me.getUpdateObj(me.updateType.update, firstPreSibling.children[firstPreSibling.children.length - 1].getID(), selNodes[0].getID(), null, null, null));
  421. }
  422. //更新选中节点
  423. for(let i = 0; i < selNodes.length; i++){
  424. let selNode = selNodes[i];
  425. postData.push(me.getUpdateObj(me.updateType.update, selNode.getID(), i === selNodes.length - 1 ? -1 : selNode.getNextSiblingID(), firstPreSibling.getID(), null, null));
  426. }
  427. if(postData.length > 0){
  428. //ajax
  429. me.sectionTreeAjax(postData, function (rstData) {
  430. for(let selNode of selNodes){
  431. me.controller.setTreeSelected(selNode);
  432. me.controller.downLevel();
  433. }
  434. me.refreshBtn(me.tree.selected);
  435. me.workBook.focus();
  436. });
  437. }
  438. },
  439. upMove: function (selected) {
  440. let me = this;
  441. me.upMoveBtn.addClass('disabled');
  442. let postData = [];
  443. if(!me.isDef(selected)){
  444. return;
  445. }
  446. if(!me.isDef(selected.preSibling)){
  447. return;
  448. }
  449. let updateObj = me.getUpdateObj(me.updateType.update, selected.getID(), selected.preSibling.getID(), null, null, null);
  450. postData.push(updateObj);
  451. let updatePre = me.getUpdateObj(me.updateType.update, selected.preSibling.getID(), selected.getNextSiblingID(), null, null, null);
  452. postData.push(updatePre);
  453. if(me.isDef(selected.preSibling.preSibling)){
  454. let updatePrepre = me.getUpdateObj(me.updateType.update, selected.preSibling.preSibling.getID(), selected.getID(), null, null, null);
  455. postData.push(updatePrepre);
  456. }
  457. if(postData.length > 0){
  458. //ajax
  459. me.sectionTreeAjax(postData, function (rstData) {
  460. me.controller.upMove();
  461. me.refreshBtn(me.tree.selected);
  462. me.workBook.focus();
  463. });
  464. }
  465. },
  466. downMove: function (selected) {
  467. let me = this;
  468. me.downMoveBtn.addClass('disabled');
  469. let postData = [];
  470. if(!me.isDef(selected)){
  471. return;
  472. }
  473. if(!me.isDef(selected.nextSibling)){
  474. return;
  475. }
  476. if(me.isDef(selected.preSibling)){
  477. let updatePre = me.getUpdateObj(me.updateType.update, selected.preSibling.getID(), selected.getNextSiblingID(), null, null, null);
  478. postData.push(updatePre);
  479. }
  480. let updateObj = me.getUpdateObj(me.updateType.update, selected.getID(), selected.nextSibling.getNextSiblingID(), null, null, null);
  481. postData.push(updateObj);
  482. let updateNext = me.getUpdateObj(me.updateType.update, selected.getNextSiblingID(), selected.getID(), null, null, null);
  483. postData.push(updateNext);
  484. if(postData.length > 0){
  485. //ajax
  486. me.sectionTreeAjax(postData, function (rstData) {
  487. me.controller.downMove();
  488. me.refreshBtn(me.tree.selected);
  489. me.workBook.focus();
  490. });
  491. }
  492. },
  493. getUpdateObj: function (updateType, id, nid, pid, name, deleted) {
  494. let updateObj = Object.create(null);
  495. updateObj.updateType = '';
  496. updateObj.updateData = Object.create(null);
  497. updateObj.updateData.rationRepId = pageOprObj.rationLibId;
  498. if(this.isDef(updateType)){
  499. updateObj.updateType = updateType;
  500. }
  501. if(this.isDef(id)){
  502. updateObj.updateData.ID = id;
  503. }
  504. if(this.isDef(nid)){
  505. updateObj.updateData.NextSiblingID = nid;
  506. }
  507. if(this.isDef(pid)){
  508. updateObj.updateData.ParentID = pid;
  509. }
  510. if(this.isDef(name)){
  511. updateObj.updateData.name = name;
  512. }
  513. if(this.isDef(deleted)){
  514. updateObj.updateData.isDeleted = true;
  515. }
  516. return updateObj;
  517. },
  518. sectionTreeAjax: function (postData, scFunc, errFunc) {
  519. CommonAjax.post('api/updateNodes', {updateData: postData, lastOpr: userAccount}, scFunc, errFunc);
  520. },
  521. initTools: function (node) {
  522. if(this.isDef(node)){
  523. explanatoryOprObj.setAttribute(explanatoryOprObj.currentTreeNode ? explanatoryOprObj.currentTreeNode : node, node, node.data.explanation, node.data.ruleText);
  524. explanatoryOprObj.clickUpdate($('#explanationShow'), $('#ruleTextShow'));
  525. explanatoryOprObj.showText($('#explanationShow'), $('#ruleTextShow'), node.data.explanation, node.data.ruleText);
  526. //job
  527. jobContentOprObj.currentSituation = typeof node.data.jobContentSituation !== 'undefined'? node.data.jobContentSituation : jobContentOprObj.situations.NONE;
  528. jobContentOprObj.setAttribute(jobContentOprObj.currentTreeNode ? jobContentOprObj.currentTreeNode : node, node);
  529. jobContentOprObj.clickUpdate($('#txtareaAll'));
  530. //fz
  531. annotationOprObj.currentSituation = typeof node.data.annotationSituation !== 'undefined'? node.data.annotationSituation : annotationOprObj.situations.NONE;
  532. annotationOprObj.clickUpdate($('#fzTxtareaAll'));
  533. }
  534. },
  535. //模仿默认点击
  536. initSelection: function (node) {
  537. let me = this;
  538. if(!me.isDef(node)){
  539. return;
  540. }
  541. me.initTools(node);
  542. me.refreshBtn(node);
  543. if(!me.isDef(node.children) || node.children.length === 0){
  544. rationOprObj.canRations = true;
  545. rationOprObj.workBook.getSheet(0).clearSelection();
  546. rationOprObj.getRationItems(node.data.ID);
  547. rationOprObj.setCombo(rationOprObj.workBook.getSheet(0), 'dynamic');
  548. }
  549. else {
  550. rationOprObj.canRations = false;
  551. rationOprObj.currentSectionId = node.data.ID;
  552. rationOprObj.workBook.getSheet(0).setRowCount(30);
  553. rationOprObj.setCombo(rationOprObj.workBook.getSheet(0), null);
  554. jobContentOprObj.setRadiosDisabled(true, jobContentOprObj.radios);
  555. jobContentOprObj.hideTable($('#tableAll'), $('#tablePartial'));
  556. annotationOprObj.setRadiosDisabled(true, annotationOprObj.radios);
  557. annotationOprObj.hideTable($('#fzTableAll'), $('#fzTablePartial'));
  558. sheetCommonObj.cleanSheet(rationOprObj.workBook.getSheet(0), rationOprObj.setting, -1);
  559. rationGLJOprObj.sheet.getParent().focus(false);
  560. }
  561. sheetCommonObj.cleanSheet(rationGLJOprObj.sheet, rationGLJOprObj.setting, -1);
  562. sheetCommonObj.cleanSheet(rationAssistOprObj.sheet, rationAssistOprObj.setting, -1);
  563. sheetCommonObj.cleanSheet(rationCoeOprObj.sheet, rationCoeOprObj.setting, -1);
  564. sheetCommonObj.cleanSheet(rationInstObj.sheet, rationInstObj.setting, -1);
  565. me.workBook.focus(true);
  566. }
  567. };