fix collect readonly in table

develop
Спиридонов Денис 12 years ago
parent 1261e792a6
commit 0a297cd961

@ -50,7 +50,7 @@ def client_post_cert (client, clVars, show_info = False):
print _("Certificate not send!") print _("Certificate not send!")
else: else:
if show_info: if show_info:
print _(" Your certifitate id = %d") %(result_post_cert[0]) print _(" Your certifitate id - %d") %(result_post_cert[0])
try: try:
if result_post_cert[1] == -2: if result_post_cert[1] == -2:
print _("expiry date certificate has passed") print _("expiry date certificate has passed")
@ -135,7 +135,7 @@ def get_password(text1 = None, text2 = None):
def client_post_request (cert_path, args): def client_post_request (cert_path, args):
if os.path.exists(cert_path + 'req_id'): if os.path.exists(cert_path + 'req_id'):
print _("You have sent a request to sign the certificate.") print _("You have sent a request to sign the certificate.")
_print (_("request id = %s") %open(cert_path + 'req_id', 'r').read()) _print (_("request id - %s") %open(cert_path + 'req_id', 'r').read())
ans = raw_input (_("Send new request? y/[n]: ")) ans = raw_input (_("Send new request? y/[n]: "))
if not ans.lower() in ['y','yes']: if not ans.lower() in ['y','yes']:
return 0 return 0
@ -178,7 +178,7 @@ def client_post_request (cert_path, args):
fc = open(os.path.join(cert_path, 'req_id'), 'w') fc = open(os.path.join(cert_path, 'req_id'), 'w')
fc.write(res) fc.write(res)
fc.close() fc.close()
_print (_("Your request id = %s") %res) _print (_("Your request id - %s") %res)
return 0 return 0
def client_get_cert(cert_path, args): def client_get_cert(cert_path, args):
@ -220,7 +220,7 @@ def client_get_cert(cert_path, args):
return 1 return 1
elif cert == '2': elif cert == '2':
print _("Request for the signing has not yet reviewed.") print _("Request for the signing has not yet reviewed.")
print _("Your request id = %s") %req_id print _("Your request id - %s") %req_id
return 1 return 1
elif cert == '3': elif cert == '3':
print _("Request on signature does not match sent earlier.") print _("Request on signature does not match sent earlier.")
@ -236,7 +236,7 @@ def client_get_cert(cert_path, args):
os.unlink(cert_path + 'req_id') os.unlink(cert_path + 'req_id')
except OSError, e: except OSError, e:
_print (e.message) _print (e.message)
print 'OK. Certificate save. Your certificate id = %s' %req_id print 'OK. Certificate save. Your certificate id - %s' %req_id
user_name = pwd.getpwuid(os.getuid()).pw_name user_name = pwd.getpwuid(os.getuid()).pw_name
try: try:
pwdObj = pwd.getpwnam(user_name) pwdObj = pwd.getpwnam(user_name)

@ -318,7 +318,8 @@ def collect_table(field, val_list, client, wait_thread):
choice_value = ChoiceValue[j] choice_value = ChoiceValue[j]
typefield = choice_value.typefield typefield = choice_value.typefield
if typefield == 'readonly': # if readonly, except first column
if typefield == 'readonly' and j > 0:
continue continue
elif typefield in ['check', 'check_tristate']: elif typefield in ['check', 'check_tristate']:
if len (val_table[i]) < j + 1: if len (val_table[i]) < j + 1:

@ -2,8 +2,8 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: console_gui_translate\n" "Project-Id-Version: console_gui_translate\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-15 15:51+0300\n" "POT-Creation-Date: 2012-06-20 09:22+0300\n"
"PO-Revision-Date: 2012-06-15 16:12+0300\n" "PO-Revision-Date: 2012-06-20 09:22+0300\n"
"Last-Translator: Denis <ds@mail.ru>\n" "Last-Translator: Denis <ds@mail.ru>\n"
"Language-Team: \n" "Language-Team: \n"
"Language: \n" "Language: \n"
@ -452,8 +452,8 @@ msgstr "Сертификат не отправлен!"
#: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:53 #: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:53
#, python-format #, python-format
msgid " Your certifitate id = %d" msgid " Your certifitate id - %d"
msgstr "Номер Вашего сертификата = %d" msgstr "Номер Вашего сертификата - %d"
#: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:56 #: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:56
msgid "expiry date certificate has passed" msgid "expiry date certificate has passed"
@ -495,8 +495,8 @@ msgstr "У Вас уже есть отправленный запрос на п
#: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:138 #: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:138
#, python-format #, python-format
msgid "request id = %s" msgid "request id - %s"
msgstr "Номер запроса = %s" msgstr "Номер запроса - %s"
#: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:139 #: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:139
msgid "Send new request? y/[n]: " msgid "Send new request? y/[n]: "
@ -532,8 +532,8 @@ msgstr "Сервер не подписал сертификат!"
#: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:181 #: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:181
#: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:223 #: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:223
#, python-format #, python-format
msgid "Your request id = %s" msgid "Your request id - %s"
msgstr "Номер Вашего запроса = %s" msgstr "Номер Вашего запроса - %s"
#: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:186 #: /var/calculate/mydir/git/calculate-console/console/application/cert_func.py:186
#, python-format #, python-format

Loading…
Cancel
Save