<< # if user_name='Paul Berkas' or user_name='bry65ts' then goto 'approved_products_grs.htm' /if /# if need_metabuild=0 then add_body_tag=1 current_page_title="Approved Products" active_tab="approved" return_page=page goto comp_metabuild else need_metabuild=0 /if master_item="error" master_description="error" retail_price=0 use_common_recipe=1 if appr_prod.sort="ERROR" then appr_prod.sort=row("PRODUCT_ITEM_SORT","N") /if sort_fld="ERROR" if appr_srch_item_type='ERROR' then appr_srch_item_type='MY' /if # Set Link back to current page: /# mis.back_page = page >> <>
> tag="kilwins_franchise">

Approved Products

    

Enter search criteria or leave blank for all products

<< # Display table of Approved Groups search criteria checkboxes: /# approved_groups_rs=dbfind("data/approved_groups","",1,100,"GRP_ID,GRP_DESCRIPTION") if dbresults[1,1]="TRUE" and dbresults[2,1]>0 then display '' /display for name=i value=1 to rows(approved_groups_rs) do mis_cls[1,i]=approved_groups_rs[1,i] display '' /display if mod(i,4)=0 and i<>rows(approved_groups_rs) then display lf+'' /display /if /for test_col=mod(i,4) if test_col>0 then for name=i value=1 to test_col-1 do display '' /display /for /if display '
'+replaceall(approved_groups_rs[2,i],'&','&')+'
 
' /display /if >>
<< if approved_search_results<>"error" then display '
           
