This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const styles = theme => ({ | |
| selected: { | |
| boxShadow: `18px 0px 0 #6699FF inset`, | |
| backgroundColor: `rgba(102,153,255,0.2) !important` | |
| } | |
| }); | |
| render(){ | |
| return ( | |
| <div key={msg.id}> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const theme = createMuiTheme({ | |
| palette: { | |
| primary: { main: '#FAFAFA' }, | |
| secondary: lightBlue | |
| }, | |
| overrides: { | |
| MuiTooltip: { | |
| tooltip: { // Name of the component ⚛️ / style sheet | |
| fontSize: 12, // Some CSS | |
| }, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class ChangeGroupType < ActiveRecord::Migration[5.0] | |
| def up | |
| add_column :messages, :groups, :integer, array: true | |
| Message.find_each do |msg| | |
| msg.groups << msg.group | |
| msg.save! | |
| end | |
| remove_column :messages, :group, :integer | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no"> | |
| <title>FeatureLayer</title> | |
| <link rel="stylesheet" href="https://js.arcgis.com/3.18/esri/css/esri.css"> | |
| <script src="https://js.arcgis.com/3.18/"></script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import pyodbc | |
| import json | |
| SQLstatement = "SELECT * from %s %s" %(table, whereClause) | |
| rows = cursor.execute(SQLstatement, params).fetchall() | |
| columns = [column[0] for column in cursor.description] | |
| results = [] | |
| for row in rows: | |
| results.append(dict(zip(columns, row))) | |
| print json.dumps(results) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if ($education->name != $input->name){ | |
| $education->name = $input->name | |
| }elseif ($education->degree != $input->degree){ | |
| $education->degree = $input->degree | |
| } elseif ($education->completion_date != $input->completion_date){ | |
| $education->completion_date = $input->completion_date | |
| }; | |
| $education->save(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var bookmark = new Bookmarks({ | |
| map: map, | |
| bookmarks: [], | |
| editable: true | |
| }, dojo.byId('bookmarks2')); | |
| var measurement = new Measurement({ | |
| map: map | |
| }, dom.byId("measurementDiv")); | |
| measurement.startup(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div id="mapDiv" data-dojo-type="dijit/layout/ContentPane" data-dojo-props="region:'center'" style="margin:5px;"> | |
| <div id="bookmarks-pane" data-dojo-type="dijit.TitlePane" data-dojo-props="title:'Bookmarks'"> | |
| <div id="bookmarks2"></div> | |
| <button id="clear-storage">Remove Map Bookmarks</button> | |
| </div> | |
| <div style="position:absolute; right:20px; top:10px; z-Index:999;"> | |
| <div id="titlePane" data-dojo-type="dijit/TitlePane" data-dojo-props="title:'Measurement', closable:false, open:false"> | |
| <div id="measurementDiv"></div> | |
| <span style="font-size:smaller;padding:5px 5px;">Press <b>CTRL</b> to enable snapping.</span> | |
| </div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ionicPlatform.ready(function() { | |
| // Hide the accessory bar by default (remove this to show the accessory bar above the keyboard | |
| // for form inputs) | |
| if (window.cordova && window.cordova.plugins.Keyboard) { | |
| cordova.plugins.Keyboard.hideKeyboardAccessoryBar(true); | |
| cordova.plugins.Keyboard.disableScroll(true); | |
| } | |
| if (window.StatusBar) { | |
| // org.apache.cordova.statusbar required |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| editCredentials: function(uid, credItem, newData){ | |
| var ref = new Firebase('https://myapp.firebaseio.com/users/' + uid + '/credentials/'); | |
| var editCred = $firebaseObject(ref); | |
| editCred[credItem] = newData; | |
| editCred.$save(ref) | |
| .then(function(data){ | |
| console.log(data) | |
| }) | |
| .catch(function(error){ | |
| console.log(error) |
NewerOlder