473,225 Members | 1,375 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,225 software developers and data experts.

can help me with this Update inventory funciton, where is wrong?

hi

currently i am doing this car booking website. i would like to only update our inventory one day before customer's start booking time, thus before that, i am still able to rent to other customers. E.g. if she book two month before, i can still rent this car to others within this 2 month, but one day before i need to deduct this car inventory as the next day i have to give this car to that customer.
the following is my car inventory update function. but it seems did not work in my way, as i loop through my Booking1 table to get all the start_datetime and update my inventory only if it is one day before this start_datetime. my start_datetime is in the format of "2007-12-21 17:05:05", i have changed it into seconds by using Bktime=time.mktime(time.strptime(invtime,"%Y-%m-%d %H:%M:%S")). but it seems not work. can anyone help me with this. can update my car inventory only one day before the start_datetime. thanks for any kind help:)

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         #print i.booking_time
  6.         invtime=i.start_datetime
  7.         #t=str(invtime).split('.')[0]
  8.         Bktime=time.mktime(time.strptime(invtime,"%Y-%m-%d %H:%M:%S"))
  9.         #now=datetime.datetime.now()
  10.         one_day=60*60*24
  11.         #diff=comp_dates(t,str(now).split('.')[0])
  12.         #print diff
  13.         onebefore=Bktime-one_day------>>>Error,where is wrong?date type?
  14.         if str(onebefore):
  15.             for a in CarModel.objects.all():    
  16.                 qtyInStock=a.car_inventory
  17.                 orderQuantity = 1
  18.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  19.                 a.car_inventory=qtyLeft
  20.                 a.save()
  21.                 allObj=CarModel.objects.all()
  22.                 print allObj
  23.                 print "LLLLLLLLLLLLLLLLLL"
  24.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  25.         if not str(onebefore):
  26.             all=CarModel.objects.all()
  27.             return render_to_response("inventory.html",{'all':all})
  28.  
Dec 22 '07 #1
12 1827
bvdet
2,851 Expert Mod 2GB
hi

currently i am doing this car booking website. i would like to only update our inventory one day before customer's start booking time, thus before that, i am still able to rent to other customers. E.g. if she book two month before, i can still rent this car to others within this 2 month, but one day before i need to deduct this car inventory as the next day i have to give this car to that customer.
the following is my car inventory update function. but it seems did not work in my way, as i loop through my Booking1 table to get all the start_datetime and update my inventory only if it is one day before this start_datetime. my start_datetime is in the format of "2007-12-21 17:05:05", i have changed it into seconds by using Bktime=time.mktime(time.strptime(invtime,"%Y-%m-%d %H:%M:%S")). but it seems not work. can anyone help me with this. can update my car inventory only one day before the start_datetime. thanks for any kind help:)

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         #print i.booking_time
  6.         invtime=i.start_datetime
  7.         #t=str(invtime).split('.')[0]
  8.         Bktime=time.mktime(time.strptime(invtime,"%Y-%m-%d %H:%M:%S"))
  9.         #now=datetime.datetime.now()
  10.         one_day=60*60*24
  11.         #diff=comp_dates(t,str(now).split('.')[0])
  12.         #print diff
  13.         onebefore=Bktime-one_day------>>>Error,where is wrong?date type?
  14.         if str(onebefore):
  15.             for a in CarModel.objects.all():    
  16.                 qtyInStock=a.car_inventory
  17.                 orderQuantity = 1
  18.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  19.                 a.car_inventory=qtyLeft
  20.                 a.save()
  21.                 allObj=CarModel.objects.all()
  22.                 print allObj
  23.                 print "LLLLLLLLLLLLLLLLLL"
  24.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  25.         if not str(onebefore):
  26.             all=CarModel.objects.all()
  27.             return render_to_response("inventory.html",{'all':all})
  28.  
