diff --git a/pym/unix/variables/groups.py b/pym/unix/variables/groups.py index d444c2a..c9f1f01 100644 --- a/pym/unix/variables/groups.py +++ b/pym/unix/variables/groups.py @@ -261,6 +261,7 @@ class VariableUrUnixGroupUsersAdd(UnixUserHelper, Variable): """ type = "choiceedit-list" opt = ("-a", "--add") + guitype = "hidden" value = [] metavalue = "USERS" @@ -336,6 +337,7 @@ class VariableUrUnixGroupUsersDel(UnixUserHelper, Variable): """ type = "choiceedit-list" opt = ("-r", "--remove") + guitype = "hidden" value = [] metavalue = "USERS" diff --git a/pym/unix/variables/users.py b/pym/unix/variables/users.py index 64b96c1..79430a2 100644 --- a/pym/unix/variables/users.py +++ b/pym/unix/variables/users.py @@ -185,6 +185,13 @@ class VariableUrUnixHomePathMove(Variable): _("Previous home directory %s not found") % old_path) +class VariableClUnixGroupDefault(Variable): + """ + Основная группа пользователя по умолчанию + """ + value = "domain" + + class VariableUrUnixPrimaryGroup(ExistsUserHelper, UnixGroupHelper, UnixActionHelper, Variable): """ @@ -195,7 +202,9 @@ class VariableUrUnixPrimaryGroup(ExistsUserHelper, UnixGroupHelper, opt = ('-g', '--gid') metavalue = "GROUP" - domain_group = "domain" + @property + def domain_group(self): + return self.Get('cl_unix_group_default') def init(self): self.label = _("Primary group") @@ -203,7 +212,7 @@ class VariableUrUnixPrimaryGroup(ExistsUserHelper, UnixGroupHelper, "('default' value for create default group)") def get_new(self): - return "domain" + return self.domain_group def get_exists(self): value = str(ExistsUserHelper.get_exists(self)) @@ -332,6 +341,7 @@ class VariableUrUnixGroupsAdd(UnixGroupHelper, UnixActionHelper, Variable): Список групп в которые необходимо добавить пользователя """ type = "choiceedit-list" + guitype = "hidden" opt = ("-a", "--append") metavalue = "GROUPS" value = [] @@ -390,6 +400,7 @@ class VariableUrUnixGroupsDel(VariableUrUnixGroupsAdd): """ type = "choiceedit-list" opt = ("-r", "--remove") + guitype = "hidden" metavalue = "GROUPS" value = [] diff --git a/pym/unix/wsdl_unix.py b/pym/unix/wsdl_unix.py index fbaba1a..ee1302b 100644 --- a/pym/unix/wsdl_unix.py +++ b/pym/unix/wsdl_unix.py @@ -382,16 +382,16 @@ class Wsdl(WsdlBase): 'ur_unix_primary_group', 'ur_unix_comment', 'ur_unix_groups', - 'ur_unix_visible_set', - 'ur_unix_lock_set', ), expert=( 'ur_unix_groups_add', 'ur_unix_groups_del', + 'ur_unix_lock_set', + 'ur_unix_pw_delete_set', + 'ur_unix_visible_set', 'ur_unix_home_path', 'ur_unix_home_path_move', 'ur_unix_shell', - 'ur_unix_pw_delete_set', ), custom_buttons=[ CustomButton.run_method(Unix.Method.UserShow,