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 _DataTableExample extends State<DataTableExample> { | |
List<Map> data; | |
bool sort; | |
int iSortColumnIndex; | |
@override | |
void initState() { | |
sort = true; // Note that in flutter ascending/descending icon are inversed | |
iSortColumnIndex = 1; | |
onCountSortColum(1, true); |
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 hashlib as hasher | |
import datetime as date | |
# Define what a Snakecoin block is | |
class Block: | |
def __init__(self, index, timestamp, data, previous_hash): | |
self.index = index | |
self.timestamp = timestamp | |
self.data = data | |
self.previous_hash = previous_hash |
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
jQuery.validator.addMethod("alphanumeric", function(value, element) { | |
return this.optional(element) || /^[A-Za-z0-9 _]*[A-Za-z0-9][A-Za-z0-9 _]*$/.test(value); | |
}); | |
jQuery.validator.addMethod("letterwithspaces", function(value, element) { | |
return this.optional(element) || /^[a-zA-Z\s]+$/.test(value); | |
}); | |
jQuery.validator.addMethod("imagetype", function(value, element) { | |
return this.optional(element) || /^.*\.(jpg|png|jpeg|gif)$/i.test(value); |