From: Stéphane Jacob Date: Fri, 15 Oct 2010 13:47:26 +0000 (+0200) Subject: Removes issues once a profile has been validated. X-Git-Tag: xorg/1.0.1~40 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=3f09ff5200812339c3df8f81ccff01f8c2ceb087;p=platal.git Removes issues once a profile has been validated. Signed-off-by: Stéphane Jacob --- diff --git a/modules/profile/page.inc.php b/modules/profile/page.inc.php index aad3b96..252b3a6 100644 --- a/modules/profile/page.inc.php +++ b/modules/profile/page.inc.php @@ -394,6 +394,16 @@ abstract class ProfilePage implements PlWizardPage } $this->markChange(); } + // XXX: removes this code once all merge related issues have been fixed. + static $issues = array(0 => array('name', 'promo', 'phone', 'education'), 1 => array('address'), 2 => array('job')); + if (isset($issues[Post::i('valid_page')])) { + foreach ($issue as $issues[Post::i('valid_page')]) { + XDB::execute("UPDATE profile_merge_issues + SET issues = REPLACE(issues, {?}, '') + WHERE pid = {?}", + $issue, $this->pid()); + } + } return Post::has('next_page') ? PlWizard::NEXT_PAGE : PlWizard::CURRENT_PAGE; } $text = "Certains champs n'ont pas pu être validés, merci de corriger les informations "