The way you have calculated onebefore, it will always evaluate to True. I think you should calculate the difference between the date the car has been rented and the present date, and if the difference is greater than one day, keep the car in inventory, otherwise remove it.
Dec 22 '07 #2
The way you have calculated onebefore, it will always evaluate to True. I think you should calculate the difference between the date the car has been rented and the present date, and if the difference is greater than one day, keep the car in inventory, otherwise remove it.
hi, thanks for it, i have done according to this logic and i feel it is correct. but it got small error. my code is in the following:

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         #print i.booking_time
  6.         invtime=i.start_datetime
  7.         now=datetime.datetime.now()
  8.         one_day=60*60*24
  9.         diff=comp_dates(invtime,str(now).split('.')[0])
  10.         print diff
  11.         print"LLLLLLLLLLLLLLLLLPPPPPPPPPPPPPPPPPJ"
  12.         if diff < one_day:
  13.             for a in CarModel.objects.all():    
  14.                 qtyInStock=a.car_inventory
  15.                 orderQuantity = 1
  16.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  17.                 a.car_inventory=qtyLeft
  18.                 a.save()
  19.                 allObj=CarModel.objects.all()
  20.                 print allObj
  21.                 print "LLLLLLLLLLLLLLLLLL"
  22.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  23.         if not diff < one_day:
  24.                 all=CarModel.objects.all()
  25.                 return render_to_response("inventory.html",{'all':all})
  26.  
my error is:

Request Method: GET
Request URL: http://localhost:8000/inventoryupdate/
Exception Type: TypeError
Exception Value: expected string or buffer
Exception Location: C:\Python25\lib\_strptime.py in strptime, line 328
Python Executable: C:\Python25\python.exe

i think there is some TypeError, but i am not sure where? can help me with this, thanks in advance. i believe it is just a small step to success..haha
Dec 23 '07 #3
The way you have calculated onebefore, it will always evaluate to True. I think you should calculate the difference between the date the car has been rented and the present date, and if the difference is greater than one day, keep the car in inventory, otherwise remove it.
hi, thanks for it, i have done according to this logic and i feel it is correct. but it got small error. my code is in the following:

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         #print i.booking_time
  6.         invtime=i.start_datetime
  7.         now=datetime.datetime.now()
  8.         one_day=60*60*24
  9.         diff=comp_dates(invtime,str(now).split('.')[0])
  10.         print diff
  11.         print"LLLLLLLLLLLLLLLLLPPPPPPPPPPPPPPPPPJ"
  12.         if diff < one_day:
  13.             for a in CarModel.objects.all():    
  14.                 qtyInStock=a.car_inventory
  15.                 orderQuantity = 1
  16.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  17.                 a.car_inventory=qtyLeft
  18.                 a.save()
  19.                 allObj=CarModel.objects.all()
  20.                 print allObj
  21.                 print "LLLLLLLLLLLLLLLLLL"
  22.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  23.         if not diff < one_day:
  24.                 all=CarModel.objects.all()
  25.                 return render_to_response("inventory.html",{'all':all})
  26.  
my error is:

Request Method: GET
Request URL: http://localhost:8000/inventoryupdate/
Exception Type: TypeError
Exception Value: expected string or buffer
Exception Location: C:\Python25\lib\_strptime.py in strptime, line 328
Python Executable: C:\Python25\python.exe

i think there is some TypeError, but i am not sure where? can help me with this, thanks in advance. i believe it is just a small step to success..haha
Dec 23 '07 #4
The way you have calculated onebefore, it will always evaluate to True. I think you should calculate the difference between the date the car has been rented and the present date, and if the difference is greater than one day, keep the car in inventory, otherwise remove it.
hi, thanks for it, i have done according to this logic and i feel it is correct. but it got small error. my code is in the following:

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         #print i.booking_time
  6.         invtime=i.start_datetime
  7.         now=datetime.datetime.now()
  8.         one_day=60*60*24
  9.         diff=comp_dates(invtime,str(now).split('.')[0])
  10.         print diff
  11.         print"LLLLLLLLLLLLLLLLLPPPPPPPPPPPPPPPPPJ"
  12.         if diff < one_day:
  13.             for a in CarModel.objects.all():    
  14.                 qtyInStock=a.car_inventory
  15.                 orderQuantity = 1
  16.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  17.                 a.car_inventory=qtyLeft
  18.                 a.save()
  19.                 allObj=CarModel.objects.all()
  20.                 print allObj
  21.                 print "LLLLLLLLLLLLLLLLLL"
  22.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  23.         if not diff < one_day:
  24.                 all=CarModel.objects.all()
  25.                 return render_to_response("inventory.html",{'all':all})
  26.  
my error is:

Request Method: GET
Request URL: http://localhost:8000/inventoryupdate/
Exception Type: TypeError
Exception Value: expected string or buffer
Exception Location: C:\Python25\lib\_strptime.py in strptime, line 328
Python Executable: C:\Python25\python.exe

