コード例 #1
0
        public void Uninstall(string feature)
        {
            // Logger.Information("Uninstalling feature: {0}.", feature);

            var migrations = GetDataMigrations(feature);

            // apply update methods to each migration class for the module
            foreach (var migration in migrations)
            {
                // copy the object for the Linq query
                var tempMigration = migration;

                // get current version for this migration
                var dataMigrationRecord = GetDataMigrationRecord(tempMigration);

                var uninstallMethod = GetUninstallMethod(migration);
                if (uninstallMethod != null)
                {
                    uninstallMethod.Invoke(migration, new object[0]);
                }

                if (dataMigrationRecord == null)
                {
                    continue;
                }

                OrmManager.Delete(dataMigrationRecord);
                //_dataMigrationRepository.Flush();
            }
        }
コード例 #2
0
 public void Delete(object Entity)
 {
     _OrmManager.Delete(Entity);
 }