*Y – Recommended product in all Kilwin'+ascii(39)+'s stores.
' /display # Display status message: /# IF LENGTH(my_item_update_status) > 0 and my_item_update_status != 'ERROR' THEN DISPLAY my_item_update_status /DISPLAY /IF my_item_update_status = '' if show_approved_rows>0 then i=0 # approved_search_results: "1)PRODUCT_NUMBER, 2)PRODUCT_DESCRIPTION, 3)PRODUCT_LINK, 4)PRODUCT_IMAGE, 5)PRODUCT_SUGGESTED, 6)PRODUCT_MIS_LIST, 7)[target]NUMBER" /# approved_my_items_rs = '' # Table to store 'My Items' for printing recipes /# for name = approved_search_results rowname = result_row do i=i+1 if iseven(i) then t_cls='kpage_row2' else t_cls='kpage_row1' /if image_link='' pdf_link='' if isfile('data/recipe/'+result_row[1]+'.htm') then tmp_doc='/apps/kilwins_store/data/recipe/'+result_row[1]+'.htm' tmp_link=filepushlink('push_document','doc_var',tmp_doc,result_row[1]+'.htm') if secure_tag='SECURE' then tmp_link=replace(tmp_link,'http://','https://') /if /if # Show image: /# if trim(result_row[4])<>'' then image_link='IMAGE' if isfile('images/'+result_row[4]) then if secure_tag='SECURE' then t_prefix='https://' else t_prefix='http://' /if if getcol(getcoleq(GETSYSCONF,1,'AddWWW'),2)='Y' then t_prefix+='www.' /if image_link='File Type' /if /if if result_row[5]<>'Y' then result_row[5]=' ' /if # Get Target Amount and My_MIS flag [Y/N]: /# tmp=dbfind('data/'+user_datafile+'/approved_targets','NUMBER='+result_row[1],1,1,'TARGET,MY_MIS') if dbresults[2]>0 then if tmp[2]!='Y' then tmp[2]='N' /if target_flds[1,i]=tmp[1] # Target amount /# target_flds[2,i]=tmp[2] # MY_MIS: "Y/N" /# # If My_MIS is 'Y', Append Item to 'approved_my_items_rs': /# IF tmp[2] = 'Y' THEN APPEND result_row TO approved_my_items_rs /APPEND /IF else target_flds[1,i]='' # Target amount /# target_flds[2,i]='N' # MY_MIS: "Y/N" /# /if # if target_flds[1,i]>0 then t_img=row('check_on.gif','My Item') else t_img=row('check_off.gif','Not My Item') /if /# display ' ' /display /for else display ' ' /display /if display '
Item Description *Sugg My Target My Item Make Image'+t_img[2]+'
'+result_row[1]+' '+replaceall(proper(result_row[2]),'&','&')+' '+result_row[5]+' '+image_link+'
No Items Found
' /display /if >>
<> << overlay exec_option if htmlos.clicked='plist_btn' then goto 'price_list.htm' elif htmlos.clicked='ctag_btn' then case_tags.back_page = page case_tags.back_crumb = current_page_title goto 'case_tags.htm' elif htmlos.clicked='dlist_btn' then description_list.back_page = page description_list.back_crumb = current_page_title goto 'description_list.htm' elif htmlos.clicked='print_recipes_btn' then print_recipes.back_page = page print_recipes.back_crumb = current_page_title goto 'print_recipes.htm' elif htmlos.clicked='print_recipes' then print_recipes.back_page = page print_recipes.back_crumb = current_page_title goto 'print_recipes.htm' else /if goto page >> << overlay plist_btn price_list.back_page = page price_list.back_crumb = current_page_title goto 'price_list.htm' >> << overlay ctag_btn case_tags.back_page = page case_tags.back_crumb = current_page_title goto 'case_tags.htm' >> << overlay dlist_btn description_list.back_page = page description_list.back_crumb = current_page_title goto 'description_list.htm' >> << overlay print_recipes_btn print_recipes.back_page = page print_recipes.back_crumb = current_page_title goto 'print_recipes.htm' >> << overlay ingredient_tags_btn ing_tags.back_page = page ing_tags.back_crumb = current_page_title goto 'ing_tags.htm' >> << overlay approved_search if sort_fld<>"ERROR" then if appr_prod.sort[1,1]=sort_fld then if appr_prod.sort[2,1]="Y" then appr_prod.sort[2,1]="N" else appr_prod.sort[2,1]="Y" /if else appr_prod.sort[1,1]=sort_fld appr_prod.sort[2,1]="N" /if /if sql='' t_cls=getcoleq(mis_cls,2,1) row_cnt=rows(t_cls) if row_cnt>1 or t_cls[2,1]=1 then # ##### Old Way ##### # sql='PRODUCT_MIS_CLS="'+t_cls[1,1]+'"' # if row_cnt>1 then # for name=i value=2 to row_cnt do sql+=' OR PRODUCT_MIS_CLS="'+t_cls[1,i]+'"' /for # /if ################### /# sql='PRODUCT_MIS_LIST~~"|'+t_cls[1,1]+'|"' if row_cnt>1 then for name=ii value=2 to row_cnt do sql+=' AND PRODUCT_MIS_LIST~~"|'+t_cls[1,ii]+'|"' /for /if /if # if sql!='' then sql+=' AND ' /if sql+='(TEST_MARKET_STORES="" OR TEST_MARKET_STORES~~"|'+user_datafile+'|")' /# if appr_srch_text!='' then if sql!='' then sql='('+sql+') AND ' /if sql+='(PRODUCT_DESCRIPTION'+search_type+'"'+replaceall(appr_srch_text,'"','\"')+'" OR PRODUCT_NUMBER'+search_type+'"'+replaceall(appr_srch_text,'"','\"')+'")' if user_datafile!='998' then sql+=' and STORE_110_ONLY!="Y"' /if /if approved_search_results=dbfindsort('data/approved_products_header',sql,1,2000,appr_prod.sort[1],appr_prod.sort[2],'PRODUCT_NUMBER,PRODUCT_DESCRIPTION,PRODUCT_LINK,PRODUCT_IMAGE,PRODUCT_SUGGESTED,PRODUCT_MIS_LIST') # If search results returned and searching for 'My Items', then join the 'My Target' values for 'My Items'(MY_MIS="Y"): /# if dbresults[2]>0 and appr_srch_item_type='MY' then approved_search_results=dbfindj('data/'+user_datafile+'/approved_targets','MY_MIS="Y"',1,2000,'NUMBER,MY_MIS',approved_search_results,1,'NUMBER') approved_search_results=GETCOLEQ(approved_search_results,8,'Y') approved_search_results=nodups(approved_search_results) if approved_search_results[7]='' then show_approved_rows=0 else show_approved_rows=rows(approved_search_results) /if ##### DEBUG: ##### my_item_update_status = approved_search_results /# else show_approved_rows=dbresults[2] /if target_flds=row('','') make_flds=row('') goto page >> << overlay change_sort if appr_prod.sort[1,1]=sort_fld then if appr_prod.sort[2,1]="Y" then appr_prod.sort[2,1]="N" else appr_prod.sort[2,1]="Y" /if else appr_prod.sort[1,1]=sort_fld appr_prod.sort[2,1]="N" /if goto page >> << overlay push_document tmp_ext=mime(cutx(reverse(chopright(reverse(doc_var),"/")),"/")) stat=filepush(doc_var,"xyz") >> << overlay approved_item_detail labor_hours="ERROR" appr_item_detail.return_page=page master_item='ERROR' goto "approved_item_detail.htm" >> << overlay update_targets # 'Update' button pressed: /# if target_btn='Update' then # If approved_targets.db doesn't exist, create it: /# if isfalse(isfile('data/'+user_datafile+'/approved_targets.db')) then tmp=syscp('data/config/approved_targets.conf','data/'+user_datafile+'/approved_targets.conf') tmp=dbcreate('data/'+user_datafile+'/approved_targets') /if # approved_search_results: "1)PRODUCT_NUMBER, 2)PRODUCT_DESCRIPTION, 3)PRODUCT_LINK, 4)PRODUCT_IMAGE, 5)PRODUCT_SUGGESTED, 6)PRODUCT_MIS_LIST, 7)[target]NUMBER" /# # Get all Product Numbers in approved_search_results /# store_approved_targets_rs=getcol(approved_search_results,1) # Join "TARGET,MY_MIS,RECORD" columns to # store_approved_targets_rs on [Product]NUMBER col in approved_targets.db: /# store_approved_targets_rs=dbfindj('data/'+user_datafile+'/approved_targets','RECORD>0',1,1000,'TARGET,MY_MIS,RECORD',store_approved_targets_rs,1,'NUMBER') # Set field values for 'my_items_log.db': /# MIL_CUST=user_datafile MIL_USER=user_name MIL_DATE_TIME=now MIL_PAGE=page # Loop over search results: /# for name=ii value=1 to rows(approved_search_results) do MIL_ITEM = approved_search_results[1,ii] # Get the Item number /# PRODUCT_MIS_LIST = approved_search_results[6,ii] # Get Search Criteria list /# # If checkbox not selected (value is empty), assign value to 'N': /# if target_flds[2,ii]!='Y' then target_flds[2,ii]='N' /if # store_approved_targets_rs: "1)PRODUCT_NUMBER, 2)TARGET, 3)MY_MIS, 4)RECORD /# target_item=getcoleq(store_approved_targets_rs,1,MIL_ITEM) # If Product Number is in approved_targets.db, continue: /# if target_item[1]!='' then # If the Target value entered in form is different from value in DB, # OR the MY Item checkbox was just checked, # OR the MY Item checkbox was just unchecked, continue: /# if target_item[2]!=target_flds[1,ii] or (target_item[3]!='Y' and target_flds[2,ii]='Y') or (target_item[3]='Y' and target_flds[2,ii]!='Y') then # [Target Amount is valid]: # OR My Item checkbox checked, continue: /# if (isnumber(target_flds[1,ii]) and target_flds[1,ii]>0) or target_flds[2,ii]='Y' then NUMBER=MIL_ITEM TARGET=target_flds[1,ii] MY_MIS=target_flds[2,ii] # If Item exists in approved_targets.db then edit the record. Otherwise, add a record: /# if target_item[4]!='' then tmp=dbedit('data/'+user_datafile+'/approved_targets',target_item[4]) else tmp=dbadd('data/'+user_datafile+'/approved_targets') # If MY Item checkbox was just checked, then update the log: /# if target_item[3]!='Y' and target_flds[2,ii]='Y' then MIL_NEW_VAL='Y' t=dbadd('data/my_items_log') elif target_item[3]='Y' and target_flds[2,ii]!='Y' then MIL_NEW_VAL='N' t=dbadd('data/my_items_log') /if /if # If Item is 'PACKAGED IN STORE', then also assign the Label associated with Item as a 'My Item': /# IF PRODUCT_MIS_LIST ~~ "|010|" THEN # Get the item number for the Label associated with Item: /# label_line_item = dbfind("data/approved_products_detail",'PRODUCT_LINE_ITEM~"' + MIL_ITEM + '"',1,1,"PRODUCT_LINE_ITEM") # If a label exists, then update the 'Items' record for the Label to indicate it is a My Item: /# IF dbresults[2]>0 then label_product_number = label_line_item[1] # Get the Label Item number /# # Get the Label Item number: /# label_record_number = dbfind('data/'+user_datafile+'/items','ITEM="' + label_product_number + '"',1,1,'RECORD') # If the Label exists in Items DB, then update the 'MY_ITEM' field: /# IF dbresults[2]>0 then MY_ITEM = target_flds[2,ii] # Assign 'MY_ITEM' field to value of checkbox [Y/N] /# IF MY_ITEM = 'Y' THEN my_item_update_type = 'added' MIL_NEW_VAL='Y' # for 'my_items_log' /# ELSE my_item_update_type = 'removed' MIL_NEW_VAL='N' # for 'my_items_log' /# /IF tmp=dbedit('data/'+user_datafile+'/items',label_record_number,'MY_ITEM') # Update status message: /# my_item_update_status += '

