Requires any of the roles: | bookingsupplier-administrator-write, superadmin |
PUT | /homepage/widget/settings | Update homepage widget settings | Update homepage widget settings on the company of the currently logged in user, only administrators are allowed to update homepage menu. |
---|
namespace BokaMera.API.ServiceModel.Dtos
open System
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations
[<AllowNullLiteral>]
type HomepageWidgetServiceLayoutsResponse() =
///<summary>
///The layout id.
///</summary>
[<ApiMember(Description="The layout id.")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The layout name.
///</summary>
[<ApiMember(Description="The layout name.")>]
member val Name:String = null with get,set
///<summary>
///The layout description.
///</summary>
[<ApiMember(Description="The layout description.")>]
member val Description:String = null with get,set
///<summary>
///The layout code.
///</summary>
[<ApiMember(Description="The layout code.")>]
member val Code:String = null with get,set
[<AllowNullLiteral>]
type HomepageWidgetTimeLayoutsResponse() =
///<summary>
///The layout id.
///</summary>
[<ApiMember(Description="The layout id.")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The layout name.
///</summary>
[<ApiMember(Description="The layout name.")>]
member val Name:String = null with get,set
///<summary>
///The layout description.
///</summary>
[<ApiMember(Description="The layout description.")>]
member val Description:String = null with get,set
///<summary>
///The layout code.
///</summary>
[<ApiMember(Description="The layout code.")>]
member val Code:String = null with get,set
[<AllowNullLiteral>]
type HomepageWidgetBookingLayoutsResponse() =
///<summary>
///The layout id.
///</summary>
[<ApiMember(Description="The layout id.")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The layout name.
///</summary>
[<ApiMember(Description="The layout name.")>]
member val Name:String = null with get,set
///<summary>
///The layout description.
///</summary>
[<ApiMember(Description="The layout description.")>]
member val Description:String = null with get,set
///<summary>
///The layout code.
///</summary>
[<ApiMember(Description="The layout code.")>]
member val Code:String = null with get,set
[<AllowNullLiteral>]
type HomepageWidgetBookingMethodsResponse() =
///<summary>
///The layout id.
///</summary>
[<ApiMember(Description="The layout id.")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The layout name.
///</summary>
[<ApiMember(Description="The layout name.")>]
member val Name:String = null with get,set
///<summary>
///The layout description.
///</summary>
[<ApiMember(Description="The layout description.")>]
member val Description:String = null with get,set
///<summary>
///The layout code.
///</summary>
[<ApiMember(Description="The layout code.")>]
member val Code:String = null with get,set
[<AllowNullLiteral>]
type HomepageWidgetSettingsQueryResponse() =
///<summary>
///The company id.
///</summary>
[<ApiMember(Description="The company id.")>]
member val CompanyId:Guid = new Guid() with get,set
///<summary>
///The service layouts id.
///</summary>
[<ApiMember(Description="The service layouts id.")>]
member val ServiceLayoutId:Int32 = new Int32() with get,set
///<summary>
///The time layouts id.
///</summary>
[<ApiMember(Description="The time layouts id.")>]
member val TimeLayoutId:Int32 = new Int32() with get,set
///<summary>
///The booking layouts id.
///</summary>
[<ApiMember(Description="The booking layouts id.")>]
member val BookingLayoutId:Int32 = new Int32() with get,set
///<summary>
///The primary color of the booking widget.
///</summary>
[<ApiMember(Description="The primary color of the booking widget.")>]
member val PrimaryColor:String = null with get,set
///<summary>
///If you should show the service image in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the service image in the booking widget.")>]
member val ShowServiceImage:Boolean = new Boolean() with get,set
///<summary>
///If you should show the rebate code field in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the rebate code field in the booking widget.")>]
member val ShowRebateCodeField:Boolean = new Boolean() with get,set
///<summary>
///If you should show the next available time in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the next available time in the booking widget.")>]
member val ShowNextAvailableTime:Boolean = new Boolean() with get,set
///<summary>
///If you should show the subscribe to newsletter checkbox in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the subscribe to newsletter checkbox in the booking widget.")>]
member val ShowSubscribeToNewsletter:Boolean = new Boolean() with get,set
///<summary>
///If you should show the create account option.
///</summary>
[<ApiMember(Description="If you should show the create account option.")>]
member val EnableCreateAccount:Boolean = new Boolean() with get,set
///<summary>
///If you should show the login to account option.
///</summary>
[<ApiMember(Description="If you should show the login to account option.")>]
member val EnableLogin:Boolean = new Boolean() with get,set
///<summary>
///If you should show the facebook login to account option.
///</summary>
[<ApiMember(Description="If you should show the facebook login to account option.")>]
member val EnableFacebookLogin:Boolean = new Boolean() with get,set
///<summary>
///If you should show the direct booking option. This enables customer to book with entering contact information.
///</summary>
[<ApiMember(Description="If you should show the direct booking option. This enables customer to book with entering contact information.")>]
member val EnableDirectBooking:Boolean = new Boolean() with get,set
///<summary>
///If the site should have dark theme or not.
///</summary>
[<ApiMember(Description="If the site should have dark theme or not.")>]
member val DarkTheme:Boolean = new Boolean() with get,set
///<summary>
///If you should show the end time in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the end time in the booking widget.")>]
member val ShowEndTime:Boolean = new Boolean() with get,set
///<summary>
///What text to show on booked time slots. Default text is Booked
///</summary>
[<ApiMember(Description="What text to show on booked time slots. Default text is Booked")>]
member val BookedTimeSlotText:String = null with get,set
member val ServiceLayoutOptions:ResizeArray<HomepageWidgetServiceLayoutsResponse> = new ResizeArray<HomepageWidgetServiceLayoutsResponse>() with get,set
member val TimeLayoutOptions:ResizeArray<HomepageWidgetTimeLayoutsResponse> = new ResizeArray<HomepageWidgetTimeLayoutsResponse>() with get,set
member val BookingLayoutOptions:ResizeArray<HomepageWidgetBookingLayoutsResponse> = new ResizeArray<HomepageWidgetBookingLayoutsResponse>() with get,set
member val BookingMethodOptions:ResizeArray<HomepageWidgetBookingMethodsResponse> = new ResizeArray<HomepageWidgetBookingMethodsResponse>() with get,set
[<ValidateRequest(Validator="IsAuthenticated")>]
[<AllowNullLiteral>]
type UpdateHomepageWidgetSettings() =
///<summary>
///The company id, if empty will use the company id for the user you are logged in with.
///</summary>
[<ApiMember(Description="The company id, if empty will use the company id for the user you are logged in with.")>]
member val CompanyId:Nullable<Guid> = new Nullable<Guid>() with get,set
///<summary>
///Serivce Layout.
///</summary>
[<ApiMember(Description="Serivce Layout.")>]
member val ServiceLayoutId:Nullable<Int32> = new Nullable<Int32>() with get,set
///<summary>
///Time Layout.
///</summary>
[<ApiMember(Description="Time Layout.")>]
member val TimeLayoutId:Nullable<Int32> = new Nullable<Int32>() with get,set
///<summary>
///Booking Layout.
///</summary>
[<ApiMember(Description="Booking Layout.")>]
member val BookingLayoutId:Nullable<Int32> = new Nullable<Int32>() with get,set
///<summary>
///The primary color of the booking widget.
///</summary>
[<ApiMember(Description="The primary color of the booking widget.")>]
member val PrimaryColor:String = null with get,set
///<summary>
///If the site should have dark theme or not.
///</summary>
[<ApiMember(Description="If the site should have dark theme or not.")>]
member val DarkTheme:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///If you should show the service image in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the service image in the booking widget.")>]
member val ShowServiceImage:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///If you should show the rebate code field in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the rebate code field in the booking widget.")>]
member val ShowRebateCodeField:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///If you should show the next available time in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the next available time in the booking widget.")>]
member val ShowNextAvailableTime:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///If you should show the end time in the booking widget.
///</summary>
[<ApiMember(Description="If you should show the end time in the booking widget.")>]
member val ShowEndTime:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///Show subscribe to newsletter checkbox on the page
///</summary>
[<ApiMember(Description="Show subscribe to newsletter checkbox on the page")>]
member val ShowSubscribeToNewsletter:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///What text to show on booked time slots. Default text is Booked
///</summary>
[<ApiMember(Description="What text to show on booked time slots. Default text is Booked")>]
member val BookedTimeSlotText:String = null with get,set
///<summary>
///If you should show the create account option.
///</summary>
[<ApiMember(Description="If you should show the create account option.")>]
member val EnableCreateAccount:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///If you should show the login to account option.
///</summary>
[<ApiMember(Description="If you should show the login to account option.")>]
member val EnableLogin:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///If you should show the facebook login to account option.
///</summary>
[<ApiMember(Description="If you should show the facebook login to account option.")>]
member val EnableFacebookLogin:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///If you should show the direct booking option. This enables customer to book with entering contact information.
///</summary>
[<ApiMember(Description="If you should show the direct booking option. This enables customer to book with entering contact information.")>]
member val EnableDirectBooking:Nullable<Boolean> = new Nullable<Boolean>() with get,set
F# UpdateHomepageWidgetSettings DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
PUT /homepage/widget/settings HTTP/1.1
Host: api.bokamera.se
Accept: application/json
Content-Type: application/json
Content-Length: length
{"CompanyId":"00000000-0000-0000-0000-000000000000","ServiceLayoutId":0,"TimeLayoutId":0,"BookingLayoutId":0,"PrimaryColor":"String","DarkTheme":false,"ShowServiceImage":false,"ShowRebateCodeField":false,"ShowNextAvailableTime":false,"ShowEndTime":false,"ShowSubscribeToNewsletter":false,"BookedTimeSlotText":"String","EnableCreateAccount":false,"EnableLogin":false,"EnableFacebookLogin":false,"EnableDirectBooking":false}
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"ServiceLayoutId":0,"TimeLayoutId":0,"BookingLayoutId":0,"PrimaryColor":"String","ShowServiceImage":false,"ShowRebateCodeField":false,"ShowNextAvailableTime":false,"ShowSubscribeToNewsletter":false,"EnableCreateAccount":false,"EnableLogin":false,"EnableFacebookLogin":false,"EnableDirectBooking":false,"DarkTheme":false,"ShowEndTime":false,"BookedTimeSlotText":"String","ServiceLayoutOptions":[{"Id":0,"Name":"String","Description":"String","Code":"String"}],"TimeLayoutOptions":[{"Id":0,"Name":"String","Description":"String","Code":"String"}],"BookingLayoutOptions":[{"Id":0,"Name":"String","Description":"String","Code":"String"}],"BookingMethodOptions":[{"Id":0,"Name":"String","Description":"String","Code":"String"}]}