section_tree.js 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582
  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. postData.push(me.getUpdateObj(me.updateType.update, selNode.getID(), firstParent.getNextSiblingID(), firstParent.getParentID(), null, null));
  390. }
  391. if(postData.length > 0){
  392. //ajax
  393. me.sectionTreeAjax(postData, function (rstData) {
  394. for(let selNode of selNodes){
  395. me.controller.setTreeSelected(selNode);
  396. me.controller.upLevel();
  397. }
  398. me.refreshBtn(me.tree.selected);
  399. me.workBook.focus();
  400. });
  401. }
  402. },
  403. downLevel: function (selected) {
  404. let me = this;
  405. me.downLevelBtn.addClass('disabled');
  406. let postData = [];
  407. let selNodes = me.getSameDepthNodes();
  408. if(selNodes.length <= 0 ){
  409. return;
  410. }
  411. let firstPreSibling = selNodes[0].preSibling;
  412. if(!me.isDef(firstPreSibling)){
  413. return;
  414. }
  415. //更新前节点
  416. postData.push(me.getUpdateObj(me.updateType.update, firstPreSibling.getID(), selNodes[selNodes.length - 1].getNextSiblingID(), null, null, null));
  417. //更新前节点最末子节点
  418. if(firstPreSibling.children.length > 0){
  419. postData.push(me.getUpdateObj(me.updateType.update, firstPreSibling.children[firstPreSibling.children.length - 1].getID(), selNodes[0].getID(), null, null, null));
  420. }
  421. //更新选中节点
  422. for(let i = 0; i < selNodes.length; i++){
  423. let selNode = selNodes[i];
  424. postData.push(me.getUpdateObj(me.updateType.update, selNode.getID(), i === selNodes.length - 1 ? -1 : selNode.getNextSiblingID(), firstPreSibling.getID(), null, null));
  425. }
  426. if(postData.length > 0){
  427. //ajax
  428. me.sectionTreeAjax(postData, function (rstData) {
  429. for(let selNode of selNodes){
  430. me.controller.setTreeSelected(selNode);
  431. me.controller.downLevel();
  432. }
  433. me.refreshBtn(me.tree.selected);
  434. me.workBook.focus();
  435. });
  436. }
  437. },
  438. upMove: function (selected) {
  439. let me = this;
  440. me.upMoveBtn.addClass('disabled');
  441. let postData = [];
  442. if(!me.isDef(selected)){
  443. return;
  444. }
  445. if(!me.isDef(selected.preSibling)){
  446. return;
  447. }
  448. let updateObj = me.getUpdateObj(me.updateType.update, selected.getID(), selected.preSibling.getID(), null, null, null);
  449. postData.push(updateObj);
  450. let updatePre = me.getUpdateObj(me.updateType.update, selected.preSibling.getID(), selected.getNextSiblingID(), null, null, null);
  451. postData.push(updatePre);
  452. if(me.isDef(selected.preSibling.preSibling)){
  453. let updatePrepre = me.getUpdateObj(me.updateType.update, selected.preSibling.preSibling.getID(), selected.getID(), null, null, null);
  454. postData.push(updatePrepre);
  455. }
  456. if(postData.length > 0){
  457. //ajax
  458. me.sectionTreeAjax(postData, function (rstData) {
  459. me.controller.upMove();
  460. me.refreshBtn(me.tree.selected);
  461. me.workBook.focus();
  462. });
  463. }
  464. },
  465. downMove: function (selected) {
  466. let me = this;
  467. me.downMoveBtn.addClass('disabled');
  468. let postData = [];
  469. if(!me.isDef(selected)){
  470. return;
  471. }
  472. if(!me.isDef(selected.nextSibling)){
  473. return;
  474. }
  475. if(me.isDef(selected.preSibling)){
  476. let updatePre = me.getUpdateObj(me.updateType.update, selected.preSibling.getID(), selected.getNextSiblingID(), null, null, null);
  477. postData.push(updatePre);
  478. }
  479. let updateObj = me.getUpdateObj(me.updateType.update, selected.getID(), selected.nextSibling.getNextSiblingID(), null, null, null);
  480. postData.push(updateObj);
  481. let updateNext = me.getUpdateObj(me.updateType.update, selected.getNextSiblingID(), selected.getID(), null, null, null);
  482. postData.push(updateNext);
  483. if(postData.length > 0){
  484. //ajax
  485. me.sectionTreeAjax(postData, function (rstData) {
  486. me.controller.downMove();
  487. me.refreshBtn(me.tree.selected);
  488. me.workBook.focus();
  489. });
  490. }
  491. },
  492. getUpdateObj: function (updateType, id, nid, pid, name, deleted) {
  493. let updateObj = Object.create(null);
  494. updateObj.updateType = '';
  495. updateObj.updateData = Object.create(null);
  496. updateObj.updateData.rationRepId = pageOprObj.rationLibId;
  497. if(this.isDef(updateType)){
  498. updateObj.updateType = updateType;
  499. }
  500. if(this.isDef(id)){
  501. updateObj.updateData.ID = id;
  502. }
  503. if(this.isDef(nid)){
  504. updateObj.updateData.NextSiblingID = nid;
  505. }
  506. if(this.isDef(pid)){
  507. updateObj.updateData.ParentID = pid;
  508. }
  509. if(this.isDef(name)){
  510. updateObj.updateData.name = name;
  511. }
  512. if(this.isDef(deleted)){
  513. updateObj.updateData.isDeleted = true;
  514. }
  515. return updateObj;
  516. },
  517. sectionTreeAjax: function (postData, scFunc, errFunc) {
  518. CommonAjax.post('api/updateNodes', {updateData: postData, lastOpr: userAccount}, scFunc, errFunc);
  519. },
  520. initTools: function (node) {
  521. if(this.isDef(node)){
  522. explanatoryOprObj.setAttribute(explanatoryOprObj.currentTreeNode ? explanatoryOprObj.currentTreeNode : node, node, node.data.explanation, node.data.ruleText);
  523. explanatoryOprObj.clickUpdate($('#explanationShow'), $('#ruleTextShow'));
  524. explanatoryOprObj.showText($('#explanationShow'), $('#ruleTextShow'), node.data.explanation, node.data.ruleText);
  525. //job
  526. jobContentOprObj.currentSituation = typeof node.data.jobContentSituation !== 'undefined'? node.data.jobContentSituation : jobContentOprObj.situations.NONE;
  527. jobContentOprObj.setAttribute(jobContentOprObj.currentTreeNode ? jobContentOprObj.currentTreeNode : node, node);
  528. jobContentOprObj.clickUpdate($('#txtareaAll'));
  529. //fz
  530. annotationOprObj.currentSituation = typeof node.data.annotationSituation !== 'undefined'? node.data.annotationSituation : annotationOprObj.situations.NONE;
  531. annotationOprObj.clickUpdate($('#fzTxtareaAll'));
  532. }
  533. },
  534. //模仿默认点击
  535. initSelection: function (node) {
  536. let me = this;
  537. if(!me.isDef(node)){
  538. return;
  539. }
  540. me.initTools(node);
  541. me.refreshBtn(node);
  542. if(!me.isDef(node.children) || node.children.length === 0){
  543. rationOprObj.canRations = true;
  544. rationOprObj.workBook.getSheet(0).clearSelection();
  545. rationOprObj.getRationItems(node.data.ID);
  546. rationOprObj.setCombo(rationOprObj.workBook.getSheet(0), 'dynamic');
  547. }
  548. else {
  549. rationOprObj.canRations = false;
  550. rationOprObj.currentSectionId = node.data.ID;
  551. rationOprObj.workBook.getSheet(0).setRowCount(30);
  552. rationOprObj.setCombo(rationOprObj.workBook.getSheet(0), null);
  553. jobContentOprObj.setRadiosDisabled(true, jobContentOprObj.radios);
  554. jobContentOprObj.hideTable($('#tableAll'), $('#tablePartial'));
  555. annotationOprObj.setRadiosDisabled(true, annotationOprObj.radios);
  556. annotationOprObj.hideTable($('#fzTableAll'), $('#fzTablePartial'));
  557. sheetCommonObj.cleanSheet(rationOprObj.workBook.getSheet(0), rationOprObj.setting, -1);
  558. rationGLJOprObj.sheet.getParent().focus(false);
  559. }
  560. sheetCommonObj.cleanSheet(rationGLJOprObj.sheet, rationGLJOprObj.setting, -1);
  561. sheetCommonObj.cleanSheet(rationAssistOprObj.sheet, rationAssistOprObj.setting, -1);
  562. sheetCommonObj.cleanSheet(rationCoeOprObj.sheet, rationCoeOprObj.setting, -1);
  563. sheetCommonObj.cleanSheet(rationInstObj.sheet, rationInstObj.setting, -1);
  564. me.workBook.focus(true);
  565. }
  566. };