I tried to restore the object from admin mode and did not work
Admin.only_deleted.first.recover Admin Load (1.9ms) SELECT "admins".* FROM "admins" WHERE ("admins"."deleted_at" IS NOT NULL) ORDER BY "admins"."id" ASC LIMIT 1 NoMethodError: undefined method `recover' for #<Admin:0xa57f10c>
Any idea?
Now there is a recovery, not a recovery, but its incorrect recovery of dependent records, which are a real pain
I donβt know why the developers did this, but I see that the recovery method has protected visibility.
So you must call this method from the model, and you cannot call it from the outside
Well, it seems that the problem is in the active version of the record, they moved something and therefore do not restore the records, it is fixed in the newest version.
Source: https://habr.com/ru/post/1204287/More articles:MVVM Light - user controls in the form of views - c #Rails validation enable error 'not included in list' - ruby ββ| fooobar.comSelect min (date), max (date) and group by day from one column - SQL - maxProtect user credentials when connecting R to databases using JDBC / ODBC drivers - securityAngular Auth vs Laravel backend - javascriptGoogle BigQuery System Status Page? - google-bigqueryHow to extract a subvector (from Eigen :: Vector) from an index vector in Eigen? - c ++Node.js, Express, Mongoose - input validation - within a route or model? - node.jsHow to programmatically move a tab to another window in the Firefox add-on SDK extension? - firefoxPostgres Rules CTE Request Prevention - postgresqlAll Articles