Giter VIP home page Giter VIP logo

equipment-decision-support's Introduction

ODDS|

  • 👋 Hi, I’m @apirak
  • 👀 I’m interested in User Experience
  • 🌱 I’m currently learning about System Thinking
  • 💞️ I’m looking to collaborate on Design & Code
  • 📫 Reach me at fb.com/apirak

equipment-decision-support's People

Contributors

apirak avatar

Stargazers

 avatar

Watchers

 avatar  avatar

equipment-decision-support's Issues

ใส่ traffic และสร้าง info windows

การใส่ traffic ไม่ยากมาก ที่ตอนแรกทำไม่ได้เพราะดันไปดู API v2
ใน gmap ของ EXTJS ดันหลอกว่าเอามาจาก google map v 2.x ทำให้ไปดู api ของ version 2 เลยลองอะไรไม่ผ่านซักที

ขั้นตอนต่อไปสำหรับ marker คือ ทำให้ช่อง info windows มันเล็กลงมา เพราะถ้าใหญ่มากจะไม่มีประโยชน์
ดูตัวอย่างได้จาก

http://gmaps-samples-v3.googlecode.com/svn/trunk/infowindow_custom/infowindow-custom.html

Add traffic to map

พยายามใส่ traffic ลงในแผนที่แต่ไม่สำเร็จ ได้ตัวอย่างมาจาก

http://gmaps-utility-library.googlecode.com/svn/trunk/extmaptypecontrol/release/examples/trafficexample.html

พยายาม

function load() {
  if (GBrowserIsCompatible()) {
    var map = new GMap2(document.getElementById("map"));
    map.setCenter(new GLatLng(37.441944, -122.141944), 10);
    map.addControl(new ExtMapTypeControl({showTraffic: true, showTrafficKey: true}));
    map.addControl(new GSmallMapControl());
    map.setMapType(G_SATELLITE_MAP);
  }
}

แต่ไม่ได้ตั้งแต่ var map = new GMap2(document.getElementById("map"));

ทดลองทำตามนี้

map = Ext.getCmp('station_map').getMap();
map.addControl(new ExtMapTypeControl({showTraffic: true, showTrafficKey: true}));
//map.addOverlay(new GTrafficOverlay());

โดยดูจาก http://googlemapsapi.blogspot.com/2007/06/add-traffic-to-your-mashup-button.html

แต่ไม่สำเร็จเลยล้มเลิกการใส่ traffic ไปก่อน

ทำ Drag & Drop ให้กับแต่ละ Station

พบวิธีง่ายๆ คือ

this.setDraggable(true);

วางแผนว่าจะทำปุ่ม edit ไว้ตอนที่ช่อง information แล้วให้มัน drag ได้
นอกจากนั้นอาจจะต้องทำ startMove กำหนด height ใหักับ icon ด้วย
เพื่อให้มันมียกขึ้นกระกระเด้งตอนปล่อง แบบ google map

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.