Exemple #1
0
    def test_xhd_12_contract_signing(self):
        """签约"""

        rec_bank_info = dict(
            recBankNum=self.data['houseCommonLoanInfoList'][0]['recBankNum'],
            recPhone=self.data['houseCommonLoanInfoList'][0]['recPhone'],
            recBankProvince=self.data['houseCommonLoanInfoList'][0]
            ['recBankProvince'],
            recBankDistrict=self.data['houseCommonLoanInfoList'][0]
            ['recBankDistrict'],
            recBank=self.data['houseCommonLoanInfoList'][0]['recBank'],
            recBankBranch=self.data['houseCommonLoanInfoList'][0]
            ['recBankBranch'],
        )

        # 获取合同打印专员ID
        self.test_xhd_11_manager_approval()
        self.case_name = custom.get_current_function_name()
        # 下一个处理人重新登录
        page = Login(self.next_user_id)

        # 签约
        rc = Cts.ContractSign(page, self.apply_code, rec_bank_info)
        rs = rc.execute_enter_borroers_bank_info()
        if not rs:
            self.run_result = False
            self.log.error("签约失败")
            raise AssertionError('签约失败')
        else:
            rc.contract_submit()
            self.log.info("签约成功")

        # 查看下一步处理人
        self.next_user_id = common.get_next_user(page, self.apply_code)
Exemple #2
0
	def test_02_2Person_contract(self):
		"""双人签约"""
		try:
			# 贷款金额
			self.update_product_amount(400000)
			self.before_contract_sign(400000)
			self.case_name = custom.get_current_function_name()
			
			Cts.ContractSign(self.page, self.apply_code, self.rec_bank_info, 2).execute_enter_borroers_bank_info()
		except Exception as e:
			self.run_result = False
			raise e
Exemple #3
0
	def test_01_1person_contract(self):
		"""单人签约"""
		self.case_name = custom.get_current_function_name()
		try:
			self.before_contract_sign(200000)
			
			rc = Cts.ContractSign(self.page, self.apply_code, self.rec_bank_info)
			res = rc.execute_enter_borroers_bank_info()
			if res:
				rc.contract_submit()
		except Exception as e:
			self.run_result = False
			raise e
Exemple #4
0
    def test_02_delete_contract_sign(self):
        """删除电子签约"""
        self.case_name = custom.get_current_function_name()
        try:
            # 1. 签约
            self.test_01_contract_sgin()

            # 2. 删除
            page = login.Login(self.next_user_id)
            # 删除电子签章
            rs = Cts.ContractSign(page, self.apply_code, self.rec_bank_info)
            rs.delete_contract_sign(page, self.apply_code)
            page.driver.quit()
        except Exception as e:
            self.run_result = False
            raise e
Exemple #5
0
    def test_cwd_12_contract_signing(self):
        """签约"""

        rec_bank_info = dict(
            recBankNum=self.data['houseCommonLoanInfoList'][0]['recBankNum'],
            recPhone=self.data['houseCommonLoanInfoList'][0]['recPhone'],
            recBankProvince=self.data['houseCommonLoanInfoList'][0]
            ['recBankProvince'],
            recBankDistrict=self.data['houseCommonLoanInfoList'][0]
            ['recBankDistrict'],
            recBank=self.data['houseCommonLoanInfoList'][0]['recBank'],
            recBankBranch=self.data['houseCommonLoanInfoList'][0]
            ['recBankBranch'],
        )

        # 获取合同打印专员ID
        self.test_cwd_11_manager_approval()
        self.case_name = custom.get_current_function_name()
        # 下一个处理人重新登录
        page = Login(self.next_user_id)

        # 签约
        rc = Cts.ContractSign(page, self.apply_code, rec_bank_info)
        res = rc.execute_enter_borroers_bank_info()
        if res:
            rc.contract_submit()

        # 查看下一步处理人
        res = self.PM.process_monitor(page, self.apply_code)
        if not res:
            self.run_result = False
            self.log.error("Can't found next User!")
        else:
            self.next_user_id = res
            self.log.info("合同打印完成")
            self.log.info("Next deal User:" + self.next_user_id)
            # 当前用户退出系统
            self.page.driver.quit()
    def test_random_product_12_contract_signing(self):
        """签约"""

        # 收款银行信息
        rec_bank_info = dict(
            recBankNum='6210302082441017886',
            recPhone='13686467482',
            recBankProvince=u'湖南省',
            recBankDistrict=u'长沙',
            recBank=u'中国农业银行',
            recBankBranch=u'北京支行',
        )

        try:
            # 获取合同打印专员ID
            self.test_random_product_11_manager_approval()
            self.case_name = custom.get_current_function_name()
            # 下一个处理人重新登录
            page = Login(self.next_user_id)
            # 签约
            rc = Cts.ContractSign(page, self.apply_code, rec_bank_info)
            res = rc.execute_enter_borroers_bank_info()
            # if res:
            # 	rc.contract_submit()

            # 查看下一步处理人
            res = self.PM.process_monitor(page, self.apply_code)
            if not res:
                raise AssertionError('没有找到下一个处理人')
            else:
                self.next_user_id = res
                self.log.info("下一个处理人: " + self.next_user_id)
                # 当前用户退出系统
                page.driver.quit()
        except Exception as e:
            self.run_result = False
            raise e
Exemple #7
0
    def test_01_contract_sgin(self):
        """电子签约"""

        self.case_name = custom.get_current_function_name()
        try:
            # 1. 签约前步骤
            self.before_contract_sign()

            # 2. 获取短信验证码
            execmd = \
             ' cd /web/apache-tomcat-7.0.69/logs; tail -10 catalina.out  > 1.txt ; ' \
             'cat 1.txt | grep "短信" | awk -F"验证码:" \'{print $2}\' ' \
             '| awk -F\',\' \'{print $1}\' | tail -1'

            # ssh.sshclient_execmd(self.host_ip, self.port, self.host_name, self.host_password, cmd)

            # 3. 短信签约
            rs = Cts.ContractSign(self.page, self.apply_code,
                                  self.rec_bank_info)
            rs.send_message(self.host_ip, self.port, self.host_name,
                            self.host_password, execmd)
        except Exception as e:
            self.run_result = False
            raise e
    def test_08_compliance_Officer_original(self):
        """合规审查员上传影像资料"""

        try:
            self.case_name = custom.get_current_function_name()
            self.update_product_amount(2000000)
            # ---------------------------------------------------------------------------------
            #                   1. 申请录入
            # ---------------------------------------------------------------------------------

            # 1 客户信息-业务基本信息
            if self.HAE.input_customer_base_info(self.page,
                                                 self.data['applyVo']):
                self.log.info("录入基本信息完成")

            # 2 客户基本信息 - 借款人/共贷人/担保人信息
            self.HAE.input_customer_borrow_info(self.page,
                                                self.data['custInfoVo'][0])

            # 3 物业信息
            self.HAE.input_all_bbi_property_info(
                self.page, self.data['applyPropertyInfoVo'][0],
                self.data['applyCustCreditInfoVo'][0], self.cust_name)
            # 提交
            self.HAE.submit(self.page)
            self.log.info("申请件录入完成提交")

            apply_code = self.AQ.get_applycode(self.page, self.cust_name)
            if apply_code:
                self.apply_code = apply_code
                self.log.info("申请件查询完成")
                print("apply_code:" + self.apply_code)
            # 流程监控
            self.next_user_id = common.get_next_user(self.page,
                                                     self.apply_code)

            # ---------------------------------------------------------------------------------------
            # 	                        2. 风控审批流程
            # ---------------------------------------------------------------------------------------

            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            list_mark = ["分公司主管审批", "分公司经理审批", "区域预复核审批", "高级审批经理审批", "风控总监审批"]

            for e in list_mark:
                res = self.PT.approval_to_review(page, apply_code, e, 0)
                self.risk_approval_result(res, e, page, apply_code)
                # 下一个处理人重新登录
                page = Login(self.next_user_id)

            # -----------------------------------------------------------------------------
            # 	                        3. 合同打印
            # -----------------------------------------------------------------------------

            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            res = ContractSign.ContractSign(page, self.apply_code,
                                            self.rec_bank_info, 10)
            res.execute_enter_borroers_bank_info()
            res.contract_submit()

            self.next_user_id = common.get_next_user(page, self.apply_code)

            # 合规审查
            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            # 合规审查, 并上传影像资料
            res = self.PT.compliance_audit(page, self.apply_code, True)
            if res:
                self.log.info("合规审批结束")
                page.driver.quit()
            else:
                self.run_result = False
                self.log.error("合规审查失败")
                raise ValueError("合规审查失败")
        except Exception as e:
            self.run_result = False
            raise e
