From eaad168c9790233fc75ab92cb1f524148a0de958 Mon Sep 17 00:00:00 2001 From: sipp11 Date: Wed, 7 Sep 2016 17:15:32 +0700 Subject: [PATCH] Add make & model fields --- instrument.html | 8 ++++++++ js/stdb.js | 22 +++++++++++++++++++--- 2 files changed, 27 insertions(+), 3 deletions(-) diff --git a/instrument.html b/instrument.html index f9d18aa..191d2e3 100755 --- a/instrument.html +++ b/instrument.html @@ -133,6 +133,14 @@
สถานที่
+
+
ยี่ห้อ
+
+
+
+
รุ่น
+
+
วีดีโอ(youtube)
diff --git a/js/stdb.js b/js/stdb.js index 0910c39..c304472 100755 --- a/js/stdb.js +++ b/js/stdb.js @@ -270,9 +270,17 @@ function getData(respone) { +'
สถานที่
' +'
' +'
' + +'
' + +'
ยี่ห้อ
' + +'
' + +'
' + +'
' + +'
รุ่น
' + +'
' + +'
' +'
' +'
วีดีโอ(youtube)
' - +'
' + +'
' +'
' +'
' +'' @@ -467,7 +475,13 @@ function addData(){ data.location = document.getElementById("LcI").value } if(document.getElementById("YlI").value != ''){ - data.model = document.getElementById("YlI").value + data.video = document.getElementById("YlI").value + } + if(document.getElementById("makeI").value != ''){ + data.make = document.getElementById("makeI").value + } + if(document.getElementById("modelI").value != ''){ + data.model = document.getElementById("modelI").value } if(dataUri.length != 0){ data.clips = dataUri @@ -504,7 +518,9 @@ function updateData(idData){ 'caretaker':document.getElementById("cr"+idData).value, 'location':document.getElementById("lc"+idData).value, 'instrument_id':document.getElementById("id"+idData).value, - 'model':document.getElementById("yl"+idData).value, + 'make':document.getElementById("make"+idData).value, + 'model':document.getElementById("model"+idData).value, + 'video':document.getElementById("yl"+idData).value, } if(dataUri.length != 0){ dataUpdate.clips = dataUri