Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
3
3f-timesheet
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dockers
3f-timesheet
Commits
5987ce36
Commit
5987ce36
authored
Oct 14, 2022
by
Azhan Hannan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
delete project function, not completed.. in discussion.
parent
10dcfc09
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
106 additions
and
1 deletions
+106
-1
packages/portal/timesheet/resources/views/maintenance/deleteproject.blade.php
+83
-0
packages/portal/timesheet/resources/views/maintenance/senaraiProject.blade.php
+6
-1
packages/portal/timesheet/routes/web.php
+2
-0
packages/portal/timesheet/src/Http/Controllers/MaintenanceController.php
+14
-0
packages/portal/timesheet/src/Http/Controllers/ReportController.php
+1
-0
No files found.
packages/portal/timesheet/resources/views/maintenance/deleteproject.blade.php
0 → 100644
View file @
5987ce36
@
extends
(
'ui::layouts.app'
)
@
section
(
'content'
)
<
div
class
="
ui
segment
">
<a class="
ui
blue
left
ribbon
label
">Delete Project</a>
<br>
<br>
<p style="
color
:
red
">This page is still in maintenance.. TQ</p>
<form class="
ui
form
">
<!--
{
{csrf_field()}
}
-->
<div class="
field
">
<label>Project Name</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$project
,
'p_project_description'
)}}
">
</div>
<div class="
field
">
<label>Project Code</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$project
,
'p_project_code'
)}}
">
</div>
<div class="
field
">
<label>Project Manager</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$project
,
'projectManager.fullname'
)}}
">
</div>
<div class="
field
">
<label>Project Director</label>
<input type="
text
" readonly="
readonly
" value="
{{
data_get
(
$project
,
'projectDirector.fullname'
)}}
">
</div>
<div class="
ui
tiny
orange
modal
uploadmodal
">
<div class="
header
text
-
center
">
Delete Confirmation
</div>
<div class="
content
text
-
center
">
<form class="
ui
form
" action="" method="
POST
" enctype="
multipart
/
form
-
data
">
{
{csrf_field()}
}
<p>
Are you sure you want to delete this project?
</p>
{
{data_get($project,'p_project_code')}
}
{
{data_get($project,'p_project_description')}
}
<br><br>
<button class="
ui
red
button
" type="
submit
">Yes</button>
<button class="
ui
blue
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
maintenance
.
deleteproject
', ['
id
' => data_get($project,'
id
')]) }}'
;
">No</button>
</form>
</div>
</div>
<br>
<button type="
button
" class="
ui
red
button
" id="
uploadmodal
">
Delete
</button>
<!-- <button class="
ui
red
button
" type="
submit
">Delete</button> -->
</form>
</div>
@endsection
@push('script')
<script>
$(function(){
$("
#uploadmodal").click(function()
{
$
(
".uploadmodal"
)
.
modal
(
'show'
);
});
$
(
".uploadmodal"
)
.
modal
(
{
closable
:
true
});
$
(
".uploadmodal"
)
.
modal
(
'attach events'
,
'.close.button'
);
});
</
script
>
@
endpush
\ No newline at end of file
packages/portal/timesheet/resources/views/maintenance/senaraiProject.blade.php
View file @
5987ce36
...
...
@@ -47,6 +47,10 @@
<button class="
compact
purple
ui
button
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
maintenance
.
mandays
', ['
id
' => $project['
id
']]) }}'
;
">
Mandays
</button>
<button type="
button
" class="
compact
ui
red
button
" id="
uploadmodal
" onclick="
window
.
location
.
href
=
'{{ route('
timesheet
::
maintenance
.
deleteproject
', ['
id
' => $project['
id
']]) }}'
;
">
Delete
</button>
</td>
</tr>
@endforeach
...
...
@@ -54,4 +58,4 @@
</table>
</div>
@endsection
@endsection
\ No newline at end of file
packages/portal/timesheet/routes/web.php
View file @
5987ce36
...
...
@@ -75,6 +75,8 @@ Route::group(
Route
::
get
(
'editPeranan'
,[
'uses'
=>
'MaintenanceController@editPeranan'
,
'as'
=>
'maintenance.editPeranan'
]);
Route
::
post
(
'updaterole'
,[
'uses'
=>
'MaintenanceController@updaterole'
,
'as'
=>
'maintenance.updaterole'
]);
Route
::
get
(
'deleteproject'
,[
'uses'
=>
'MaintenanceController@deleteproject'
,
'as'
=>
'maintenance.deleteproject'
]);
// route to form
Route
::
get
(
'chargeableForm'
,[
'uses'
=>
'FormController@chargeableForm'
,
'as'
=>
'form.chargeableForm'
]);
Route
::
get
(
'overheadForm'
,[
'uses'
=>
'FormController@overheadForm'
,
'as'
=>
'form.overheadForm'
]);
...
...
packages/portal/timesheet/src/Http/Controllers/MaintenanceController.php
View file @
5987ce36
...
...
@@ -598,4 +598,17 @@ class MaintenanceController extends Controller
return
view
(
'timesheet::ajax.senaraistaff'
,
compact
(
'staffs'
));
}
public
function
deleteproject
(
Request
$request
)
{
$project
=
Project
::
where
(
'id'
,
$request
->
id
)
->
with
(
'projectManager'
)
->
with
(
'projectDirector'
)
->
first
();
// dd($project);
return
view
(
'timesheet::maintenance.deleteproject'
,
compact
(
'project'
));
}
}
\ No newline at end of file
packages/portal/timesheet/src/Http/Controllers/ReportController.php
View file @
5987ce36
...
...
@@ -68,6 +68,7 @@ class ReportController extends Controller
->
where
(
'year'
,
$request
->
year
)
->
where
(
'status'
,
4
)
->
get
();
// dd($ringkasan);
// $projectnc = VwNonchargeSummary::where('month', $request->month)
// ->where('year', $request->year)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment