通过数据库操作支持一些目前暂不支持在界面操作的 SCOW 功能。 以下操作需在 mis 的 db 容器中完成。
docker exec -it <container-id> bash
mysql -p
<enter password>
use scow;select user_account.id, user.name, account.account_name, role from user_account inner join user on user_account.user_id=user.id inner join account on user_account.account_id=account.id where account.account_name = "freshmen";+-----+-------+--------------+-------+
| id | name | account_name | role |
+-----+-------+--------------+-------+
| 1 | whxu | freshmen | OWNER |
| 125 | ypliu | freshmen | USER |
+-----+-------+--------------+-------+
根据需要替换最后 where 的查询条件。
start transaction;
update user_account set role = "USER" where id = 1 limit 1;
update user_account set role = "OWNER" where id = 125 limit 1;
commit;如果操作错误,执行 rollback 即可回滚。
进入 mis 的 db 可以使用