Giter Club home page Giter Club logo

fabric-starter-admin-web's Introduction

Web application for Hyperledger Fabric decentralized application

FOSSA Status

Starter application built with Aurelia to connect to REST API servers and transact on Hyperledger Fabric blockchain network created with Fabric Starter.

Install and build

Install prerequisites: Node.js. This example is for Ubuntu 18:

sudo apt install nodejs npm

Install Aurelia CLI

sudo npm install aurelia-cli -g

Build

npm install && au build --env prod

Create and start the network

Follow instructions on Fabric Starter to create a network of member organizations who will run their REST API servers which will serve this web app.

Development

Run in development

au run --watch

Your web application served by au run in development at http://localhost:9000 will connect to the API server of org a http://localhost:3000.

License

FOSSA Status

fabric-starter-admin-web's People

Contributors

alxkilpio avatar dependabot[bot] avatar fossabot avatar leonidle avatar norikoff avatar olegabu avatar popov-vladimir avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

fabric-starter-admin-web's Issues

Add language and version fields to chaincode install

Default drop down of chaincode language to node; don't allow an empty value. Without the language selected it is sent as null and the api treats as golang and cannot install.
Add edit box for version; default to 1.0.

Webapp calls api at 4000

Webapp calls api at 4000 when itslef is served from another port and org like 4001, 4002...
The calls should go to root /, don't hard code http://localhost:4000.

Wait for transaction to commit

Wait for transaction to commit by adding waitForTransactionEvent=true to the request, only then show info parsed out of the last block in Input, Read and Write sets. Otherwise these sets show outdated info form previous blocks.

Query all member orgs

When no targets are chosen the webapp should not pass any targets to the api so that the api uses the sdk to query all member orgs. Right now only one result is returned, presumably from peer0 of your own org.

Chaincode input

Chaincode input consist of fcn and args, not fcn, key and value the latter being valid for reference chaincode only. Also args should be a text area not text input because args are commonly large json strings which should be clearly visible.

