/** * Return the table to update depending if the request is a 'publish' one or normal. */ public String getUpdateTable() { return publish ? beanDescriptor.getBaseTable() : beanDescriptor.getDraftTable(); }
DeleteMeta(boolean emptyStringAsNull, BeanDescriptor<?> desc, BindableId id, Bindable version, Bindable tenantId) { this.emptyStringAsNull = emptyStringAsNull; this.tableName = desc.getBaseTable(); this.id = id; this.version = version; this.tenantId = tenantId; String tableName = desc.getBaseTable(); this.sqlNone = genSql(ConcurrencyMode.NONE, tableName); this.sqlVersion = genSql(ConcurrencyMode.VERSION, tableName); if (desc.isDraftable()) { String draftTableName = desc.getDraftTable(); this.sqlDraftNone = genSql(ConcurrencyMode.NONE, draftTableName); this.sqlDraftVersion = genSql(ConcurrencyMode.VERSION, draftTableName); } else { this.sqlDraftNone = sqlNone; this.sqlDraftVersion = sqlVersion; } }
/** * Return the table to update depending if the request is a 'publish' one or normal. */ public String getUpdateTable() { return publish ? beanDescriptor.getBaseTable() : beanDescriptor.getDraftTable(); }
String draftTableName = desc.getDraftTable();
DeleteMeta(boolean emptyStringAsNull, BeanDescriptor<?> desc, BindableId id, Bindable version, Bindable tenantId) { this.emptyStringAsNull = emptyStringAsNull; this.tableName = desc.getBaseTable(); this.id = id; this.version = version; this.tenantId = tenantId; String tableName = desc.getBaseTable(); this.sqlNone = genSql(ConcurrencyMode.NONE, tableName); this.sqlVersion = genSql(ConcurrencyMode.VERSION, tableName); if (desc.isDraftable()) { String draftTableName = desc.getDraftTable(); this.sqlDraftNone = genSql(ConcurrencyMode.NONE, draftTableName); this.sqlDraftVersion = genSql(ConcurrencyMode.VERSION, draftTableName); } else { this.sqlDraftNone = sqlNone; this.sqlDraftVersion = sqlVersion; } }
String draftTableName = desc.getDraftTable();