防止同一日期重复预订

防止同一日期重复预订

本文介绍了防止同一日期重复预订的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好

我正在开发一个Web表单,用户可以在其中预订房间,并且我想防止同一天再次进行预订.如何防止别人预订已经预订的房间.

例如,我正在预订5月10日至12日的房间,然后我希望任何用户都不能预订5月12日至5月12日的房间,或者直到12日为止的任何日期,因为它已经预订了10至12日. >并且我必须在其中输入开始日期和结束日期的文本框中,我想在此处进行检查.

请以JavaScript,SQL或C#编码提供逻辑或代码.

谢谢

Hello

I am developing a web form in which users can book rooms and I want to prevent another booking taking place on the same date. How would I prevent someone else from booking a room that has already been booked.

as a example i am booking a room for 10 may to 12 may then i want that any user can not book that room for 10 may to 12 may or any date upto 12 may becouse it is already booked for 10 to 12.
and i have to text boxes in which start date and and end date are being entered i want to put a check here.

Please provide logic or code in JavaScript, SQL or C# coding.

Thanks

推荐答案



这篇关于防止同一日期重复预订的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-11 14:11