Exemplo n.º 1
0
 def post(self):
     userGroupID = int(self.get_arg('userGroupID', '0'))
     userID = int(self.get_arg('userID', '0'))
     if userGroupID <= 0 or userID <= 0:
         self.out_fail(code = 105004)
         return
     id = usergroup_logic.bind_group_user(userGroupID = userGroupID, userID = userID, user = self.get_oper_user())
     if None != id and id > 0:
         self.write_oper_log(action = 'userGroupBindUser', targetType = 6, targetID = str(userGroupID), targetName = str(userID), startStatus = str(userGroupID), endStatus= str(userID))
         self.out_ok()
     else:
         self.out_fail(code = 105005)
Exemplo n.º 2
0
 def bind_user_group(self, userID, userGroupID, user):
     if None == userGroupID or '' == userGroupID:
         return
     id = usergroup_logic.bind_group_user(userGroupID=userGroupID,
                                          userID=userID,
                                          user=self.get_oper_user())
     if None != id and id > 0:
         self.write_oper_log(action='userGroupBindUser',
                             targetType=6,
                             targetID=str(userGroupID),
                             targetName=str(userID),
                             startStatus=str(userGroupID),
                             endStatus=str(userID))
Exemplo n.º 3
0
 def post(self):
     userGroupID = int(self.get_arg('userGroupID', '0'))
     userID = int(self.get_arg('userID', '0'))
     if userGroupID <= 0 or userID <= 0:
         self.out_fail(code=105004)
         return
     id = usergroup_logic.bind_group_user(userGroupID=userGroupID,
                                          userID=userID,
                                          user=self.get_oper_user())
     if None != id and id > 0:
         self.write_oper_log(action='userGroupBindUser',
                             targetType=6,
                             targetID=str(userGroupID),
                             targetName=str(userID),
                             startStatus=str(userGroupID),
                             endStatus=str(userID))
         self.out_ok()
     else:
         self.out_fail(code=105005)
Exemplo n.º 4
0
 def bind_user_group(self, userID, userGroupID, user):
     if None == userGroupID or '' == userGroupID:
         return
     id = usergroup_logic.bind_group_user(userGroupID = userGroupID, userID = userID, user = self.get_oper_user())
     if None != id and id > 0:
         self.write_oper_log(action = 'userGroupBindUser', targetType = 6, targetID = str(userGroupID), targetName = str(userID), startStatus = str(userGroupID), endStatus= str(userID))