|
@@ -88,6 +88,24 @@ namespace InABox.Core
|
|
|
return this;
|
|
|
}
|
|
|
|
|
|
+ public AutoEntityUnionTable<TInterface, TEntity> AliasField<TType>(Expression<Func<TInterface, object?>> target, IComplexFormulaNode<TEntity, TType> source)
|
|
|
+ {
|
|
|
+ var _tgt = new Column<TInterface>(target);
|
|
|
+ var _src = new ComplexColumn<TEntity, TType>(_tgt.Property, source);
|
|
|
+
|
|
|
+ _mappings.Add(new AutoEntityUnionMapping(_src, _tgt));
|
|
|
+ return this;
|
|
|
+ }
|
|
|
+
|
|
|
+ public AutoEntityUnionTable<TInterface, TEntity> AliasField(Column<TInterface> target, Column<TEntity> source)
|
|
|
+ {
|
|
|
+ var _node = new ComplexFormulaFieldNode<TEntity, object?>(source.Property);
|
|
|
+ var _src = new ComplexColumn<TEntity, object?>(target.Property, _node);
|
|
|
+
|
|
|
+ _mappings.Add(new AutoEntityUnionMapping(_src, target));
|
|
|
+ return this;
|
|
|
+ }
|
|
|
+
|
|
|
public AutoEntityUnionTable<TInterface, TEntity> AliasField(Expression<Func<TInterface, object?>> target, string formatString, params Expression<Func<TEntity, object?>>[] fields)
|
|
|
{
|
|
|
var _tgt = new Column<TInterface>(target);
|