This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <dependency> | |
| <groupId>com.amazonaws</groupId> | |
| <artifactId>aws-java-sdk-s3</artifactId> | |
| <version>1.11.283</version> | |
| </dependency> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Service | |
| public class AmazonS3Service { | |
| private AmazonS3 s3client; | |
| @Value("${amazonProperties.endpointUrl}") | |
| private String endpointUrl; | |
| @Value("${amazonProperties.bucketName}") | |
| private String bucketName; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @RestController | |
| @RequestMapping("/api/v1/storage") | |
| public class AmazonS3Controller { | |
| private AmazonS3Service amazonS3Service; | |
| @Autowired | |
| AmazonS3Controller(AmazonS3Service amazonS3Service){ | |
| this.amazonS3Service = amazonS3Service; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.nostratech.project.vo; | |
| import com.fasterxml.jackson.annotation.JsonProperty; | |
| import lombok.Data; | |
| @Data | |
| public class SubmitAmanahVO extends BaseVO{ | |
| @JsonProperty("agentId") | |
| public String agentId; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.nostratech.project.vo; | |
| import com.fasterxml.jackson.annotation.JsonProperty; | |
| import lombok.Data; | |
| import java.math.BigDecimal; | |
| @Data | |
| public class SimulasiAmanahVO { | |
| @JsonProperty(value = "tipe_kendaraan") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.nostratech.project.util; | |
| import com.nostratech.project.persistence.domain.AccessLevel; | |
| import com.nostratech.project.persistence.domain.Privilege; | |
| import com.nostratech.project.persistence.repository.AccessLevelRepository; | |
| import com.nostratech.project.persistence.repository.PrivilegeRepository; | |
| import com.nostratech.project.persistence.domain.*; | |
| import com.nostratech.project.persistence.repository.*; | |
| import com.nostratech.project.oauth.provider.UserPasswordAuthenticationToken; | |
| import org.slf4j.Logger; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -----------------------------------com.example.CapWord.java----------------------------------- | |
| package com.example; | |
| import java.util.HashMap; | |
| import java.util.Map; | |
| import com.fasterxml.jackson.annotation.JsonAnyGetter; | |
| import com.fasterxml.jackson.annotation.JsonAnySetter; | |
| import com.fasterxml.jackson.annotation.JsonIgnore; | |
| import com.fasterxml.jackson.annotation.JsonInclude; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ go get gopkg.in/gin-gonic/gin.v1 | |
| $ go get -u github.com/jinzhu/gorm | |
| $ go get github.com/go-sql-driver/mysql |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "github.com/jinzhu/gorm" | |
| "github.com/gin-gonic/gin" | |
| _ "github.com/jinzhu/gorm/dialects/mysql" | |
| "net/http" | |
| ) | |
| var db *gorm.DB |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| type ( | |
| student struct { | |
| gorm.Model | |
| Nama string `json:"nama"` | |
| Alamat string `json:"alamat"` | |
| NoHp string `json:"no_hp"` | |
| Kelas string `json:"kelas"` | |
| StatusAktif int `json:"status_aktif"` | |
| } | |
| transformedStudent struct { |
OlderNewer