|
@@ -68,14 +68,26 @@
|
|
|
</div>
|
|
|
<div class="main-side col-lg-5 p-0">
|
|
|
<div class="container-fluid">
|
|
|
- <div class="row">
|
|
|
- <div class="col" style="width:50%; height: 100%">
|
|
|
+ <div style="width:50%; height: 100%; float: left;">
|
|
|
+ <h5>工作内容</h5>
|
|
|
+ <div id="spreadJobs" class="ovf-hidden" style="width:97%; height: 300px;"></div>
|
|
|
+ </div>
|
|
|
+ <div style="width:50%; height: 100%; float: left;">
|
|
|
+ <h5>项目特征</h5>
|
|
|
+ <div id="spreadItems" class="ovf-hidden" style="width: 97%; height: 300px;"></div>
|
|
|
+ </div>
|
|
|
+ <div class="form-group">
|
|
|
+ <label for="exampleTextarea"><h5>补注:</h5></label>
|
|
|
+ <textarea class="form-control" id="exampleTextarea" rows="8"></textarea>
|
|
|
+ </div>
|
|
|
+ <!-- <div class="row">
|
|
|
+ <div class="col ovf-hidden" style="width:50%; height: 100%; float: left;">
|
|
|
<h5>工作内容</h5>
|
|
|
<div id="spreadJobs" style="width:97%; height: 300px;"></div>
|
|
|
</div>
|
|
|
- <div class="col" style="width:50%; height: 100%">
|
|
|
+ <div class="col" style="width:50%; height: 100%; float: left;">
|
|
|
<h5>项目特征</h5>
|
|
|
- <div id="spreadItems" style="width: 97%; height: 300px;"></div>
|
|
|
+ <div id="spreadItems" class="ovf-hidden" style="width: 97%; height: 300px;"></div>
|
|
|
</div>
|
|
|
<div class="w-100"></div>
|
|
|
<div class="col">
|
|
@@ -84,7 +96,7 @@
|
|
|
<textarea class="form-control" id="exampleTextarea" rows="8"></textarea>
|
|
|
</div>
|
|
|
</div>
|
|
|
- </div>
|
|
|
+ </div>-->
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -374,11 +386,7 @@
|
|
|
let btnDownMove = $('#downMove');
|
|
|
let btnUpLevel = $('#upLevel');
|
|
|
let btnDownLevel = $('#downLevel');
|
|
|
- // billsSheet.clearSelection();
|
|
|
- // billsSheet.options.isProtected = true;
|
|
|
- // controller.setTreeSelected(null);
|
|
|
billsSheet.bind(GC.Spread.Sheets.Events.CellClick, function (sender, args) {
|
|
|
- // if(billsSheet.options.isProtected){
|
|
|
jobsSheet.clearSelection();
|
|
|
itemsSheet.clearSelection();
|
|
|
billsSpread.focus(true);
|
|
@@ -392,21 +400,8 @@
|
|
|
btnDownLevel.attr('fcsOnBills', 'true');
|
|
|
btnUpMove.attr('fcsOnBills', 'true');
|
|
|
btnDownMove.attr('fcsOnBills', 'true');
|
|
|
- // }
|
|
|
- // jobsSheet.clearSelection();
|
|
|
- // itemsSheet.clearSelection();
|
|
|
- //billsSheet.options.isProtected = false;
|
|
|
- /* jobsSheet.options.isProtected = true;
|
|
|
- itemsSheet.options.isProtected = true;
|
|
|
- let activeRow = billsSheet.getActiveRowIndex();
|
|
|
- let activeCol = billsSheet.getActiveColumnIndex();
|
|
|
- billsSheet.setActiveCell(activeRow === 0 ? 1: 0, 0);
|
|
|
- billsSheet.setActiveCell(activeRow, activeCol);*/
|
|
|
- // controller.setTreeSelected(controller.tree.findNode(billsSheet.getTag(activeRow, activeCol)));
|
|
|
- // }
|
|
|
});
|
|
|
jobsSheet.bind(GC.Spread.Sheets.Events.CellClick, function (sender, args) {
|
|
|
- // if(jobsSheet.options.isProtected){
|
|
|
itemsSheet.clearSelection();
|
|
|
jobsSpread.focus(true);
|
|
|
itemsSheet.options.isProtected = true;
|
|
@@ -427,18 +422,14 @@
|
|
|
let selected;
|
|
|
if(controller.tree.selected){
|
|
|
selected = controller.tree.selected.jobs[args.row];
|
|
|
- console.log(`selected`);
|
|
|
- console.log(selected);
|
|
|
}
|
|
|
if(tools.canUpMove(selected, controller.tree.selected.jobs)){
|
|
|
tools.btnAction(btnUpMove);
|
|
|
btnUpMove.attr('canMove', 'true');
|
|
|
- console.log(`canup`);
|
|
|
}
|
|
|
else{
|
|
|
tools.btnClose(btnUpMove);
|
|
|
btnUpMove.attr('canMove', 'false');
|
|
|
- console.log(`nocan`);
|
|
|
}
|
|
|
if(tools.canDownMove(selected, controller.tree.selected.jobs)){
|
|
|
tools.btnAction(btnDownMove);
|
|
@@ -448,19 +439,13 @@
|
|
|
tools.btnClose(btnDownMove);
|
|
|
btnDownMove.attr('canMove', 'false');
|
|
|
}
|
|
|
- //}
|
|
|
});
|
|
|
itemsSheet.bind(GC.Spread.Sheets.Events.CellClick, function (sender, args) {
|
|
|
- // if(itemsSheet.options.isProtected){
|
|
|
jobsSheet.clearSelection();
|
|
|
itemsSpread.focus(true);
|
|
|
jobsSheet.options.isProtected = true;
|
|
|
billsSheet.options.isProtected = true;
|
|
|
itemsSheet.options.isProtected = false;
|
|
|
- /*let activeRow = itemsSheet.getActiveRowIndex();
|
|
|
- let activeCol = itemsSheet.getActiveColumnIndex();
|
|
|
- itemsSheet.setActiveCell(activeRow === 0 ? 1: 0, 0);
|
|
|
- itemsSheet.setActiveCell(activeRow, activeCol);*/
|
|
|
|
|
|
controller.tree.selected.args = args;
|
|
|
controller.tree.selected.field = 'item';
|
|
@@ -494,7 +479,6 @@
|
|
|
tools.btnClose(btnDownMove);
|
|
|
btnDownMove.attr('canMove', 'false');
|
|
|
}
|
|
|
- //}
|
|
|
});
|
|
|
};
|
|
|
|
|
@@ -516,14 +500,8 @@
|
|
|
let showButton = function (show, btn) {
|
|
|
tools.btnAction($('#insert'), 'focusOnBills');
|
|
|
if (show) {
|
|
|
- //btn.show();
|
|
|
tools.btnAction(btn, 'doing');
|
|
|
- /*btn.css("opacity", "");
|
|
|
- btn.removeClass("disabled");*/
|
|
|
} else {
|
|
|
- //btn.hide();
|
|
|
- /*btn.css("opacity", "0.2");
|
|
|
- btn.addClass("disabled");*/
|
|
|
tools.btnClose(btn, 'doing');
|
|
|
}
|
|
|
};
|
|
@@ -597,6 +575,9 @@
|
|
|
if(arr.length > 0){
|
|
|
tools.orderReshowData(sheet, arr, setting, prefix,true);
|
|
|
}
|
|
|
+ else{
|
|
|
+ setSheet.setMaxRowCount(sheet, []);
|
|
|
+ }
|
|
|
if(recharge){
|
|
|
$('#exampleTextarea').val(recharge);
|
|
|
}
|
|
@@ -692,8 +673,6 @@
|
|
|
}
|
|
|
});
|
|
|
sheet.bind(GC.Spread.Sheets.Events.ClipboardPasted, function(sender, args){
|
|
|
- // sheet.setColumnCount(2, GC.Spread.Sheets.SheetArea.viewport);
|
|
|
- // sheet.setColumnCount(2, GC.Spread.Sheets.SheetArea.colHeader);
|
|
|
if(controller.tree.selected){
|
|
|
let orgRow = args.cellRange.row, orgCol = args.cellRange.col, rowCount = args.cellRange.rowCount, colCount = args.cellRange.colCount;
|
|
|
let maxRow = orgRow + rowCount - 1, maxCol = orgCol + colCount -1;
|
|
@@ -756,8 +735,6 @@
|
|
|
}
|
|
|
});
|
|
|
sheet.bind(GC.Spread.Sheets.Events.ClipboardPasted, function(sender, args){
|
|
|
- //sheet.setColumnCount(2, GC.Spread.Sheets.SheetArea.viewport);
|
|
|
- // sheet.setColumnCount(2, GC.Spread.Sheets.SheetArea.colHeader);
|
|
|
if(controller.tree.selected){
|
|
|
let orgRow = args.cellRange.row, orgCol = args.cellRange.col, rowCount = args.cellRange.rowCount, colCount = args.cellRange.colCount;
|
|
|
let maxRow = orgRow + rowCount - 1, maxCol = orgCol + colCount -1;
|
|
@@ -787,7 +764,6 @@
|
|
|
}
|
|
|
});
|
|
|
if(flag){
|
|
|
- //let serialNo = tools.getSerialNo(controller.tree.selected.items);
|
|
|
serialNoUn ++;
|
|
|
console.log(serialNoUn);
|
|
|
uncrossedDatas.push({data: uniqPasteArr[j], serialNo: serialNoUn});
|
|
@@ -815,7 +791,6 @@
|
|
|
|
|
|
function buildJobs(jobsSpread, setting){
|
|
|
setSheet.initSheet(jobsSpread, setting, true);
|
|
|
- // setSheet.setMaxRowCount(jobsSpread.getActiveSheet(), 10);
|
|
|
jobsSpread.getActiveSheet().clearSelection();
|
|
|
myKey.downKey(jobsSpread);
|
|
|
myKey.enterKey(jobsSpread);
|