Interal mechanism to remove Skills from Group

@param Group $model
@param mixed $data
559954
protected function doRemoveSkills(Group $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Skill';
			} else {
				$related = SkillQuery::create()->findOneById($entry['id']);
				$model->removeSkill($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}
606905
protected function doAddParts(Skill $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Skill';
			} else {
				$related = SkillQuery::create()->findOneById($entry['id']);
				$model->addSkillRelatedByPartId($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}
357686
public function remove(Builder $builder, Model $model)
    {
        $query = $builder->getQuery();

        if (is_null($query->wheres)) {
            return;
        }

        $bindingKey = 0;

        $scopeConstraints = $this->getScopeConstraints($model);

        foreach ((array) $query->wheres as $key => $where) {
            $bindingsCount = $this->countBindings($where);

            if (in_array($where, $scopeConstraints)) {
                $this->removeWhere($query, $key);

                $this->removeBindings($query, $bindingKey, $bindingsCount);
            } else {
                $bindingKey += $bindingsCount;
            }
        }

        $query->wheres = array_values($query->wheres);
    }
122288
public function remove(DomainModel $model)
    {
        $this->getEntityManager()->remove($model);
        $this->getEntityManager()->flush();
    }
1135247
public function remove(GroupInterface $group)
    {
        $this->em->remove($group);
        $this->em->flush();
        return true;

    }
1002081
protected function doRemoveVariations(Skill $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Skill';
			} else {
				$related = SkillQuery::create()->findOneById($entry['id']);
				$model->removeVariation($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}
1330167
public function removeGroup(GroupInterface $group)
	{
		if ($this->inGroup($group))
		{
			$this->remove('groups', $group);
		}

		return true;
	}
487463
protected function doRemoveParents(Skill $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Skill';
			} else {
				$related = SkillQuery::create()->findOneById($entry['id']);
				$model->removeSkillRelatedByDependencyId($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}
587818
protected function doRemoveVideos(Skill $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Video';
			} else {
				$related = VideoQuery::create()->findOneById($entry['id']);
				$model->removeVideo($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}
1158981
public function delete(Identifiable $model)
    {
        // Trigger throw
        $group = $this->groupOfConfig($config);

        if (isset($this->buildConfigs[$group])) {
            unset($this->buildConfigs[$group]);

            return true;
        }

        return false;
    }
130751
protected function doRemoveKstrukturs(Skill $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Kstruktur';
			} else {
				$related = KstrukturQuery::create()->findOneById($entry['id']);
				$model->removeKstruktur($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}
1059693
protected function doUpdateFeaturedSkills(Video $model, $data) {
		// remove all relationships before
		SkillQuery::create()->filterByFeaturedVideo($model)->delete();

		// add them
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Skill';
			} else {
				$related = SkillQuery::create()->findOneById($entry['id']);
				$model->addFeaturedSkill($related);
			}
		}

		if (count($errors) > 0) {
			throw new ErrorsException($errors);
		}
	}
97030
protected function doRemoveMultiples(Skill $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Skill';
			} else {
				$related = SkillQuery::create()->findOneById($entry['id']);
				$model->removeMultiple($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}
972667
public function removeGroup(GroupInterface $group)
	{
		if ($this->inGroup($group))
		{
			$this->groups()->detach($group);
			$this->invalidateUserGroupsCache();
			$this->invalidateMergedPermissionsCache();
		}

		return true;
	}
929820
protected function doUpdateRootSkills(Kstruktur $model, $data) {
		// remove all relationships before
		SkillQuery::create()->filterByKstrukturRoot($model)->delete();

		// add them
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Skill';
			} else {
				$related = SkillQuery::create()->findOneById($entry['id']);
				$model->addRootSkill($related);
			}
		}

		if (count($errors) > 0) {
			throw new ErrorsException($errors);
		}
	}
674752
public function removeGroup($groupName)
    {

		if(isset($this->groups[$groupName])){
			foreach($this->groups[$groupName]['elements'] as $element){
				$this->removeElement($element);
			}
			unset($this->groups[$groupName]);
		}

    }
1074290
protected function doRemovePositions(Sport $model, $data) {
		$errors = [];
		foreach ($data as $entry) {
			if (!isset($entry['id'])) {
				$errors[] = 'Missing id for Position';
			} else {
				$related = PositionQuery::create()->findOneById($entry['id']);
				$model->removePosition($related);
			}
		}

		if (count($errors) > 0) {
			return new ErrorsException($errors);
		}
	}