Ignore:
Timestamp:
Feb 16, 2018, 12:54:54 PM (19 months ago)
Author:
Juanma
Message:

refactorized

File:
1 edited

Legend:

Unmodified
Added
Removed
  • taskscheduler/trunk/fuentes/python3-taskscheduler.install/usr/share/taskscheduler/taskscheduler.py

    r6824 r6831  
    5656                        if type(result)==type({}):
    5757                                tasks=result.copy()
    58                 result=self.n4dclient.get_tasks("","SchedulerServer")['data']
     58#               result=self.n4dclient.get_tasks("","SchedulerServer")['data']
     59                result=self.n4dclient.get_local_tasks("","SchedulerServer")
    5960                if type(result)==type({}):
    6061                        if tasks:
     
    6869                        else:
    6970                                tasks.update(result.copy())
    70                 print(tasks)
    7171                return tasks
    7272        #def get_scheduled_tasks
     
    115115                return wrkfiles
    116116        #def _get_wrkfiles
     117
     118        def add_command(self,cmd_name,cmd):
     119                if self.n4dserver:
     120                        self.n4dserver.add_command(self.credentials,"SchedulerServer",cmd_name,cmd)
     121                else:
     122                        self.n4dclient.add_command(self.credentials,"SchedulerServer",cmd_name,cmd)
    117123
    118124        def get_commands(self):
Note: See TracChangeset for help on using the changeset viewer.