The required label: ' + label_product_number + ' has been ' + my_item_update_type + ' as a My Item.

' # Update the log: /# MIL_ITEM = label_product_number # Assign Label Item Number to DB field: My Items Log Item /# t=dbadd('data/my_items_log') /IF /IF /IF else # [Target Amount is not valid]: # OR My Item checkbox is not checked, remove record from approved_targets.db: /# tmp=dbremove('data/'+user_datafile+'/approved_targets','NUMBER="'+MIL_ITEM+'"') # If MY Item checkbox was just un-checked, then update the log to indicate Label Item added to My Items: /# if target_item[3]='Y' and target_flds[2,ii]!='Y' then MIL_NEW_VAL='N' t=dbadd('data/my_items_log') /if # If Item is 'PACKAGED IN STORE', then also UN-assign the Label associated with Item as a 'My Item': /# IF PRODUCT_MIS_LIST ~~ "|010|" THEN # Get the item number for the Label associated with Item: /# label_line_item = dbfind("data/approved_products_detail",'PRODUCT_LINE_ITEM~"' + MIL_ITEM + '"',1,1,"PRODUCT_LINE_ITEM") # If a label exists, then update the 'Items' record for the Label to indicate it is a My Item: /# if dbresults[2]>0 then label_product_number = label_line_item[1] # Get the Label Item number /# # Get the Label Item number: /# label_record_number = dbfind('data/'+user_datafile+'/items','ITEM="' + label_product_number + '"',1,1,'RECORD') # If the Label exists in Items DB, then update the 'MY_ITEM' field: /# IF dbresults[2]>0 then MY_ITEM = 'N' # Assign 'MY_ITEM' field to 'N' /# tmp=dbedit('data/'+user_datafile+'/items',label_record_number,'MY_ITEM') # Update status message: /# my_item_update_status += '

