Created
March 13, 2018 15:21
-
-
Save svetlio/e11cd0e5af8dd305feae44ea7103ecb9 to your computer and use it in GitHub Desktop.
ngx-datatable html select update value
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Update select list (html select) | |
*/ | |
updateValueList(event, cell, rowIndex, row) { | |
var data = { | |
//"nid": [{"value": row.nid}], | |
"type":[{"target_id":"request_material"}], | |
"field_req_material_state": [{"value": event.target.value}] | |
}; | |
this._rest.patchResource(`/node/${row.nid}`, data).subscribe(res => { | |
this.rows[rowIndex][cell] = event.target.value; | |
this.rows = [...this.rows]; | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment