From 7a89a78f573073105b3b10ff113483c445a29189 Mon Sep 17 00:00:00 2001 From: fisharebest Date: Fri, 31 Dec 2010 19:16:53 +0000 Subject: Fix: undefined $this->canedit and $this->userCanEdit() Replace both with $this->indi->canEdit() --- modules/relatives/module.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/relatives/module.php b/modules/relatives/module.php index dfa7077752..01066d2a82 100644 --- a/modules/relatives/module.php +++ b/modules/relatives/module.php @@ -106,7 +106,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab { } //-- missing father if ($type=="parents" && !isset($people["husb"]) && !isset($people["newhusb"])) { - if ($this->controller->canedit) { + if ($this->controller->indi->canEdit()) { ?> @@ -117,7 +117,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab { } //-- missing husband if ($type=="spouse" && $this->controller->indi->equals($people["wife"]) && !isset($people["husb"]) && !isset($people["newhusb"])) { - if ($this->controller->canedit) { + if ($this->controller->indi->canEdit()) { ?> @@ -152,7 +152,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab { } //-- missing mother if ($type=="parents" && !isset($people["wife"]) && !isset($people["newwife"])) { - if ($this->controller->canedit) { + if ($this->controller->indi->canEdit()) { ?> @@ -163,7 +163,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab { } //-- missing wife if ($type=="spouse" && $this->controller->indi->equals($people["husb"]) && !isset($people["wife"]) && !isset($people["newwife"])) { - if ($this->controller->canedit) { + if ($this->controller->indi->canEdit()) { ?> @@ -238,7 +238,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab { if (empty($wife) && !empty($husb)) echo translate_fact('_NMAR', $husb); else if (empty($husb) && !empty($wife)) echo translate_fact('_NMAR', $wife); else echo translate_fact('_NMAR'); - } else if ($family->getMarriageRecord()=="" && $this->controller->canedit) { + } else if ($family->getMarriageRecord()=="" && $this->controller->indi->canEdit()) { echo "".i18n::translate('Add marriage details').""; } else { $factdetail = explode(' ', trim($family->getMarriageRecord())); @@ -319,7 +319,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab { $elderdate = $child->getBirthDate(); ++$key; } - if (isset($family) && $this->controller->canedit) { + if (isset($family) && $this->controller->indi->canEdit()) { if ($type == "spouse") { $child_u = i18n::translate('Add a son or daughter'); $child_m = i18n::translate('Son'); @@ -376,7 +376,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab { $personcount=0; $families = $this->controller->indi->getChildFamilies(); if (count($families)==0) { - if ($this->controller->canedit) { + if ($this->controller->indi->canEdit()) { ?> @@ -440,7 +440,7 @@ class relatives_WT_Module extends WT_Module implements WT_Module_Tab {
controller->canedit) { + if ($this->controller->indi->canEdit()) { ?>
1) { ?> -- cgit v1.3