The data model is like this:
"audio": {
"faultType": "string" //声音故障类型
},
"screen":{
"number": "string" //屏幕故障数量
"faultType": "string" //屏幕故障类型
}
How to bind the three input items corresponding to the front desk sound fault type, screen fault number, and screen fault type using ng-model?
Is it okay to write this in the controller?
$scope.data = {
lineNo:$scope.lineNo,
trainNo:$scope.trainNo,
createdAt:$scope.createdAt,
audio: {
faultType:$scope.fault,
},
screen:{
number:$scope.number,
faultType:$scope.faultType,
}
}
You can write it like this in js.
You put
var data = [
"audio": {
"screen":{
}];
json.parse(data);
controller:
HTML:
More than