File tree 2 files changed +14
-9
lines changed
src-admin-cljs/playground/admin
2 files changed +14
-9
lines changed Original file line number Diff line number Diff line change 18
18
(POST " /_admin_/versions"
19
19
{:params {:project (-> @state :project )}
20
20
:handler #(do
21
- (println %)
21
+ ; (println %)
22
22
(swap! state assoc :versions %)
23
23
(swap! state assoc :version (first %)))
24
24
:error-handler #(println %)}))
25
25
26
26
27
27
(defn change-project [project]
28
- (println " change-project:" project)
29
28
(swap! state assoc :project project)
30
29
(update-versions ))
31
30
35
34
{:params {:project (-> @state :project )
36
35
:version (-> @state :version )}
37
36
:handler #(do
38
- (println %)
37
+ ; (println %)
39
38
(js/alert " Delete version!" )
40
39
(update-versions ))
41
40
:error-handler #(do
48
47
{:params {:project (-> @state :project )
49
48
:version (-> @state :version )}
50
49
:handler #(do
51
- (println %)
50
+ ; (println %)
52
51
(js/alert " Start rebuilding!" )
53
52
(update-versions ))
54
53
:error-handler #(do
82
81
(for [version (:versions (rum/react state))]
83
82
[:option {:key version
84
83
:value version} version])]
85
- [:button.btn.btn-danger {:type " button"
84
+ [:button.btn.btn-primary.rebuild-btn {:type " button"
85
+ :on-click rebuild-version} " Rebuild" ]
86
+ [:button.btn.btn-danger.delete-btn {:type " button"
86
87
:on-click delete-version} " Delete" ]
87
- [:button.btn.btn-primary {:type " button"
88
- :on-click rebuild-version} " Rebuild" ]]]
88
+ ]]
89
89
90
90
[:br ]
91
91
[:div.alert.alert-info
103
103
(reset! state {:projects repos
104
104
:project (first repos)})
105
105
(update-versions )
106
- (println repos)
106
+ ; (println repos)
107
107
(rum/mount (project-select )
108
108
(.getElementById js/document " main-container" ))))
Original file line number Diff line number Diff line change 1
1
body {
2
2
3
- #main-container {
3
+ #main-container {
4
4
widtH : 500px ;
5
5
6
6
select {
@@ -15,5 +15,10 @@ body {
15
15
.admin-panel {
16
16
margin-bottom : 40px ;
17
17
}
18
+
19
+ .delete-btn {
20
+ margin-left : 55px ;
21
+ }
22
+
18
23
}
19
24
}
You can’t perform that action at this time.
0 commit comments