Index: /branches/rel_apv_10_7/usr/click/webui/htdocs/new/src/hive/report.py
===================================================================
--- /branches/rel_apv_10_7/usr/click/webui/htdocs/new/src/hive/report.py	(revision 38695)
+++ /branches/rel_apv_10_7/usr/click/webui/htdocs/new/src/hive/report.py	(working copy)
@@ -28,7 +28,7 @@
 report_file_path = "/ca/webui/htdocs/new/src/media/docs/"
 font_file_path = "/ca/webui/htdocs/new/src/media/font/Alibaba/"
 
-current_lan = 'en'
+current_font = "alibaba"
 
 def generate_report_table_cover(data, col_num):
     t = Table(data, colWidths=int(480/col_num), rowHeights=20)
@@ -36,7 +36,7 @@
     t.setStyle(TableStyle([('BACKGROUND', (0, 0), (-1, -1), colors.white),
                             ('ALIGN', (1,1), (-1,-1), 'LEFT'),
                             ('ALIGN', (0,0), (0, -1), 'RIGHT'),
-                            ('FONT', (0,0), (-1, -1), 'alibaba'),
+                            ('FONT', (0,0), (-1, -1), current_font),
                             ]))
     t.hAlign = "RIGHT"
     return t
@@ -52,7 +52,7 @@
             bg_color = colors.white
 
         t.setStyle(TableStyle([('BACKGROUND', (0, each), (-1, each), bg_color),
-                                ('FONT', (0,0), (-1, -1), 'alibaba'),]))
+                                ('FONT', (0,0), (-1, -1), current_font),]))
     return t
 
 def get_time_range(from_time, to_time):
@@ -68,7 +68,7 @@
 
 def Draw_Line_Chart(chart_name, env, styles, story, time_list, chart_item, table_data, yaxis_name=""):
     ptext = '<font size="12">%s</font>' % chart_name
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     d = Draw_a_Line()
     story.append(d)
 
@@ -89,7 +89,7 @@
 
 def Draw_Bar_Chart(chart_name, env, styles, story, xaxis_list, chart_item, table_data, xrotate):
     ptext = '<font size="12">%s</font>' % chart_name
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     d = Draw_a_Line()
     story.append(d)
 
