forked from togettoyou/fabric-realty
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
zoujh
committed
Apr 26, 2021
1 parent
31ad7f3
commit 6bc227b
Showing
2,483 changed files
with
2,825 additions
and
742,677 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
.vscode | ||
.idea |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
FROM golang:1.14 | ||
|
||
ENV GO111MODULE=on | ||
ENV GOPROXY=https://goproxy.cn,direct | ||
|
||
RUN mkdir -p /root/blockchain-real-estate | ||
RUN apt update \ | ||
&& apt-get -y install nodejs npm | ||
|
||
COPY application /root/blockchain-real-estate/application | ||
COPY deploy/crypto-config /root/blockchain-real-estate/crypto-config | ||
|
||
WORKDIR /root/blockchain-real-estate/application/vue | ||
RUN npm config set registry "https://registry.npm.taobao.org/" \ | ||
&& npm i node-sass --sass_binary_site="https://npm.taobao.org/mirrors/node-sass/" \ | ||
&& npm install | ||
RUN npm run build:prod | ||
RUN mv ./dist ../ | ||
|
||
WORKDIR /root/blockchain-real-estate/application | ||
RUN go build -o "app" . | ||
|
||
EXPOSE 8000 | ||
ENTRYPOINT ["./app"] |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,3 @@ | ||
/** | ||
* @Author: 夜央 Oh oh oh oh oh oh (https://github.com/togettoyou) | ||
* @Email: [email protected] | ||
* @Date: 2020/3/4 4:21 下午 | ||
* @Description: fabric-sdk-go的封装 | ||
*/ | ||
package blockchain | ||
|
||
import ( | ||
|
@@ -19,10 +13,10 @@ var ( | |
ChainCodeName = "blockchain-real-estate" // 链码名称 | ||
Org = "org1" // 组织名称 | ||
User = "Admin" // 用户 | ||
ConfigPath = "blockchain/config.yaml" // 配置文件路径 | ||
ConfigPath = "conf/config.yaml" // 配置文件路径 | ||
) | ||
|
||
// 初始化 | ||
// Init 初始化 | ||
func Init() { | ||
var err error | ||
// 通过配置文件初始化SDK | ||
|
@@ -32,7 +26,7 @@ func Init() { | |
} | ||
} | ||
|
||
// 区块链交互 | ||
// ChannelExecute 区块链交互 | ||
func ChannelExecute(fcn string, args [][]byte) (channel.Response, error) { | ||
// 创建客户端,表明在通道的身份 | ||
ctx := SDK.ChannelContext(ChannelName, fabsdk.WithOrg(Org), fabsdk.WithUser(User)) | ||
|
@@ -53,7 +47,7 @@ func ChannelExecute(fcn string, args [][]byte) (channel.Response, error) { | |
return resp, nil | ||
} | ||
|
||
// 区块链查询 | ||
// ChannelQuery 区块链查询 | ||
func ChannelQuery(fcn string, args [][]byte) (channel.Response, error) { | ||
// 创建客户端,表明在通道的身份 | ||
ctx := SDK.ChannelContext(ChannelName, fabsdk.WithOrg(Org), fabsdk.WithUser(User)) | ||
|
This file contains 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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.