[fix] output:backend-typescript
This commit is contained in:
parent
c4c3e81067
commit
1d52365ece
|
|
@ -75,28 +75,32 @@ namespace _sindri.outputs.backend.typescript
|
|||
prog_output.render_program(
|
||||
new lib_plankton.prog.struct_program(
|
||||
[]
|
||||
/*
|
||||
// conf
|
||||
.concat(
|
||||
[
|
||||
new lib_plankton.prog.struct_statement_declaration(
|
||||
true,
|
||||
false,
|
||||
"conf",
|
||||
null,
|
||||
new lib_plankton.prog.struct_expression_dict(
|
||||
new lib_plankton.prog.struct_type_record(
|
||||
[
|
||||
{
|
||||
"key": "database_path",
|
||||
"value": new lib_plankton.prog.struct_expression_literal(database_path),
|
||||
"name": "database_path",
|
||||
"type": new lib_plankton.prog.struct_type_string(),
|
||||
"mandatory": true,
|
||||
},
|
||||
{
|
||||
"key": "server_port",
|
||||
"value": new lib_plankton.prog.struct_expression_literal(8888),
|
||||
"name": "server_port",
|
||||
"type": new lib_plankton.prog.struct_type_string(),
|
||||
"mandatory": true,
|
||||
},
|
||||
]
|
||||
)
|
||||
),
|
||||
null
|
||||
),
|
||||
]
|
||||
)
|
||||
*/
|
||||
// entities
|
||||
.concat(
|
||||
input_data["domains"]
|
||||
|
|
@ -243,7 +247,7 @@ namespace _sindri.outputs.backend.typescript
|
|||
"key": "key",
|
||||
"value": new lib_plankton.prog.struct_expression_projection(
|
||||
new lib_plankton.prog.struct_expression_variable("row"),
|
||||
new lib_plankton.prog.struct_expression_literal(0)
|
||||
new lib_plankton.prog.struct_expression_literal(domain.key_field.name)
|
||||
),
|
||||
},
|
||||
{
|
||||
|
|
@ -255,7 +259,7 @@ namespace _sindri.outputs.backend.typescript
|
|||
"key": field.name,
|
||||
"value": new lib_plankton.prog.struct_expression_projection(
|
||||
new lib_plankton.prog.struct_expression_variable("row"),
|
||||
new lib_plankton.prog.struct_expression_literal(index + 1)
|
||||
new lib_plankton.prog.struct_expression_literal(field.name)
|
||||
)
|
||||
})
|
||||
)
|
||||
|
|
@ -367,7 +371,7 @@ namespace _sindri.outputs.backend.typescript
|
|||
"key": field.name,
|
||||
"value": new lib_plankton.prog.struct_expression_projection(
|
||||
new lib_plankton.prog.struct_expression_variable("row"),
|
||||
new lib_plankton.prog.struct_expression_literal(index)
|
||||
new lib_plankton.prog.struct_expression_literal(field.name)
|
||||
)
|
||||
})
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue