• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Python myTools.getFocus函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Python中myTools.getFocus函数的典型用法代码示例。如果您正苦于以下问题:Python getFocus函数的具体用法?Python getFocus怎么用?Python getFocus使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了getFocus函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。

示例1: fCreate_CreditsForMonth

def fCreate_CreditsForMonth(pMonth):
    # ---------------------------------------------------#

    myTools.sectionStartTimeStamp("credits" + str(pMonth))
    logging.debug("Create_CreditsForMonth: " + str(pMonth))

    allClients = names_Init.fInit_Clients()
    count = 0

    myTools.getFocus()

    # open a/r tran list
    type("t", KeyModifier.CTRL)
    myTools.waitForTransList()

    for oneClient in allClients:
        count += 1

        # always create credits for first 5 clients
        # then create credits for 1 out of 9 next clients

        if (count in range(6)) or ((count + pMonth) % 9 == 0):
            creditAmount = pMonth + pMonth / float(100)
            fCreate_OneCredit(oneClient, count, pMonth, creditAmount)
        else:
            logging.debug("-- skip: " + str(pMonth) + "-" + oneClient)

    type(Key.F4, KeyModifier.CTRL)
    time.sleep(1)
    type(Key.F4, KeyModifier.CTRL)

    myTools.sectionEndTimeStamp()
    myTools.checkProcesses()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:33,代码来源:trans_Credits.py


示例2: fSetup_ClientHold

def fSetup_ClientHold():
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("set up client hold")
    logging.debug('set up client hold')

    # make sure timeslips has focus
    myTools.getFocus()

    logging.debug('- open client list')
    type("n",KeyModifier.ALT)
    type("i")
    time.sleep(1)

    fHold_Time_NextBill_Hours()
    fHold_Exp_AllBills_Amount()
    fHold_Bill_AllBills_AmountAndHours()
    fHold_AR_AllBills()

    time.sleep(1)
    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1) 
    type(Key.F4,KeyModifier.CTRL)

    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:25,代码来源:client_Hold.py


示例3: fChange_ClientSettings

def fChange_ClientSettings():
#---------------------------------------------------#

    logging.debug('- Change_ClientSettings')
    myTools.getFocus()
    
    logging.debug('-- change a client')
    type("i",KeyModifier.CTRL)
    time.sleep(1)
    type(Key.ENTER)
    time.sleep(1)

    myTools.pressF6(4)
    if Settings.tsVersion > "2014":
        myTools.pressF6(3)       
    time.sleep(1)
    
    myTools.pressTAB(3)   
    time.sleep(1)
    type("my")

    logging.debug('-- save client')
    type("s",KeyModifier.CTRL)

    fExport_ClientSettings()
    fExport_TemplateSettings()

    time.sleep(1)
    type(Key.F4,KeyModifier.CTRL)
    type(Key.F4,KeyModifier.CTRL)
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:30,代码来源:taxes_Setup.py


示例4: fFundsAccouts_Setup

def fFundsAccouts_Setup():
# - - - - - - - - - - - - - - - - - - - - - - - - - #

    myTools.sectionStartTimeStamp("funds account")
    logging.debug('FundsAccount_Setup')

    # make sure timeslips has focus
    myTools.getFocus()
    # switch date to 1/27/13
    fSet_BillDate(1)

    fBankAccount_Create()

    # open client list
    type("i",KeyModifier.CTRL)
    time.sleep(1)

    clientList = ["Hadley","Halifax"]
    count = 0    

    for oneCli in clientList:
        count += 1
        fFundsAccount_Create(oneCli,count)

    type(Key.F4,KeyModifier.CTRL)
    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:26,代码来源:client_FundsNew.py


示例5: fSetup_SplitBills

def fSetup_SplitBills():
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("setup split")
    logging.debug('- set up split bills')

    myTools.getFocus()

    # open split billing rule list
    type("b",KeyModifier.ALT)
    time.sleep(1)
    type("i")
    time.sleep(1)

    fSetup_Primary("Beverly")

    # new secondary
    myTools.pressTAB(7)   
    fSetup_Secondary("Peabody",15)
    fSetup_Secondary("Saugus",20)

    # done
    myTools.pressTAB(4)
    type(Key.SPACE)

    myTools.sectionEndTimeStamp()
    backup_Data.fBackup_Checkpoint("split")    
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:27,代码来源:bill_Split.py


示例6: fEdit_Client