Exemple #9
0
    def test_01_specail_part_raise(self):
        """第一次全额请款,第二次为0"""
        self.case_name = custom.get_current_function_name()
        # ------------合同打印-------------
        try:
            self.before_contract_sign(200000)
            rc = Cts.ContractSign(self.page, self.apply_code,
                                  self.rec_bank_info)
            res = rc.execute_enter_borroers_bank_info()
            if res:
                rc.contract_submit()  # 提交
        except Exception as e:
            self.run_result = False
            raise e
        self.next_user_id = common.get_next_user(self.page, self.apply_code)

        # ------------合规审查------------------
        # 下一个处理人重新登录
        page = Login(self.next_user_id)

        # 合规审查
        res = self.PT.compliance_audit(page, self.apply_code)
        if res:
            self.log.info("合规审批结束")
            page.driver.quit()
        else:
            raise ValueError("合规审查失败")

        # ------------权证办理----------------
        page = Login(self.company["authority_member"]["user"])
        # 权证员上传权证信息
        res = self.WM.authority_card_transact_2(page, self.apply_code, 1,
                                                self.env)
        if not res:
            raise ValueError("上传权证资料失败")
        else:
            self.log.info("权证办理完成")
            self.next_user_id = common.get_next_user(page, self.apply_code)

        # ------------权证请款----------------
        # 下一个处理人重新登录
        page = Login(self.next_user_id)
        # 部分请款
        res = self.PT.part_warrant_apply(page, self.apply_code, 0)
        if not res:
            raise AssertionError('权证请款失败!')
        else:
            self.log.info("完成权证请款")
            self.next_user_id = common.get_next_user(page, self.apply_code)

        # 权证审批流程
        roles = ['回执分公司主管', '回执审批经理审批', '回执业务助理处理']

        for i in roles:
            page = Login(self.next_user_id)
            rec = self.PT.receipt_return(page, self.apply_code)
            if not rec:
                self.log.error(i + "审批失败")
                raise ValueError('失败')
            else:
                self.log.info(i + "审批通过")
                self.next_user_id = common.get_next_user(page, self.apply_code)

        # ------------财务流程----------------------
        page = Login(self.company["business_assistant"]["user"])
        rs = self.FA.finace_transact(page, self.apply_code)
        if not rs:
            self.log.error("财务办理失败")
            raise AssertionError('财务办理失败')
        else:
            self.log.info("财务办理结束!")
        # 查看下一步处理人
        self.next_user_id = common.get_next_user(page, self.apply_code, 1)

        role2 = ['分公司经理审', '风控经理', '财务会计', '财务经理']

        for e in role2:
            self.case_name = custom.get_current_function_name()
            page = Login(self.next_user_id)
            result = self.FA.finace_approval(page, self.apply_code, e + '审批通过')
            if not result:
                raise AssertionError(e + '审批失败')
            # 查看下一步处理人
            self.next_user_id = common.get_next_user(page, self.apply_code, 1)

        # ----------发起募资-----------------------------
        page = Login(self.treasurer)
        res = self.RA.funds_raise(page, self.apply_code, '第一次资金主管募资发起')
        if not res:
            self.log.error("募资-资金主管审批失败")
            raise AssertionError('募资-资金主管审批失败')
        else:
            self.log.info("募资-资金主管审批完成!")
            page.driver.quit()

        # 修改数据表为放款成功!
        db = database.DB()

        sql_1 = "UPDATE house_common_loan_info t SET t.pay_date=sysdate, t.status='LOAN_PASS' \
				WHERE t.apply_id= (SELECT t.apply_id FROM house_apply_info t \
				WHERE t.apply_code =" + "'" + self.apply_code + "'" + ")"

        contract_no = self.apply_code + '-3-02-1'

        sql_2 = "UPDATE house_funds_info t SET t.Funds_Status = 21  \
				WHERE t.apply_id = (SELECT t.apply_id FROM house_apply_info t \
				WHERE t.apply_code = " + "'" + self.apply_code + "'" + ")" + "AND CONTRACT_NO =" + "'" + contract_no + "'"

        db.sql_execute(sql_1)
        db.sql_execute(sql_2)
        db.sql_commit()
        time.sleep(3)

        # ----------第二次权证办理-----------------------------

        page = Login(self.company["authority_member"]["user"])
        # 权证员上传权证信息
        res = self.WM.authority_card_transact_2(page, self.apply_code, 2,
                                                self.env)
        if not res:
            self.log.error("上传权证资料失败")
            raise ValueError("上传权证资料失败")
        else:
            self.log.info("权证办理完成")
            self.next_user_id = common.get_next_user(page, self.apply_code)

        # ---------第二次权证请款--------------------------------
        # 下一个处理人重新登录
        page = Login(self.next_user_id)

        # 第二次请款金额为0
        res = self.PT.part_warrant_apply(page, self.apply_code, 2)
        if not res:
            raise ValueError('第二次权证请款金额为0请款流程出错!')
        else:
            self.log.info("第二次权证请款金额为0请款流程ok!")
        self.next_user_id = common.get_next_user(page, self.apply_code)
        page.driver.quit()

        # --------------------------回执审批流程---------------------
        page = Login(self.next_user_id)
        rec = self.PT.receipt_return(page, self.apply_code)
        if not rec:
            self.log.error("审批失败")
            raise ValueError('失败')
        else:

            self.log.info("审批通过,放款成功")
            page.driver.quit()
