Beispiel #1
0
        /// <summary>
        /// 初始化共享实例
        /// </summary>
        public void InitShare(TagHelperContext context)
        {
            var shareConfig = new TableShareConfig(GetId(context));

            InitShareConfig(context, shareConfig);
            context.SetValueToItems(shareConfig);
        }
Beispiel #2
0
        /// <summary>
        /// 初始化共享实例
        /// </summary>
        public void InitShare(TagHelperContext context)
        {
            var shareConfig = new GridShareConfig();

            InitShareConfig(context, shareConfig);
            context.SetValueToItems(typeof(GridShareConfig), shareConfig);
        }
Beispiel #3
0
        /// <summary>
        /// 初始化共享实例
        /// </summary>
        public void InitShare(TagHelperContext context)
        {
            var shareConfig = context.GetValueFromItems <TableShareConfig>();

            if (shareConfig == null)
            {
                shareConfig = new TableShareConfig(GetId(context));
                context.SetValueToItems(shareConfig);
            }
            InitShareConfig(context, shareConfig);
        }
Beispiel #4
0
 /// <summary>
 /// 初始化共享实例
 /// </summary>
 public void InitShare(TagHelperContext context)
 {
     context.SetValueToItems(TableConfig.TableShareKey, new TableShareConfig(GetId(context)));
 }
Beispiel #5
0
 /// <summary>
 /// 设置TagHelperContext Items值
 /// </summary>
 /// <param name="value">值</param>
 public void SetValueToItems <T>(T value)
 {
     TagHelperContext.SetValueToItems(value);
 }