1234567891011121314151617181920212223242526272829 |
- (function() {
- BemsWebApplication.CmUserToLicenseViewModel = function(data) {
- this.SiteId = ko.observable()
- this.UserId = ko.observable()
- this.LicenseId = ko.observable()
- if(data)
- this.fromJS(data)
- }
- $.extend(BemsWebApplication.CmUserToLicenseViewModel.prototype, {
- toJS: function() {
- return {
- SiteId: this.SiteId(),
- UserId: this.UserId(),
- LicenseId: this.LicenseId(),
- }
- },
- fromJS: function(data) {
- if(data) {
- this.SiteId(data.SiteId)
- this.UserId(data.UserId)
- this.LicenseId(data.LicenseId)
- }
- }
- })
- })()
|