More in this section

Forums / Developing with Sitefinity / New event item fields on page preview

New event item fields on page preview

11 posts, 0 answered
  1. Martin
    Martin avatar
    8 posts
    Registered:
    10 Mar 2009
    19 Mar 2009
    Link to this post
    I am facing the following issue.
    After i created and applied successfully two external templates(EventItemEdit and EventItemNew and respectively their resource files), i wanted to show the "new" fields i added to these files in page preview. I am currently using EventsView control and i tried already to edit some other external templates like "EventsViewControlDesigner.ascx" and "ContentViewSingleItemView.ascx" files but no positive results by far.
    Any suggestions ?
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    19 Mar 2009
    Link to this post
    Hello Martin,

    EventsItemEdit and EventsItemNew are responsible for the back end of Sitefinity - module section and they do not have anything to do with the front end and cmspagemode=preview. The other template - EventsViewControlDesigner loads the templates for the public part - Detail and Master mode. It is reponsible for the BlogPosts control properties.

    Could you elaborate a bit more about the difficulties  you have?

    Regards,
    Ivan Dimitrov
    the Telerik team


    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  3. Martin
    Martin avatar
    8 posts
    Registered:
    10 Mar 2009
    19 Mar 2009
    Link to this post
    I just need to add checkbox, textfield and another editor on the page which appears after i click "title" on particular "event" in preview page.
  4. Martin
    Martin avatar
    8 posts
    Registered:
    10 Mar 2009
    19 Mar 2009
    Link to this post
  5. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    23 Mar 2009
    Link to this post
    Hello Martin,

    I have just sent a reply to your support request with steps to accomplish required functionality. Let us know if you need further assistance in this matter.

    Kind regards,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer , the state of the art learning tool for Telerik products.
  6. Martin
    Martin avatar
    8 posts
    Registered:
    10 Mar 2009
    23 Mar 2009
    Link to this post
    Thank you for your reply, Ivan :).
    Now i am trying to add custom checkbock(its metafield value is used in the back end - events module) on the public site with the same value as in the back end.
    Here are the  metafield tag settings(in web.config) and the other needed tags:

    web.config:

    <
    add key="Events.CustomCheckBox" valueType="Boolean" visible="True" searchable="False" sortable="False" defaultValue=""/>
    ---------------------------------------------------------------------------------------------------
    ListPageDetail:

    <

     

    div id="ContactInfo" runat="server" class="sf_eventContact">

     

     

    <div>Name: <asp:Literal ID="Contact_Name" runat="server"></asp:Literal></div>

     

     

    <div>Email: <asp:Literal ID="Contact_Email" runat="server"></asp:Literal></div>

     

     

     ....

     

     

     

     

     

    <div>Custom checkbox: <asp:CheckBox ID="CustomCheckBox" runat="server"/> </div>

     

     

     

     

     

    </div> 
    ---------------------------------------------------------------------------------------------------
    EventsViewControlDesigner:

     

    <

     

    sfDesignSettings:TextSetting ID="TextSetting37"

     

     

    TargetID="CustomCheckBox"

     

     

    SettingTitle="Contact: Check if true"

     

     

    AllowLabelSetting="False"

     

     

    AllowFormatSetting="False"

     

     

    AllowVisibilitySetting="True"

     

     

    TargetVisibleByDefault="True">

     

     

    </sfDesignSettings:TextSetting>

     

    ---------------------

     

    The above code doesn't work.
    Should i do it with custom - user control?

  7. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    24 Mar 2009
    Link to this post
    Hello Martin,

    As I see form your code you are making changes under the place holder with ID="plhWho", which settings are managed by the control below on the EventsViewControlDesigner template:

    <sfDesignSettings:TextSetting ID="TextSetting11" 
            TargetID="plhWho"  
            SettingTitle="Contact person details"  
            AllowLabelSetting="True"  
            AllowFormatSetting="False" 
            AllowVisibilitySetting="True" 
            TargetVisibleByDefault="True"
     </sfDesignSettings:TextSetting> 

    You can expose your control outside of the holder or remove the place holder and create settings for each literal control separately. Just to let you know RadEditor supports "Format Code block" that is useful when you paste some code.

    Kind regards,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer , the state of the art learning tool for Telerik products.
  8. Martin
    Martin avatar
    8 posts
    Registered:
    10 Mar 2009
    24 Mar 2009
    Link to this post

    No, i removed this tag  ID="PlhWho". 
    Anyway, the idea has changed a bit. Now i need to show on the public content
    in "ListPageDetails" value of a checkbox(i am using it in EventsItemEdit.ascx and EventsItemNew.ascx)  which is taken from its metafield:

     

    <

     

    add key="Events.CustomCheckBox" valueType="Boolean" visible="True" searchable="False" sortable="False"/>
    and  is with boolean valueType. For that purpose
    i want to use a literal - custom control. It must have two possible text values :"yes" and "no". 
    Regards .

  9. Martin
    Martin avatar
    8 posts
    Registered:
    10 Mar 2009
    24 Mar 2009
    Link to this post
    In other words i want to get access to boolean "metafield" valueType through my custom control "CheckboxToLiteral.ascx".
  10. Martin
    Martin avatar
    8 posts
    Registered:
    10 Mar 2009
    25 Mar 2009
    Link to this post
    It is ok. I found a way to do it.
    Thank you guys ! Good luck ! :)
  11. Sebastian Menendez
    Sebastian Menendez avatar
    19 posts
    Registered:
    15 Oct 2004
    29 May 2009
    Link to this post
    Hey Martin,

    I'm trying to do something similar. Care to sahre the solution you found?

    Sebastian
Register for webinar
11 posts, 0 answered