Exemple #10
0
    def test_01_part_receipt_director_approval(self):
        """400000元部分请款,回执分公司主管审批"""

        # ---------------------------------------------------------------------------------
        #                   1. 申请录入
        # ---------------------------------------------------------------------------------
        self.case_name = custom.get_current_function_name()
        self.update_product_amount(400000)

        # 1 客户信息-业务基本信息

        try:
            # 打印贷款产品信息
            custom.print_product_info(self.product_info)
            if self.company['branchName'] not in product.product_city:
                # 非渠道城市进件
                self.HAE.input_customer_base_info(self.page,
                                                  self.data['applyVo'])
            else:
                # 渠道城市新产品
                self.HAE.input_customer_base_info(self.page,
                                                  self.data['applyVo'], True)
        except Exception as e:
            self.run_result = False
            raise e

        # 2 客户基本信息 - 借款人/共贷人/担保人信息
        self.HAE.input_customer_borrow_info(self.page,
                                            self.data['custInfoVo'][0])

        # 3 物业信息
        self.HAE.input_all_bbi_property_info(
            self.page, self.data['applyPropertyInfoVo'][0],
            self.data['applyCustCreditInfoVo'][0], self.cust_name)
        # 提交
        self.HAE.submit(self.page)
        self.log.info("申请件录入完成提交")

        apply_code = self.AQ.get_applycode(self.page, self.cust_name)
        if apply_code:
            self.apply_code = apply_code
            self.log.info("申请件查询完成")
            print("apply_code:" + self.apply_code)
        # 流程监控
        result = self.PM.process_monitor(self.page, apply_code)
        if result is not None:
            self.next_user_id = result
            self.log.info("完成流程监控查询")
        else:
            raise ValueError("流程监控查询出错!")

        # ---------------------------------------------------------------------------------------
        # 	                        2. 风控审批流程
        # ---------------------------------------------------------------------------------------

        # 下一个处理人重新登录
        page = Login(self.next_user_id)

        list_mark = [
            "分公司主管审批",
            "分公司经理审批",
            "区域预复核审批",
            # "高级审批经理审批"
        ]

        for e in list_mark:
            res = self.PT.approval_to_review(page, apply_code, e, 0)
            self.risk_approval_result(res, e, page, apply_code)
            # 下一个处理人重新登录
            page = Login(self.next_user_id)

        if self.next_user_id == self.senior_manager:
            res = self.PT.approval_to_review(page, apply_code, '高级审批经理', 0)
            self.risk_approval_result(res, '高级审批经理', page, apply_code)

            page = Login(self.next_user_id)
            # 两个人签约
            rc = Cts.ContractSign(page, self.apply_code, self.rec_bank_info, 2)
            res = rc.execute_enter_borroers_bank_info()
            if res:
                rc.contract_submit()
                self.log.info("合同打印完成!")
                # 查看下一步处理人
                self.next_user_id = common.get_next_user(page, apply_code)

            # -----------------------------------------------------------------------------
            #                                合规审查
            # -----------------------------------------------------------------------------
            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            # 合规审查
            res = self.PT.compliance_audit(page, self.apply_code)
            if res:
                self.log.info("合规审批结束")
                page.driver.quit()
            else:
                self.log.error("合规审查失败")
                raise ValueError("合规审查失败")

            # -----------------------------------------------------------------------------
            #                                权证办理
            # -----------------------------------------------------------------------------
            page = Login(self.company["authority_member"]["user"])
            # 权证员上传权证信息
            res = self.WM.authority_card_transact_2(page, self.apply_code, 1,
                                                    self.env)
            if not res:
                self.log.error("上传权证资料失败")
                raise ValueError("上传权证资料失败")
            else:
                self.log.info("权证办理完成")
                self.next_user_id = common.get_next_user(page, self.apply_code)

            # -----------------------------------------------------------------------------
            #                                权证请款
            # -----------------------------------------------------------------------------
            # 下一个处理人重新登录
            page = Login(self.next_user_id)
            # 部分请款
            res = self.PT.part_warrant_apply(page, self.apply_code)
            if not res:
                self.log.error("权证请款失败!")
                raise ValueError('权证请款失败!')
            else:
                self.log.info("完成权证请款")
                self.next_user_id = common.get_next_user(page, self.apply_code)

            # -----------------------------------------------------------------------------
            #                                回执提放审批审核,回执分公司主管审批
            # -----------------------------------------------------------------------------
            page = Login(self.next_user_id)
            rec = self.PT.receipt_return(page, self.apply_code)
            if not rec:
                self.log.error("回执分公司主管审批失败")
                raise ValueError('失败')
            else:
                self.log.info("回执分公司主管审批通过")
                self.next_user_id = common.get_next_user(page, self.apply_code)

        else:

            # 两个人签约
            rc = Cts.ContractSign(page, self.apply_code, self.rec_bank_info, 2)
            res = rc.execute_enter_borroers_bank_info()
            if res:
                rc.contract_submit()
                self.log.info("合同打印完成!")
                # 查看下一步处理人
                self.next_user_id = common.get_next_user(page, apply_code)

            # -----------------------------------------------------------------------------
            #                                合规审查
            # -----------------------------------------------------------------------------
            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            # 合规审查
            res = self.PT.compliance_audit(page, self.apply_code)
            if res:
                self.log.info("合规审批结束")
                page.driver.quit()
            else:
                self.log.error("合规审查失败")
                raise ValueError("合规审查失败")

            # -----------------------------------------------------------------------------
            #                                权证办理
            # -----------------------------------------------------------------------------
            page = Login(self.company["authority_member"]["user"])
            # 权证员上传权证信息
            res = self.WM.authority_card_transact_2(page, self.apply_code, 1,
                                                    self.env)
            if not res:
                self.log.error("上传权证资料失败")
                raise ValueError("上传权证资料失败")
            else:
                self.log.info("权证办理完成")
                self.next_user_id = common.get_next_user(page, self.apply_code)

            # -----------------------------------------------------------------------------
            #                                权证请款
            # -----------------------------------------------------------------------------
            # 下一个处理人重新登录
            page = Login(self.next_user_id)
            # 部分请款
            res = self.PT.part_warrant_apply(page, self.apply_code)
            if not res:
                self.log.error("权证请款失败!")
                raise ValueError('权证请款失败!')
            else:
                self.log.info("完成权证请款")
                self.next_user_id = common.get_next_user(page, self.apply_code)

            # -----------------------------------------------------------------------------
            #                                回执提放审批审核,回执分公司主管审批
            # -----------------------------------------------------------------------------
            page = Login(self.next_user_id)
            rec = self.PT.receipt_return(page, self.apply_code)
            if not rec:
                self.log.error("回执分公司主管审批失败")
                raise ValueError('失败')
            else:
                self.log.info("回执分公司主管审批通过")
                self.next_user_id = common.get_next_user(page, self.apply_code)
