我如何以不同的方式使用价值? [英] How Can I Use A Value In Different Ways?

查看:65
本文介绍了我如何以不同的方式使用价值?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好

我有一个网站,其登录表格为用户名,密码和下拉列表,其中包含管理员,教师,替补等不同的用户类型。现在我需要添加一个新的usertype审批人谁也可以是userTypeID = 5的教师。现在我的问题是我如何使用作为Approver的usertype作为Approver,其数据库中的usertypeID为11。我无法删除usertypeid值,因为它们是登录的关键角色。

我如何以批准者的身份登录谁也是一名usertypeID = 11的教师?



我一直无法让新用户存在。如何进行?

Hi All
I have a website having the login form as username , password and a drop down with different usertypes like Administrator , Teacher , Substitutes etc .Now i need to add a new usertype Approver who can also be a teacher whose userTypeID=5 .Now my problem is how can i use the usertype which is teacher as Approver which has usertypeID as 11 in database. I cant remove the usertypeid values because they are the key role to login .
How can i login as a Approver who is also a teacher with usertypeID = 11?

I cant a new user all the time who is already existed . How to proceed ?

推荐答案

Soooo你有一个UserType,用户必须在你的登录表单上选择?你让用户选择他们想成为什么样的用户?



这对我来说似乎有点愚蠢。我会想管理员会选择这个人的用户类型并将其分配给他们。这将要求您在用户和组表之间建立映射表,以便用户可以同时在多个组中。



奇怪的是,这会也可以在不做任何额外工作的情况下解决您的问题。
Soooo you have a "UserType" that the user has to pick on your login form?? You're letting the user pick what kind of user they want to be??

This seems a bit stupid to me. I would have though that administrators would pick what type of user this person is and assign it to them. This would require you to have a mapping table between your user and your group tables so a user can be in multiple groups at the same time.

Oddly enough, this would also solve your problem without doing anything extra.


这篇关于我如何以不同的方式使用价值?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