Skip to content

Commit 403b0f1

Browse files
committed
Merge branch 'new-dev-demo' of github.com:devforth/adminforth into new-dev-demo
2 parents 8f898df + 31ee04e commit 403b0f1

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

dev-demo/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ if (fileURLToPath(import.meta.url) === path.resolve(process.argv[1])) {
216216
for (let i = 0; i < 100; i++) {
217217
const engine_type = ENGINE_TYPES[Math.floor(Math.random() * ENGINE_TYPES.length)].value;
218218
await admin.resource('cars_mongo').create({
219-
id: `${i}`,
219+
_id: `${i}`,
220220
model: `${FICTIONAL_CAR_BRANDS[Math.floor(Math.random() * FICTIONAL_CAR_BRANDS.length)]} ${FICTIONAL_CAR_MODELS_BY_BRAND[FICTIONAL_CAR_BRANDS[Math.floor(Math.random() * FICTIONAL_CAR_BRANDS.length)]][Math.floor(Math.random() * 4)]}`,
221221
price: (Math.random() * 10000).toFixed(2),
222222
engine_type: engine_type,

dev-demo/resources/cars_mongo.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export default {
3434
*********************************************************************************/
3535
columns: [
3636
{
37-
name: 'id',
37+
name: '_id',
3838
type: AdminForthDataTypes.STRING,
3939
label: 'Identifier',
4040
showIn: {
@@ -58,7 +58,7 @@ export default {
5858
inputSuffix: 'USD',
5959
allowMinMaxQuery: true,
6060
editingNote: 'Price is in USD',
61-
type: AdminForthDataTypes.FLOAT,
61+
type: AdminForthDataTypes.DECIMAL,
6262
required: true,
6363
},
6464
{

0 commit comments

Comments
 (0)