Exemple #11
0
    def test_01_warrantManage_original(self):
        """权证原件请款"""
        self.case_name = custom.get_current_function_name()
        try:
            self.update_product_amount(2000000)
            # 1. 申请录入
            self.before_application_entry()
            # 2. 风控审批
            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            list_mark = ["分公司主管审批", "分公司经理审批", "区域预复核审批", "高级审批经理审批", "风控总监审批"]

            count = 0
            for e in list_mark:
                if count == 3:
                    if self.next_user_id != self.senior_manager:
                        continue
                res = self.PT.approval_to_review(page, self.apply_code, e, 0)
                self.risk_approval_result(res, e, page, self.apply_code)
                # 下一个处理人重新登录
                page = Login(self.next_user_id)
                count = count + 1

            # -----------------------------------------------------------------------------
            # 	                        3. 合同打印
            # -----------------------------------------------------------------------------

            rc = ContractSign.ContractSign(page, self.apply_code,
                                           self.rec_bank_info, 10)
            res = rc.execute_enter_borroers_bank_info()
            if res:
                rc.contract_submit()

            self.next_user_id = common.get_next_user(page, self.apply_code)

            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            # 合规审查
            res = self.PT.compliance_audit(page, self.apply_code)
            if res:
                self.log.info("合规审批结束")
                page.driver.quit()
            else:
                self.run_result = False
                self.log.error("合规审查失败")
                raise ValueError("合规审查失败")

            # 权证办理
            # 权证员登录
            page = Login(self.company["authority_member"]["user"])
            # 权证员上传权证信息
            self.WM.authority_card_transact(page, self.apply_code, self.env)
            self.next_user_id = common.get_next_user(page, self.apply_code)

            page = Login(self.next_user_id)
            # 权证请款
            res = self.WM.warrant_apply(page, self.apply_code)
            if not res:
                self.run_result = False
                self.log.error("权证请款失败!")
                raise ValueError('权证请款失败!')
            else:
                self.log.info("完成权证请款")
                self.next_user_id = common.get_next_user(page, self.apply_code)
        except Exception as e:
            self.run_result = False
            raise e
