Last active
May 18, 2016 20:45
-
-
Save dbarjs/f11fc11bd59558fc54ac2c2c1f67476d to your computer and use it in GitHub Desktop.
This file contains 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
/* | |
table structures | |
meta_rules | |
_id | |
app_id | |
contentType | |
file_rules | |
_id | |
app_id | |
contentType | |
*/ | |
var app = { | |
name: 'test', | |
rules: { | |
restricted: true, | |
meta: { | |
rules: [ | |
{ | |
name: 'name', | |
contentType: 'string' | |
}, | |
{ | |
name: 'age', | |
contentType: 'number' | |
} | |
] | |
}, | |
files: { | |
rules: [ | |
{} | |
] | |
} | |
} | |
}; | |
var appString = JSON.stringify(app); | |
// $app = json.decode($_POST['app']); | |
//return | |
var app = { | |
_id: 'J#$#$#465d', | |
name: 'test', | |
rules: { | |
restricted: true, | |
meta: [ | |
{ | |
name: 'name', | |
contentType: 'string' | |
}, | |
{ | |
name: 'age', | |
contentType: 'number' | |
} | |
], | |
files: [ | |
{ | |
name: 'photo', | |
contentType: 'image', | |
max: 5000, | |
min: 1000 | |
} | |
] | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment