made otc wui. no back end

This commit is contained in:
didier amyot committed 2018-11-12 15:39:39 -05:00
1 parent 10b054db25
commit 2c53b516d6
2 files changed
+16 -18

No files matched your search

+14 -16
View File
@@ -1,5 +1,6 @@
(ns skirmish.wui.components.otc-page
(:require [reagent.core :refer [atom]]
[skirmish.wui.components.securities-page :refer [get-securities]]
[skirmish.wui.util :refer [email?]]))
@@ -22,31 +23,29 @@
(and (-> state :value js/parseInt pos?)
(-> state :email email?)))
(defn direct-send-confirmation []
[:div.model
[:div.modal-background]
[:div.modal-content
[:div.modal-card
[:header.modal-card-head
[:p.modal-card-title "Modal title"]
[:button.delete]]]]
[:a.button.modal-close.is-large {:aria-label "close"} "dslkds"]])
(defn select-securities-for [securities on-change]
[:select {:on-change on-change}
(for [security securities]
[:option {:value (:sec-id security) :key (:sec-id security)} (:sec-id security)])])
(defn select-security [on-change]
(let [securities (atom [])]
(get-securities securities)
#(select-securities-for @securities on-change)))
(defn direct-send []
(let [state (atom {})]
(fn []
[:div
[:div.content
[:p "Send securities to another person."]
[:pre (str @state)]]
[:p "Send securities to another person."]]
[:form.form
[:div.field.has-addons.has-addons-centered
[:div.control
[:span.select
[:select {:value (:sec-id @state)
:on-change (partial set-sec-id state)}
[:option {:value :foo :selected true} "damp"]
[:option {:value :bar } "blah blah blah"]]]]
[select-security (partial set-sec-id state)]]]
[:div.control
[:input.input {:type "text"
:value (:value @state)
@@ -62,7 +61,6 @@
(defn page [state]
[:div
;[direct-send-confirmation]
[:div.content
[:h5 "Do transaction without passing by the exchange."]]
@@ -41,13 +41,13 @@
[:li done "create two stocks"]
[:li done "add stocks to didier@gmail.com"]
[:li done "make something for urls on the backend"]
[:li on-it "add a wui for OTC"]
[:li done "add a wui for OTC"]
[:li "fix the stupid chat. This is an important feature for OTC users."]
[:li "make something that allows to send securities from one user to another"]
[:li "move 'routes' in 'rest'"]
[:li "add a little bit of professionalism on top of the broker api"]
[:li "make the api support transit and edn"]
[:li "implements interest rate in ledger."]
[:li on-it "implements interest rate in ledger."]
[:li "Make sure the ledger can have accounts"]
[:li done "when a new user signs in, he should receive some sort of money"]
[:li "implement send securities to friends"]