|
@@ -1316,7 +1316,7 @@ $(document).ready(() => {
|
|
|
} else {
|
|
|
$('#pos-expr').val('').attr('readOnly', true);
|
|
|
$('#pos-expr').removeAttr('data-row');
|
|
|
- }
|
|
|
+ }
|
|
|
},
|
|
|
/**
|
|
|
* 加载计量单元 根据当前台账选择节点
|
|
@@ -1326,7 +1326,7 @@ $(document).ready(() => {
|
|
|
if (node) {
|
|
|
const posData = pos.getLedgerPos(node.id) || [];
|
|
|
SpreadJsObj.loadSheetData(posSheet, 'data', posData);
|
|
|
- posSheet.zh_setting.readOnly = readOnly || posData.length === 0;
|
|
|
+ posSheet.zh_setting.readOnly = readOnly || (node.used && posData.length === 0);
|
|
|
} else {
|
|
|
SpreadJsObj.loadSheetData(posSheet, 'data', []);
|
|
|
posSheet.zh_setting.readOnly = true;
|