示例#1
0
        /// <inheritdoc/>
        public void PackColours(ICaller caller)
        {
            using IDealData data = InstanceFactory.GetInstance <IDealData>();

            if (data.AnyPackColour())
            {
                return;
            }

            IList <string> colours = new List <string>
            {
                "Red", "Blue"
            };

            foreach (string colour in colours)
            {
                IPackColour packColour = new PackColour(
                    id: Guid.NewGuid(),
                    code: colour.Substring(0, 1),
                    colour: colour);
                data.CreatePackColour(packColour);
            }
        }