The required label: ' + label_product_number + ' has been removed as a My Item.

' # Update the log to indicate Label Item removed from My Items: /# MIL_ITEM = label_product_number # Assign Label Item Number to DB field: My Items Log Item /# MIL_NEW_VAL='N' # for 'my_items_log' /# t=dbadd('data/my_items_log') /IF /IF /IF /if # END [Target Amount valid] /# /if # Otherwise, Product Number is NOT in approved_targets.db: # IF Target value is valid, # OR My Item checkbox checked, then add a record to approved_targets: /# elif (isnumber(target_flds[1,ii]) and target_flds[1,ii]>0) or target_flds[2,ii]='Y' then NUMBER=MIL_ITEM TARGET=target_flds[1,ii] MY_MIS=target_flds[2,ii] tmp=dbadd('data/'+user_datafile+'/approved_targets') if MY_MIS='Y' then MIL_NEW_VAL='Y' t=dbadd('data/my_items_log') /if /if /for ELIF (target_btn = "Print My Recipes" OR target_btn = "Print My Nutrition Info") THEN # 'Print My Recipes' OR 'Print My Nutrition Info' button pressed: /# # If 'Print My Nutrition Info' button pressed, then set flag to only display nutrition info: /# IF target_btn = "Print My Nutrition Info" THEN nutrition_only = 'TRUE' ELSE nutrition_only = 'FALSE' /IF # Construct SQL for all selected Item Numbers: /# # approved_my_items_rs: "1)PRODUCT_NUMBER, 2)PRODUCT_DESCRIPTION, 3)PRODUCT_LINK, 4)PRODUCT_IMAGE, 5)PRODUCT_SUGGESTED, 6)PRODUCT_MIS_LIST, 7)[target]NUMBER" /# approved_my_items_rs = GETCOLNOTEQ(approved_my_items_rs,2,'') # Discard the first blank row in array /# approved_my_items_sql = "PRODUCT_NUMBER = '" + COLTOLIST(approved_my_items_rs,1,"' OR PRODUCT_NUMBER = '") + "'" # Get Product Headers /# product_header=dbfind("data/approved_products_header",approved_my_items_sql,1,1,"PRODUCT_NUMBER,PRODUCT_DESCRIPTION,PRODUCT_IMAGE,PRODUCT_YIELD,PRODUCT_YIELD_UM,PRODUCT_LABOR_HOURS,PRODUCT_RETAIL_PRICE,PRODUCT_LINK,PRODUCT_SUGGESTED_MULTI,PRODUCT_MIS_CLS,LAST_CHANGED") # Create HTML file with list of recipes for Items included in search results: /# # If Nutrition Only: add class to div: /# IF nutrition_only = 'TRUE' THEN nutr_only_class_str = ' class="nutr_only"' ELSE nutr_only_class_str = '' /IF recipe_chg_date='' last_chg_date=product_header[11] # right(product_header[11],5)+middle(product_header[11],5,5)+left(product_header[11],4) /# if product_header[11]!='' and last_chg_date!='12/31/2005' then recipe_chg_date='Last Updated: '+last_chg_date /if if use_common_recipe=1 then recipe.back_page=page recipe.back_text='Approved Products' expand file='build_recipes_script.lib' /expand else recipes_html = ' '+current_page_title+': Recipes ' # Loop over search results and add a Recipe Page for each Item: /# # approved_search_results: "1)PRODUCT_NUMBER, 2)PRODUCT_DESCRIPTION, 3)PRODUCT_LINK, 4)PRODUCT_IMAGE, 5)PRODUCT_SUGGESTED, 6)PRODUCT_MIS_LIST, 7)[target]NUMBER" /# FOR name = approved_my_items_rs rowname = approved_my_item DO approved_PRODUCT_NUMBER = approved_my_item[1] approved_PRODUCT_DESCRIPTION = approved_my_item[2] # Populate product vars: /# product_number = approved_my_item[1] product_description = approved_my_item[2] product_image = approved_my_item[4] # Get Recipe Text: /# # Display if not nutrition only: /# item_recipe_rs = 'ERROR' # Reset recordset /# recipe_text = '' # Don't show if Nutrition Only: /# IF nutrition_only != 'TRUE' THEN item_recipe_rs = dbfind("data/approved_recipe",'PRODUCT_NUMBER = ' + approved_PRODUCT_NUMBER,1,10000,"PRODUCT_NUMBER,PRODUCT_RECIPE") recipe_text = GETITEM(item_recipe_rs,2,1) # Get text of recipe for Item /# /IF # Get Product Line Items for the Product /# product_lines = dbfindsort("data/approved_products_detail",'PRODUCT_NUMBER = ' + approved_PRODUCT_NUMBER,1,1000,"PRODUCT_LINE_NUMBER","N","PRODUCT_LINE_ITEM,PRODUCT_LINE_DESCRIPTION,PRODUCT_LINE_QTY,PRODUCT_LINE_UM,PRODUCT_LINE_PRICE,PRODUCT_IS_BOM,PRODUCT_LINE_ALT_DESCRIPTION,PRODUCT_LINE_UM_DESC,PRODUCT_LINE_CARRY_OVER,PRODUCT_NUMBER") # product_lines_rs: "1)PRODUCT_LINE_ITEM, 2)PRODUCT_LINE_DESCRIPTION, 3)PRODUCT_LINE_QTY, 4)PRODUCT_LINE_UM, 5)PRODUCT_LINE_PRICE, 6)PRODUCT_IS_BOM, 7)PRODUCT_LINE_ALT_DESCRIPTION, 8)PRODUCT_LINE_UM_DESC, 9)PRODUCT_LINE_CARRY_OVER, 10)PRODUCT_NUMBER" /# # Add recipe to HTML: /# # Don't show if Nutrition Only: /# IF nutrition_only != 'TRUE' THEN # Wrap Recipe with [div class="recipe_body"] to enable CSS page breaks. /# recipes_html += '
' recipes_html += '

