Skip to content

Commit

Permalink
add message
Browse files Browse the repository at this point in the history
  • Loading branch information
liberhe committed Jan 25, 2024
1 parent 1e9354a commit 50c49dc
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
6 changes: 5 additions & 1 deletion src/main/java/com/dl/officialsite/redpacket/RedPacket.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public class RedPacket {
@Column(length = 66)
private String name;

@Column(length = 64) //
@Column(length = 66) //
@NotNull
private String id;

Expand Down Expand Up @@ -66,7 +66,11 @@ public class RedPacket {
//the number of redpacket
private Integer number;

@Column(length = 66)
private String hashLock;

@Column(length = 66)
private String message;
//usdc or dai
private String token;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public void updateRedpacketStatus() throws IOException {
JsonObject data = jsonObject.getAsJsonObject("data");
JsonArray redpacketsArray = data.getAsJsonArray("redpackets");
JsonArray lastupdatesArray = data.getAsJsonArray("lastupdates");
// String lastTimestampFromGraph = lastupdatesArray.get(0).getAsJsonObject().get("lastupdateTimestamp").getAsString();
// String lastTimestampFromGraph = lastupdatesArray.get(0).getAsJsonObject().get("lastupdateTimestamp").getAsString();

// open in prod todo
// if(Objects.equals(lastTimestampFromGraph, lastUpdateTimestamp)){
Expand Down Expand Up @@ -152,7 +152,7 @@ private HttpEntity getHttpEntityFromChain(String chainId) throws IOException {
" claimedValue " +
" }" +
" }" +
" lastupdates (orderBy : lastupdateTimestamp , orderDirection: desc) { lastupdateTimestamp} " +
" lastupdates (orderBy : lastupdateTimestamp , orderDirection: desc) { lastupdateTimestamp } " +

"}\"";

Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/DB/2.sql
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ alter table red_packet add unique index id_chain(id,chain_id);

alter table red_packet MODIFY COLUMN id varchar(66);

ALTER TABLE red_packet add INDEX id(id);
ALTER TABLE red_packet add unique INDEX id(id);

0 comments on commit 50c49dc

Please sign in to comment.