Ejemplo n.º 1
0
        private void DeleteDashboard(ApiDashboard dashboard)
        {
            var tmp = DashboardMapper.ConvertToDALEntity(dashboard);

            foreach (var relation in tmp.Relations)
            {
                DashboardFilterRelationAdapter.Delete(relation.Id);
            }
            DashboardAdapter.Delete(tmp.Dashboard.Id);
        }
Ejemplo n.º 2
0
        private void InsertDashboard(ref ApiDashboard dashboard)
        {
            var tmp = DashboardMapper.ConvertToDALEntity(dashboard);

            var idx = DashboardAdapter.Insert(tmp.Dashboard);

            dashboard.UpdateId(idx);
            foreach (var relation in tmp.Relations)
            {
                relation.UpdateDashboardId(idx);
                DashboardFilterRelationAdapter.Insert(relation);
            }
        }