query about passing parameters using the "InplaceAdd" instruction #5703
Unanswered
patriciomh1965
asked this question in
Help
Replies: 3 comments 3 replies
-
check this issue #4122 (comment) this.form.SomeField.onInitNewEntity = entity => {
entity.SomeInfoField = "someValue";
} |
Beta Was this translation helpful? Give feedback.
0 replies
-
Hello Thanks To pass two or more parameters? |
Beta Was this translation helpful? Give feedback.
2 replies
-
Hi jin
I had done it that way, believe me I did. Sorry for the inconvenience.
Patrick
Example :
//this.form.PolNumero.onInitNewEntity = x => x.PolCia = this.form.PlnCia;
//this.form.PolNumero.onInitNewEntity = x => x.PolOrigen = this.form.PlnOrigen;
this.form.PprNumero.onInitNewEntity = entity => {
entity.SomeInfoField = this.form.TprNumero;
}
// this.form.PolNumero.onInitNewEntity = x => x.PolOrigen = this.form.PlnOrigen; x => x.PolCia = this.form.PlnCia;
// this.form.PprNumero.onInitNewEntity = x => x.PprTipoProducto = this.form.TprNumero;
// this.form.PprNumero.onInitNewEntity = x => x.PprTipoProducto = 163;
// TRASPASA PARAMETROS A LA NUEVA ENTIDAD (INPLACED)
this.form.PolNumero.onInitNewEntity = entity => {
entity.SomeInfoField = this.form.PlnCia,
entity.SomeInfoField = this.form.PlnOrigen;
}
//this.form.PolNumero.inplaceCreateClick(e => {
// var dlg = new ServiciosProducto.TaCncConfigPolizaNuevaDialog();
// this.initDialog(dlg);
// dlg.loadEntityAndOpenDialog(<ServiciosProducto.TaCncConfigPolizaNuevaRow>{
// PolOrigen: this.form.PlnOrigen,
// PolCia: this.form.PlnCia
// });
//});
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello Community
I must create a new record within a form using the "InplaceAdd" instruction, I must pass some parameters to it. Look in the "Issues" and I have not achieved the solution, below I attach an image and the instruction that I am using in XYZRow:
Next I show you the instruction in XYZRow ;
public sealed class TaCncPlanRow : Row, IIdRow, INameRow
......
......
//
[DisplayName("Origen"), Column("pln_origen"), ForeignKey("[dbo].[ta_cnc_param_origen]", "ori_numero"), LeftJoin("jOrigen"), TextualField("NombreOrigen"), DefaultValue(1)]
[LookupEditor(typeof(TaCncParamOrigenFiltroRow))]
public Int32? PlnOrigen
{
get { return Fields.PlnOrigen[this]; }
set { Fields.PlnOrigen[this] = value; }
}
//
[DisplayName("Origen"), Expression("jOrigen.[ori_descripcion]")]
public String NombreOrigen
{
get { return Fields.NombreOrigen[this]; }
set { Fields.NombreOrigen[this] = value; }
}
public sealed class TaCncConfigPolizaNuevaRow : Row, IIdRow, INameRow
......
.....
[DisplayName("Origen"), Column("pol_origen"), DefaultValue(0), LookupInclude]
[LookupEditor(typeof(TaCncParamOrigenRow))]
public Int32? PolOrigen
{
get { return Fields.PolOrigen[this]; }
set { Fields.PolOrigen[this] = value; }
}
[DisplayName("Compania"), Column("pol_compania"), DefaultValue(0), LookupInclude]
[LookupEditor(typeof(TaCncConfigCiaRow))]
public Int32? PolCia
{
get { return Fields.PolCia[this]; }
set { Fields.PolCia[this] = value; }
}
....
....
The parameters that I must pass are:
PlnOrigin and PlnCia
Already grateful for the help you can give me
Greetings.
Beta Was this translation helpful? Give feedback.
All reactions