Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
yotta
/
pictogram
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
60
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
191f71c3
authored
Nov 06, 2017
by
Arturo Montejo Ráez
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
minor change in new-grid-update
parent
028727e1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
sails/roles/database/files/new-grid-system-adapt.sql
sails/roles/database/files/new-grid-system-adapt.sql
View file @
191f71c3
...
...
@@ -35,8 +35,6 @@ BEGIN
END
IF
;
-- Carga las variables desde el JSON para free_category_coord e id_cat
SELECT
_attributes
->>
"$.free_category_coord_x"
INTO
_free_category_coord_x
;
SELECT
_attributes
->>
"$.free_category_coord_y"
INTO
_free_category_coord_y
;
IF
_attributes
->>
"$.free_category_coord_x"
=
'null'
THEN
SET
_free_category_coord_x
=
NULL
;
...
...
@@ -61,7 +59,7 @@ BEGIN
IF
(
_free_category_coord_x
IS
NOT
NULL
)
OR
(
_free_category_coord_y
IS
NOT
NULL
)
THEN
-- Pasa las coordenadas libres a coord_x y coord_y, ademas elimina variables antiguas
UPDATE
stu_picto
UPDATE
stu_picto
_id_cat
SET
`attributes`
=
JSON_REPLACE
(
`attributes`
,
'$.coord_x'
,
_free_category_coord_x
),
`attributes`
=
JSON_REPLACE
(
`attributes`
,
'$.coord_y'
,
_free_category_coord_y
),
...
...
@@ -127,7 +125,7 @@ BEGIN
-- Se pone id_cat a NULL, puesto que dicho valor no lo volveremos a necesitar
UPDATE
stu_picto
SET
`attributes`
=
JSON_REMOVE
(
`attributes`
,
'$.id_cat'
,
NULL
)
`attributes`
=
JSON_REMOVE
(
`attributes`
,
'$.id_cat'
)
WHERE
id
=
_id_stu_picto
;
END
IF
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment