mirror of
				https://github.com/lingble/chatwoot.git
				synced 2025-11-03 20:48:07 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			27 lines
		
	
	
		
			688 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			27 lines
		
	
	
		
			688 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
import { PRIORITY_CONDITION_VALUES } from 'dashboard/helper/automationHelper.js';
 | 
						|
export default {
 | 
						|
  methods: {
 | 
						|
    getDropdownValues(type) {
 | 
						|
      switch (type) {
 | 
						|
        case 'assign_team':
 | 
						|
        case 'send_email_to_team':
 | 
						|
          return this.teams;
 | 
						|
        case 'assign_agent':
 | 
						|
          return [{ id: 'self', name: 'Self' }, ...this.agents];
 | 
						|
        case 'add_label':
 | 
						|
        case 'remove_label':
 | 
						|
          return this.labels.map(i => {
 | 
						|
            return {
 | 
						|
              id: i.title,
 | 
						|
              name: i.title,
 | 
						|
            };
 | 
						|
          });
 | 
						|
        case 'change_priority':
 | 
						|
          return PRIORITY_CONDITION_VALUES;
 | 
						|
        default:
 | 
						|
          return [];
 | 
						|
      }
 | 
						|
    },
 | 
						|
  },
 | 
						|
};
 |