def fEdit_Client():
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("edit client")
    logging.debug('Edit_Client')

    # make sure timeslips has focus
    myTools.getFocus()

    fEdit_CliGenInfo()
    fEdit_CliCustom()
    fEdit_CliRatesNotes()

    logging.debug('- save')
    type("s",KeyModifier.CTRL)
    time.sleep(1)

    fEdit_DefaultRates()
    fEdit_InterestSetting()

    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1) 
    type(Key.F4,KeyModifier.CTRL)

    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:25,代码来源:client_Edit.py


示例7: fPrint_FeeAllocPer

def fPrint_FeeAllocPer(pReportMonth,pRepExt):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("print FeeAllocPer")

    # name report file: ex: PreBill-03
    reportName = myTools.buildRepName("FeeAllocPer",pRepExt)
    logging.debug('Print_FeeAllocPer: ' + reportName)

    # make sure timeslips has focus
    myTools.getFocus()

    logging.debug('- open FeeAllocPer')
    type("r",KeyModifier.ALT)
    type("t")
    time.sleep(1)
    myTools.pressDOWN(3)
    time.sleep(1)    

    # choose csv
    myTools.pressSHIFTTAB(2)
    type("c")
    time.sleep(1)

    myTools.enterCurrentMonthOnList(pReportMonth)

    # print the report
    type(Key.ENTER)    
    time.sleep(1)

    myTools.finishReport(reportName)
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:31,代码来源:report_FeeAllocPer.py


示例8: fCreate_Discounts

def fCreate_Discounts(pMonth):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("discounts" + str(pMonth))
    logging.debug('fCreate_Discounts: ' + str(pMonth))

    # list the client that will get a refund each month
    discountClients = ["Natick","Orange","Oakham","Oak Bluffs","Southampton","Otis","Oxford","Leyden","Monroe","Monson","Methuen","Uxbridge"]
    oneClient = discountClients[(pMonth - 1)]

    myTools.getFocus()

    # open a/r tran list
    type("t",KeyModifier.CTRL)
    myTools.waitForTransList()

    discountAmount = 49 + pMonth/float(100)
    fCreate_OneDiscount(oneClient,pMonth,discountAmount)

    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1) 
    type(Key.F4,KeyModifier.CTRL)
    
    myTools.sectionEndTimeStamp()
    myTools.checkProcesses()
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:25,代码来源:trans_Discounts.py


示例9: fCreate_Categories

def fCreate_Categories():
    # ---------------------------------------------------#

    myTools.sectionStartTimeStamp("categories")

    logging.debug("fCreate_Categories")

    # make sure timeslips has focus
    myTools.getFocus()

    logging.debug("- open category list")
    type("p", KeyModifier.ALT)

    # hot keys changed for TS2014
    if int(Settings.tsVersion) < 2014:
        type("i")
    else:
        type("o")
    time.sleep(1)

    for category in ["Construction", "General", "Landscape", "Hardware", "Supplies", "Materials", "Other"]:
        logging.debug("-- create: " + category)
        type("n", KeyModifier.ALT)
        type(category)
        type(Key.ENTER)

    logging.debug("- close list")
    myTools.pressTAB(4)
    type(Key.ENTER)

    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:31,代码来源:settings_Categories.py


示例10: fCreate_FinanceCharges

def fCreate_FinanceCharges(pMonth):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("finance" + str(pMonth))
    logging.debug('Create_FinanceCharges: ' + str(pMonth))

    allClients = names_Init.fInit_Clients()
    count = 0

    myTools.getFocus()

    # client list
    type("i",KeyModifier.CTRL)

    for oneClient in allClients:
        count += 1
        
        # always create finance charge for first 5 clients 
        # then create finance charge for 1 out of 35 next clients
        
        if (count in range(6)) or ((count + pMonth) % 35 == 0):
            financeCharge = str(count) + ".99"            
            fCreate_OneFinanceCharge(oneClient,count,pMonth,financeCharge)
        else:
            logging.debug('-- skip: ' + str(pMonth) + "-" + oneClient)

    type(Key.F4,KeyModifier.CTRL)
    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:28,代码来源:client_FinanceCharges.py


示例11: fBill_BillFields

