Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
MobileEventLog
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Data-Logistics-Support
MobileEventLog
Commits
d679e89e
Commit
d679e89e
authored
3 years ago
by
Maximilian Betz
Browse files
Options
Downloads
Patches
Plain Diff
added data model for event events and eventtypes
parent
b588e227
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
lib/data_model.dart
+29
-0
29 additions, 0 deletions
lib/data_model.dart
lib/main.dart
+72
-68
72 additions, 68 deletions
lib/main.dart
with
101 additions
and
68 deletions
lib/data_model.dart
0 → 100644
+
29
−
0
View file @
d679e89e
class
Event
{
final
int
id
;
final
String
urn
;
final
String
label
;
final
String
type
;
final
String
description
;
final
String
status
;
Event
({
required
this
.
id
,
required
this
.
urn
,
required
this
.
label
,
required
this
.
type
,
required
this
.
description
,
required
this
.
status
});
}
class
EventType
{
final
String
name
;
final
int
id
;
EventType
({
required
this
.
name
,
required
this
.
id
});
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
lib/main.dart
+
72
−
68
View file @
d679e89e
import
'package:flutter/cupertino.dart'
;
import
'package:flutter/cupertino.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/material.dart'
;
import
'data_model.dart'
;
void
main
()
{
void
main
()
{
runApp
(
MaterialApp
(
runApp
(
MaterialApp
(
...
@@ -81,85 +82,88 @@ class AddEvent extends StatelessWidget {
...
@@ -81,85 +82,88 @@ class AddEvent extends StatelessWidget {
}
}
class
ViewEvents
extends
StatelessWidget
{
class
ViewEvents
extends
StatelessWidget
{
List
<
Event
>
events
=
[]
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
.
.
add
(
Event
(
id:
8311
,
urn:
'station:neumayer_iii:awi_snow_sampler_1'
,
label:
'SML_KO21_SC01'
,
type:
'Deployment'
,
description:
'Remi tool Tag1 1 Traverse'
,
status:
'PENDING'
))
;
String
testString
=
'blabalala'
;
@override
@override
Widget
build
(
BuildContext
context
)
{
Widget
build
(
BuildContext
context
)
{
return
Scaffold
(
return
Scaffold
(
appBar:
AppBar
(
appBar:
AppBar
(
title:
const
Text
(
"View Added Events"
),
title:
const
Text
(
"View Added Events"
),
),
),
body:
InteractiveViewer
(
body:
SingleChildScrollView
(
minScale:
0.1
,
scrollDirection:
Axis
.
horizontal
,
child:
DataTable
(
child:
SingleChildScrollView
(
columns:
const
<
DataColumn
>[
scrollDirection:
Axis
.
vertical
,
DataColumn
(
child:
DataTable
(
label:
Text
(
columns:
const
<
DataColumn
>[
'URN'
,
DataColumn
(
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
),
label:
Text
(
'Id'
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
),
),
),
),
),
DataColumn
(
DataColumn
(
label:
Text
(
label:
Text
(
'URN'
,
'Label'
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
)
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
),
),
),
),
),
DataColumn
(
DataColumn
(
label:
Text
(
label:
Text
(
'Label'
,
'Type'
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
)
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
),
),
),
),
),
DataColumn
(
DataColumn
(
label:
Text
(
label:
Text
(
'Type'
,
'Description'
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
)
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
),
),
),
),
),
DataColumn
(
DataColumn
(
label:
Text
(
label:
Text
(
'Description'
,
'Status'
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
)
,
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
),
),
),
),
),
DataColumn
(
],
label:
Text
(
rows:
const
<
DataRow
>[
'Status'
,
DataRow
(
style:
TextStyle
(
fontStyle:
FontStyle
.
italic
),
cells:
<
DataCell
>[
),
DataCell
(
Text
(
'station:neumayer_iii:awi_snow_sampler_1'
)),
),
DataCell
(
Text
(
'SML_KO21_SC01'
)),
],
DataCell
(
Text
(
'Deployment'
)),
rows:
<
DataRow
>[
DataCell
(
Text
(
'Remi tool Tag1 1 Traverse'
)),
for
(
var
event
in
events
)
DataRow
(
DataCell
(
Text
(
'PENDING'
)),
cells:
<
DataCell
>[
],
DataCell
(
Text
(
event
.
id
.
toString
())),
),
DataCell
(
Text
(
event
.
urn
)),
DataRow
(
DataCell
(
Text
(
event
.
label
)),
cells:
<
DataCell
>[
DataCell
(
Text
(
event
.
type
)),
DataCell
(
Text
(
'radar_system:awi_pres_1'
)),
DataCell
(
Text
(
event
.
description
)),
DataCell
(
Text
(
'MP_A_01+100m'
)),
DataCell
(
Text
(
event
.
status
)),
DataCell
(
Text
(
'Information'
)),
],
DataCell
(
Text
(
'100 m NNW of MP_A_01 3 metal bars 2 m wide 20 cm apart 30 cm deep'
)),
),
DataCell
(
Text
(
'EXPORTED'
)),
],
],
),
),
DataRow
(
cells:
<
DataCell
>[
DataCell
(
Text
(
'radar_system:awi_pres_1'
)),
DataCell
(
Text
(
'MP_A_01'
)),
DataCell
(
Text
(
'Deployment'
)),
DataCell
(
Text
(
'position 2,35 m south of point midway TX RX'
)),
DataCell
(
Text
(
'EXPORTED'
)),
],
),
DataRow
(
cells:
<
DataCell
>[
DataCell
(
Text
(
'station:neumayer_iii:level_measure_1'
)),
DataCell
(
Text
(
'1'
)),
DataCell
(
Text
(
'Information'
)),
DataCell
(
Text
(
'Test measurements of snow deposition in cm follow'
)),
DataCell
(
Text
(
'PENDING'
)),
],
),
],
),
),
),
),
);
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment