Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Ğecko
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
Service Desk
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
clients
Ğecko
Commits
380b51de
Commit
380b51de
authored
10 months ago
by
poka
Browse files
Options
Downloads
Patches
Plain Diff
feat: add real date of certifications
parent
c7b4f396
No related branches found
Branches containing commit
Tags
v0.1.7+78
Tags containing commit
No related merge requests found
Pipeline
#36878
failed
10 months ago
Stage: format
Stage: build_and_test
Stage: package
Changes
3
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
lib/models/queries_indexer.dart
+12
-2
12 additions, 2 deletions
lib/models/queries_indexer.dart
lib/widgets/certs_list.dart
+9
-2
9 additions, 2 deletions
lib/widgets/certs_list.dart
pubspec.yaml
+1
-1
1 addition, 1 deletion
pubspec.yaml
with
22 additions
and
5 deletions
lib/models/queries_indexer.dart
+
12
−
2
View file @
380b51de
...
...
@@ -68,11 +68,16 @@ const String getCertsReceived = r'''
query (
$address
: String!) {
certConnection(
where: {receiver: {accountId: {_eq:
$address
}}}
orderBy: {updatedOn: DESC}
) {
edges {
node {
isActive
createdOn
updatedIn {
block {
timestamp
}
}
issuer {
accountId
name
...
...
@@ -87,11 +92,16 @@ const String getCertsSent = r'''
query (
$address
: String!) {
certConnection(
where: {issuer: {accountId: {_eq:
$address
}}}
orderBy: {updatedOn: DESC}
) {
edges {
node {
isActive
createdOn
updatedIn {
block {
timestamp
}
}
receiver {
accountId
name
...
...
This diff is collapsed.
Click to expand it.
lib/widgets/certs_list.dart
+
9
−
2
View file @
380b51de
...
...
@@ -18,6 +18,10 @@ class CertsList extends StatelessWidget {
final
String
address
;
final
CertDirection
direction
;
String
formatNumber
(
int
number
)
{
return
number
<
10
?
'0
$number
'
:
'
$number
'
;
}
@override
Widget
build
(
BuildContext
context
)
{
final
indexerProvider
=
Provider
.
of
<
DuniterIndexer
>(
context
,
listen:
false
);
...
...
@@ -81,9 +85,12 @@ class CertsList extends StatelessWidget {
}
final
String
issuerAddress
=
cert
[
certFrom
][
'accountId'
];
final
String
issuerName
=
cert
[
certFrom
][
'name'
];
final
date
=
DateTime
.
parse
(
'2024-02-04T21:20:54.001+00:00'
);
final
date
=
DateTime
.
parse
(
cert
[
'updatedIn'
][
'block'
][
'timestamp'
]);
final
dp
=
DateTime
(
date
.
year
,
date
.
month
,
date
.
day
);
final
dateForm
=
'
${dp.day}
-
${dp.month}
-
${dp.year}
'
;
final
dateForm
=
'
${formatNumber(dp.day)}
-
${formatNumber(dp.month)}
-
${dp.year}
'
;
// Check if we have a more recent certification, we skip
if
(
!
listCerts
.
any
((
cert
)
=
>
cert
[
'address'
]
==
issuerAddress
))
{
...
...
This diff is collapsed.
Click to expand it.
pubspec.yaml
+
1
−
1
View file @
380b51de
...
...
@@ -2,7 +2,7 @@ name: gecko
description
:
Pay with G1.
publish_to
:
"
none"
version
:
0.1.7+7
7
version
:
0.1.7+7
8
environment
:
sdk
:
"
>=2.12.0
<3.0.0"
...
...
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