mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-11-10 17:36:33 +08:00
added layout, added css, added select2 lib, WIP
This commit is contained in:
parent
5b5c6c7122
commit
76c3db0b11
5 changed files with 106 additions and 0 deletions
|
@ -20,3 +20,4 @@
|
|||
@import "ajax-bootstrap-select.min";
|
||||
@import "extend/bootstrap";
|
||||
@import "themes/scinote";
|
||||
@import "select2.min";
|
||||
|
|
52
app/assets/stylesheets/themes/global_activities.scss
Normal file
52
app/assets/stylesheets/themes/global_activities.scss
Normal file
|
@ -0,0 +1,52 @@
|
|||
@import 'constants';
|
||||
|
||||
.global-activities__container {
|
||||
background: white;
|
||||
padding: 1em;
|
||||
margin-top: 2em;
|
||||
grid-template-columns: 3fr 1fr;
|
||||
display: grid;
|
||||
grid-template-areas:
|
||||
"top top"
|
||||
"main side";
|
||||
}
|
||||
|
||||
.global-activities__top{
|
||||
grid-area: top;
|
||||
grid-template-columns: 1fr 3fr;
|
||||
}
|
||||
|
||||
.global-activities__main{
|
||||
display: grid;
|
||||
grid-template-areas:
|
||||
"actions search"
|
||||
"activities activities";
|
||||
grid-area: main;
|
||||
}
|
||||
|
||||
.global-activities__side{
|
||||
grid-area: side;
|
||||
}
|
||||
|
||||
.global-activities_activities-list{
|
||||
border-top: 1px solid $gray-lighter;
|
||||
margin-top: 2em;
|
||||
grid-area: activities;
|
||||
overflow-y: scroll;
|
||||
min-height: 600px;
|
||||
}
|
||||
|
||||
.global-activities__top-actions{
|
||||
grid-area: actions;
|
||||
}
|
||||
|
||||
.global-activities__search-container{
|
||||
grid-area: search;
|
||||
}
|
||||
|
||||
.global-activiteis__title{
|
||||
grid-area: title;
|
||||
font-size: $font-size-h4;
|
||||
color: $gray-darker;
|
||||
border-bottom: 1px solid $gray-lighter;
|
||||
}
|
18
app/controllers/global_activities_controller.rb
Normal file
18
app/controllers/global_activities_controller.rb
Normal file
|
@ -0,0 +1,18 @@
|
|||
class GlobalActivitiesController < ApplicationController
|
||||
before_action :set_placeholder_variables, only: [:index]
|
||||
|
||||
def index
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
# Whoever will be implementig the filters
|
||||
# will delete this method and before action
|
||||
def set_placeholder_variables
|
||||
@teams = %w(team1 team2 team3)
|
||||
@notification_types = %w(notificationType1 notificationType2 notificationType3)
|
||||
@activity_types = %w(activityType1 activityType2 activityType3)
|
||||
@users = %w(user1 User2 User3 User4)
|
||||
@subjects = %w(Subject1 Subject2 Subject3)
|
||||
end
|
||||
end
|
4
app/views/global_activities/_team_selection.html.erb
Normal file
4
app/views/global_activities/_team_selection.html.erb
Normal file
|
@ -0,0 +1,4 @@
|
|||
<h5>Team</h5>
|
||||
<select name="team">
|
||||
<%=options_for_select @teams %>
|
||||
</select>
|
31
app/views/global_activities/index.html.erb
Normal file
31
app/views/global_activities/index.html.erb
Normal file
|
@ -0,0 +1,31 @@
|
|||
<div class="global-activities__container">
|
||||
<br>
|
||||
<div class="global-activities__top">
|
||||
<h2 class="global-activiteis__title">Global activities</h2>
|
||||
</div>
|
||||
|
||||
<div class="global-activities__main">
|
||||
<div class="global-activities__top-actions">
|
||||
<span><i class="fas fa-caret-square-down"></i> Expand All</span>
|
||||
|
||||
<span><i class="fas fa-caret-square-up"></i> Colapse All</span>
|
||||
</div>
|
||||
<div class="global-activities__search-container">
|
||||
<div class="input-group">
|
||||
<input type="text" class="form-control" placeholder="Search..." aria-describedby="basic-addon1">
|
||||
<span class="input-group-addon" id="basic-addon1">
|
||||
<i class="fas fa-search"></i>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="global-activities_activities-list">
|
||||
<h2>list of activities</h2>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="global-activities__side">
|
||||
<%= render "team_selection" %>
|
||||
</div>
|
||||
|
||||
</div>
|
Loading…
Reference in a new issue