Update an organization

@param \Jaspersoft\Dto\Organization\Organization $org
975545
public function updateOrganization(Organization $org)
	{
        $url = self::makeUrl($org->id);
        $data = json_encode($org);
        $this->service->prepAndSend($url, array(201, 200), 'PUT', $data, false, 'application/json', 'application/json');
    }
507925
def update_org(cls, module):
        
        try:
            cls.module_registry[module]["OrgModel"]._meta.get_field("users")
        except FieldDoesNotExist:
            cls.module_registry[module]["OrgModel"].add_to_class(
                "users",
                models.ManyToManyField(
                    USER_MODEL,
                    through=cls.module_registry[module]["OrgUserModel"].__name__,
                    related_name="%(app_label)s_%(class)s",
                ),
            )

        cls.module_registry[module]["OrgModel"].invitation_model = cls.module_registry[
            module
        ][
            "OrgInviteModel"
        ]
106954
func (s *Service) UpdateOrganization(ctx context.Context, id platform.ID, upd platform.OrganizationUpdate) (*platform.Organization, error) {
	o, err := s.FindOrganizationByID(ctx, id)
	if err != nil {
		return nil, &platform.Error{
			Err: err,
			Op:  OpPrefix + platform.OpUpdateOrganization,
		}
	}

	if upd.Name != nil {
		o.Name = *upd.Name
	}

	s.organizationKV.Store(o.ID.String(), o)

	return o, nil
}
1336848
public static function setOrganization($organization, $basepath = '/')
    {
        if ($organization) {
            // Set the cookie for 30 days
            return self::set(self::ORGANIZATION_COOKIE, $organization, 30, $basepath);
        }
    }
29278
public function update($table) {
        UpdateImpl::update($this->context, $table);
        return new UpdateSetRule($this->context);
    }
1324211
def update_org_owner(cls, module):
        
        try:
            cls.module_registry[module]["OrgOwnerModel"]._meta.get_field(
                "organization_user"
            )
        except FieldDoesNotExist:
            cls.module_registry[module]["OrgOwnerModel"].add_to_class(
                "organization_user",
                models.OneToOneField(
                    cls.module_registry[module]["OrgUserModel"],
                    on_delete=models.CASCADE,
                ),
            )
        try:
            cls.module_registry[module]["OrgOwnerModel"]._meta.get_field("organization")
        except FieldDoesNotExist:
            cls.module_registry[module]["OrgOwnerModel"].add_to_class(
                "organization",
                models.OneToOneField(
                    cls.module_registry[module]["OrgModel"],
                    related_name="owner",
                    on_delete=models.CASCADE,
                ),
            )
214567
public function setActiveOrganization(\WobbleCode\UserBundle\Model\OrganizationInterface $activeOrganization)
    {
        $this->activeOrganization = $activeOrganization;
        return $this;
    }
503985
protected function create_organization(cc_i_organization &$org, DOMDocument &$doc, $xmlnode = null) {

        $usenew = is_object($xmlnode);
        $dnode  = $usenew ? $xmlnode : $doc->createElementNS($this->ccnamespaces['imscc'], "organization");
        $this->update_attribute($doc, 'identifier', $org->identifier, $dnode);
        $this->update_attribute($doc, 'structure', $org->structure, $dnode);

        $this->create_item_folder($org, $doc, $dnode);

        return $dnode;
    }
1220729
public function update($index, $type, $id, $document)
    {
        $request = $this->createRequestInstance(self::UPDATE_DOCUMENT, $index, $type);
        $request->setId($id);
        $request->setBody($document);

        return $this->client->send($request);
    }
1115686
public static function hydrate(stdClass $organization)
    {
        $hydrated = new OrgEntity();

        if (isset($organization->id)) {
            $hydrated->setId($organization->id);
        }

        if (isset($organization->name)) {
            $hydrated->setName($organization->name);
        }

        if (isset($organization->valid_until)) {
            $hydrated->setValidUntil(new DateTime($organization->valid_until));
        }

        if (isset($organization->quotas) && is_array($organization->quotas)) {
            $hydrated->setQuotas(QuotaHydrator::hydrateCollection($organization->quotas));
        }

        if (isset($organization->trial_issue_types) && is_array($organization->trial_issue_types)) {
            $hydrated->setTrialIssueTypes(TypeHydrator::hydrateCollection($organization->trial_issue_types));
        }

        if (isset($organization->disabled)) {
            $hydrated->setDisabled($organization->disabled);
        }

        return $hydrated;
    }
1145852
func (s *OrganizationService) UpdateOrganization(ctx context.Context, id platform.ID, upd platform.OrganizationUpdate) (*platform.Organization, error) {
	return s.UpdateOrganizationF(ctx, id, upd)
}
565515
protected function create_item_folder(cc_i_organization &$org, DOMDocument &$doc, DOMElement &$xmlnode = null) {

        $itemfoldernode = $doc->createElementNS($this->ccnamespaces['imscc'], 'item');
        $this->update_attribute($doc, 'identifier', "root", $itemfoldernode);

        if ($org->has_items()) {
            $this->update_items($org->itemlist, $doc, $itemfoldernode);
        }
        if (is_null($this->organizations)) {
            $this->organizations = array();
        }
        $this->organizations[$org->identifier] = $org;

        $xmlnode->appendChild($itemfoldernode);
    }
530662
public function findByOrganization($organizationId)
    {
        $criteria = $this->getIsDeletedCriteria([
            'organization' => new \MongoId($organizationId),
        ]);

        return $this->findBy($criteria);
    }
868480
protected function update(Event $event)
    {
        $this->dispatch(static::EVENT_UPDATE_BEFORE, $event);
        if (!$event->isPropagationStopped()) {
            $this->updateProcess($event);
            if (!$event->isPropagationStopped()) {
                $this->dispatch(static::EVENT_UPDATE_AFTER, $event);
            }
        }
    }
1338612
public function add_new_organization(cc_i_organization &$org) {
        $norg    = $this->activemanifest->create_organization_node($org, $this->doc);
        $orgnode = $this->node("//imscc:manifest[@identifier='".
            $this->activemanifest->manifestID().
            "']/imscc:organizations");
        $orgnode->appendChild($norg);
    }
1182285
public function update(TaxGroupRequest $request, TaxGroup $taxGroup)
    {
        $taxGroup->update($request->all());

        return redirect()->route('admin.tax-group.index');
    }
1258386
func UpdateOrg(c *m.ReqContext, form dtos.UpdateOrgForm) Response {
	return updateOrgHelper(form, c.ParamsInt64(":orgId"))
}