i think there is some TypeError, but i am not sure where? can help me with this, thanks in advance. i believe it is just a small step to success..haha
Dec 23 '07 #5
bvdet
2,851 Expert Mod 2GB
Check the type of object returned by:
Expand|Select|Wrap|Line Numbers
  1. invtime=i.start_datetime
Dec 23 '07 #6
Check the type of object returned by:
Expand|Select|Wrap|Line Numbers
  1. invtime=i.start_datetime
i have checked its datatype, it is datetime.datetime. so i use str() to change its data type back to string and thus can compare: my change code is in the following and it works. however, i think there is an logic error, as everytime i click update inventory link, it will deduct inventory one more time. this function is mainly for admin or staff user. if one staff click this link to see the inventory in warehouse, it deduct one already, then within next second, another staff come and click again to view inventory. it deduct one again, which is wrong and inventory is not accurate. how can i solve this issue.....can kindly help me with this.....

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         #print i.booking_time
  6.         invtime=i.start_datetime
  7.         #start_datetime = datetime.datetime(*strptime(invtime,"%Y-%m-%dT%H:%M:%S")[0:6])
  8.         print invtime
  9.         print type(invtime)
  10.         print"KKKKKKKKKKKKKKKK"
  11.         now=datetime.datetime.now()
  12.         one_day=60*60*24
  13.         diff=comp_dates(str(invtime),str(now).split('.')[0])
  14.         print diff
  15.         print"LLLLLLLLLLLLLLLLLPPPPPPPPPPPPPPPPPJ"
  16.  
  17.         if diff < one_day:
  18.             for a in CarModel.objects.all():    
  19.                 qtyInStock=a.car_inventory
  20.                 orderQuantity = 1
  21.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  22.                 a.car_inventory=qtyLeft
  23.                 a.save()
  24.                 allObj=CarModel.objects.all()
  25.                 print allObj
  26.                 print "LLLLLLLLLLLLLLLLLL"
  27.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  28.         if not diff < one_day:
  29.                 all=CarModel.objects.all()
  30.                 return render_to_response("inventory.html",{'all':all})
  31.  
  32.  
thanks so much for your kind help.
Dec 24 '07 #7
bvdet
2,851 Expert Mod 2GB
It seems to me that you need a Booking1.object attribute that can be checked to determine if it has been applied to the existing inventory.
Expand|Select|Wrap|Line Numbers
  1. if diff < one_day and Booking1.object.deducted_from_inventory == False:
Dec 24 '07 #8
It seems to me that you need a Booking1.object attribute that can be checked to determine if it has been applied to the existing inventory.
Expand|Select|Wrap|Line Numbers
  1. if diff < one_day and Booking1.object.deducted_from_inventory == False:
i think i need to create one more datebase table and its type should boolean.so when it deducts, i should turn it to true. and when it does not deducts, the default setting should be false. if my understanding is not wrong, i believe this should be the correct way. i will try to do now, thanks so much for giving me this bright idea. i will try now and let you know later. :)
Dec 24 '07 #9
i have tried it, in fact car inventory is in CarModel table which is separated from Booking1 table, as i have normalized the database table. Thus i edited the code in the following and i think it works.

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         invtime=i.start_datetime
  6.         #print invtime
  7.         #print type(invtime)
  8.         now=datetime.datetime.now()
  9.         one_day=60*60*24
  10.         diff=comp_dates(str(invtime),str(now).split('.')[0])
  11.         print diff
  12.         print"LLLLLLLLLLLLLLLLLPPPPPPPPPPPPPPPPPJ"
  13.  
  14.         #if diff < one_day and CarModel.objects.filter(inventory_deduct=0):
  15.         for a in CarModel.objects.all():
  16.             if a.inventory_deduct==0 and diff<one_day:
  17.                 qtyInStock=a.car_inventory
  18.                 orderQuantity = 1
  19.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  20.                 a.car_inventory=qtyLeft
  21.                 a.inventory_deduct=1
  22.                 a.save()
  23.  
  24.                 allObj=CarModel.objects.all()
  25.                 print allObj
  26.                 print "LLLLLLLLLLLLLLLLLL"
  27.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  28.             if a.inventory_deduct==1 and diff < one_day:
  29.                 all=CarModel.objects.all()
  30.                 return render_to_response("inventory.html",{'all':all})
  31.             if diff    > one_day:
  32.                 all=CarModel.objects.all()
  33.                 return render_to_response("inventory.html",{'all':all})
  34.  
  35.  
