From f3509f1da7734eded424022544460f666f80ce8e Mon Sep 17 00:00:00 2001 From: Sashi20 Date: Wed, 17 Jun 2020 10:46:57 +0530 Subject: Update my proposals page to view disapproved proposal details --- my_proposals.inc | 14 ++++++++++++++ proposal.inc | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/my_proposals.inc b/my_proposals.inc index 10ba23d..4c56bce 100644 --- a/my_proposals.inc +++ b/my_proposals.inc @@ -571,6 +571,7 @@ function arduino_projects_blog_my_proposal_view_form($form, &$form_state) '#title' => t('Expected Completion date'), '#markup' => date('d-m-Y', $proposal_data->expected_date_of_completion) ); + if($proposal_data->approval_status == 2){ if($proposal_data->resubmit_comment){ $form['resubmit_comment'] = array( '#type' => 'item', @@ -578,6 +579,19 @@ function arduino_projects_blog_my_proposal_view_form($form, &$form_state) '#markup' => $proposal_data->resubmit_comment ); } +} + else if($proposal_data->approval_status == 4){ + $form['status'] = array( + '#type' => 'item', + '#title' => t('Status'), + '#markup' => t('Dis-approved') + ); + $form['disapproval_reason'] = array( + '#type' => 'item', + '#title' => t('Disapproval Reason'), + '#markup' => $proposal_data->dissapproval_reason + ); + } $form['cancel'] = array( '#type' => 'item', '#markup' => l(t('Cancel'), 'arduino-projects/my-proposals') diff --git a/proposal.inc b/proposal.inc index 9ddd45a..4901fb0 100755 --- a/proposal.inc +++ b/proposal.inc @@ -636,7 +636,7 @@ function arduino_projects_blog_my_proposal() if($my_proposals_data->approval_status == 2){ $action = l('Edit', 'arduino-projects/my-proposals/edit/' . $my_proposals_data->id); } - else if($my_proposals_data->approval_status == 1 or $my_proposals_data->approval_status == 3){ + else if($my_proposals_data->approval_status == 1 or $my_proposals_data->approval_status == 3 or $my_proposals_data->approval_status == 4){ $action = l('View', 'arduino-projects/my-proposals/view/' . $my_proposals_data->id); } else if($my_proposals_data->approval_status == 0){ -- cgit