1234567891011121314151617181920212223242526 |
- (function() {
- BemsWebApplication.BemsServiceTypeViewModel = function(data) {
- this.ServiceTypeId = ko.observable()
- this.Name = ko.observable()
- if(data)
- this.fromJS(data)
- }
- $.extend(BemsWebApplication.BemsServiceTypeViewModel.prototype, {
- toJS: function() {
- return {
- ServiceTypeId: this.ServiceTypeId(),
- Name: this.Name(),
- }
- },
- fromJS: function(data) {
- if(data) {
- this.ServiceTypeId(data.ServiceTypeId)
- this.Name(data.Name)
- }
- }
- })
- })()
|