# Double or tripple bids - how to restrict?

**URL:** <https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279>\
**Category:** phpVMS Legacy Support (v2/v5)\
**Created:** [August 22, 2010, 5:04pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279 "2010-08-22T17:04:32Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![CEO\_North\_Air](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/c/f07891/32.png) [@CEO\_North\_Air](https://forum.phpvms.net/u/CEO_North_Air)\
**Post date:** [August 22, 2010, 5:04pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/1 "2010-08-22T17:04:32Z")

</div>

Good eve,

long time ago since I needed your help. Short question, and IÂ´m sure youÂ´wll have the solution. Well how restrict double or tripple bids? I mean one pilot made his bid for flight NXA1, now no one else will have the chance to bid as well.

Hopefully can help as soon as possible.

Best regards from rainy northern Germany

Tobias

---

<div class="post-metadata">

**Author:** ![CEO\_North\_Air](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/c/f07891/32.png) [@CEO\_North\_Air](https://forum.phpvms.net/u/CEO_North_Air)\
**Post date:** [August 22, 2010, 5:07pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/2 "2010-08-22T17:07:41Z")

</div>

We added following code to the localconfig.php

# If someone places a bid, whether to disable that or not

Config::Set(‘DISABLE\_SCHED\_ON\_BID’, true);

Config::Set(‘DISABLE\_BIDS\_ON\_BID’, true);

But nothing works.

Thanks a lot for you help!

---

<div class="post-metadata">

**Author:** ![BastiDE](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/b/5daacb/32.png) [@BastiDE](https://forum.phpvms.net/u/BastiDE)\
**Post date:** [August 22, 2010, 5:28pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/3 "2010-08-22T17:28:05Z")

</div>

we use Real Schedule Lite. And how we can make this:

Pilot A have rank 1, but he can add a bid with an aircraft for rank 3. How we can disable this?

---

<div class="post-metadata">

**Author:** ![mark1million](https://forum.phpvms.net/user_avatar/forum.phpvms.net/mark1million/32/15_2.png) [@mark1million](https://forum.phpvms.net/u/mark1million)\
**Post date:** [August 22, 2010, 6:26pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/4 "2010-08-22T18:26:10Z")

</div>

> we use Real Schedule Lite. And how we can make this:
> 
> Pilot A have rank 1, but he can add a bid with an aircraft for rank 3. How we can disable this?

I believe you can restrict what a pilot can see on the schedules also preventing him from bidding on flights that he does not have the rank to fly.

In the admin section edit the aircrafts, in there you will see minimum rank to fly.

In the schedules results tpl (i think) there is an option to uncomment out the code to restrict the display to the aircraft the pilot is ranked to fly.

Hope you get what i mean.

---

<div class="post-metadata">

**Author:** ![TAV1702](https://forum.phpvms.net/user_avatar/forum.phpvms.net/tav1702/32/41_2.png) [@TAV1702](https://forum.phpvms.net/u/TAV1702)\
**Post date:** [August 22, 2010, 7:22pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/5 "2010-08-22T19:22:57Z")

</div>

Ahh I just bumped in to the very same issue not even 5 minutes ago. Using Real Schedule, a pilot bid on a flight and flew it, but as soon as she tried to file a pirep, it would not allow her to choose the correct aircraft. I have everything setup the way it should be.

The only way I see it until we can come up with a fix, dirty or clean, is to just let them fly what ever they want. No rank required.

---

<div class="post-metadata">

**Author:** ![BastiDE](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/b/5daacb/32.png) [@BastiDE](https://forum.phpvms.net/u/BastiDE)\
**Post date:** [August 22, 2010, 8:04pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/6 "2010-08-22T20:04:14Z")

</div>

> The only way I see it until we can come up with a fix, dirty or clean, is to just let them fly what ever they want. No rank required.

but we want this

> Ahh I just bumped in to the very same issue not even 5 minutes ago. Using Real Schedule, a pilot bid on a flight and flew it, but as soon as she tried to file a pirep, it would not allow her to choose the correct aircraft. I have everything setup the way it should be.

And how did the second Pilot this know? He fly 6 hours and then he becomes the message: An other Pilot has already do this flight?

---

<div class="post-metadata">

**Author:** ![TAV1702](https://forum.phpvms.net/user_avatar/forum.phpvms.net/tav1702/32/41_2.png) [@TAV1702](https://forum.phpvms.net/u/TAV1702)\
**Post date:** [August 23, 2010, 10:01pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/7 "2010-08-23T22:01:31Z")

</div>

The problem she had was it showed that the flight was available. So she bid on it and then flew the flight. After flying the flight, she went in to file a manual pirep only to find out that she could not because the aircraft was not available for her rank. So in other words, the flight will still show up but if they can’t fly that aircraft, they are sh\*t out of luck unless they have a nice admin. There was never no 2nd pilot it was only her.

And yeah I agree, I want that too. Meaning ranks to fly aircraft, but so far I have tested 3 times since then and have had the same issue. Maybe this is something Simpilot needs to look at in his Module. I do not see this as being a phpVMS issue.

\*\* @ the original thread poster\*\*

Now as far as the double and triple bids go, you must go in to the local config file and disable schedule on bid if that is how you want it to be.

---

<div class="post-metadata">

**Author:** ![BastiDE](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/b/5daacb/32.png) [@BastiDE](https://forum.phpvms.net/u/BastiDE)\
**Post date:** [August 24, 2010, 10:06am UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/8 "2010-08-24T10:06:10Z")

</div>

correct, with the schedule from PHPVMS works it. When other choose a Flight, then remove the system this flight from the schedule. The same with the Aircraft, when one Aircraft not for your rank is, then is this flight not in the shedule to see.

Real Shedule Lite show all. And this is our problem, doesnt anybody know an code? For this two problems?

---

<div class="post-metadata">

**Author:** ![simpilot](https://forum.phpvms.net/user_avatar/forum.phpvms.net/simpilot/32/26_2.png) [@simpilot](https://forum.phpvms.net/u/simpilot)\
**Post date:** [August 24, 2010, 4:59pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/9 "2010-08-24T16:59:08Z")

</div>

I did not build any flight restrictions into RealSchedule. You could apply the same if and else commands to the RealSchedule templates to achive what you are requestsing. Take a look at the native functions of phpvms in regards to the schedules and aircraft, namly the schedule\_results.tpl file and use some of those logical operators within the templates for RealSchedule.

---

<div class="post-metadata">

**Author:** ![TAV1702](https://forum.phpvms.net/user_avatar/forum.phpvms.net/tav1702/32/41_2.png) [@TAV1702](https://forum.phpvms.net/u/TAV1702)\
**Post date:** [August 24, 2010, 9:36pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/10 "2010-08-24T21:36:46Z")

</div>

> I did not build any flight restrictions into RealSchedule. You could apply the same if and else commands to the RealSchedule templates to achive what you are requestsing. Take a look at the native functions of phpvms in regards to the schedules and aircraft, namly the schedule\_results.tpl file and use some of those logical operators within the templates for RealSchedule.

DOH! I never though of that Simpilot. Nice one. I’ll give that a go and see. Or it could even show the flight, but add a disclaimer that it is unavailable for their rank or something like that. Hmmmmm. The posibillities.

---

<div class="post-metadata">

**Author:** ![CEO\_North\_Air](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/c/f07891/32.png) [@CEO\_North\_Air](https://forum.phpvms.net/u/CEO_North_Air)\
**Post date:** [August 29, 2010, 7:50pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/11 "2010-08-29T19:50:59Z")

</div>

Good eve to all,

@ Simpilot

Am I right, you meant to check the schedule\_results.tpl and fix some operators in the same ways we can fix those problems for phpvms schedule?

@ TAV1702

Do you fixed that problem? Maybe you can show us your code and explain in a few words how it works and prohibited double bids or bids without rank-availability?

Thanks a lot guys, wish you all the best and sending best regards from rainy Germany

---

<div class="post-metadata">

**Author:** ![TAV1702](https://forum.phpvms.net/user_avatar/forum.phpvms.net/tav1702/32/41_2.png) [@TAV1702](https://forum.phpvms.net/u/TAV1702)\
**Post date:** [August 30, 2010, 12:19am UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/12 "2010-08-30T00:19:58Z")

</div>

> Good eve to all,
> 
> @ Simpilot
> 
> Am I right, you meant to check the schedule\_results.tpl and fix some operators in the same ways we can fix those problems for phpvms schedule?
> 
> @ TAV1702
> 
> Do you fixed that problem? Maybe you can show us your code and explain in a few words how it works and prohibited double bids or bids without rank-availability?
> 
> Thanks a lot guys, wish you all the best and sending best regards from rainy Germany

I was not able to fix it. Most of all 6 of my pilots use the schedule search. Only a couple of us are using real schedule. So really for me it is no big deal since there are only a whopping 6 whole pilots on my roster. When and IF I ever get more pilots, I will be majorly concerned over this if I did away with schedule search and only used real schedule.

---

<div class="post-metadata">

**Author:** ![BastiDE](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/b/5daacb/32.png) [@BastiDE](https://forum.phpvms.net/u/BastiDE)\
**Post date:** [September 17, 2010, 11:30am UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/13 "2010-09-17T11:30:43Z")

</div>

Okay, I was trying it. But it doesnt work!

At the moment i dont have added the control for ranks (because the double-bid doesnt work )

Please help me, here is the code:

> //If pilot is logged in check their location
> 
> //If the pilot is at this airport allow them to bid on flights
> 
> if(Auth::LoggedIn() == true)
> 
> {
> 
> $location = PIREPData::getLastReports(Auth::$userinfo-\>pilotid, 1, ‘’);
> 
> $location = RealScheduleLiteData::get\_pilot\_location(Auth::$userinfo-\>pilotid);
> 
> if(!$location == $name-\>hub)
> 
> {
> 
> echo ‘\<td\>\<a id="’.$flight-\>id.'" class=“addbid”
> 
> href=“‘.actionurl(’/schedules/addbid’).'”\>Buchen\</a\>\</td\>';
> 
> }
> 
> else if($location-\>arricao == $name-\>icao)
> 
> {
> 
> echo ‘\<td\>\<a id="’.$flight-\>id.'" class=“addbid”
> 
> href=“‘.actionurl(’/schedules/addbid’).'”\>Buchen\</a\>\</td\>';
> 
> }
> 
> else
> 
> {
> 
> echo ‘\<td\>Sie sind nicht in ‘.$name-\>name.’\</td\>’;
> 
> }
> 
> }
> 
> if(Auth::LoggedIn() == true)
> 
> {
> 
> if(Config::Get(‘DISABLE\_SCHED\_ON\_BID’) == true && $route-\>bidid != 0)
> 
> {
> 
> echo ‘\<td\>\<a id="’.$flight-\>id.'" class=“addbid”
> 
> href=“‘.actionurl(’/schedules/addbid’).'”\>Buchen\</a\>\</td\>';
> 
> }
> 
> {
> 
> if(Auth::LoggedIn())
> 
> {
> 
> ?\>
> 
> \<a id=“\<?php echo $route-\>id; ?\>” class=“addbid”
> 
> href=“\<?php echo url(‘/schedules/addbid’);?\>”\>Buchung\</a\>
> 
> \<?php
> 
> }
> 
> }
> 
> }

But i can add an bid, who have added another!

Can one help me? And eventually say me how i can add the flight restrictions for rankings? Or can one correct it?

---

<div class="post-metadata">

**Author:** ![BastiDE](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/b/5daacb/32.png) [@BastiDE](https://forum.phpvms.net/u/BastiDE)\
**Post date:** [September 18, 2010, 12:01pm UTC](https://forum.phpvms.net/t/double-or-tripple-bids-how-to-restrict/3279/14 "2010-09-18T12:01:19Z")

</div>

nobody an idea?
