Beispiel #1
0
 /// <summary>
 /// Clone
 /// </summary>
 /// <param name="articleView"></param>
 public GlobalView(GlobalView globalView)
 {
     this.id                        = globalView.id;
     this.shopName                  = globalView.shopName;
     this.slogan                    = globalView.slogan;
     this.phoneNumber               = globalView.phoneNumber;
     this.logoAbsoluteUrl           = globalView.logoAbsoluteUrl;
     this.address                   = globalView.address;
     this.page404                   = globalView.page404;
     this.page500                   = globalView.page500;;
     this.pageNoSearchResult        = globalView.pageNoSearchResult;
     this.footer                    = globalView.footer;
     this.googleCustSearchCode      = globalView.googleCustSearchCode;
     this.signupAgreement           = globalView.signupAgreement;
     this.version                   = globalView.version;
     this.siteType                  = globalView.siteType;
     this.unlockEmailTemplate       = globalView.unlockEmailTemplate;
     this.resetPasswordMailTemplate = globalView.resetPasswordMailTemplate;
 }
Beispiel #2
0
 /// <summary>
 /// ArticleView merge
 /// </summary>
 /// <param name="articleView"></param>
 public void Restore(GlobalView original)
 {
     this.id                        = original.id;
     this.shopName                  = original.shopName;
     this.slogan                    = original.slogan;
     this.phoneNumber               = original.phoneNumber;
     this.logoAbsoluteUrl           = original.logoAbsoluteUrl;
     this.address                   = original.address;
     this.page404                   = original.page404;
     this.page500                   = original.page500;
     this.pageNoSearchResult        = original.pageNoSearchResult;
     this.footer                    = original.footer;
     this.googleCustSearchCode      = original.googleCustSearchCode;
     this.signupAgreement           = original.signupAgreement;
     this.version                   = original.version;
     this.siteType                  = original.siteType;
     this.unlockEmailTemplate       = original.unlockEmailTemplate;
     this.resetPasswordMailTemplate = original.resetPasswordMailTemplate;
 }
Beispiel #3
0
 /// <summary>
 /// 'Cancel' button is clicked
 /// </summary>
 public void CancelEdit()
 {
     Restore(cache);
     cache = null;
 }
Beispiel #4
0
 /// <summary>
 /// 'Edit' button is clicked
 /// Due to binding, all UI changed will be mapped to the object, so we need make a copy of object before edit in case user wants to cancel the editing
 /// </summary>
 public void BeginEdit()
 {
     cache = new GlobalView(this);
 }
        /// <summary>
        /// global -> GlobalView in collection
        /// </summary>
        /// <param name="articleCollection"></param>
        /// <returns></returns>
        static public GlobalView Convert(myGlob global)
        {
            GlobalView globalView = new GlobalView(global);

            return(globalView);
        }