i have added one field called inventory_deduct and if it is true, it is 1 else it is 0. thus as you can see in my if statement, i have covered three possible situation. this logic is correct, right?? am i lack of any scenario?
Dec 24 '07 #10
i have tried it, in fact car inventory is in CarModel table which is separated from Booking1 table, as i have normalized the database table. Thus i edited the code in the following and i think it works.

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         invtime=i.start_datetime
  6.         #print invtime
  7.         #print type(invtime)
  8.         now=datetime.datetime.now()
  9.         one_day=60*60*24
  10.         diff=comp_dates(str(invtime),str(now).split('.')[0])
  11.         print diff
  12.         print"LLLLLLLLLLLLLLLLLPPPPPPPPPPPPPPPPPJ"
  13.  
  14.         #if diff < one_day and CarModel.objects.filter(inventory_deduct=0):
  15.         for a in CarModel.objects.all():
  16.             if a.inventory_deduct==0 and diff<one_day:
  17.                 qtyInStock=a.car_inventory
  18.                 orderQuantity = 1
  19.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  20.                 a.car_inventory=qtyLeft
  21.                 a.inventory_deduct=1
  22.                 a.save()
  23.  
  24.                 allObj=CarModel.objects.all()
  25.                 print allObj
  26.                 print "LLLLLLLLLLLLLLLLLL"
  27.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  28.             if a.inventory_deduct==1 and diff < one_day:
  29.                 all=CarModel.objects.all()
  30.                 return render_to_response("inventory.html",{'all':all})
  31.             if diff    > one_day:
  32.                 all=CarModel.objects.all()
  33.                 return render_to_response("inventory.html",{'all':all})
  34.  
  35.  
i have added one field called inventory_deduct and if it is true, it is 1 else it is 0. thus as you can see in my if statement, i have covered three possible situation. this logic is correct, right?? am i lack of any scenario?
sometimes, i find out that inventory will turn out to be negative....is this really correct to do in this way?? hmm...if inventory becomes negative means the company is lack of this amount of car? i am not sure if this kind of scenario is correct. as from my current coding, it will occurs this negative inventory scenario.i would like to hear from your opinion.
Dec 25 '07 #11
bvdet
2,851 Expert Mod 2GB
i have tried it, in fact car inventory is in CarModel table which is separated from Booking1 table, as i have normalized the database table. Thus i edited the code in the following and i think it works.

Expand|Select|Wrap|Line Numbers
  1. def inventory(request):
  2.  
  3.     allObj=[]
  4.     for i in Booking1.objects.all():
  5.         invtime=i.start_datetime
  6.         #print invtime
  7.         #print type(invtime)
  8.         now=datetime.datetime.now()
  9.         one_day=60*60*24
  10.         diff=comp_dates(str(invtime),str(now).split('.')[0])
  11.         print diff
  12.         print"LLLLLLLLLLLLLLLLLPPPPPPPPPPPPPPPPPJ"
  13.  
  14.         #if diff < one_day and CarModel.objects.filter(inventory_deduct=0):
  15.         for a in CarModel.objects.all():
  16.             if a.inventory_deduct==0 and diff<one_day:
  17.                 qtyInStock=a.car_inventory
  18.                 orderQuantity = 1
  19.                 qtyLeft = int(qtyInStock) - int(orderQuantity)
  20.                 a.car_inventory=qtyLeft
  21.                 a.inventory_deduct=1
  22.                 a.save()
  23.  
  24.                 allObj=CarModel.objects.all()
  25.                 print allObj
  26.                 print "LLLLLLLLLLLLLLLLLL"
  27.                 return render_to_response("inventoryupdate.html", {'allObj':allObj})    
  28.             if a.inventory_deduct==1 and diff < one_day:
  29.                 all=CarModel.objects.all()
  30.                 return render_to_response("inventory.html",{'all':all})
  31.             if diff    > one_day:
  32.                 all=CarModel.objects.all()
  33.                 return render_to_response("inventory.html",{'all':all})
  34.  
  35.  
i have added one field called inventory_deduct and if it is true, it is 1 else it is 0. thus as you can see in my if statement, i have covered three possible situation. this logic is correct, right?? am i lack of any scenario?
I think you are going about it the wrong way. You have Inventory (a collection of CarModels) and Booking1 objects. Think about each CarModel in your inventory having a status attribute which would include date information. If the car is in inventory and has not been booked, the date data could be set to False. If the car is in inventory and has been booked for a future date, the date data would be from...to dates. If the car is not in inventory, the date data should be from < now < to.