(' + approved_PRODUCT_NUMBER + ') ' + replaceall(approved_PRODUCT_DESCRIPTION,'&','&') + '

' # DISPLAY Product Line Items: /# # product_lines: "1)PRODUCT_LINE_ITEM, 2)PRODUCT_LINE_DESCRIPTION, 3)PRODUCT_LINE_QTY, 4)PRODUCT_LINE_UM, 5)PRODUCT_LINE_PRICE, 6)PRODUCT_IS_BOM, 7)PRODUCT_LINE_ALT_DESCRIPTION, 8)PRODUCT_LINE_UM_DESC, 9)PRODUCT_LINE_CARRY_OVER, 10)PRODUCT_NUMBER" /# for name=product_lines rowname=product_line do # If PRODUCT_NUMBER is not 'M' /# if product_line[1]<>"M" then desc=product_line[2] # PRODUCT_LINE_DESCRIPTION /# last_word=desc spaces=count(desc," ") for name=x value=1 to spaces do last_word=trim(chopleft(last_word," ")) /for if middle(last_word,1,1)="c" then desc=replaceall(desc,last_word,"") /if recipes_html += ' ' # /# recipes_html += '
Ingredients Amount
('+product_line[1]+') '+replaceall(replaceall(proper(replaceall(desc,'"','"~ ')),'&','&'),'"~ ','"')+'('+product_line[1]+') '+replaceall(proper(desc),'&','&')+'' if trim(product_line[7])<>"" then recipes_html += ' '+product_line[7] else recipes_html += ' '+product_line[3]+'  '+product_line[4] /if /if /FOR # END: DISPLAY Product Line Items: /# recipes_html += '

