I'm looking for 2 addons for a site I'm working on.
1. Create Customers from admin
2. Assign Categories to Customers
Number 1 is pretty self explanatory, number 2 I would like to have some categories show to specific customers.
Before I start working on these does anyone know of anything similar that already exists?
Create customers in admin & assign categories to users
-
raiwa
- Certified Developer
- Posts: 1641
- Joined: Sat Dec 21, 2019 8:08 am
- Phoenix Version: 1.1.0.6
- : Buy Me A Beverage
- Has thanked: 70 times
- Been thanked: 152 times
Re: Create customers in admin & assign categories to users
1.: There was an addon in the old marketplace "Create Account & Manual Order Maker" which was linked to the old order editor. You could use the part of create account as a starting point.
2..: If you wish to assign categories to customer groups, it should be possible to extend my Wholesale addon to assign categories to wholesale group(s). If you need it for individual customers/different categories for each customer, it's not useful.
2..: If you wish to assign categories to customer groups, it should be possible to extend my Wholesale addon to assign categories to wholesale group(s). If you need it for individual customers/different categories for each customer, it's not useful.
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing
Need Help?viewtopic.php?f=10&t=27
https://docs.google.com/spreadsheets/d/ ... sp=sharing
Need Help?viewtopic.php?f=10&t=27
- burt
- Core Team
- Posts: 4560
- Joined: Tue Oct 29, 2019 9:37 am
- Phoenix Version: v1.1.0.8
- : Buy Me A Beverage
- Has thanked: 252 times
- Been thanked: 413 times
Re: Create customers in admin & assign categories to users
I haven't tried, but in recent versions of Phoenix, the admin pages are sort of modular using views and actions. So you may be able to add in a new view in the customers.php page?
A bit like editing an existing customer? You would just be "editing" a blank customer.
As I say, untried.
A bit like editing an existing customer? You would just be "editing" a blank customer.
As I say, untried.
I am not here to build for you.
I am here to build with you. Let's help each other.
I am here to build with you. Let's help each other.
-
LeeFoster
- Contributor
- Posts: 263
- Joined: Sun Feb 28, 2021 9:41 pm
- Phoenix Version: v1.0.8.20
- Has thanked: 1 time
- Been thanked: 5 times
Re: Create customers in admin & assign categories to users
No it's single category single customer.
Will have a look into this tomorrowburt wrote: ↑Tue Jun 21, 2022 5:38 pm I haven't tried, but in recent versions of Phoenix, the admin pages are sort of modular using views and actions. So you may be able to add in a new view in the customers.php page?
A bit like editing an existing customer? You would just be "editing" a blank customer.
As I say, untried.
-
LeeFoster
- Contributor
- Posts: 263
- Joined: Sun Feb 28, 2021 9:41 pm
- Phoenix Version: v1.0.8.20
- Has thanked: 1 time
- Been thanked: 5 times
Re: Create customers in admin & assign categories to users
Working on this first, I have the drop down to select a category hooked in. I'm struggling to see how to process this into the database though. Normally I'd have used the hook for updateAction but this doesn't exist in customers.php at the moment.
Any suggestions appreciated.
Site is Phoenix 1.0.8.14 for reference.
- Kofod95
- Senior Contributor
- Posts: 748
- Joined: Sat Feb 06, 2021 7:38 pm
- Phoenix Version: 1.0.8.20
- Has thanked: 99 times
- Been thanked: 179 times
Re: Create customers in admin & assign categories to users
onchange=this.form.submit()?
//Daniel
//Daniel
I'm not smart, but sometimes even a blind chicken can find a corn.
Here are a lot of corns: Phoenix user guide
Here are a lot of corns: Phoenix user guide
-
LeeFoster
- Contributor
- Posts: 263
- Joined: Sun Feb 28, 2021 9:41 pm
- Phoenix Version: v1.0.8.20
- Has thanked: 1 time
- Been thanked: 5 times
Re: Create customers in admin & assign categories to users
Thought I'd share a list of things I think I'm going to need to do and hopefully cross them off as I go. Happy to listen to ideas on how to achieve some of these.
1. Create hook to add categories to customer.
2. Add category type (private, public etc).
3. Create table - customers_to_categories
4. Create hook to hide "private" categories.
1. Create hook to add categories to customer.
2. Add category type (private, public etc).
3. Create table - customers_to_categories
4. Create hook to hide "private" categories.
-
ecartz
- Core Team
- Posts: 3084
- Joined: Tue Nov 05, 2019 6:02 pm
- Phoenix Version:
- Has thanked: 4 times
- Been thanked: 208 times
Re: Create customers in admin & assign categories to users
Have you tried it? There are hook listeners for both the actions processed by admin/customers.php : updateAction and deleteConfirmAction
But it would probably make more sense to create a new action, as update won't work for a customer who doesn't exist.
-
LeeFoster
- Contributor
- Posts: 263
- Joined: Sun Feb 28, 2021 9:41 pm
- Phoenix Version: v1.0.8.20
- Has thanked: 1 time
- Been thanked: 5 times
Re: Create customers in admin & assign categories to users
I haven't tried it, I didn't know there were listeners for it that would work without there being an actual hook in the file.
-
LeeFoster
- Contributor
- Posts: 263
- Joined: Sun Feb 28, 2021 9:41 pm
- Phoenix Version: v1.0.8.20
- Has thanked: 1 time
- Been thanked: 5 times
Re: Create customers in admin & assign categories to users
This
Next on to
And this
Are now done and working for existing customers. It is configured to use check boxes to allow multiple categories to be selected for each customer.
Next on to
@ecartz are there any listeners I can use on catalog.php?