Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
laravel-guardian-for-Zhang
Project
Project
Details
Activity
Releases
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
YONG-LIN SU
laravel-guardian-for-Zhang
Commits
1f00a78c
Commit
1f00a78c
authored
Sep 10, 2020
by
陳芷妤
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
加上驗證頁面
parent
e5614e1c
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
170 additions
and
95 deletions
+170
-95
DeviceController.php
app/Http/Controllers/DeviceController.php
+36
-31
PersonController.php
app/Http/Controllers/PersonController.php
+39
-27
PersonGroupController.php
app/Http/Controllers/PersonGroupController.php
+26
-28
Device.blade.php
resources/views/Device.blade.php
+7
-1
Device_group.blade.php
resources/views/Device_group.blade.php
+7
-1
Device_relation.blade.php
resources/views/Device_relation.blade.php
+7
-1
Device_type.blade.php
resources/views/Device_type.blade.php
+7
-0
Person.blade.php
resources/views/Person.blade.php
+7
-1
Person_Attendance.blade.php
resources/views/Person_Attendance.blade.php
+6
-1
Person_Comparison.blade.php
resources/views/Person_Comparison.blade.php
+7
-1
Person_Group.blade.php
resources/views/Person_Group.blade.php
+7
-1
Person_Insert.blade.php
resources/views/Person_Insert.blade.php
+7
-1
Person_Search_Group.blade.php
resources/views/Person_Search_Group.blade.php
+7
-1
No files found.
app/Http/Controllers/DeviceController.php
View file @
1f00a78c
...
...
@@ -10,8 +10,9 @@ use phpDocumentor\Reflection\Types\Null_;
class
DeviceController
extends
Controller
{
public
function
index
()
public
function
index
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
// 取得 Device 資料
...
...
@@ -63,16 +64,16 @@ class DeviceController extends Controller
if
(
$msg
!=
null
){
return
view
(
"Device"
,[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$msg
,
"devices"
=>
$drives
,
"count"
=>
$count
,
"types"
=>
$type
]);
return
view
(
"Device"
,[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$msg
,
"devices"
=>
$drives
,
"count"
=>
$count
,
"types"
=>
$type
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device"
,[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"devices"
=>
$drives
,
"count"
=>
$count
,
"types"
=>
$type
]);
return
view
(
"Device"
,[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"devices"
=>
$drives
,
"count"
=>
$count
,
"types"
=>
$type
,
"msg"
=>
$username
]);
}
}
public
function
device_select
(
Request
$request
)
{
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得所有 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -158,9 +159,9 @@ class DeviceController extends Controller
}
if
(
$msg
!=
null
)
{
return
view
(
"Device"
,
[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$msg
,
"devices"
=>
$select_devices
,
"count"
=>
$count
,
"types"
=>
$type
]);
return
view
(
"Device"
,
[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$msg
,
"devices"
=>
$select_devices
,
"count"
=>
$count
,
"types"
=>
$type
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device"
,
[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"devices"
=>
$select_devices
,
"count"
=>
$count
,
"types"
=>
$type
]);
return
view
(
"Device"
,
[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"devices"
=>
$select_devices
,
"count"
=>
$count
,
"types"
=>
$type
,
"msg"
=>
$username
]);
}
}
...
...
@@ -193,6 +194,7 @@ class DeviceController extends Controller
public
function
device_delete
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
[
$ret
,
$res
]
=
$this
->
request_server
(
sprintf
(
"http://%s:%s/device/delete"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"POST"
,
"multipart"
,
[
...
...
@@ -256,13 +258,13 @@ class DeviceController extends Controller
}
return
view
(
"Device"
,[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
,
"devices"
=>
$drives
,
"count"
=>
$count
,
"types"
=>
$type
]);
return
view
(
"Device"
,[
"title"
=>
"設備管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
,
"devices"
=>
$drives
,
"count"
=>
$count
,
"types"
=>
$type
,
"msg"
=>
$username
]);
}
public
function
type
()
public
function
type
(
Request
$request
)
{
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -298,16 +300,16 @@ class DeviceController extends Controller
}
if
(
$msg
!=
null
)
{
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"error_msg"
=>
$msg
,
"types"
=>
$type
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"error_msg"
=>
$msg
,
"types"
=>
$type
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"types"
=>
$type
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"types"
=>
$type
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
}
public
function
type_select
(
Request
$request
)
{
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -377,9 +379,9 @@ class DeviceController extends Controller
}
if
(
$msg
!=
null
)
{
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"error_msg"
=>
$msg
,
"types"
=>
$select_types
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"error_msg"
=>
$msg
,
"types"
=>
$select_types
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"types"
=>
$select_types
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"types"
=>
$select_types
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
}
...
...
@@ -387,6 +389,7 @@ class DeviceController extends Controller
public
function
type_insert
(
Request
$request
)
{
// 取得 Device 資料
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
[
$ret
,
$res
]
=
$this
->
request_server
(
sprintf
(
"http://%s:%s/device/select/all"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"GET"
);
...
...
@@ -450,7 +453,7 @@ class DeviceController extends Controller
));
}
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"types"
=>
$type
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
]);
return
view
(
"Device_type"
,
[
"title"
=>
"類型管理"
,
"types"
=>
$type
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
,
"msg"
=>
$username
]);
}
public
function
type_update
(
Request
$request
)
...
...
@@ -498,10 +501,10 @@ class DeviceController extends Controller
}
public
function
group
()
public
function
group
(
Request
$request
)
{
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -571,16 +574,16 @@ class DeviceController extends Controller
}
if
(
$msg
!=
null
)
{
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"error_msg"
=>
$msg
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"error_msg"
=>
$msg
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
}
public
function
group_select
(
Request
$request
)
{
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -684,9 +687,9 @@ class DeviceController extends Controller
}
if
(
$msg
!=
null
)
{
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"error_msg"
=>
$msg
,
"device_groups"
=>
$select_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"error_msg"
=>
$msg
,
"device_groups"
=>
$select_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"device_groups"
=>
$select_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"device_groups"
=>
$select_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
}
...
...
@@ -694,6 +697,7 @@ class DeviceController extends Controller
{
// 取得 Device 資料
$groups
=
array
();
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$camera_list
=
array
(
"Enabled"
=>
array
());
[
$ret
,
$res
]
=
$this
->
request_server
(
sprintf
(
"http://%s:%s/device/select/all"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"GET"
);
$jsondata
=
json_decode
(
$res
->
getBody
()
->
__toString
(),
true
);
...
...
@@ -758,7 +762,7 @@ class DeviceController extends Controller
}
}
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
]);
return
view
(
"Device_group"
,
[
"title"
=>
"群組管理"
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
,
"msg"
=>
$username
]);
}
...
...
@@ -796,10 +800,10 @@ class DeviceController extends Controller
return
redirect
()
->
route
(
'group'
);
}
public
function
relation
()
public
function
relation
(
Request
$request
)
{
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -851,16 +855,16 @@ class DeviceController extends Controller
if
(
$msg
!=
null
)
{
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"error_msg"
=>
$msg
,
"relations"
=>
$relation
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"error_msg"
=>
$msg
,
"relations"
=>
$relation
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"relations"
=>
$relation
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"relations"
=>
$relation
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
}
public
function
relation_select
(
Request
$request
)
{
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -961,14 +965,15 @@ class DeviceController extends Controller
}
if
(
$msg
!=
null
)
{
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"error_msg"
=>
$msg
,
"relations"
=>
$select_relations
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"count"
=>
$count
]);
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"error_msg"
=>
$msg
,
"relations"
=>
$select_relations
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"count"
=>
$count
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"relations"
=>
$select_relations
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"count"
=>
$count
]);
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"relations"
=>
$select_relations
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"count"
=>
$count
,
"msg"
=>
$username
]);
}
}
public
function
relation_insert
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得 Device 資料
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -1029,7 +1034,7 @@ class DeviceController extends Controller
));
}
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"relations"
=>
$relation
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
]);
return
view
(
"Device_relation"
,
[
"title"
=>
"設備群組關係"
,
"relations"
=>
$relation
,
"device_groups"
=>
$device_groups
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$error_msg
,
"msg"
=>
$username
]);
}
...
...
app/Http/Controllers/PersonController.php
View file @
1f00a78c
...
...
@@ -20,8 +20,9 @@ class PersonController extends Controller
private
$influxdb
=
"http://192.168.5.17:8086"
;
private
$imgserver
=
"http://192.168.5.185:8000"
;
public
function
index
()
public
function
index
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
// 取得所有設備資訊
// $devices_info=$this->get_all_device();
...
...
@@ -100,9 +101,9 @@ class PersonController extends Controller
// dd($jsondata);
if
(
$msg
!=
null
){
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"error_msg"
=>
$msg
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"error_msg"
=>
$msg
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
}
...
...
@@ -139,14 +140,14 @@ class PersonController extends Controller
}
else
{
$insert_msg
=
"
$insert[0]人新增成功,$fail[1]人新增失敗:$failname[1]
"
;
}
return
$this
->
index
()
->
with
([
"error_msg"
=>
$insert_msg
]);
return
$this
->
index
(
$request
)
->
with
([
"error_msg"
=>
$insert_msg
]);
}
else
{
$msg
=
"未匯入成功,錯誤為檔案不是execl檔"
;
return
$this
->
index
()
->
with
([
"error_msg"
=>
$msg
]);
return
$this
->
index
(
$request
)
->
with
([
"error_msg"
=>
$msg
]);
}
}
else
{
$msg
=
"未匯入成功,錯誤為未選擇檔案"
;
return
$this
->
index
()
->
with
([
"error_msg"
=>
$msg
]);
return
$this
->
index
(
$request
)
->
with
([
"error_msg"
=>
$msg
]);
}
/*
try{ }catch (\Exception $e){
...
...
@@ -164,6 +165,7 @@ class PersonController extends Controller
// 人員搜尋
public
function
person_search_type
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// request回調
session
()
->
flashInput
(
$request
->
input
());
$msg
=
null
;
...
...
@@ -270,15 +272,16 @@ class PersonController extends Controller
));
}
if
(
$msg
!=
null
){
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"error_msg"
=>
$msg
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"error_msg"
=>
$msg
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
}
// 出勤狀態頁面
public
function
attendance_index
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$msg
=
request
()
->
session
()
->
get
(
'msg'
);
// 取得所有設備資訊
// $devices_info=$this->get_all_device();
...
...
@@ -307,9 +310,9 @@ class PersonController extends Controller
array_push
(
$groups
,
array
(
"group"
=>
"Enabled"
));
$export
=
array
(
"In"
=>
"08:30"
,
"Out"
=>
"17:30"
,
"LunchBreak"
=>
60
);
if
(
$msg
!=
null
){
return
view
(
"Person_Attendance"
,[
"title"
=>
"出勤管理"
,
"export_arg"
=>
$export
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$msg
]);
return
view
(
"Person_Attendance"
,[
"title"
=>
"出勤管理"
,
"export_arg"
=>
$export
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
$msg
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Person_Attendance"
,[
"title"
=>
"出勤管理"
,
"export_arg"
=>
$export
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Person_Attendance"
,[
"title"
=>
"出勤管理"
,
"export_arg"
=>
$export
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
}
...
...
@@ -317,6 +320,7 @@ class PersonController extends Controller
// 取得區間內出勤考核狀態
public
function
post_attendance_old
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
date_default_timezone_set
(
'Asia/Taipei'
);
$stime
=
"'"
.
$request
->
start_time
.
"T00:00:00Z'"
;
$etime
=
"'"
.
$request
->
end_time
.
"T00:00:00Z'"
;
...
...
@@ -473,7 +477,7 @@ class PersonController extends Controller
array_push
(
$groups
,
array
(
"group"
=>
"Enabled"
));
// return $camera_list["RD"];
return
view
(
"Person_Attendance"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$attendance
]);
return
view
(
"Person_Attendance"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$attendance
,
"msg"
=>
$username
]);
}
// 取得區間內出勤考核狀態
...
...
@@ -481,7 +485,7 @@ class PersonController extends Controller
{
// request回調
session
()
->
flashInput
(
$request
->
input
());
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得所有設備資訊
// $devices_info=$this->get_all_device();
// 取得攝影機群組與清單
...
...
@@ -603,7 +607,7 @@ class PersonController extends Controller
}
$export
=
array
(
"In"
=>
"08:30"
,
"Out"
=>
"17:30"
,
"LunchBreak"
=>
60
);
return
view
(
"Person_Attendance"
,[
"title"
=>
"出勤管理"
,
"export_arg"
=>
$export
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$attendance
]);
return
view
(
"Person_Attendance"
,[
"title"
=>
"出勤管理"
,
"export_arg"
=>
$export
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$attendance
,
"msg"
=>
$username
]);
}
// Export 出勤考核狀態
...
...
@@ -757,8 +761,9 @@ class PersonController extends Controller
}
// 比對狀態頁面
public
function
comparison_index
()
public
function
comparison_index
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得所有設備資訊
// $devices_info=$this->get_all_device();
// 取得攝影機群組與清單
...
...
@@ -803,12 +808,13 @@ class PersonController extends Controller
}
// return $camera_list["RD"];
return
view
(
"Person_Comparison"
,[
"title"
=>
"比對紀錄"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"imgserver"
=>
sprintf
(
"http://%s:%s"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"person_noimage"
=>
$person_noimage
]);
return
view
(
"Person_Comparison"
,[
"title"
=>
"比對紀錄"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"imgserver"
=>
sprintf
(
"http://%s:%s"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"person_noimage"
=>
$person_noimage
,
"msg"
=>
$username
]);
}
// 取得區間內比對紀錄
public
function
post_comparison
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 表單傳值回帶
session
()
->
flashInput
(
$request
->
input
());
// 取得所有設備資訊
...
...
@@ -948,7 +954,7 @@ class PersonController extends Controller
$ID
=
sprintf
(
'"%s"'
,
$rowdata
[
"Image"
]);
// $image = sprintf("<a>%s</a>", $rowdata["ID"]);
$image
=
""
;
$unknown
=
sprintf
(
"<button class='btn btn-outline-dark float-right' onclick='insert_user(%s)' style='margin-right: 10px;' data-toggle='modal' data-target='#InsertMemberModalCenter'>新增人員</button>"
,
$ID
);
$unknown
=
sprintf
(
"<button class='btn btn-outline-dark float-right' onclick='insert_user(%s
%
)' style='margin-right: 10px;' data-toggle='modal' data-target='#InsertMemberModalCenter'>新增人員</button>"
,
$ID
);
}
else
{
$image
=
sprintf
(
"<img class='faceimg' src='%s/person/%s'>"
,
sprintf
(
"http://%s:%s"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
$id_datetime
[
0
]);
...
...
@@ -986,12 +992,14 @@ class PersonController extends Controller
));
}
}
return
view
(
"Person_Comparison"
,[
"title"
=>
"比對紀錄"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$comparison
,
"imgserver"
=>
sprintf
(
"http://%s:%s"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"person_noimage"
=>
$person_noimage
]);
return
view
(
"Person_Comparison"
,[
"title"
=>
"比對紀錄"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$comparison
,
"imgserver"
=>
sprintf
(
"http://%s:%s"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"person_noimage"
=>
$person_noimage
,
"msg"
=>
$username
]);
}
// 新增人員頁面
public
function
insert_index
()
public
function
insert_index
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得所有設備資訊
// $devices_info=$this->get_all_device();
// 取得攝影機群組與清單
...
...
@@ -1018,13 +1026,14 @@ class PersonController extends Controller
}
array_push
(
$groups
,
array
(
"group"
=>
"Enabled"
));
// return $camera_list["RD"];
return
view
(
"Person_Insert"
,[
"title"
=>
"新增人員"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
]);
return
view
(
"Person_Insert"
,[
"title"
=>
"新增人員"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"msg"
=>
$username
]);
}
// post 新增人員處理
public
function
insert
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// 取得所有設備資訊
// $devices_info=$this->get_all_device();
// 取得攝影機群組與清單
...
...
@@ -1058,18 +1067,19 @@ class PersonController extends Controller
$person
->
name
=
$request
->
name
;
$person
->
state
=
$request
->
group
;
$person
->
save
();
return
view
(
"Person_Insert"
,[
"title"
=>
"新增人員"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
"新增成功"
]);
return
view
(
"Person_Insert"
,[
"title"
=>
"新增人員"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
"新增成功"
,
"msg"
=>
$username
]);
}
else
{
// 判斷是否有相同資料存在
// 使用人臉庫圖片特徵比對
return
view
(
"Person_Insert"
,[
"title"
=>
"新增人員"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
"已有重複人員在庫"
]);
return
view
(
"Person_Insert"
,[
"title"
=>
"新增人員"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"error_msg"
=>
"已有重複人員在庫"
,
"msg"
=>
$username
]);
}
}
// 新增人臉
public
function
insert_face
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$devices
=
array
();
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -1137,7 +1147,7 @@ class PersonController extends Controller
foreach
(
$errors
as
$error
){
$error_msg
=
$error_msg
.
","
.
$error
;
}
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
[
$ret
,
$res
]
=
$this
->
request_server
(
sprintf
(
"http://%s:%s/person/insert"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"POST"
,
...
...
@@ -1220,11 +1230,12 @@ class PersonController extends Controller
));
}
// dd($jsondata);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
public
function
insert_face_no_image
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// dd($request->all());
$errors
=
array
();
$client
=
new
\GuzzleHttp\Client
();
...
...
@@ -1294,7 +1305,7 @@ class PersonController extends Controller
));
}
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
else
{
// $facnames=explode("/",$facname);
...
...
@@ -1331,7 +1342,7 @@ class PersonController extends Controller
// }
$person_noimage
=
array
();
//dd($jsondata);
return
view
(
"Person_Comparison"
,[
"title"
=>
"比對紀錄"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"imgserver"
=>
sprintf
(
"http://%s:%s"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"error_msg"
=>
$jsondata
[
"Message"
],
"person_noimage"
=>
$person_noimage
]);
return
view
(
"Person_Comparison"
,[
"title"
=>
"比對紀錄"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"imgserver"
=>
sprintf
(
"http://%s:%s"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"error_msg"
=>
$jsondata
[
"Message"
],
"person_noimage"
=>
$person_noimage
,
"msg"
=>
$username
]);
// return view("Person_Comparison",["title"=>"比對紀錄","groups"=>$groups,"camera_list"=>$camera_list,"imgserver"=>sprintf("http://%s:%s",env("IMAGE_SERVER_HOST"),env("IMAGE_SERVER_PORT")),"error_msg"=>$jsondata["Message"],"person_noimage"=>$person_noimage]);
}
//
...
...
@@ -1414,6 +1425,7 @@ class PersonController extends Controller
public
function
post_modify
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
// dd($request->all());
$devices
=
array
();
$groups
=
array
();
...
...
@@ -1483,7 +1495,7 @@ class PersonController extends Controller
));
}
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
]);
return
view
(
"Person"
,[
"title"
=>
"人員管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
""
,
"error_msg"
=>
$error_msg
,
"person_groups"
=>
$person_groups
,
"msg"
=>
$username
]);
}
[
$ret
,
$res
]
=
$this
->
request_server
(
sprintf
(
"http://%s:%s/person/update"
,
env
(
"IMAGE_SERVER_HOST"
),
env
(
"IMAGE_SERVER_PORT"
)),
"POST"
,
...
...
@@ -1528,7 +1540,7 @@ class PersonController extends Controller
$jsondata
=
json_decode
(
$res
->
getBody
()
->
__toString
(),
true
);
// dd($jsondata);
return
$this
->
index
();
return
$this
->
index
(
$request
);
}
// 公用方法
...
...
app/Http/Controllers/PersonGroupController.php
View file @
1f00a78c
...
...
@@ -15,7 +15,7 @@ class PersonGroupController extends Controller
use
AuthorizesRequests
,
DispatchesJobs
,
ValidatesRequests
;
//人員群組首頁
public
function
Group_index
()
public
function
Group_index
(
Request
$request
)
{
$devices
=
array
();
$groups
=
array
();
...
...
@@ -52,14 +52,14 @@ class PersonGroupController extends Controller
//$personGer=array();
//$personGer=explode(',',"$persondata");
//$data =array('name' => 'ray','age' => 25);
return
view
(
"Person_Search_Group"
,
[
"title"
=>
"人員群組"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
]);
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
return
view
(
"Person_Search_Group"
,
[
"title"
=>
"人員群組"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"msg"
=>
$username
]);
}
//新增人員群組
public
function
insert_Group
(
Request
$request
)
{
$server_ip
=
"192.168.6.240"
;
$server_port
=
"5000"
;
$devices
=
array
();
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -113,14 +113,12 @@ class PersonGroupController extends Controller
}
else
{
$error_msg
=
"請填寫群組名稱,未新增成功"
;
}
return
$this
->
Group_index
()
->
with
([
"error_msg"
=>
$error_msg
]);
return
$this
->
Group_index
(
$request
)
->
with
([
"error_msg"
=>
$error_msg
]);
}
//搜尋人員群組
public
function
search_Group
(
Request
$request
)
{
$server_ip
=
"192.168.6.240"
;
$server_port
=
"5000"
;
$devices
=
array
();
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -178,10 +176,11 @@ class PersonGroupController extends Controller
}
else
{
$msg
=
"以下為查詢結果"
;
}
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
if
(
$msg
!=
null
)
{
return
view
(
"Person_Search_Group"
,
[
"title"
=>
"人員群組"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"error_msg"
=>
$msg
]);
return
view
(
"Person_Search_Group"
,
[
"title"
=>
"人員群組"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"error_msg"
=>
$msg
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Person_Search_Group"
,
[
"title"
=>
"人員群組"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
]);
return
view
(
"Person_Search_Group"
,
[
"title"
=>
"人員群組"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"msg"
=>
$username
]);
}
}
...
...
@@ -189,8 +188,7 @@ class PersonGroupController extends Controller
//修改人員群組
public
function
modify_Group
(
Request
$request
)
{
$server_ip
=
"192.168.6.240"
;
$server_port
=
"5000"
;
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$devices
=
array
();
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
...
...
@@ -228,7 +226,7 @@ class PersonGroupController extends Controller
$stuat
=
2
;
}
else
{
$msg
=
"請輸入修改內容"
;
return
$this
->
Group_index
()
->
with
([
"error_msg"
=>
$msg
]);
return
$this
->
Group_index
(
$request
)
->
with
([
"error_msg"
=>
$msg
]);
}
}
if
(
$stuat
!=
2
){
...
...
@@ -246,10 +244,10 @@ class PersonGroupController extends Controller
]);
$msg
=
"修改成功"
;
return
$this
->
Group_index
()
->
with
([
"error_msg"
=>
$msg
]);
return
$this
->
Group_index
(
$request
)
->
with
([
"error_msg"
=>
$msg
]);
}
else
{
$msg
=
"已有重複群組名稱"
;
return
$this
->
Group_index
()
->
with
([
"error_msg"
=>
$msg
]);
return
$this
->
Group_index
(
$request
)
->
with
([
"error_msg"
=>
$msg
]);
}
}
...
...
@@ -257,8 +255,7 @@ class PersonGroupController extends Controller
//刪除人員群組
public
function
delete_Group
(
Request
$request
)
{
$server_ip
=
"192.168.6.240"
;
$server_port
=
"5000"
;
if
(
$request
->
selectedId
!=
null
)
{
$client
=
new
\GuzzleHttp\Client
();
$id
=
$request
->
selectedId
;
...
...
@@ -274,10 +271,10 @@ class PersonGroupController extends Controller
array_push
(
$error_ids
,
$id
);
}
}
return
$this
->
Group_index
();
return
$this
->
Group_index
(
$request
);
}
else
{
$msg
=
"未選擇刪除群組名稱"
;
return
$this
->
Group_index
()
->
with
([
"error_msg"
=>
$msg
]);
return
$this
->
Group_index
(
$request
)
->
with
([
"error_msg"
=>
$msg
]);
}
}
...
...
@@ -285,8 +282,7 @@ class PersonGroupController extends Controller
//人員群組首頁
public
function
index_Group
(
Request
$request
)
{
$server_ip
=
"192.168.6.240"
;
$server_port
=
"5000"
;
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
// 取得 Device 資料
...
...
@@ -328,7 +324,7 @@ class PersonGroupController extends Controller
));
}
$msg
=
"群組無相關人員"
;
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"error_msg"
=>
$msg
]);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"error_msg"
=>
$msg
,
"msg"
=>
$username
]);
}
if
(
$persongroupid
!=
null
and
$jsondata
[
"Data"
]
!=
null
)
{
if
(
$persongroupid
!=
null
and
$jsondata
[
"Data"
]
!=
null
)
{
...
...
@@ -394,7 +390,7 @@ class PersonGroupController extends Controller
}
}
// dd($rowdata);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
]);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"msg"
=>
$username
]);
}
}
}
...
...
@@ -511,6 +507,7 @@ class PersonGroupController extends Controller
}*/
public
function
search_personGroup
(
Request
$request
)
{
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
$groups
=
array
();
$camera_list
=
array
(
"Enabled"
=>
array
());
// 取得 Device 資料
...
...
@@ -556,10 +553,10 @@ class PersonGroupController extends Controller
));
}
$msg
=
"群組無相關人員"
;
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"error_msg"
=>
$msg
]);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"error_msg"
=>
$msg
,
"msg"
=>
$username
]);
}
else
{
$msg
=
"群組無相關人員"
;
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"error_msg"
=>
$msg
]);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"error_msg"
=>
$msg
,
"msg"
=>
$username
]);
}
}
if
(
$persongroupid
!=
null
and
$jsondata
[
"Data"
]
!=
null
){
...
...
@@ -625,10 +622,10 @@ class PersonGroupController extends Controller
}
}
//dd($rowdata);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
]);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata2
,
"msg"
=>
$username
]);
}
else
{
$msg
=
"請選擇搜尋群組"
;
return
$this
->
Group_index
()
->
with
([
"error_msg"
=>
$msg
]);
return
$this
->
Group_index
(
$request
)
->
with
([
"error_msg"
=>
$msg
]);
}
}
...
...
@@ -863,10 +860,11 @@ class PersonGroupController extends Controller
));
}
}
$username
=
$request
->
session
()
->
get
(
'Tusername'
);
if
(
$msg
!=
null
)
{
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata3
,
"error_msg"
=>
$msg
]);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata3
,
"error_msg"
=>
$msg
,
"msg"
=>
$username
]);
}
else
{
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata3
]);
return
view
(
"Person_Group"
,
[
"title"
=>
"人員群組管理"
,
"groups"
=>
$groups
,
"camera_list"
=>
$camera_list
,
"rowdata"
=>
$rowdata
,
"rowdata2"
=>
$rowdata3
,
"msg"
=>
$username
]);
}
...
...
resources/views/Device.blade.php
View file @
1f00a78c
...
...
@@ -63,7 +63,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Device_group.blade.php
View file @
1f00a78c
...
...
@@ -62,7 +62,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Device_relation.blade.php
View file @
1f00a78c
...
...
@@ -61,7 +61,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Device_type.blade.php
View file @
1f00a78c
...
...
@@ -63,6 +63,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Person.blade.php
View file @
1f00a78c
...
...
@@ -115,7 +115,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Person_Attendance.blade.php
View file @
1f00a78c
...
...
@@ -97,7 +97,12 @@
@endif
</div>
</div>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Person_Comparison.blade.php
View file @
1f00a78c
...
...
@@ -102,7 +102,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Person_Group.blade.php
View file @
1f00a78c
...
...
@@ -99,7 +99,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
resources/views/Person_Insert.blade.php
View file @
1f00a78c
...
...
@@ -71,7 +71,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
8
" style="
background
:
darkgray
">
...
...
resources/views/Person_Search_Group.blade.php
View file @
1f00a78c
...
...
@@ -98,7 +98,13 @@
@endif
</div>
</div>
<p></p>
<form method="
GET
" action="
{{
Route
(
"user_logout"
)
}}
">
<div class="
col
-
12
">
<label style="
text
-
align
:
left
;
font
-
size
:
16
px
;
color
:
#ffffff">使用者:{{$msg}} </label>
<
input
class
="
btn
btn
-
outline
-
light
" style="
font
-
size
:
16
px
;
text
-
align
:
center
" type="
submit
" id="
logout
" name="
logout
" value="
登出
" >
</div>
</form>
</div>
{{--攝影機 畫面區--}}
<div id="
Screen
-
aria
" class="
col
-
md
-
10
" style="
background
:
darkgray
">
...
...
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