fix
This commit is contained in:
@@ -347,13 +347,9 @@ class Proj extends Users_Controller {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function thisjob() {
|
public function thisjob() {
|
||||||
// echo 'oooooooooooooooooooooooooo';
|
|
||||||
// $data['redirect_to'] = str_replace(base_url(),'',$_SERVER['HTTP_REFERER']);
|
|
||||||
$data = $this->getSessionArray();
|
$data = $this->getSessionArray();
|
||||||
$data['redirect_to'] = '/proj/active/';
|
$data['redirect_to'] = '/proj/active/';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||||
redirect(home);
|
redirect(home);
|
||||||
} else {
|
} else {
|
||||||
@@ -442,8 +438,7 @@ class Proj extends Users_Controller {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function mycompltjob() {
|
public function mycompltjob() {
|
||||||
// echo 'oooooooooooooooooooooooooo';
|
$data = $this->getSessionArray();
|
||||||
$data = $this->getSessionArray();
|
|
||||||
|
|
||||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||||
redirect(home);
|
redirect(home);
|
||||||
|
|||||||
@@ -89,3 +89,73 @@
|
|||||||
}
|
}
|
||||||
// -->
|
// -->
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
<script type="text/javascript">
|
||||||
|
<!--
|
||||||
|
|
||||||
|
function showModal(interest_id) {
|
||||||
|
if (typeof event !== 'undefined') {
|
||||||
|
event.preventDefault();
|
||||||
|
}
|
||||||
|
// collect data - either from forms or from data variables
|
||||||
|
var id = $(this).data('id');
|
||||||
|
|
||||||
|
// load the modal content with a loader gif and message
|
||||||
|
$('#modal-content').html('Loading...');
|
||||||
|
|
||||||
|
// show modal window
|
||||||
|
$('#modal_theme_primary').modal('show');
|
||||||
|
|
||||||
|
// do the ajax bit
|
||||||
|
var post_data = {
|
||||||
|
'interest_id': id,
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: "/jobs/jobinterest_modal?interest_id="+interest_id
|
||||||
|
}).done(function (data) {
|
||||||
|
//alert(data);
|
||||||
|
$('#modal-content').html(data);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function showJobModal(contact_id) {
|
||||||
|
if (typeof event !== 'undefined') {
|
||||||
|
event.preventDefault();
|
||||||
|
}
|
||||||
|
// collect data - either from forms or from data variables
|
||||||
|
var id = $(this).data('id');
|
||||||
|
|
||||||
|
// load the modal content with a loader gif and message
|
||||||
|
$('#modal-content').html('Loading...');
|
||||||
|
|
||||||
|
// show modal window
|
||||||
|
$('#modal_theme_primary').modal('show');
|
||||||
|
|
||||||
|
// do the ajax bit
|
||||||
|
var post_data = {
|
||||||
|
'interest_id': id,
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: "/jobs/jobdetail_modal?contact_id="+contact_id
|
||||||
|
}).done(function (data) {
|
||||||
|
//alert(data);
|
||||||
|
$('#modal-content').html(data);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// -->
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Basic modal -->
|
||||||
|
<div id="modal_theme_primary" class="modal fade">
|
||||||
|
<div class="modal-dialog">
|
||||||
|
<div class="modal-content" id="modal-content">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- /basic modal -->
|
||||||
@@ -1,8 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
//var_dump($this_job_result);
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<!-- Main content -->
|
|
||||||
<form method="post" name="post_nav_find" action="">
|
<form method="post" name="post_nav_find" action="">
|
||||||
<input type="hidden" name="jobID" value="">
|
<input type="hidden" name="jobID" value="">
|
||||||
</form>
|
</form>
|
||||||
@@ -10,7 +7,6 @@
|
|||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
<!--
|
<!--
|
||||||
function post_nav_find_action(what, value) {
|
function post_nav_find_action(what, value) {
|
||||||
// alert(what);
|
|
||||||
document.post_nav_find.action = what + '';
|
document.post_nav_find.action = what + '';
|
||||||
document.post_nav_find.jobID.value = value;
|
document.post_nav_find.jobID.value = value;
|
||||||
document.post_nav_find.submit();
|
document.post_nav_find.submit();
|
||||||
@@ -19,7 +15,6 @@
|
|||||||
// -->
|
// -->
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<!--begin::Row-->
|
|
||||||
<div class="row g-5 g-xl-8">
|
<div class="row g-5 g-xl-8">
|
||||||
<div class="col-xl-12">
|
<div class="col-xl-12">
|
||||||
<div class="card card-xl-stretch mb-5 mb-xl-8">
|
<div class="card card-xl-stretch mb-5 mb-xl-8">
|
||||||
@@ -55,34 +50,158 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!--end::Row-->
|
|
||||||
|
<div class="row g-5 g-xl-8">
|
||||||
|
<div class="col-xl-8">
|
||||||
|
<div class="card card-xl-stretch mb-5 mb-xl-8">
|
||||||
|
|
||||||
|
<div class="card-body py-3">
|
||||||
|
<div class="tab-content">
|
||||||
|
<div class="tab-pane fade show active" id="kt_table_widget_5_tab_1">
|
||||||
|
<div class="table-responsive">
|
||||||
|
|
||||||
|
|
||||||
|
<ul class="nav nav-tabs nav-line-tabs mb-5 fs-6">
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link active" data-bs-toggle="tab" href="#kt_tab_pane_1">Send Message</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" data-bs-toggle="tab" href="#kt_tab_pane_2">Add File(s)</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" data-bs-toggle="tab" href="#kt_tab_pane_3">Actions</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="tab-content" id="myTabContent">
|
||||||
|
<div class="tab-pane fade show active" id="kt_tab_pane_1" role="tabpanel">
|
||||||
|
<div id="sendmessagenote"></div>
|
||||||
|
|
||||||
|
<form name="message" id="message" action="/proj/thisjob" method='POST'>
|
||||||
|
<input type='hidden' name='ajax' value='1'>
|
||||||
|
<input type='hidden' name='jobID' value='<?php echo $jobID; ?>'>
|
||||||
|
<input type='hidden' name='contractId' value='<?php echo $contract_id; ?>'>
|
||||||
|
|
||||||
<div class="content-wrapper">
|
<div class="form-group">
|
||||||
<!-- Quick stats boxes -->
|
<textarea cols="18" style="height:180px;" rows="3" id='jobmessage' name='jobmessage' class="textarea wysihtml5 wysihtml5-min form-control" placeholder="Enter message here ..."></textarea>
|
||||||
<?php include('common/jobstrip.php'); ?>
|
</div>
|
||||||
<!-- /quick stats boxes -->
|
|
||||||
|
|
||||||
<!-- WYSIHTML5 basic -->
|
<div class="text-right">
|
||||||
<div class="row">
|
<button id='btn_cancel' name='btn_cancel' type="submit" class="btn btn-danger btn-xs" onclick="document.message.ajax.value = '0';">Cancel</button>
|
||||||
|
<button id='btm_submit' name='btn_submit' type="submit" class="btn btn-primary btn-xs" onclick="SendMessage();return false;">Send Message</button>
|
||||||
|
</div>
|
||||||
<div class="col-lg-12">
|
</form>
|
||||||
<div class="panel panel-flat">
|
</div>
|
||||||
<div class="panel-body" style=' background-color: #CEECF5;' >
|
<div class="tab-pane fade" id="kt_tab_pane_2" role="tabpanel">
|
||||||
<a href="<?php echo $redirect_to; ?>" class="label label-flat border-warning text-primary-600"> <i class="icon-arrow-left52 position-left"></i> Return to List </a> <?php echo $this_job; ?>
|
<div class="form-group">
|
||||||
|
<form action="/proj/thisjob" method='POST' enctype="multipart/form-data">
|
||||||
|
<input type='hidden' name='uploadForm' value='1'>
|
||||||
|
<input type='hidden' name='jobID' value='<?php echo $jobID; ?>'>
|
||||||
|
<input type='hidden' name='contractId' value='<?php echo $contract_id; ?>'>
|
||||||
|
<input type="file" class="file-input" multiple="multiple" name="fileToUpload[]" id="fileToUpload[]">
|
||||||
|
<span class="help-block">There is a file size limit [<?php echo UPLOAD_FILE_SIZE; ?> MB]. Split large files into smaller size</span>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="tab-pane fade" id="kt_tab_pane_3" role="tabpanel">
|
||||||
|
|
||||||
|
|
||||||
|
<h3>Use action to manage the status of the project</h3>
|
||||||
|
<div class="form-group">
|
||||||
|
<?php
|
||||||
|
if ($this_is_client == true) {
|
||||||
|
?>
|
||||||
|
<table class='table table-striped table-hover table-bordered table-condensed'>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
If you have completed this task and will like the owner to review the work for acceptance, click "Completed" button.
|
||||||
|
</td>
|
||||||
|
<td style="width:120px;">
|
||||||
|
<div id="req_completion"> <button type="submit" id="req_completion_submit" class="btn btn-primary btn-xs" onclick="return requestCompletion('<?php echo $job_contract; ?>');" <?php echo $disabled1; ?> >Completed</button></div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
If you are unable to complete and will like this project canceled, click "Cancel task" button.
|
||||||
|
</td>
|
||||||
|
<td style="width:120px;">
|
||||||
|
<div id="req_cancel"> <button type="submit" id="req_cancel_submit" onclick="return requestCancel('<?php echo $job_contract; ?>');" class="btn btn-danger btn-xs" <?php echo $disabled2; ?> >Request Cancel</button> </div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<div style="font-size: large; font-family: sans-serif">
|
||||||
|
<p style="color: #ff0000; background-color: #ffffff">Note: Buttons may be disabled for some days at the start of the task</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
if ($this_is_project_owner == true) {
|
||||||
|
?>
|
||||||
|
<table class='table table-striped table-hover table-bordered table-condensed'>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Accept or reject the completion of the task below. We will notify the other partner and finalize payment for the task.
|
||||||
|
</td>
|
||||||
|
<td style="width:120px;">
|
||||||
|
<div id="accept_completion"> <button type="submit" id="accept_completion_submit" class="btn btn-primary btn-xs" onclick="return acceptCompletion('<?php echo $job_contract; ?>');" <?php echo $disabled11; ?> >Accept Completion</button></div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
If you reject the work done or want more review before accepting, click "Reject Completion."
|
||||||
|
</td>
|
||||||
|
<td style="width:120px;">
|
||||||
|
<div id="reject_completion"> <button type="submit" id="reject_completion_submit" class="btn btn-danger btn-xs" <?php echo $disabled22; ?> onclick="return rejectCompletion('<?php echo $job_contract; ?>');" >Reject Completion</button></div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="col-xl-4">
|
||||||
|
<div class="card card-xl-stretch mb-5 mb-xl-8">
|
||||||
|
<div class="card-header border-0 pt-5">
|
||||||
|
<h3 class="card-title align-items-start flex-column">
|
||||||
|
<span class="card-label fw-bolder fs-3 mb-1">Messages</span>
|
||||||
|
</h3>
|
||||||
|
<div class="card-toolbar">
|
||||||
|
|
||||||
<script type="text/javascript">
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="card-body py-3">
|
||||||
|
<div class="tab-content">
|
||||||
|
<div class="tab-pane fade show active" id="kt_table_widget_5_tab_1">
|
||||||
|
<div class="table-responsive">
|
||||||
|
<?=$message_result_show?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!--end::Col-->
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<script type="text/javascript">
|
||||||
<!--
|
<!--
|
||||||
var timerId = setTimeout(function tick() {
|
var timerId = setTimeout(function tick() {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
@@ -141,9 +260,8 @@
|
|||||||
// -->
|
// -->
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
<?php include('common/jobstrip.php'); ?>
|
||||||
|
|
||||||
|
|
||||||
<!-- Basic modal -->
|
|
||||||
<div id="modal_theme_primary_fail" class="modal fade">
|
<div id="modal_theme_primary_fail" class="modal fade">
|
||||||
<div class="modal-dialog">
|
<div class="modal-dialog">
|
||||||
<div class="modal-content">
|
<div class="modal-content">
|
||||||
@@ -162,142 +280,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- /basic modal -->
|
|
||||||
|
|
||||||
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-lg-6">
|
|
||||||
|
|
||||||
|
|
||||||
<div class="panel panel-flat">
|
|
||||||
|
|
||||||
<div class="panel-body">
|
|
||||||
<?= $message ?>
|
|
||||||
<div class="tabbable">
|
|
||||||
<ul class="nav nav-tabs bg-primary">
|
|
||||||
<li class="active"><a href="#basic-tab1" data-toggle="tab">Send Message</a></li>
|
|
||||||
<li><a href="#basic-tab2" data-toggle="tab">Add File(s)</a></li>
|
|
||||||
<li><a href="#basic-tab3" data-toggle="tab">Actions</a></li>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
<div class="tab-content">
|
|
||||||
<div class="tab-pane active" id="basic-tab1">
|
|
||||||
|
|
||||||
<div id="sendmessagenote"></div>
|
|
||||||
|
|
||||||
<form name="message" id="message" action="/proj/thisjob" method='POST'>
|
|
||||||
<input type='hidden' name='ajax' value='1'>
|
|
||||||
<input type='hidden' name='jobID' value='<?php echo $jobID; ?>'>
|
|
||||||
<input type='hidden' name='contractId' value='<?php echo $contract_id; ?>'>
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<textarea cols="18" style="height:180px;" rows="3" id='jobmessage' name='jobmessage' class="textarea wysihtml5 wysihtml5-min form-control" placeholder="Enter message here ..."></textarea>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="text-right">
|
|
||||||
<button id='btn_cancel' name='btn_cancel' type="submit" class="btn btn-danger btn-xs" onclick="document.message.ajax.value = '0';">Cancel</button>
|
|
||||||
<button id='btm_submit' name='btn_submit' type="submit" class="btn btn-primary btn-xs" onclick="SendMessage();return false;">Send Message</button>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="tab-pane" id="basic-tab2">
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<form action="/proj/thisjob" method='POST' enctype="multipart/form-data">
|
|
||||||
<input type='hidden' name='uploadForm' value='1'>
|
|
||||||
<input type='hidden' name='jobID' value='<?php echo $jobID; ?>'>
|
|
||||||
<input type='hidden' name='contractId' value='<?php echo $contract_id; ?>'>
|
|
||||||
<input type="file" class="file-input" multiple="multiple" name="fileToUpload[]" id="fileToUpload[]">
|
|
||||||
<span class="help-block">There is a file size limit [<?php echo UPLOAD_FILE_SIZE; ?> MB]. Split large files into smaller size</span>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="tab-pane" id="basic-tab3">
|
|
||||||
<h3>Use action to manage the status of the project</h3>
|
|
||||||
<div class="form-group">
|
|
||||||
<?php
|
|
||||||
if ($this_is_client == true) {
|
|
||||||
?>
|
|
||||||
<table class='table table-striped table-hover table-bordered table-condensed'>
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
If you have completed this task and will like the owner to review the work for acceptance, click "Completed" button.
|
|
||||||
</td>
|
|
||||||
<td style="width:100px;">
|
|
||||||
<div id="req_completion"> <button type="submit" id="req_completion_submit" class="btn btn-primary btn-xs" onclick="return requestCompletion('<?php echo $job_contract; ?>');" <?php echo $disabled1; ?> >Completed</button></div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
If you are unable to complete and will like this project canceled, click "Cancel task" button.
|
|
||||||
</td>
|
|
||||||
<td style="width:100px;">
|
|
||||||
<div id="req_cancel"> <button type="submit" id="req_cancel_submit" onclick="return requestCancel('<?php echo $job_contract; ?>');" class="btn btn-danger btn-xs" <?php echo $disabled2; ?> >Request Cancel</button> </div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
<div style="font-size: large; font-family: sans-serif">
|
|
||||||
<p style="color: #ff0000; background-color: #ffffff">Note: Buttons may be disabled for some days at the start of the task</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<?php
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<?php
|
|
||||||
if ($this_is_project_owner == true) {
|
|
||||||
?>
|
|
||||||
<table class='table table-striped table-hover table-bordered table-condensed'>
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
Accept or reject the completion of the task below. We will notify the other partner and finalize payment for the task.
|
|
||||||
</td>
|
|
||||||
<td style="width:100px;">
|
|
||||||
<div id="accept_completion"> <button type="submit" id="accept_completion_submit" class="btn btn-primary btn-xs" onclick="return acceptCompletion('<?php echo $job_contract; ?>');" <?php echo $disabled11; ?> >Accept Completion</button></div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
If you reject the work done or want more review before accepting, click "Reject Completion."
|
|
||||||
</td>
|
|
||||||
<td style="width:100px;">
|
|
||||||
<div id="reject_completion"> <button type="submit" id="reject_completion_submit" class="btn btn-danger btn-xs" <?php echo $disabled22; ?> onclick="return rejectCompletion('<?php echo $job_contract; ?>');" >Reject Completion</button></div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
<?php
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="col-lg-6">
|
|
||||||
<div class="panel panel-flat">
|
|
||||||
<div id="message_table">
|
|
||||||
<?=$message_result_show?>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- /WYSIHTML5 basic -->
|
|
||||||
</div>
|
|
||||||
<!-- /main content -->
|
|
||||||
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
<!--
|
<!--
|
||||||
|
|||||||
@@ -76,8 +76,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<!--end::Col-->
|
<!--end::Col-->
|
||||||
</div>
|
</div>
|
||||||
<!--end::Row-->
|
|
||||||
<!--begin::Row-->
|
|
||||||
<div class="row g-5 g-xl-8">
|
<div class="row g-5 g-xl-8">
|
||||||
<div class="col-xl-12">
|
<div class="col-xl-12">
|
||||||
<!--begin::Charts Widget 1-->
|
<!--begin::Charts Widget 1-->
|
||||||
|
|||||||
Reference in New Issue
Block a user