bugfix
This commit is contained in:
parent
606836b9ac
commit
4b2ed36943
@ -548,7 +548,7 @@ bricks.UiImage =class extends bricks.VBox {
|
|||||||
this.value = e.target.result;
|
this.value = e.target.result;
|
||||||
console.log('this.value=', this.value);
|
console.log('this.value=', this.value);
|
||||||
this.imgw = new bricks.Image({
|
this.imgw = new bricks.Image({
|
||||||
url:e.target.result,
|
url:this.value,
|
||||||
width:'100%'
|
width:'100%'
|
||||||
});
|
});
|
||||||
this.add_widget(this.imgw);
|
this.add_widget(this.imgw);
|
||||||
@ -560,20 +560,14 @@ bricks.UiImage =class extends bricks.VBox {
|
|||||||
fd.append(this.name, this.resultValue());
|
fd.append(this.name, this.resultValue());
|
||||||
}
|
}
|
||||||
resultValue(){
|
resultValue(){
|
||||||
if (this.imgw){
|
if (this.value){
|
||||||
this.value = this.imgw.base64();
|
|
||||||
return this.value;
|
return this.value;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
getValue(){
|
getValue(){
|
||||||
var ret = {}
|
var ret = {};
|
||||||
if (this.imgw){
|
ret[this.name] = this.resultValue();
|
||||||
// ret[this.name] = this.imgw.base64()
|
|
||||||
ret[this.name] = this.value;
|
|
||||||
} else {
|
|
||||||
ret[this.name] = null;
|
|
||||||
}
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user