1
0
Fork 0
mirror of https://code.sup39.dev/repos/Wqawg synced 2024-12-28 09:24:50 +09:00

In persistent models for migrations, suffix the names of uniques too

This commit is contained in:
fr33domlover 2019-05-25 03:20:01 +00:00
parent 5479c99e1c
commit d77877eba5

View file

@ -109,10 +109,15 @@ append entnames suffix entity =
{ foreignRefTableHaskell = updateEnt $ foreignRefTableHaskell f
}
updateUnique u = u
{ uniqueHaskell = updateName $ uniqueHaskell u
}
in entity
{ entityHaskell = updateName $ entityHaskell entity
, entityId = updateField $ entityId entity
, entityFields = map updateField $ entityFields entity
, entityUniques = map updateUnique $ entityUniques entity
, entityForeigns = map updateForeign $ entityForeigns entity
}