Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
pa21617d4ti08
Project
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
jhon
pa21617d4ti08
Commits
4b6195aa
Commit
4b6195aa
authored
May 23, 2017
by
Yonatan Parapat
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://gitlab.del.ac.id/charles/pa21617d4ti08
parents
0c4a4b21
eea96b68
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
55 additions
and
0 deletions
+55
-0
InventoriController.php
app/Http/Controllers/InventoriController.php
+55
-0
No files found.
app/Http/Controllers/InventoriController.php
View file @
4b6195aa
...
...
@@ -14,6 +14,11 @@ use App\DataRequest;
use
App\Pembelian
;
use
App\RequestBarang
;
use
App\DataRequest
;
class
InventoriController
extends
Controller
{
public
function
ListBarang
()
...
...
@@ -91,8 +96,22 @@ class InventoriController extends Controller
}
<<<<<<<
HEAD
//----------------------------List Request----------------------//
public
function
ListRequest
()
{
$request_barangs
=
RequestBarang
::
all
();
return
view
(
'adminlte::inventori.ListRequest.index'
,
compact
(
'request_barangs'
));
}
public
function
editRequest
(
$id
)
{
=======
public
function
editRequest
(
$id
)
{
>>>>>>>
226
a4f92be2de6ce884543bf9425346660a5031f
$request_barangs
=
RequestBarang
::
where
(
'id'
,
$id
)
->
first
();
return
view
(
'adminlte::inventori.ListRequest.edit'
)
->
with
(
'request_barangs'
,
$request_barangs
);
}
...
...
@@ -131,6 +150,42 @@ class InventoriController extends Controller
$data_requests
->
harga
=
$request
[
'harga'
];
$data_requests
->
save
();
return
redirect
(
'DataRequest'
);
<<<<<<<
HEAD
}
public
function
editDataRequest
(
$id
)
{
$data_requests
=
DataRequest
::
where
(
'id'
,
$id
)
->
first
();
return
view
(
'adminlte::inventori.DataRequest.editDataRequest'
)
->
with
(
'data_requests'
,
$data_requests
);
}
public
function
updateDataRequest
(
Request
$request
,
$id
)
{
$this
->
validate
(
$request
,
[
'nama_barang'
=>
'required'
,
'kategori'
=>
'required'
,
'harga'
=>
'required'
,
]);
$data_requests
=
DataRequest
::
findOrFail
(
$id
);
$data_requests
->
nama_barang
=
$request
->
nama_barang
;
$data_requests
->
kategori
=
$request
->
kategori
;
$data_requests
->
harga
=
$request
->
harga
;
$data_requests
->
save
();
return
redirect
(
'DataRequest'
);
}
public
function
destroyDataRequest
(
$id
)
{
$data_requests
=
DataRequest
::
find
(
$id
);
$data_requests
->
delete
();
return
redirect
(
'DataRequest'
);
=======
>>>>>>>
226
a4f92be2de6ce884543bf9425346660a5031f
}
...
...
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