Fix 4.0.5 (#904)

* be: 记录转换兼容性

* 4.0.5

* Update @rbv

* fix: Gitee#IC85YQ

* Update rb-forms.js

* Update @rbv
This commit is contained in:
REBUILD 企业管理系统 2025-05-21 22:28:07 +08:00 committed by GitHub
parent d50876c0c9
commit 94a6fbbc8b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 28 additions and 10 deletions

2
@rbv

@ -1 +1 @@
Subproject commit 5d3f22654a0e208b4ad4a16a5bcfff8c8bf97dd2
Subproject commit 6c98fdaf00ec81ce787d9adffb96b6e277a62bd0

View file

@ -10,7 +10,7 @@
</parent>
<groupId>com.rebuild</groupId>
<artifactId>rebuild</artifactId>
<version>4.0.4</version>
<version>4.0.5</version>
<name>rebuild</name>
<description>Building your business-systems freely!</description>
<url>https://getrebuild.com/</url>

View file

@ -75,11 +75,11 @@ public class Application implements ApplicationListener<ApplicationStartedEvent>
/**
* Rebuild Version
*/
public static final String VER = "4.0.4";
public static final String VER = "4.0.5";
/**
* Rebuild Build [MAJOR]{1}[MINOR]{2}[PATCH]{2}[BUILD]{2}
*/
public static final int BUILD = 4000410;
public static final int BUILD = 4000511;
static {
// Driver for DB

View file

@ -162,7 +162,8 @@ public class GeneralEntityService extends ObservableService implements EntitySer
if (checkDetailsRepeated) {
Record c = d.clone();
// for check use clone
if (!c.hasValue(dtfField)) c.setID(dtfField, mainid);
ID hasMainid = c.getID(dtfField);
if (hasMainid == null || EntityHelper.isUnsavedId(hasMainid)) c.setID(dtfField, mainid);
List<Record> repeated = des.getAndCheckRepeated(c, 20);
if (!repeated.isEmpty()) throw new RepeatedRecordsException(repeated);

View file

@ -53,12 +53,18 @@ public class RecordTransfomer37 extends RecordTransfomer {
throw new ConfigurationException("INVALID CONFIG OF TRANSFORM");
}
// 兼容
if (fieldsMapping.get("_") == null) return super.transform(sourceRecordId, specMainId);
if (fieldsMapping.get("_") == null) {
transConfig.put("checkNullable35", false);
return super.transform(sourceRecordId, specMainId);
}
// ND:明细
JSONArray fieldsMappingDetails = transConfig.getJSONArray("fieldsMappingDetails");
// 兼容
if (fieldsMappingDetails == null) return super.transform(sourceRecordId, specMainId);
if (fieldsMappingDetails == null) {
transConfig.put("checkNullable35", false);
return super.transform(sourceRecordId, specMainId);
}
// v3.5 此配置未开放
// 在之前的版本中虽然文档写明非空字段无值会转换失败但是从来没有做过非空检查

View file

@ -41,7 +41,10 @@
</div>
</div>
<div class="splash-footer">
<span><a href="javascript:history.back()">[[${bundle.L('返回')}]]</a></span>
<span>
<a href="javascript:history.back()">[[${bundle.L('返回')}]]</a>
<a href="javascript:window.close()" class="hide">[[${bundle.L('关闭')}]]</a>
</span>
</div>
</div>
</div>
@ -49,7 +52,7 @@
</div>
<th:block th:replace="~{/_include/footer}" />
<script type="text/babel">
$(document).ready(function () {
$(document).ready(() => {
const nexturl = $decode($urlp('nexturl') || '../admin/systems')
const $btn = $('.J_verify-btn').on('click', () => {
const passwd = $val('#admin-passwd')
@ -69,6 +72,13 @@
})
return false
})
// fix:4.0.5
function _FN() {
$('.splash-footer a:eq(0)').addClass('hide')
$('.splash-footer a:eq(1)').removeClass('hide')
}
history.length <= 1 && _FN()
})
</script>
</body>

View file

@ -3169,6 +3169,7 @@ class RbFormRefform extends React.Component {
}
render() {
if (!this.props.refvalue) return null
return (
<div className={`rbview-form form-layout refform ${window.__LAB_VERTICALLAYOUT && 'vertical38'}`} ref={(c) => (this._viewForm = c)}>
{this.state.formComponent || 'LOADING'}

View file

@ -51,7 +51,7 @@ const formatWhen = function (maskVal) {
for (let k in WHENS) {
let k2 = ~~k.substring(1)
if ((maskVal & k2) !== 0) {
if (k2 === 512) timed = true
if (k2 === 'W512') timed = true
else ss.push(WHENS[k])
}
}