Layout

  • Top left label should read not Hyperledger but the domain of the network, get it from the api at /domain.
  • Install chaincode should always show, no need to select channel to show it
  • Move Install chaincode section into the left column below Join channel
  • List all chaincodes installed in Install chaincode section
  • When no channel is selected don't show labels Chaincodes, Instantiate, Organizations, Targets
  • Replace Join the channel with Join channel
  • Remove (comment out for now) bottom bar with Web-admin label
  • Replace buttons Result, Info, Json with headers above each column: Transaction, Endorsed, Block
  • Transaction section should show a column of sections
  • Response: what the api returned (what you're showing now)
    When the transaction commits, add these sections parsed out of the block just like in the 3rd column:
  • Input: args from ...chaincode_proposal_payload.input (convert each from Buffer into readable string)
  • Result: array of ns_rwset from ...proposal_response_payload.extension.results (show reads and writes)
  • Endorsed section should show a list of trnsaction creator and endorsers as their cert attributes
  • Creator subject.commonName issuer.organizationName
  • Endorser subject.commonName issuer.organizationName
  • Endorser subject.commonName issuer.organizationName
  • Replace Add Organization with Add Organization to Channel

Labels are translated into mixed languages

Some labels like headers show in Russian some like buttons in English even though browser language is chosen English. May have to do with the fact that translation files are loaded via separate GET requests and arrive out of sync with page rendering. Noe translation files should be packed into js archive; the fact they're loaded separately was a work around failed packaging with aurelia.

Invoke\query with long arguments not showing results

no result is shown on UI (but returned to browser) for reference chaincode, fcn: query
arguments:
["[{"key":{"transferer":{"account":"ML9404120506","division":"00000000000000000"},"receiver":{"account":"MS1712180049","division":"00000000000000000"},"security":"RU000A0JVVB5","quantity":"1","reference":"TEST","instructionDate":"2019-05-21","tradeDate":"2019-05-21","type":"dvp","transfererRequisites":{"account":"40701810800001000033","bic":"044583505"},"receiverRequisites":{"account":"30109810200000000000","bic":"044525505"},"paymentAmount":"100","paymentCurrency":"RUB"},"value":{"deponentFrom":"MC0005500000","deponentTo":"MS0241300000","status":"executed","statusInfo":"","initiator":"transferer","memberInstructionIdFrom":"123","memberInstructionIdTo":"123","reasonFrom":{"created":"","document":"","description":""},"reasonTo":{"created":"","document":"","description":""},"alamedaFrom":"\u003c?xml version=\"1.0\" encoding=\"Windows-1251\"?\u003e\n\u003cBatch\u003e\n\u003cDocuments_amount\u003e1\u003c/Documents_amount\u003e\n\u003cDocument DOC_ID=\"1\" version=\"7\"\u003e\n\u003cORDER_HEADER\u003e\n\u003cdeposit_c\u003eNDC000000000\u003c/deposit_c\u003e\n\u003ccontrag_c\u003eMC0005500000\u003c/contrag_c\u003e\n\u003ccontr_d_id\u003e123\u003c/contr_d_id\u003e\n\u003ccreatedate\u003e2019-05-21\u003c/createdate\u003e\n\u003corder_t_id\u003e16/2\u003c/order_t_id\u003e\n\u003cexecute_dt\u003e2019-05-21 00:00:00\u003c/execute_dt\u003e\n\u003cexpirat_dt\u003e2019-05-21 23:59:59\u003c/expirat_dt\u003e\n\u003c/ORDER_HEADER\u003e\n\u003cMF170\u003e\n\u003cdep_acc_c\u003eML9404120506\u003c/dep_acc_c\u003e\n\u003csec_c\u003e00000000000000000\u003c/sec_c\u003e\n\u003ccorr_acc_c\u003eMS1712180049\u003c/corr_acc_c\u003e\n\u003ccorr_sec_c\u003e00000000000000000\u003c/corr_sec_c\u003e\n\u003cdeal_num\u003eTEST\u003c/deal_num\u003e\n\u003cdeal_date\u003e2019-05-21\u003c/deal_date\u003e\n\u003ccon_code\u003eMS0241300000\u003c/con_code\u003e\n\u003csen_acc\u003e30109810200000000000\u003c/sen_acc\u003e\n\u003csen_bic\u003e044525505\u003c/sen_bic\u003e\n\u003crec_acc\u003e40701810800001000033\u003c/rec_acc\u003e\n\u003crec_bic\u003e044583505\u003c/rec_bic\u003e\n\u003cpay_sum\u003e100\u003c/pay_sum\u003e\n\u003cpay_curr\u003eRUB\u003c/pay_curr\u003e\n\n\u003cblock_securities\u003eN\u003c/block_securities\u003e\n\u003cf_instruction\u003eN\u003c/f_instruction\u003e\n\u003cauto_borr\u003eN\u003c/auto_borr\u003e\n\u003csecurities\u003e\n\u003csecurity\u003e\n\u003csecurity_c\u003eRU000A0JVVB5\u003c/security_c\u003e\n\u003csecurity_q\u003e1\u003c/security_q\u003e\n\u003c/security\u003e\n\u003c/securities\u003e\n\u003c/MF170\u003e\n\u003c/Document\u003e\n\u003c/Batch\u003e","alamedaTo":"\u003c?xml version=\"1.0\" encoding=\"Windows-1251\"?\u003e\n\u003cBatch\u003e\n\u003cDocuments_amount\u003e1\u003c/Documents_amount\u003e\n\u003cDocument DOC_ID=\"1\" version=\"7\"\u003e\n\u003cORDER_HEADER\u003e\n\u003cdeposit_c\u003eNDC000000000\u003c/deposit_c\u003e\n\u003ccontrag_c\u003eMS0241300000\u003c/contrag_c\u003e\n\u003ccontr_d_id\u003e123\u003c/contr_d_id\u003e\n\u003ccreatedate\u003e2019-05-21\u003c/createdate\u003e\n\u003corder_t_id\u003e16/3\u003c/order_t_id\u003e\n\u003cexecute_dt\u003e2019-05-21 00:00:00\u003c/execute_dt\u003e\n\u003cexpirat_dt\u003e2019-05-21 23:59:59\u003c/expirat_dt\u003e\n\u003c/ORDER_HEADER\u003e\n\u003cMF170\u003e\

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.