' + recipe_chg_date + '

Instructions

' + replaceall(recipe_text,'&','&') + '

' # Display Product Image: /# if product_image<>"" and isfile(dirname(page) + 'images/' + product_image)="TRUE" then recipes_html += '
Product Image
' /if # Display Label: /# t=dbfind('data/'+user_datafile+'/items','ITEM="'+product_number+'L"',1,1,'ITEM') if dbresults[2]>0 then recipes_html += '

Required Label: '+product_number+'L

' # Display Label Image: /# i_img=dbfind('data/item_images','ITEM="'+product_number+'L"',1,1,'ITEM_IMAGE') if dbresults[2]>0 and i_img[1]<>"" and isfile(dirname(page) + 'item_images/'+i_img[1]) then recipes_html += 'Label Image' elif isfile(dirname(page) + 'images/'+comp_default_item_image) then recipes_html += 'Missing Image' /if recipes_html += '
' /if # Display ingredients: /# if isfile(dirname(page) + 'statements/'+product_number+'.txt') then copy file='statements/'+product_number+'.txt' to statement /copy recipes_html += '

'+replaceall(statement,'&','&')+'

' /if /IF # END: Display if not nutrition only: /# # Display Nutrition Label: /# if isfile(dirname(page) + 'nutrition/'+product_number+'.png') then t_ext='.png' elif isfile(dirname(page) + 'nutrition/'+product_number+'.gif') then t_ext='.gif' else t_ext='' /if if t_ext!='' then recipes_html += '
' recipes_html += '

