|
@@ -62,6 +62,7 @@ const checkOption = {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
$(document).ready(function() {
|
|
$(document).ready(function() {
|
|
|
|
|
+ const aiTrans = AITrans();
|
|
|
const unit = ledgerSpreadSetting.cols.find(x => { return x.field === 'unit'; });
|
|
const unit = ledgerSpreadSetting.cols.find(x => { return x.field === 'unit'; });
|
|
|
if (unit) unit.comboEdit = true;
|
|
if (unit) unit.comboEdit = true;
|
|
|
let stdXmj, stdGcl, dealBills, searchLedger, featureDisplay, posDisplay;
|
|
let stdXmj, stdGcl, dealBills, searchLedger, featureDisplay, posDisplay;
|
|
@@ -133,7 +134,6 @@ $(document).ready(function() {
|
|
|
const ancGclSheet = ancGclSpread.getActiveSheet();
|
|
const ancGclSheet = ancGclSpread.getActiveSheet();
|
|
|
|
|
|
|
|
// 设计量明细相关
|
|
// 设计量明细相关
|
|
|
- const aiTrans = AITrans();
|
|
|
|
|
const posCalcDetail = (function() {
|
|
const posCalcDetail = (function() {
|
|
|
const detail = createPosCalcDetail({ id: 'id', masterId: 'pid', topId: 'lid', sort: [['pcd_order', 'asc']]});
|
|
const detail = createPosCalcDetail({ id: 'id', masterId: 'pid', topId: 'lid', sort: [['pcd_order', 'asc']]});
|
|
|
const spread = SpreadJsObj.createNewSpread($('#pos-detail-spread')[0]);
|
|
const spread = SpreadJsObj.createNewSpread($('#pos-detail-spread')[0]);
|
|
@@ -518,7 +518,7 @@ $(document).ready(function() {
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- return { detail, spread, sheet, refresh, loadCurDetailData, reloadCurDetailData }
|
|
|
|
|
|
|
+ return { detail, spread, sheet, refresh, loadCurDetailData, reloadCurDetailData, afterPostData: ctrlObj.afterPostData }
|
|
|
})();
|
|
})();
|
|
|
const ancGclDetail = (function() {
|
|
const ancGclDetail = (function() {
|
|
|
const detail = createAncGclDetail({ id: 'id', masterId: 'ag_id', firstId: 'lid', secondId: 'pid', sort: [['agd_order', 'asc']]});
|
|
const detail = createAncGclDetail({ id: 'id', masterId: 'ag_id', firstId: 'lid', secondId: 'pid', sort: [['agd_order', 'asc']]});
|
|
@@ -1732,6 +1732,8 @@ $(document).ready(function() {
|
|
|
$('#dqjiedian').find('.check-all-file').prop('checked', false);
|
|
$('#dqjiedian').find('.check-all-file').prop('checked', false);
|
|
|
}
|
|
}
|
|
|
SpreadJsObj.saveTopAndSelect(info.sheet, ckBillsSpread);
|
|
SpreadJsObj.saveTopAndSelect(info.sheet, ckBillsSpread);
|
|
|
|
|
+ const curNode = SpreadJsObj.getSelectObject(info.sheet);
|
|
|
|
|
+ aiTrans.setRelaInfo('bills', curNode, curNode);
|
|
|
},
|
|
},
|
|
|
topRowChanged(e, info) {
|
|
topRowChanged(e, info) {
|
|
|
SpreadJsObj.saveTopAndSelect(info.sheet, ckBillsSpread);
|
|
SpreadJsObj.saveTopAndSelect(info.sheet, ckBillsSpread);
|
|
@@ -3459,6 +3461,7 @@ $(document).ready(function() {
|
|
|
posOperationObj.refreshOperationValid(posSpread.getActiveSheet());
|
|
posOperationObj.refreshOperationValid(posSpread.getActiveSheet());
|
|
|
posCalcDetail.loadCurDetailData();
|
|
posCalcDetail.loadCurDetailData();
|
|
|
ancGclObj.loadCurAncillaryGcl();
|
|
ancGclObj.loadCurAncillaryGcl();
|
|
|
|
|
+ aiTrans.setRelaInfo('pos', SpreadJsObj.getSelectObject(info.sheet), SpreadJsObj.getSelectObject(ledgerSheet));
|
|
|
},
|
|
},
|
|
|
addPegs: function (pegs) {
|
|
addPegs: function (pegs) {
|
|
|
if (!pegs || pegs.length <= 0) return;
|
|
if (!pegs || pegs.length <= 0) return;
|
|
@@ -3991,6 +3994,7 @@ $(document).ready(function() {
|
|
|
},
|
|
},
|
|
|
selectionChanged: function(e, info) {
|
|
selectionChanged: function(e, info) {
|
|
|
ancGclDetail.loadCurDetailData();
|
|
ancGclDetail.loadCurDetailData();
|
|
|
|
|
+ aiTrans.setRelaInfo('ancGcl', SpreadJsObj.getSelectObject(info.sheet), SpreadJsObj.getSelectObject(ledgerSheet));
|
|
|
},
|
|
},
|
|
|
removeCalcTemplate: function(node) {
|
|
removeCalcTemplate: function(node) {
|
|
|
const ancGclUpdateData = { calcTmpl: { id: node.id, calc_template: '' } };
|
|
const ancGclUpdateData = { calcTmpl: { id: node.id, calc_template: '' } };
|
|
@@ -6473,7 +6477,9 @@ $(document).ready(function() {
|
|
|
$('#binddskuser').modal('show');
|
|
$('#binddskuser').modal('show');
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
-
|
|
|
|
|
|
|
+ $('.ai-btn').click(function() {
|
|
|
|
|
+ if (aiTrans.rela_type() === 'pos') aiTrans.transDetail(posCalcDetail.afterPostData);
|
|
|
|
|
+ });
|
|
|
});
|
|
});
|
|
|
// 生成当前节点列表
|
|
// 生成当前节点列表
|
|
|
function getNodeList(node) {
|
|
function getNodeList(node) {
|
|
@@ -6499,7 +6505,7 @@ function getNodeList(node) {
|
|
|
}
|
|
}
|
|
|
$('#nodelist-table').html(html);
|
|
$('#nodelist-table').html(html);
|
|
|
$('#nodelist-table').on('click', 'tr', function() {
|
|
$('#nodelist-table').on('click', 'tr', function() {
|
|
|
- $('#nodelist-table tr').removeClass('bg-light')
|
|
|
|
|
|
|
+ $('#nodelist-table tr').removeClass('bg-light');
|
|
|
$(this).addClass('bg-light')
|
|
$(this).addClass('bg-light')
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|