示例#1
0
        public IPXTrigger Add(PXTriggerContext context)
        {
            context.PropertyChanged += Context_PropertyChanged;
            IPXTrigger newTrigger = GetTrigger(context);

            triggers.Add(newTrigger);
            return(newTrigger);
        }
示例#2
0
        //public IEnumerable<PXTriggerContext> Save()
        //{
        //    List<PXTriggerContext> contexts = List().ToList();
        //    return contexts;
        //}

        public IPXTrigger GetTrigger(PXTriggerContext context)
        {
            if (context.Key == "rss")
            {
                return(new RSS.RSS(context));
            }
            else if (context.Key == "test")
            {
                return(new TriggerTest(context));
            }
            return(null);
        }
示例#3
0
 public PXTriggerBase(PXTriggerContext context)
 {
     this.context      = context;
     this.localStorage = context.LocalStorage;
 }
示例#4
0
 public TriggerTest(PXTriggerContext context)
     : base(context)
 {
 }