Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
workbiu-admin
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Boards
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
gxx
workbiu-admin
Commits
9a508ad7
Commit
9a508ad7
authored
Dec 12, 2017
by
gxx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
yixie
parent
a739e424
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
8 deletions
+9
-8
FileService.php
app/Services/FileService.php
+4
-4
groupinformation.blade.php
resources/views/admin/group/groupinformation.blade.php
+5
-4
No files found.
app/Services/FileService.php
View file @
9a508ad7
...
...
@@ -25,7 +25,7 @@ class FileService implements FileServiceContract
public
function
getAll
(
$group_id
)
{
$files
=
File
::
where
(
'group_id'
,
$group_id
)
->
get
(
);
$files
=
File
::
where
(
'group_id'
,
$group_id
)
->
paginate
(
8
);
if
(
$files
->
isEmpty
()){
return
null
;
}
...
...
@@ -40,8 +40,8 @@ class FileService implements FileServiceContract
public
function
delete
(
$file_id
)
{
$file
=
File
::
where
([
"id"
=>
file_id
])
->
get
();
$result
=
$file
->
delete
();
//
$file =File::where(["id"=>file_id])->get();
//
$result = $file->delete();
// $pointer = $file->pointer;
// $count =File::where(["pointer"=>$pointer])->count();
// if($result && $count == 0){
...
...
@@ -57,6 +57,6 @@ class FileService implements FileServiceContract
// return Message::makeError('文件不存在');
// }
// }
return
$result
;
//
return $result;
}
}
\ No newline at end of file
resources/views/admin/group/groupinformation.blade.php
View file @
9a508ad7
...
...
@@ -95,7 +95,7 @@
<
th
>
文件夹
</
th
>
<
th
>
所属项目
</
th
>
<
th
>
创建者
</
th
>
<
th
>
操作
</
th
>
{{
--<
th
>
操作
</
th
>--
}}
</
tr
>
</
thead
>
@
if
(
$files
==
null
)
...
...
@@ -116,15 +116,16 @@
<
td
>
{{
$file
->
folder_id
}}
</
td
>
<
td
>
{{
$file
->
fileInProject
->
name
}}
</
td
>
<
td
>
{{
$file
->
fileCreator
->
user_name
}}
</
td
>
<
td
><
a
href
=
"{{route('file.get',['id' =>
$file->id
])}}"
class
=
"btn btn-info"
>
查看详情
</
a
>
<
a
href
=
"{{route('file.delete',['id' =>
$file->id
])}}"
class
=
"btn bg-orange"
>
删除
</
a
>
<
td
>
{{
--<
a
href
=
"{{route('file.get',['id' =>
$file->id
])}}"
class
=
"btn btn-info"
>
查看详情
</
a
>--
}}
{{
--<
a
href
=
"{{route('file.delete',['id' =>
$file->id
])}}"
class
=
"btn bg-orange"
>
删除
</
a
>--
}}
</
td
>
</
tr
>
</
tbody
>
@
endforeach
@
endif
</
table
>
{{
$files
->
links
()
}}
</
div
>
<!--
/.
tab
-
pane
-->
...
...
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