|
@@ -15,7 +15,7 @@ import {PropertyDescription} from "../../PropertyDescription";
|
|
|
export default function () {
|
|
|
|
|
|
const cc = Ext.form.field.Checkbox.prototype.constructor
|
|
|
- const {initComponent} = Ext.form.field.Checkbox.prototype
|
|
|
+ const {initComponent, getValue} = Ext.form.field.Checkbox.prototype
|
|
|
Ext.form.field.Checkbox.override({
|
|
|
constructor(config) {
|
|
|
const newConfig = _.defaultsDeep({
|
|
@@ -26,6 +26,13 @@ export default function () {
|
|
|
cc.call(this, newConfig)
|
|
|
},
|
|
|
|
|
|
+ getValue() {
|
|
|
+ const ov = getValue.call(this)
|
|
|
+ const nv = ov ? 1 : 0
|
|
|
+ // console.log('cc:', nv, ov)
|
|
|
+ return nv
|
|
|
+ },
|
|
|
+
|
|
|
initComponent() {
|
|
|
initComponent.call(this)
|
|
|
},
|