From f23a348dfb7279095d7a83823b677f762b8838bb Mon Sep 17 00:00:00 2001 From: Crazy_Coder Date: Wed, 29 May 2019 17:06:44 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A4=E6=96=ADtrue=20false?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- java/ShitJudge.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 java/ShitJudge.java diff --git a/java/ShitJudge.java b/java/ShitJudge.java new file mode 100644 index 0000000..b5b4cd1 --- /dev/null +++ b/java/ShitJudge.java @@ -0,0 +1,19 @@ +/** + * 判断表单数据是否被发起流程. + * + * @param _formDef 表单对象 + * @param id 表单数据id + * @return + */ +public boolean isFormDataAssocationProcess(FormDef _formDef, Long id) { + String sql = "select count(*) from t_auto_" + _formDef.getId() + " where db_id=:id and processinstanceid_ is not null"; + Map params = new HashMap(); + params.put("id", id); + int count = this.genericJdbcDAO.queryForInt(sql, params); + // 这个判断,一口老血喷出来,一个项目经理写的 + if (count > 0) { + return true; + } else { + return false; + } +} \ No newline at end of file -- Gitee