private void UpdateChangeableStatus() { Boolean allowSubmit = (FPreviouslySelectedDetailRow != null) && (grdDetails.Rows.Count > 1); FPetraUtilsObject.EnableAction("actSubmitBatch", allowSubmit); FPetraUtilsObject.EnableAction("actDelete", allowSubmit); pnlDetails.Enabled = allowSubmit; pnlDetailsProtected = !allowSubmit; if ((FPreviouslySelectedDetailRow == null) && (((TFrmRecurringGLBatch)this.ParentForm) != null)) { ((TFrmRecurringGLBatch)this.ParentForm).DisableJournals(); } }
private void UpdateChangeableStatus() { FPetraUtilsObject.EnableAction("actReverseBatch", (FPreviouslySelectedDetailRow != null) && FPreviouslySelectedDetailRow.BatchStatus == MFinanceConstants.BATCH_POSTED); Boolean postable = (FPreviouslySelectedDetailRow != null) && FPreviouslySelectedDetailRow.BatchStatus == MFinanceConstants.BATCH_UNPOSTED; FPetraUtilsObject.EnableAction("actPostBatch", postable); FPetraUtilsObject.EnableAction("actTestPostBatch", postable); FPetraUtilsObject.EnableAction("actCancel", postable); pnlDetails.Enabled = postable; pnlDetailsProtected = !postable; if ((FPreviouslySelectedDetailRow == null) && (((TFrmGLBatch)this.ParentForm) != null)) { ((TFrmGLBatch)this.ParentForm).DisableJournals(); } }