Exemple #12
0
    def test_02_warrantManage_part(self):
        """部分权证请款"""
        self.case_name = custom.get_current_function_name()
        try:
            self.update_product_amount(400000)
            self.before_contract_sign()

            # -----------------------------------------------------------------------------
            # 	                        3. 合同打印
            # -----------------------------------------------------------------------------
            # next transcat person
            self.next_user_id = common.get_next_user(self.page,
                                                     self.apply_code)

            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            # 两个人签约
            rc = ContractSign.ContractSign(page, self.apply_code,
                                           self.rec_bank_info, 2)
            res = rc.execute_enter_borroers_bank_info()
            if res:
                rc.contract_submit()
                self.log.info("合同打印完成!")
                # 查看下一步处理人
                self.next_user_id = common.get_next_user(page, self.apply_code)

            # -----------------------------------------------------------------------------
            #                                合规审查
            # -----------------------------------------------------------------------------
            # 下一个处理人重新登录
            page = Login(self.next_user_id)

            # 合规审查
            res = self.PT.compliance_audit(page, self.apply_code)
            if res:
                self.log.info("合规审批结束")
                page.driver.quit()
            else:
                self.run_result = False
                self.log.error("合规审查失败")
                raise ValueError("合规审查失败")

            # -----------------------------------------------------------------------------
            #                                权证办理
            # -----------------------------------------------------------------------------
            page = Login(self.company["authority_member"]["user"])
            # 权证员上传权证信息
            res = self.WM.authority_card_transact(page, self.apply_code,
                                                  self.env)
            if not res:
                self.run_result = False
                self.log.error("上传权证资料失败")
                raise ValueError("上传权证资料失败")
            else:
                self.log.info("权证办理完成")
                self.next_user_id = common.get_next_user(page, self.apply_code)

            # -----------------------------------------------------------------------------
            #                                权证请款
            # -----------------------------------------------------------------------------
            # 下一个处理人重新登录
            page = Login(self.next_user_id)
            # 部分请款
            res = self.PT.part_warrant_apply(page, self.apply_code)
            if not res:
                self.run_result = False
                self.log.error("权证请款失败!")
                raise ValueError('权证请款失败!')
            else:
                self.log.info("完成权证请款")
                self.next_user_id = common.get_next_user(page, self.apply_code)

            # -----------------------------------------------------------------------------
            #                                回执提放审批审核,回执分公司主管审批
            # -----------------------------------------------------------------------------
            receipt_lst = ['回执分公司主管审批', '回执审批经理审批', '第一次回执放款申请']

            for i in receipt_lst:
                page = Login(self.next_user_id)
                rec = self.PT.receipt_return(page, self.apply_code)
                if not rec:
                    self.run_result = False
                    self.log.error(i + "失败")
                    raise ValueError(i + '失败')
                else:
                    self.log.info(i + "通过")
                    self.next_user_id = common.get_next_user(
                        page, self.apply_code)
        except Exception as e:
            self.run_result = False
            raise e