This commit is contained in:
@@ -127,17 +127,28 @@ export default {
|
||||
computed: {
|
||||
c2: {
|
||||
get: function() {
|
||||
debugger;
|
||||
return "this is my test";
|
||||
return this.GetValueForField("c2");
|
||||
},
|
||||
set: function(newValue) {
|
||||
debugger;
|
||||
this.SetValueForField("c2", newValue);
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
lt: function(ltkey) {
|
||||
return this.$gzlocale.get(ltkey);
|
||||
},
|
||||
GetValueForField: function(dataKey) {
|
||||
if (!this.value) {
|
||||
return null;
|
||||
}
|
||||
// debugger;
|
||||
var cData = JSON.parse(this.value);
|
||||
// debugger;
|
||||
return cData[dataKey];
|
||||
},
|
||||
SetValueForField: function(dataKey, newValue) {
|
||||
console.log("Setting " + dataKey + " TO " + newValue);
|
||||
}
|
||||
},
|
||||
beforeCreate() {
|
||||
@@ -172,4 +183,14 @@ export default {
|
||||
//"c3":30453626,"c4":false,"c5":0.529134196010015}
|
||||
}
|
||||
};
|
||||
|
||||
// //////////////////////
|
||||
// // Get the data for the specified field key from the custom fields object
|
||||
// // coerce the type if necessary / handle incompatible types
|
||||
// function GetDataForField(fldKey, vm) {
|
||||
// debugger;
|
||||
// var cData = JSON.parse(vm.value);
|
||||
// debugger;
|
||||
// return "BaLH";
|
||||
// }
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user