I don't have much experience with this type of programming, and I am unfamiliar with your objects, so I may be off base. It seems to me that if you set it up this way, you could determine the available inventory on any particular day, either now or in the future.
Dec 26 '07 #12
I think you are going about it the wrong way. You have Inventory (a collection of CarModels) and Booking1 objects. Think about each CarModel in your inventory having a status attribute which would include date information. If the car is in inventory and has not been booked, the date data could be set to False. If the car is in inventory and has been booked for a future date, the date data would be from...to dates. If the car is not in inventory, the date data should be from < now < to.

I don't have much experience with this type of programming, and I am unfamiliar with your objects, so I may be off base. It seems to me that if you set it up this way, you could determine the available inventory on any particular day, either now or in the future.
i have 2 tables to complete this function, in my Booking1 table i have car_id, user_id, start_datetime and end_datetime, pickup _location, return_locaiton. and in my CarModel table, i have car_model_code. outlet_id as foreign key, car_model_name, booking_price. inventory_deduct and car_inventory, etc.

i have separate this two tables. only deduct inventory 24 hours before customer's start_datetime of booking car. as before this, i am still able to rent this car to other customers. if this condition is matched, then it inventory_deduct will set to 1, which means it has already deduct car inventory for this booking. hmm...i am not sure is you mean this part is wrong, which means i should include inventory_deduct in Booking1 table? i would like to hear from you and clear my doubts about this part. haha, thanks so much :)
Dec 27 '07 #13

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Melissa | last post by:
Products appear on multiple orders in a batch of orders. I created a totals query with the fields, ProductID and SumOfQuantity. I have a TblProduct table of products with the fields ProductID,...
6
by: ralph_noble | last post by:
Can someome please advise what the equivalent query would be in Microsoft SQL Server ... I've tried a number of combinations with no success ... Thanks, Ralph Noble (ralph_noble@hotmail.com) ...
12
by: qt1504 | last post by:
I have two small stores in two different building which is not a LAN network. However, each has an internet access. I am trying to write an inventory program which manage inventory two stores. ...
0
by: Jeff | last post by:
I have a simple database with Table Inventory and Order. In Table Order, I have fields SKU#......QtySold Where Inventory-SKU# related to Order-SKU# (One SKU# to many Order) Now I want to calculate...
2
by: SamDev | last post by:
I have a table that lists inventory items with prices and suppler and inventory description. There are times when a supplier will have a % increase of prices for all items so I want to be able to...
46
by: arion | last post by:
Hello, I am working on a very complex database and now I am trying to create an update query. The query is showing too few records. I am trying to update data in the table "inventory" with data...
5
by: cblank | last post by:
I'm having some trouble with my inventory program. Its due tom and my teacher is not wanting to help. He keeps giving me a soluction that is not related to my code. I have everything working except...
6
by: deltamami0999 | last post by:
I just received this e-mail from a colleague of mine that got stuck and she sent it to me and i'm stuck....we're wondering what this is all about.....can anyone help? Inventory Management...
3
by: 100grand | last post by:
Modify the Inventory Program to use a GUI. The GUI should display the information one product at a time, including the item number, the name of the product, the number of units in stock, the price...
1
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
0
by: veera ravala | last post by:
ServiceNow is a powerful cloud-based platform that offers a wide range of services to help organizations manage their workflows, operations, and IT services more efficiently. At its core, ServiceNow...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: mar23 | last post by:
Here's the situation. I have a form called frmDiceInventory with subform called subfrmDice. The subform's control source is linked to a query called qryDiceInventory. I've been trying to pick up the...
2
by: jimatqsi | last post by:
The boss wants the word "CONFIDENTIAL" overlaying certain reports. He wants it large, slanted across the page, on every page, very light gray, outlined letters, not block letters. I thought Word Art...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
0
Git
by: egorbl4 | last post by:
Скачал я git, хотел начать настройку, а там вылезло вот это Что это? Что мне с этим делать? ...
1
by: davi5007 | last post by:
Hi, Basically, I am trying to automate a field named TraceabilityNo into a web page from an access form. I've got the serial held in the variable strSearchString. How can I get this into the...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.