Пример #1
0
 def test_asset_update_issuer(self):
     self.op = operations.Asset_update_issuer(
         **{
             "fee": {
                 "amount": 0,
                 "asset_id": "1.3.0"
             },
             "issuer": "1.2.0",
             "asset_to_update": "1.3.0",
             "new_issuer": "1.2.1",
             "extensions": [],
         })
     self.cm = ("f68585abf4dce7c804570130000000000000000000000001000"
                "001207d24b86eb3e6ae1de872829223d205123aaf2c5d11eab4"
                "6d8a80dbe83a42af03687cd3c43a5dd1d7f4d7a7b5afdf8d69c"
                "42acf9224354b1af7d81bd556724a43")
     self.doit()
Пример #2
0
    def change_issuer(self, new_issuer, **kwargs):
        """
        Change asset issuer (needs signing with owner key!)

        :param str new_issuer: account name
        """
        from .account import Account

        new_issuer = Account(new_issuer, blockchain_instance=self.blockchain)
        op = operations.Asset_update_issuer(
            **{
                "fee": {"amount": 0, "asset_id": "1.3.0"},
                "issuer": self["issuer"],
                "asset_to_update": self["id"],
                "new_issuer": new_issuer["id"],
                "extensions": [],
            }
        )
        return self.blockchain.finalizeOp(op, self["issuer"], "owner", **kwargs)
Пример #3
0
    def change_issuer(self, new_issuer, **kwargs):
        """ Change asset issuer (needs signing with owner key!)

            :param str type: ``blacklist`` or ``whitelist``
            :param list authorities: List of authorities (Accounts)
        """
        from .account import Account

        new_issuer = Account(new_issuer)
        op = operations.Asset_update_issuer(
            **{
                "fee": {
                    "amount": 0,
                    "asset_id": "1.3.0"
                },
                "issuer": self["issuer"],
                "asset_to_update": self["id"],
                "new_issuer": new_issuer["id"],
                "extensions": [],
            })
        return self.blockchain.finalizeOp(op, self["issuer"], "owner",
                                          **kwargs)