Пример #1
0
 def deleteFilter(cls, data: DataModel, id: int):
     filterIndex = DataController.getElementById(data.filters, id)
     if filterIndex != -1:
         data.filters[filterIndex].isDeleted = True
         return data.filters[filterIndex]
     return None
 def deleteDashBoard(cls, data: DataModel, id):
     dashBoardIndex = DataController.getElementById(data.dashboards, id)
     if dashBoardIndex != -1:
         data.dashboards[dashBoardIndex].isDeleted = True
         return data.dashboards[dashBoardIndex]
     return None
Пример #3
0
 def deleteTable(cls, data: DataModel, id: int):
     elementIndex = DataController.getElementById(data.dataSources, id)
     if elementIndex != -1:
         data.dataSources[elementIndex].isDeleted = True
         return data.dataSources[elementIndex]
     return None