Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- define([
- ],function(){
- var ui = {
- rows: [
- {
- id: "class",
- view: "datatable",
- },
- {
- id: "students",
- view: "datatable",
- },
- ]
- };
- return {
- $ui: ui,
- $onurlchange: function(config, url, $scope){
- if(config.ClassId){
- $$("class").url = "http://localhost:5000/api/class/" + config.ClassId + "/";
- $$("class").load($$("class").url);
- $$("students").data = webix.ajax($$("class").url).then(function(data){ return data.json().students; });
- $$("students").load();
- }
- }
- };
- });
Advertisement
Add Comment
Please, Sign In to add comment