def fBill_BillFields():
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("bill fields")
    logging.debug("fBill_BillFields")    

    buName = Settings.tsVersion + "-bill-12b"
    backup_Data.fRestore_Backup(buName)

    reportName = "BillFields-13-" + Settings.tsVersion + ".txt"

    myTools.getFocus()                                # make sure timeslips has focus

    if int(Settings.tsVersion) < 2016:                # to get around a defect in pre-2016
        type("i",KeyModifier.CTRL)                    # open client info and close it to load custom fields
        time.sleep(1)
        type("o",KeyModifier.CTRL)
        time.sleep(1)
        type(Key.F4,KeyModifier.CTRL)
        time.sleep(1)
        type(Key.F4,KeyModifier.CTRL)
    
    bill_ImportLayout.fImport_BillLayout("Fields")    # import the layout    
    fSet_BillDate(12)                                 # set billing data to 12/27 for text bills 
    fPrint_BillsToText(reportName)                    # print all bills to one text file
    reports_Compare.Compare_OneReport(reportName)

    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:28,代码来源:bill_BillFields.py


示例12: fCreate_Writeoffs

def fCreate_Writeoffs(pMonth):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("writeoffs" + str(pMonth))
    logging.debug('Create_Writeoffs: ' + str(pMonth))

    count = 0

    myTools.getFocus()

    # open a/r tran list
    type("t",KeyModifier.CTRL)
    myTools.waitForTransList()

    clientList = ["Blackstone","Carver"]
    for woClient in clientList:    
        count += 1
        if woClient == "Blackstone":
            woAmount = 2
        else:
            woAmount = 3
            
        woAmount = woAmount + pMonth/float(100)            
        fCreate_OneWriteOff(woClient,count,pMonth,woAmount)

    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1) 
    type(Key.F4,KeyModifier.CTRL)
    
    myTools.sectionEndTimeStamp()
    myTools.checkProcesses()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:31,代码来源:trans_Writeoff.py


示例13: fBudget_Setup

def fBudget_Setup():
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("budgets")
    logging.debug('budgets')
    
    myTools.getFocus()

    # open budget setup
    type("n", KeyModifier.ALT)
    type("b")
    time.sleep(1)    

    if (int(Settings.tsVersion) > 2016) and (Settings.tsDB == "PREM"):
        fTimekeeperBudget_New()
        fClientBudget_New()
        fFirmBudget_New()        
    else:
        fTimekeeperBudget()
        fClientBudget()
        fFirmBudget()

    type(Key.F4,KeyModifier.CTRL)
    
    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:25,代码来源:budget_Setup.py


示例14: fCreate_Refunds

def fCreate_Refunds(pMonth):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("refunds" + str(pMonth))
    logging.debug('fCreate_Refunds: ' + str(pMonth))

    # list the client that will get a refund each month
    refundClients = ["Hawley","Haverhill","Hatfield","Harwich","Harvard","Hawley","Haverhill","Hatfield","Harwich","Harvard","Hawley","Haverhill"]
    oneClient = refundClients[(pMonth - 1)]

    myTools.getFocus()

    # open a/r tran list
    type("t",KeyModifier.CTRL)
    myTools.waitForTransList()

    refundAmount = 99 + pMonth/float(100)        
    fCreate_OneRefund(oneClient,pMonth,refundAmount)

    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1) 
    type(Key.F4,KeyModifier.CTRL)
    
    myTools.sectionEndTimeStamp()
    myTools.checkProcesses()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:25,代码来源:trans_Refunds.py


示例15: fCreate_Transfers

def fCreate_Transfers(pMonth):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("transfers" + str(pMonth))
    logging.debug('Create_Transfers: ' + str(pMonth))

    allClients = ["East.Bridgewater","North.Adams","West.Boylston"]
    count = 0

    myTools.getFocus()

    # open a/r tran list
    type("t",KeyModifier.CTRL)
    myTools.waitForTransList()

    for oneClient in allClients:
        count += 1
        transferAmount = 10 + int(count) + pMonth/float(100)        
        fCreate_OneTransfer(oneClient,count,pMonth,transferAmount)

    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1) 
    type(Key.F4,KeyModifier.CTRL)
    
    myTools.sectionEndTimeStamp()
    myTools.checkProcesses()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:26,代码来源:trans_Transfers.py


示例16: fSetup_InvoiceListing

