| Total Complexity | 7 |
| Complexity/F | 1.75 |
| Lines of Code | 35 |
| Function Count | 4 |
| Duplicated Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | |||
| 2 | (function () { |
||
| 3 | |||
| 4 | /** |
||
| 5 | * @constructor |
||
| 6 | */ |
||
| 7 | function CustomAdminSettings() |
||
| 8 | { |
||
| 9 | this.php = ko.observable(''); |
||
| 10 | |||
| 11 | this.loading = ko.observable(false); |
||
| 12 | } |
||
| 13 | |||
| 14 | CustomAdminSettings.prototype.onBuild = function () // special function |
||
| 15 | { |
||
| 16 | var self = this; |
||
| 17 | |||
| 18 | this.loading(true); |
||
| 19 | |||
| 20 | window.rl.pluginRemoteRequest(function (sResult, oData) { |
||
| 21 | |||
| 22 | self.loading(false); |
||
| 23 | |||
| 24 | if (window.rl.Enums.StorageResultType.Success === sResult && oData && oData.Result) |
||
| 25 | { |
||
| 26 | self.php(oData.Result.PHP || ''); |
||
| 27 | } |
||
| 28 | |||
| 29 | }, 'AjaxAdminGetData'); |
||
| 30 | |||
| 31 | }; |
||
| 32 | |||
| 33 | window.rl.addSettingsViewModelForAdmin(CustomAdminSettings, 'PluginCustomAdminSettingnTab', |
||
| 34 | 'SETTINGS_CUSTOM_ADMIN_CUSTOM_TAB_PLUGIN/TAB_NAME', 'custom'); |
||
| 35 | |||
| 36 | }()); |