@@ -630,7 +630,7 @@
     system_data_dic = get_system_data_sql(from_time, to_time)
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("System Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     if "cpu_usage" in system_list:
         graph_item = [{
@@ -675,7 +675,7 @@
     start_time = time.strftime("%Y-%m-%d %H:%M:%S", time.localtime(intervalStart))
     if 'cpu_usage' in system_list or 'mem_usage' in system_list or 'net_load' in system_list:
         ptext = '<font size="12">' + unicode(_("Conclusion")) +'</font>'
-        story.append(Paragraph(ptext, styles["alibaba"]))
+        story.append(Paragraph(ptext, styles[current_font]))
         d = Draw_a_Line()
         story.append(d)
         ptext = '<font size="10">'+ unicode(_('During the period from %s to %s, ')) % (start_time, end_time)
@@ -684,14 +684,14 @@
         else:
             ptext += unicode(_('the system encountered the following abnormal conditions:'))+'</font>'
             ptext += run_status
-        story.append(Paragraph(ptext, styles["alibaba"]))
+        story.append(Paragraph(ptext, styles[current_font]))
     
     return story
 
 def generateSLBVSReport(from_time, to_time, slb_vs_list, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("SLB Virtual Service Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     
     for each_vs in slb_vs_list:
@@ -797,7 +797,7 @@
 def generateSLBRSReport(from_time, to_time, slb_rs_list, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("SLB Real Service Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     
     for each_rs in slb_rs_list:
@@ -862,7 +862,7 @@
 def generateSSLVHostReport(from_time, to_time, slb_vh_dic, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="12">' + unicode(_("SSL Virtual Host Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     ssl_status = SSLStatFacade(from_time)
     for each_vh in slb_vh_dic:
@@ -905,7 +905,7 @@
 def generateSSLRHostReport(from_time, to_time, slb_rh_dic, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="12">' + unicode(_("SSL Real Host Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     
     for each_rh in slb_rh_dic:
@@ -937,7 +937,7 @@
 def generateSLBTotalReport(from_time, to_time, slb_total_list, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("SLB Global Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     
     slb_total_dic = get_slb_total_sql(from_time, to_time)
@@ -1002,7 +1002,7 @@
 def generateLLBTotalReport(from_time, to_time, llb_total_list, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("LLB Total Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
 
     p = os.popen("/ca/bin/webui_utils -a 4")
@@ -1073,7 +1073,7 @@
 def generateLLBReport(from_time, to_time, llb_list, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("LLB Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     
     for each_link in llb_list:
@@ -1113,7 +1113,7 @@
 def generateGSLBReport(from_time, to_time, gslb_list, env, styles, story):
     story.append(Spacer(1, 12))
     ptext = '<font size="16">'+ unicode(_("GSLB Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
     
     time_list = []
@@ -1150,7 +1150,7 @@
     tcp_syn_drop_dic = tcp_syn_drop.get_sql(tcp_syn_drop.C_TYPE_TOTAL)
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("TCP Global Status")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
 
     for field in tcp_list:
@@ -1184,7 +1184,7 @@
     """
     story.append(Spacer(1, 12))
     ptext = '<font size="16">' + unicode(_("SSL Total Statistics")) + '</font>'
-    story.append(Paragraph(ptext, styles["alibaba"]))
+    story.append(Paragraph(ptext, styles[current_font]))
     story.append(Spacer(1, 12))
 
     ssl_status = SSLStatFacade(from_time)
@@ -1627,7 +1627,7 @@
 
 def myFirstPages(canvas, doc):
     canvas.saveState()
-    canvas.setFont('alibaba',10)
+    canvas.setFont(current_font,10)
     canvas.drawRightString(7.5 * inch, 0.75 * inch, unicode(_("Page %s")) % (doc.page))
     canvas.restoreState()
 
@@ -1638,7 +1638,7 @@
     w, h = p.wrap(doc.width, doc.bottomMargin)
     p.drawOn(canvas, doc.leftMargin, doc.topMargin + doc.height - 0.5*cm)
     #canvas.line(doc.leftMargin, doc.bottomMargin+doc.height + 0.5*cm, doc.leftMargin+doc.width, doc.bottomMargin+doc.height + 0.5*cm) 
-    canvas.setFont('alibaba',10)
+    canvas.setFont(current_font,10)
     canvas.drawRightString(7.5 * inch, 0.75 * inch, unicode(_("Page %s")) % (doc.page))
     canvas.restoreState()
 
@@ -1648,13 +1648,12 @@
                         rightMargin=60,leftMargin=60,
                         topMargin=70,bottomMargin=55)
     env = create_default_environment("png")
-    if current_lan == 'ja':
-        pdfmetrics.registerFont(TTFont('alibaba', font_file_path + 'AlibabaSansJP/AlibabaSansJP-Regular.ttf'))
-    else:
-        pdfmetrics.registerFont(TTFont('alibaba', 'Alibaba-PuHuiTi-Regular.ttf'))
+    pdfmetrics.registerFont(TTFont('alibaba', 'Alibaba-PuHuiTi-Regular.ttf'))
+    pdfmetrics.registerFont(TTFont('alibabajp', font_file_path + 'AlibabaSansJP/AlibabaSansJP-Regular.ttf'))
 
     styles=getSampleStyleSheet()
     styles.add(ParagraphStyle(fontName='alibaba', name='alibaba', alignment=TA_JUSTIFY))
+    styles.add(ParagraphStyle(fontName='alibabajp', name='alibabajp', alignment=TA_JUSTIFY))
     data = [[unicode(_("Create Time")), time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())], 
             [unicode(_("Statistics From")), start_time], 
             [unicode(_("Statistics To")), end_time], 
@@ -1704,8 +1703,9 @@
     to_time = post_dict['to']
     monitor_type = post_dict['monitor_type']
     report_type = post_dict['report_type']
-    global current_lan
-    current_lan = request.COOKIES['django_language']
+    global current_font
+    if request.COOKIES['django_language'] == "ja":
+        current_font = "alibabajp"
     system_list = []
     slb_rn_list = []    # slb rs name list
     slb_vn_list = []    # slb vs name list
Index: /branches/rel_apv_10_7/usr/click/webui/htdocs/new/src/locale/ja/LC_MESSAGES/django.po
===================================================================
--- /branches/rel_apv_10_7/usr/click/webui/htdocs/new/src/locale/ja/LC_MESSAGES/django.po	(revision 38695)
+++ /branches/rel_apv_10_7/usr/click/webui/htdocs/new/src/locale/ja/LC_MESSAGES/django.po	(working copy)
@@ -2109,7 +2109,7 @@
 #: apv/templates/sslo/sslo/wizard/wizard.html:818
 #: apv/templates/sslo/sslo/wizard/wizard.html:1768
 msgid "Back"
-msgstr "リターンマッチ"
+msgstr "キャンセル"
 
 #: apv/templates/sslo/sslo/wizard/wizard.html:821
 msgid "Select an Existing Sercurity Device"
