0

I want to get the list of all active offline payment methods like cashondelivery, checkmo, banktransfer etc. in magento2.2

Can anyone help me out?

Thanks in advance.

Suman
  • 239
  • 2
  • 13
  • Please provide some more details about your problem and about what you've tried so far. From where do you want to read the payment methods? – sissy Feb 08 '18 at 09:37
  • I have created a custom module which allow sales representatives ( frontend user with different customer group id ) to place order from their account for any customer. I just want to allow them to use only offline payment methods like cashondelivery, checkmo, banktransfer etc. So I want the list of offline payment methods. – Suman Feb 08 '18 at 10:10
  • Ok, so these users are creating the orders from the backend? What I still do not understand is what you mean with "Active offline". Payment methods can be only enabled/disabled so they're shown or not throughout frontend and backend. I think you have to enable all the methods you want available for your special users and then filter out which you do not want enabled for normal users in the frontend. Isn't it? – sissy Feb 08 '18 at 10:34
  • As I saids they are frontend user mean customers with different customer group ( like sales representatives ) . They are placing the orders from frontend for other customers with different customer group. "Active offline" mean the payment methods which payment group are offline and also enabled. I have the total enabled payment methods list. I just need to filter those payment which groups are offline. Hope it make sense. Thanks – Suman Feb 08 '18 at 11:18
  • Oh sorry, I didn't read read well they're placing order from frontend. ok, so the offline is referred to the group of people. well you should just check to what group of users belongs the logged in user and filter out the payment methods. Otherwise if they're all enabled and you do not put any check in the payment phase, everybody would see ALL the payment methods. Right? – sissy Feb 08 '18 at 11:43

0 Answers0