浏览代码

[kitagata_support:08691] HP更新依頼 町の人口

kuni 5 年前
父节点
当前提交
4d3decb2be
共有 3 个文件被更改,包括 95 次插入94 次删除
  1. 24
    23
      index.html
  2. 64
    64
      js/piechart.js
  3. 7
    7
      third/introduction_of_northern_town/Population_of_the_town.html

+ 24
- 23
index.html 查看文件

@@ -2687,6 +2687,30 @@
2687 2687
                         <a class="i_link" href="third/introduction_of_northern_town/Population_of_the_town.html">町の人口</a>
2688 2688
                       </span>
2689 2689
                       <!--現在の人口開始=============================================================================================================================================================-->
2690
+                      <table width="180" border="1px" bordercolor="#CCCCCC" cellpadding="0" cellspacing="0" id="infokitagata"
2691
+                        style="font-size:10px; border-collapse:collapse; margin-top:0; padding-top:0">
2692
+                        <caption style="text-align:right; line-height:5px; padding-bottom:4px;">
2693
+                          平成31年2月1日現在
2694
+                        </caption>
2695
+                        <tr align="center">
2696
+                          <th width="45%" bgcolor="#ADD8E6">人口(人)</th>
2697
+                          <td width="55%" style="text-align:right" bgcolor="#FFFFFF">18,465[+22]</td>
2698
+                        </tr>
2699
+                        <tr>
2700
+                          <th bgcolor="#ADD8E6">世帯数(戸)</th>
2701
+                          <td style="text-align:right" bgcolor="#FFFFFF">7,490[+18]</td>
2702
+                        </tr>
2703
+                        <tr>
2704
+                          <th bgcolor="#ADD8E6">男(人)</th>
2705
+                          <td style="text-align:right" bgcolor="#FFFFFF">8,857</td>
2706
+                        </tr>
2707
+                        <tr>
2708
+                          <th bgcolor="#ADD8E6">女(人)</th>
2709
+                          <td style="text-align:right" bgcolor="#FFFFFF">9,608</td>
2710
+                        </tr>
2711
+                      </table>
2712
+                      <!--前月の人口=============================================================================================================================================================-->
2713
+                      <!--
2690 2714
                       <table width="180" border="1px" bordercolor="#CCCCCC" cellpadding="0" cellspacing="0" id="infokitagata"
2691 2715
                         style="font-size:10px; border-collapse:collapse; margin-top:0; padding-top:0">
2692 2716
                         <caption style="text-align:right; line-height:5px; padding-bottom:4px;">
@@ -2709,29 +2733,6 @@
2709 2733
                           <td style="text-align:right" bgcolor="#FFFFFF">9,578</td>
2710 2734
                         </tr>
2711 2735
                       </table>
2712
-                      <!--前月の人口=============================================================================================================================================================-->
2713
-                      <!--
2714
-                <table width="180" border="1px" bordercolor="#CCCCCC" cellpadding="0" cellspacing="0" id="infokitagata" style="font-size:10px; border-collapse:collapse; margin-top:0; padding-top:0">
2715
-                  <caption style="text-align:right; line-height:5px; padding-bottom:4px;">
2716
-                                                    平成30年6月1日現在
2717
-                      </caption>
2718
-                      <tr align="center">
2719
-                        <th width="45%" bgcolor="#ADD8E6">人口(人)</th>
2720
-                        <td width="55%" style="text-align:right" bgcolor="#FFFFFF">18,458[±0]</td>
2721
-                      </tr>
2722
-                      <tr>
2723
-                        <th bgcolor="#ADD8E6">世帯数(戸)</th>
2724
-                        <td style="text-align:right" bgcolor="#FFFFFF">7,454[+13]</td>
2725
-                      </tr>
2726
-                      <tr>
2727
-                        <th bgcolor="#ADD8E6">男(人)</th>
2728
-                        <td style="text-align:right" bgcolor="#FFFFFF">8,862</td>
2729
-                      </tr>
2730
-                      <tr>
2731
-                        <th bgcolor="#ADD8E6">女(人)</th>
2732
-                        <td style="text-align:right" bgcolor="#FFFFFF">9,596</td>
2733
-                      </tr>
2734
-                </table>
2735 2736
             -->
2736 2737
 
2737 2738
                       <!--セクション facebook-->

+ 64
- 64
js/piechart.js 查看文件

@@ -1,76 +1,76 @@
1 1
 //円グラフのデータ
2
-var PopMan = 8862;
3
-var PopWoman = 9596;
4
-var data = [
5
-	{
6
- 		value : PopMan,
7
-		color : "#01a9de"
8
-	},
9
-	{
10
-		value : PopWoman,
11
-		color : "#eb5f60"
12
-	}
2
+var PopMan = 8857;
3
+var PopWoman = 9608;
4
+var data = [{
5
+    value: PopMan,
6
+    color: "#01a9de"
7
+  },
8
+  {
9
+    value: PopWoman,
10
+    color: "#eb5f60"
11
+  }
13 12
 ];
14 13
 var options = {
15
-	//Boolean - Whether we should animate the chart	
16
-	animation : true,
17
-	
18
-	//Number - Amount of animation steps
19
-	animationSteps : 100,
20
-	
21
-	//String - Animation easing effect
22
-	//animationEasing : "easeOutBounce",
23
-	
24
-	//Boolean - Whether we animate the rotation of the Pie
25
-	//animateRotate : true,
26
-	
27
-	//Boolean - Whether we animate scaling the Pie from the centre
28
-	animateScale : false,
29
-	
30
-	//Function - Will fire on animation completion.
31
-	onAnimationComplete : function(){
32
-		var Man = new Image();
33
-		var Woman = new Image();
34
-		Man.src = "css/img/Man.png?" + new Date().getTime();
35
-		Woman.src = "css/img/Woman.png?" + new Date().getTime();
36
-		Man.onload = function() {
37
-			ctx.drawImage(Man, 151, 70, 20, 50);
38
-		}
39
-		Woman.onload = function() {
40
-			ctx.drawImage(Woman, 9, 70, 20, 50);
41
-		}
42
-		var Pop = parseInt(PopMan) + parseInt(PopWoman);
43
-		var PerPopMan = Math.round(parseInt(PopMan) / parseInt(Pop) * 100);
44
-		var PerPopWoman = Math.round(parseInt(PopWoman) / parseInt(Pop) * 100);
45
-		
46
-		var PopMan_text = document.getElementById("PopMan_text");
47
-		var PopWoman_text = document.getElementById("PopWoman_text");
48
-		var PerPopMan_text = document.getElementById("PerPopMan_text");
49
-		var PerPopWoman_text = document.getElementById("PerPopWoman_text");
50
-		
51
-		PerPopMan_text.innerHTML = PerPopMan + "%";
52
-		PerPopWoman_text.innerHTML = PerPopWoman + "%";
53
-		
54
-		PopMan_text.style.display = "block";
55
-		PopWoman_text.style.display = "block";
56
-		PerPopMan_text.style.display = "block";
57
-		PerPopWoman_text.style.display = "block";
58
-		
59
-	}
14
+  //Boolean - Whether we should animate the chart	
15
+  animation: true,
16
+
17
+  //Number - Amount of animation steps
18
+  animationSteps: 100,
19
+
20
+  //String - Animation easing effect
21
+  //animationEasing : "easeOutBounce",
22
+
23
+  //Boolean - Whether we animate the rotation of the Pie
24
+  //animateRotate : true,
25
+
26
+  //Boolean - Whether we animate scaling the Pie from the centre
27
+  animateScale: false,
28
+
29
+  //Function - Will fire on animation completion.
30
+  onAnimationComplete: function () {
31
+    var Man = new Image();
32
+    var Woman = new Image();
33
+    Man.src = "css/img/Man.png?" + new Date().getTime();
34
+    Woman.src = "css/img/Woman.png?" + new Date().getTime();
35
+    Man.onload = function () {
36
+      ctx.drawImage(Man, 151, 70, 20, 50);
37
+    }
38
+    Woman.onload = function () {
39
+      ctx.drawImage(Woman, 9, 70, 20, 50);
40
+    }
41
+    var Pop = parseInt(PopMan) + parseInt(PopWoman);
42
+    var PerPopMan = Math.round(parseInt(PopMan) / parseInt(Pop) * 100);
43
+    var PerPopWoman = Math.round(parseInt(PopWoman) / parseInt(Pop) * 100);
44
+
45
+    var PopMan_text = document.getElementById("PopMan_text");
46
+    var PopWoman_text = document.getElementById("PopWoman_text");
47
+    var PerPopMan_text = document.getElementById("PerPopMan_text");
48
+    var PerPopWoman_text = document.getElementById("PerPopWoman_text");
49
+
50
+    PerPopMan_text.innerHTML = PerPopMan + "%";
51
+    PerPopWoman_text.innerHTML = PerPopWoman + "%";
52
+
53
+    PopMan_text.style.display = "block";
54
+    PopWoman_text.style.display = "block";
55
+    PerPopMan_text.style.display = "block";
56
+    PerPopWoman_text.style.display = "block";
57
+
58
+  }
60 59
 
61 60
 };
62 61
 var ctx = null;
63 62
 var NewChart = null;
64
-function piechart1(){
65
-	ctx = $("#Maletofemaleratio").get(0).getContext("2d"),//Canvasのコンテキスト取得
66
-	NewChart = new Chart(ctx);//チャートを生成
67 63
 
68
-	NewChart.Pie(data,options);
64
+function piechart1() {
65
+  ctx = $("#Maletofemaleratio").get(0).getContext("2d"), //Canvasのコンテキスト取得
66
+    NewChart = new Chart(ctx); //チャートを生成
67
+
68
+  NewChart.Pie(data, options);
69 69
 }
70 70
 
71 71
 /* オンロード時に動作 */
72
-if(window.addEventListener) {
73
-	window.addEventListener('load', piechart1, false);
72
+if (window.addEventListener) {
73
+  window.addEventListener('load', piechart1, false);
74 74
 } else {
75
-	window.attachEvent("onload", piechart1);
76
-}
75
+  window.attachEvent("onload", piechart1);
76
+}

+ 7
- 7
third/introduction_of_northern_town/Population_of_the_town.html 查看文件

@@ -148,7 +148,7 @@
148 148
             </div>
149 149
           </div>
150 150
           <span id="template_article_block">
151
-            <p class="paragraphT5">平成30年10月1日時点での人口・世帯数</p>
151
+            <p class="paragraphT5">平成31年2月1日時点での人口・世帯数</p>
152 152
             <table border="0" cellpadding="2" cellspacing="2" width="280px" id="town">
153 153
               <tr>
154 154
                 <th width="100px"></th>
@@ -157,26 +157,26 @@
157 157
               </tr>
158 158
               <tr>
159 159
                 <th width="100px" bgcolor="#add8e6">人口(人)</th>
160
-                <td width="100px" bgcolor="#dcdcdc" align="right">18,410</td>
161
-                <td bgcolor="#dcdcdc" align="right">(-49)</td>
160
+                <td width="100px" bgcolor="#dcdcdc" align="right">18,465</td>
161
+                <td bgcolor="#dcdcdc" align="right">(+22)</td>
162 162
               </tr>
163 163
 
164 164
               <tr>
165 165
                 <th width="100px" bgcolor="#add8e6">男(人)</th>
166
-                <td width="100px" bgcolor="#dcdcdc" align="right">8,832</td>
166
+                <td width="100px" bgcolor="#dcdcdc" align="right">8,857</td>
167 167
                 <td bgcolor="#dcdcdc" align="right"></td>
168 168
               </tr>
169 169
 
170 170
               <tr>
171 171
                 <th width="100px" bgcolor="#add8e6">女(人)</th>
172
-                <td width="100px" bgcolor="#dcdcdc" align="right">9,578</td>
172
+                <td width="100px" bgcolor="#dcdcdc" align="right">9,608</td>
173 173
                 <td bgcolor="#dcdcdc" align="right"></td>
174 174
               </tr>
175 175
 
176 176
               <tr>
177 177
                 <th width="100px" bgcolor="#add8e6">世帯数</th>
178
-                <td width="100px" bgcolor="#dcdcdc" align="right">7,449</td>
179
-                <td bgcolor="#dcdcdc" align="right">(-18)</td>
178
+                <td width="100px" bgcolor="#dcdcdc" align="right">7,490</td>
179
+                <td bgcolor="#dcdcdc" align="right">(+18)</td>
180 180
               </tr>
181 181
 
182 182
 

正在加载...
取消
保存