(' + approved_PRODUCT_NUMBER + ') ' + replaceall(approved_PRODUCT_DESCRIPTION,'&','&') + '

' recipes_html += 'Nutrition Label
' /if # Display if not nutrition only: /# IF nutrition_only != 'TRUE' THEN # Display Disclaimer: /# copy file='data/disclaimer.dat' to t_text /copy recipes_html += '

'+t_text+'

' t_text='' recipes_html += '
' # END: Wrap Recipe with to enable CSS page breaks. /# /IF # END: Display if not nutrition only: /# /FOR # END: Loop over search results and add a Recipe Page for each Item /# recipes_html += '' copy recipes_html to file="data/"+user_datafile+"/approved_recipes.htm" /copy recipes_html="" goto "data/"+user_datafile+"/approved_recipes.htm" /if ELSE # Button other than 'Update' or 'Print My Recipes' pressed: /# if lines_per_page='ERROR' then lines_per_page=37 /if page_hdr='   _______ _______ _______ _______ _______ Item Description Sugg My Target Make Stk Ord Stk Ord Stk Ord Stk Ord Stk Ord'+lf excel_file=' '+current_page_title+': recipes
'+page_hdr # approved_search_results: "1)PRODUCT_NUMBER, 2)PRODUCT_DESCRIPTION, 3)PRODUCT_LINK, 4)PRODUCT_IMAGE, 5)PRODUCT_SUGGESTED, 6)PRODUCT_MIS_LIST, 7)[target]NUMBER" /# line_count=0 for name=i value=1 to rows(approved_search_results)do approved_PRODUCT_SUGGESTED = approved_search_results[5,i] if target_btn="Print Suggested" and approved_PRODUCT_SUGGESTED<>"Y" then continue elif target_btn="Print My Target" and target_flds[1,i]="" then continue elif target_btn="Print Make" and make_flds[1,i]="" then continue /if line_count=line_count+1 if line_count>lines_per_page then excel_file=excel_file+''+page_hdr line_count=1 /if if iseven(line_count) then t_cls="listRow2" else t_cls="listRow1" /if excel_file=excel_file+' '+lf /for excel_file=excel_file+'
Print Date: '+today+'
Kilwin'+ascii(39)+'s Approved Products Work Order
 
 
'+approved_search_results[1,i]+' '+proper(approved_search_results[2,i])+' '+approved_PRODUCT_SUGGESTED+' '+target_flds[1,i]+' '+make_flds[1,i]+' ___|___ ___|___ ___|___ ___|___ ___|___
' copy excel_file to file="data/"+user_datafile+"/approved_list.htm" /copy excel_file="ERROR" page_hdr="ERROR" goto "data/"+user_datafile+"/approved_list.htm" /if goto page >>