def fSetup_InvoiceListing():
    # ---------------------------------------------------#

    logging.debug("- set up invlist")

    myTools.getFocus()
    type("r", KeyModifier.ALT)
    type("a")
    time.sleep(1)
    type("i")
    time.sleep(1)

    myTools.removeDateAndTime()

    type(Key.F4, KeyModifier.CTRL)
    time.sleep(1)
    type("y")
    time.sleep(1)

    # open report
    type("o", KeyModifier.CTRL)
    # add invoice number sort
    type(Key.F6)
    time.sleep(1)
    myTools.pressTAB(2)
    time.sleep(1)
    type(Key.SPACE)

    # close and save report
    type(Key.F4, KeyModifier.CTRL)
    time.sleep(1)
    type("y")
    time.sleep(1)
    type(Key.F4, KeyModifier.CTRL)
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:34,代码来源:report_InvoiceListing.py


示例17: fPrint_SlipListCalc

def fPrint_SlipListCalc(pReportMonth,pRepExt):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("print slipcalcs")

    # name report file: ex: UDSlip1-03
    reportName = myTools.buildRepName("UDSCalc",pRepExt)
    logging.debug('Print_UDSCalc: ' + reportName)
    myTools.getFocus()

    logging.debug('- open report list')
    type("r",KeyModifier.ALT)
    type("s")
    time.sleep(1)

    logging.debug('- choose report')
    type("uds c")
    time.sleep(1)

#    fSort_SlipReportFields()
    fChoose_CSV_Print(reportName)
    myTools.waitForReport()
    reports_Compare.Compare_OneReport(reportName)

    # close the report
    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1)
    type("n")
    type(Key.F4,KeyModifier.CTRL)

    myTools.sectionEndTimeStamp()
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:31,代码来源:report_UDSlip.py


示例18: fPrint_ARwRunBal

def fPrint_ARwRunBal(pReportMonth,pRepExt):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("print ARwRunBal")

    # name report file: ex: UDSlip1-03
    reportName = myTools.buildRepName("ARwRunBal",pRepExt)
    logging.debug('fPrint_ARwRunBal: ' + reportName)
    myTools.getFocus()

    logging.debug('- open report list')
    type("r",KeyModifier.ALT)
    type("a")
    time.sleep(1)

    logging.debug('- choose report')
    myTools.pressDOWN(2)
    time.sleep(1)

    # choose txt
    myTools.pressSHIFTTAB(2)
    time.sleep(1)
    type("t")
    time.sleep(1)

    myTools.enterCurrentMonthOnList(pReportMonth)

    # print the report
    type(Key.ENTER)    
    time.sleep(1)

    myTools.finishReport(reportName)
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:32,代码来源:report_ARwRunBal.py


示例19: fCreate_TransfersToFunds

def fCreate_TransfersToFunds(pMonth):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("transfer funds" + str(pMonth))
    logging.debug('Create_TransfersFunds: ' + str(pMonth))

    allClients = ["East.Brookfield","North.Andover","West.Bridgewater"]
    count = 0

    myTools.getFocus()

    # open a/r tran list
    type("t",KeyModifier.CTRL)
    myTools.waitForTransList()

    for oneClient in allClients:
        count += 1
        fCreate_OneFundsTransfer(oneClient,count,pMonth)

    type(Key.F4,KeyModifier.CTRL)
    time.sleep(1)
    type(Key.F4,KeyModifier.CTRL)
    
    myTools.sectionEndTimeStamp()
    myTools.checkProcesses()
开发者ID:gh-tomhinds,项目名称:ConfirmDataEntry,代码行数:25,代码来源:trans_TransfersToFunds.py


示例20: fPrint_FlatFee

def fPrint_FlatFee(pReportMonth,pRepExt):
#---------------------------------------------------#

    myTools.sectionStartTimeStamp("print FlatFee")

    # name report file: ex: ARAgedBal-03
    reportName = myTools.buildRepName("FlatFee",pRepExt)    
    logging.debug('Print_FlatFee: ' + reportName)

    # make sure timeslips has focus
    myTools.getFocus()

    logging.debug('- open report')
    type("r",KeyModifier.ALT)
    type("c")
    time.sleep(1)
    type("f")
    time.sleep(1)

    # move to Print To and choose CSV
    myTools.pressSHIFTTAB(2)
    time.sleep(1)
    type("c")

    # print the report
    type(Key.ENTER)    
    time.sleep(1)

    myTools.finishReport(reportName)
开发者ID:gh-tomhinds,项目名称:Test_It_All,代码行数:29,代码来源:report_FlatFee.py



注:本文中的myTools.getFocus函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Python myTools.pressDOWN函数代码示例发布时间:2022-05-27
下一篇:
Python myTools.deal_with_plot函数代码示例发布时间:2022-05-27
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap