Difference between revisions of "Template:HSNU-TAIPEI/members js"

 
(35 intermediate revisions by 2 users not shown)
Line 22: Line 22:
 
for(var i = 0; i < length; i++) {
 
for(var i = 0; i < length; i++) {
 
                 var check = true;
 
                 var check = true;
if(personName[i] !== ' ' || personName[i] !== '-') {
+
if(personName[i] == ' ' || personName[i] == '-') {
 
                         check = false;
 
                         check = false;
 
}
 
}
Line 32: Line 32:
 
};
 
};
  
var generatePersonImg = function(personName) {
+
var generatePersonImg = function(personName, personSrc) {
 
var justifiedName = justifyPersonName(personName);
 
var justifiedName = justifyPersonName(personName);
        console.log(justifiedName);
+
var source = "https://static.igem.org/mediawiki/2015/" + personSrc + "/HSNU-TAIPEI_" + justifiedName + ".jpg";
var source = "https://static.igem.org/mediawiki/2015/f/f7/HSNU-TAIPEI_" + justifiedName + ".jpg";
+
 
return '<img src="' + source + '">';
 
return '<img src="' + source + '">';
 
};
 
};
  
var generatePersonFigure = function(personName, personRole) {
+
var generatePersonFigure = function(personName) {
 
var figure = "<figure>";
 
var figure = "<figure>";
 
figure += generatePersonName(personName);
 
figure += generatePersonName(personName);
figure += generatePersonRole(personRole);
 
 
figure += "</figure>";
 
figure += "</figure>";
 
return figure;
 
return figure;
Line 49: Line 47:
 
var generateProfile = function(person) {
 
var generateProfile = function(person) {
 
var personName = person["Name"],
 
var personName = person["Name"],
personRole = person["Role"];
+
                personSrc = person["Source"];
 
var profile = document.createElement('div');
 
var profile = document.createElement('div');
var content = generatePersonImg(personName);
+
var content = generatePersonImg(personName, personSrc);
content += generatePersonFigure(personName, personRole);
+
        content += generatePersonFigure(personName)
 
profile.setAttribute('class', 'profile');
 
profile.setAttribute('class', 'profile');
 
profile.innerHTML = content;
 
profile.innerHTML = content;
Line 86: Line 84:
 
sectionName: "Teacher",
 
sectionName: "Teacher",
 
persons: [
 
persons: [
{ Name:"Su Shu-Ching", Role:"Teacher" },
+
{ Name:"Su Shu-Ching", Source: "8/88" },
{ Name:"Wu Tzu-Yun", Role:"Teacher" }
+
{ Name:"Wu Tzu-Yun", Source: "9/9f" },
 +
{ Name: "Chen Jhih-Sheng", Source: "b/b4" },
 +
{ Name: "Chiang Ching-Chao", Source: "8/80" },
 +
{ Name: "Hsieh Hui-Lin", Source: "3/3b" },
 +
{ Name: "Hsieh Jui-Lin", Source: "0/0a" },
 +
{ Name: "Huang Tzung-Hsien", Source: "5/58" },
 +
{ Name: "Lai Hsiang-Ju", Source: "6/69" },
 +
{ Name: "Lin Chun-Wei", Source: "6/64" },
 +
{ Name: "Lin Yi-Hsiung", Source: "a/a2" },
 +
{ Name: "Pan Guan-Chi", Source: "a/a9" },
 +
{ Name: "Wang Shih-Haur", Source: "9/95" },
 +
{ Name: "Chen Chao-Chin", Source: "2/21" },
 +
{ Name: "Yeh Hua-Yu", Source: "3/35" },
 +
{ Name: "Pan Su-Chen", Source: "0/0b" },
 
]
 
]
 
};
 
};
Line 94: Line 105:
 
sectionName: "Experiment",
 
sectionName: "Experiment",
 
persons: [
 
persons: [
{ Name:"Chang Ko-Yu", Role:"Student" },
+
                { Name: "Chang Ko-Yu", Source: "b/bc" },
{ Name:"Lin Sheng", Role:"Student" },
+
                { Name: "Chu Yi-Chia", Source: "5/5b" },
{ Name:"Shen Yu-Chun", Role:"Student" },
+
                { Name: "Lin Sheng", Source: "0/09" },
{ Name:"Chu Yi-Chia", Role:"Student" },
+
                { Name: "Shen Yu-Chun", Source: "9/9d" },
{ Name:"Zhao Ming-Cheng", Role:"Student" }
+
                { Name: "Zhao Ming-Cheng", Source: "f/fa" },
 +
                {Name:"Lee Wen-Ti",Source:"2/24"},
 +
    { Name: "Chang Yu-Ting", Source: "8/86" },
 +
    { Name: "Chen Sheng-Yuan", Source: "a/a1" },
 +
    { Name: "Chi Ying-Cheng", Source: "1/12" },
 +
    { Name: "Hsu Chia-Yang", Source: "8/84" },
 +
    { Name: "Lee Chang-Lung", Source: "4/47" },
 +
        { Name: "Leng Yi-Yan", Source: "4/4a" },
 +
    { Name: "Chu Wei-Min", Source: "c/ca" },
 +
    { Name: "Su Chin-Fong", Source: "a/a3" },
 +
    { Name: "Lee Min-Chou", Source: "b/b6" },
 +
    { Name: "Han Yun-An", Source: "e/e9" },
 +
    { Name: "Chang I", Source: "a/a6" },
 
]
 
]
 
};
 
};
Line 105: Line 128:
 
sectionName: "Human Practice",
 
sectionName: "Human Practice",
 
persons: [
 
persons: [
 +
                {Name:"Chang Chun-Chieh",Source:"0/08"},
 +
                {Name:"Tsai Min-Hao",Source:"7/74"},
 +
                {Name:"Wang Tz-Tung",Source:"5/56"},
 +
                {Name:"Liu Pin-Lan",Source:"3/39"},
 +
                {Name:"Lai Ching-Lan",Source:"4/46"},
 +
                {Name:"Hsieh Wan-Hsuan",Source:"0/0f"},
 +
                {Name:"Wang Ying-Chyi",Source:"b/bd"},
 +
                {Name:"Wu Chia-Yang",Source:"4/42"},
 +
                {Name:"Lee Ming-Jhen",Source:"0/06"},
 +
                { Name: "Shen Yu-Kai",  Source: "b/b8" },
 +
                { Name: "Huang Chi-Hung", Source: "2/27" },
 +
                { Name: "Lee Po-Yen", Source: "a/a3" },
 +
  { Name: "Chang Chin-Yuan", Source: "0/0d" },
 +
    { Name: "Chou Nai-Ching", Source: "8/88" },
 +
    { Name: "Ou Hsu-Feng", Source: "d/da" },
 +
    { Name: "Wu Sheng-Yuan", Source: "5/50" },
 +
    { Name: "Lu Yi-Wen", Source: "8/8c" },
 +
{ Name: "Chang Jen-Han", Source: "c/c7" },
 +
    { Name: "Cheng Hao-Sheng", Source: "f/fd" },
 +
    { Name: "Hong Jun-Cheng", Source: "e/e2" },
 +
    { Name: "Lee Ching-Yen", Source: "9/94" },
 +
    { Name: "Wu Hsiu", Source: "3/38" },
 
]
 
]
 
};
 
};
Line 117: Line 162:
 
sectionName: "Wiki",
 
sectionName: "Wiki",
 
persons: [
 
persons: [
{ Name:"Hung Chi-Heng", Role:"Student" },
+
{ Name:"Yu Hsiu-Ting", Role:"Student", Source:"c/c6" },
{ Name:"Wang Yen-Jen", Role:"Student" },
+
{ Name:"Shi Cheng-Yu", Role:"Student", Source:"d/d1" },
{ Name:"Shi Cheng-Yu", Role:"Student" },
+
{ Name:"Hung Chi-Heng", Role:"Student", Source:"f/f7" }
{ Name:"Yu Hsiu-Ting", Role:"Student" }
+
 
]
 
]
 
};
 
};
Line 128: Line 172:
 
addSection(section_teacher);
 
addSection(section_teacher);
 
addSection(section_experiment);
 
addSection(section_experiment);
 +
addSection(section_human_practice);
 
addSection(section_wiki);
 
addSection(section_wiki);
  

Latest revision as of 02:11, 19 September 2015