Explorar o código

红票删除判断调整

沈静伟 %!s(int64=3) %!d(string=hai) anos
pai
achega
49848ff92e
Modificáronse 1 ficheiros con 8 adicións e 2 borrados
  1. 8 2
      src/apps/tinvoicebillitem/tinvoiceItemDataBean.java

+ 8 - 2
src/apps/tinvoicebillitem/tinvoiceItemDataBean.java

@@ -8,8 +8,14 @@ public class tinvoiceItemDataBean extends DataBeanCust {
 
     @Override
     public int TOGGLEDELETEROW() throws P2Exception {
-        if ("审核".equals(parent.getPao().getOwner().getString("fstatus"))) {
-            throw new P2AppException("", "审核状态下不可删除");
+        if ("红".equals(parent.getString("frb"))) {
+            if (!"".equals(parent.getString("STATUS"))) {
+                throw new P2AppException("", "红票已提交,不可删除");
+            }
+        } else {
+            if ("审核".equals(parent.getPao().getOwner().getString("fstatus"))) {
+                throw new P2AppException("", "审核状态下不可删除");
+            }
         }
         return super.TOGGLEDELETEROW();
     }