mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-01 21:21:50 +08:00
Fix small css issues [SCI-7699][SCI-7694][SCI-7678]
This commit is contained in:
parent
83ba9d40dc
commit
85eaf7c246
4 changed files with 14 additions and 7 deletions
|
@ -60,7 +60,7 @@
|
|||
position: sticky;
|
||||
position: -webkit-sticky;
|
||||
top: 0;
|
||||
z-index: 10;
|
||||
z-index: 7;
|
||||
|
||||
&.select-all-checkboxes {
|
||||
justify-content: center;
|
||||
|
|
|
@ -58,8 +58,8 @@
|
|||
align-items: center;
|
||||
display: flex;
|
||||
height: 2em;
|
||||
justify-content: center;
|
||||
width: 2em;
|
||||
justify-content: left;
|
||||
width: 1.5em;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -111,6 +111,7 @@
|
|||
|
||||
.checkbox-cell {
|
||||
grid-column: 1;
|
||||
justify-content: center;
|
||||
position: initial;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -91,6 +91,9 @@
|
|||
background: $color-concrete;
|
||||
}
|
||||
|
||||
.btn {
|
||||
height: 36px;
|
||||
}
|
||||
|
||||
a {
|
||||
display: inline-block;
|
||||
|
|
|
@ -35,11 +35,14 @@ class MyModulesController < ApplicationController
|
|||
end
|
||||
|
||||
def create
|
||||
max_xy = @experiment.my_modules.select('MAX("my_modules"."x") AS x, MAX("my_modules"."y") AS y').take
|
||||
x = max_xy.x ? (max_xy.x + 14) : 1
|
||||
y = max_xy.y ? (max_xy.y + 14) : 1
|
||||
@my_module = @experiment.my_modules.new(my_module_params)
|
||||
@my_module.assign_attributes(created_by: current_user, last_modified_by: current_user, x: x, y: y)
|
||||
new_pos = @my_module.get_new_position
|
||||
@my_module.assign_attributes(
|
||||
created_by: current_user,
|
||||
last_modified_by: current_user,
|
||||
x: new_pos[:x],
|
||||
y: new_pos[:y]
|
||||
)
|
||||
@my_module.transaction do
|
||||
if my_module_tags_params[:tag_ids].present?
|
||||
@my_module.tags << @experiment.project.tags.where(id: JSON.parse(my_module_tags_params[:tag_ids]))
|
||||
|
|
Loading…
Reference in a new issue