Subversion Repositories SmartDukaan

Rev

Rev 18456 | Rev 20152 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
3206 mandeep.dh 1
/**
2
 * 
3
 */
4
package in.shop2020.util;
5
 
3269 mandeep.dh 6
import in.shop2020.model.v1.order.OrderStatus;
7
 
8
import java.util.Arrays;
4020 mandeep.dh 9
import java.util.Collections;
13438 amit.gupta 10
import java.util.HashMap;
3269 mandeep.dh 11
import java.util.List;
13438 amit.gupta 12
import java.util.Map;
3269 mandeep.dh 13
 
3206 mandeep.dh 14
/**
15
 * @author mandeep
16
 *
17
 * Class containing constants used across CRM
18
 */
19
public class CRMConstants {
4241 anupam.sin 20
    public static final String ATTACHMENTS_ARCHIVE_DIR = "/var/crm/archive/";
15005 manish.sha 21
    public static final String CRM_EMAIL_SENDOR = "Saholic <help@saholic.com>";
22
    public static final String PROFIT_MANDI_EMAIL_SENDER = "ProfitMandi <help@profitmandi.com>";
3206 mandeep.dh 23
    public static final String CRM_EMAIL_TYPE   = "CRMInfo";
14882 manish.sha 24
    public static final String PROFIT_MANDI_EMAIL_TYPE   = "ProfitMandiInfo";
3206 mandeep.dh 25
    public static final String CRM_SUBJECT_PREFIX_FOR_TICKET_ID = "Saholic#";
14882 manish.sha 26
    public static final String PROFIT_MANDI_SUBJECT_PREFIX_FOR_TICKET_ID = "ProfitMandi#";
3339 mandeep.dh 27
    public static final long   ADMIN_AGENT_ID   = 1;
4605 anupam.sin 28
    public static final int DESCRIPTION_MAX_WIDTH = 8000;
3339 mandeep.dh 29
 
3269 mandeep.dh 30
    public static final List<OrderStatus> failedStatusList = Arrays.asList(new OrderStatus[] {
4484 rajveer 31
            OrderStatus.RTO_RESHIPPED,
3269 mandeep.dh 32
            OrderStatus.PAYMENT_FAILED,
4484 rajveer 33
            OrderStatus.RTO_REFUNDED,
3269 mandeep.dh 34
            OrderStatus.DOA_INVALID_REFUNDED,
35
            OrderStatus.DOA_INVALID_RESHIPPED,
36
            OrderStatus.DOA_VALID_REFUNDED,
4452 rajveer 37
            OrderStatus.DOA_VALID_RESHIPPED,
4682 rajveer 38
            OrderStatus.CANCELLED_DUE_TO_LOW_INVENTORY,
3269 mandeep.dh 39
            OrderStatus.REJECTED,
40
            OrderStatus.FAILED});
13438 amit.gupta 41
 
42
    @SuppressWarnings("serial")
43
	public static final Map<Long, String> PAYMENT_GATEWAYS = Collections.unmodifiableMap(
44
    		new HashMap<Long, String>(){
45
	    		{
46
	    			put(1l,"hdfc");
47
	    			put(2l,"ebs");
48
	    			put(3l,"Cheque");
49
	    			put(4l,"COD");
50
	    			put(5l,"hdfc-emi-3");
51
	    			put(6l,"rtgs");
52
	    			put(8l,"Wallet");
53
	    			put(9l,"GiftVoucher");
54
	    			put(10l,"hdfc-emi-6");
55
	    			put(11l,"hdfc-emi-9");
56
	    			put(12l,"hdfc-emi-12");
57
	    			put(13l,"innoviti");
58
	    			put(14l,"hdfc-emi-18");
59
	    			put(15l,"Amazon");
60
	    			put(16l,"Ebay");
61
	    			put(17l,"Flipkart");
62
	    			put(18l,"Snapdeal");
63
	    			put(19l,"PAYU");
64
	    		}
65
    		});
4020 mandeep.dh 66
 
67
    public static enum EscalationMatrix {
20087 aman.kumar 68
        SHIPPING_AND_DELIVERY("Product shipping and delivery related issues", Arrays.asList(34, 65, 47, 51)),
8228 anupam.sin 69
        RETURN_AND_REFUND("Product return, order refund, Payment status related issues", Arrays.asList(34)),
70
        CONTENT("Any questions or errors on the content about the product on our site", Arrays.asList(34, 10)),
71
        PRODUCT_AND_PRICE("Product availability and its price related enquiries", Arrays.asList(34, 13)),
72
        TECHNICAL("Any technical errors on the site (or site not working properly)", Arrays.asList(34, 35)),
20087 aman.kumar 73
        ORDER_CANCELLATION("Cancelling an order", Arrays.asList(65, 34, 51)),
9693 manish.sha 74
        BULK_DEAL("Any bulk deals related enquiries", Arrays.asList(34)),
8228 anupam.sin 75
        PROMOTION_MARKETING_PARTNERSHIP("Any promotion, marketing or partnership proposals' related queries", Arrays.asList(34, 41)),
14025 manish.sha 76
        COD_VERIFICATION("Any COD verification related tickets", Arrays.asList(34, 51)),
20087 aman.kumar 77
        ON_TIME_GUARANTEE("On Time Guarantee related enquiries",Arrays.asList(65, 47, 34)),
18456 manish.sha 78
        RECHARGE_RELATED("Recharge related", Arrays.asList(34, 51)),
20087 aman.kumar 79
        DELIVERY_PROBLEM("", Arrays.asList(34, 47, 65, 51)),
80
        OTHER("Any other issues", Arrays.asList(65, 34, 51));
4020 mandeep.dh 81
 
82
        private String description;
83
        private List<Integer> agentIds;
84
 
85
        EscalationMatrix(String description, List<Integer> agentIds) {
86
            this.description = description;
87
            this.agentIds    = agentIds;
88
        }
89
 
90
        public String getDescription() {
91
            return description;
92
        }
93
 
94
        public List<Integer> getAgentIds() {
95
            return agentIds;
96
        }
97
    };
4241 anupam.sin 98
 
16244 manish.sha 99
 
100
    public static enum PMEscalationMatrix {
18456 manish.sha 101
    	PM_CASH_BACK_INQUIRY("Customer wanted to know about cash back", Arrays.asList(34, 51)),
102
    	PM_RECHARGE_FAILED_OR_COMPLAINT("Customer complaint about recharge", Arrays.asList(34, 51)),
103
    	PM_WALLET_AMOUNT_ISSUE("Some issue in wallet amount", Arrays.asList(34, 51)),
104
    	PM_ORDER_NOT_SHOWING("Customer Order not showing at App", Arrays.asList(34, 51)),
105
    	PM_BULK_INQUIRY("Customer wanted to know about bulk purchase inquiry", Arrays.asList(34, 51)),
106
    	PM_TAX_INVOICE_ISSUE("Customer wanted to complaint about tax invoice", Arrays.asList(34, 51)),
107
        PM_ORDER_STATUS_SAHOLIC_ORDER("Customer wanted to know status of order", Arrays.asList(34, 51)),
108
        PM_PRODUCT_DEMAND("Customer wanted information about any product demand", Arrays.asList(34, 51)),
109
        PM_PRICING_ERROR("Customer wanted to ask questions about some error in pricing", Arrays.asList(34, 51)),
110
        PM_TECHNICAL_ISSUE("Some technical issue at app", Arrays.asList(34, 51));
16244 manish.sha 111
 
112
        private String description;
113
        private List<Integer> agentIds;
114
 
115
        PMEscalationMatrix(String description, List<Integer> agentIds) {
116
            this.description = description;
117
            this.agentIds    = agentIds;
118
        }
119
 
120
        public String getDescription() {
121
            return description;
122
        }
123
 
124
        public List<Integer> getAgentIds() {
125
            return agentIds;
126
        }
127
    };
128
 
4241 anupam.sin 129
    public static enum CODCancelMatrix {
4793 amar.kumar 130
    	INVALID_ADDRESS_PIN_CODE_PHONE("Address/PinCode/Phone number provided by customer"),
131
    	NOT_PICKING("Customer is not picking the call"),
132
    	NOT_REACHABLE_SWITCHED_OFF("Customer number is not reachable or switched off"),
4241 anupam.sin 133
        LOWER_PRICE_AVAILABLE_ELSEWHERE("Customer getting better price elsewhere"),
134
        CUSTOMER_TESTING_WEBSITE("Customer is testing the site"),
135
        DUPLICATE_BOOKING("Customer booked an order twice by mistake"),
136
        DEALER_ORDER("Order was place by a dealer"),
137
        OUT_OF_STOCK("Ordered item is out of stock"),
4681 amar.kumar 138
        CUSTOMER_WANTS_EARLY_DELIVERY("Customer wants order to be delivered before promised and expected date"),
139
        NOT_INTERESTED_THIS_TIME("Customer decided against buying the product"),
140
        WANT_SOME_OTHER_PRODUCT("Customer wants to buy different product"),
141
        PLACED_ANOTHER_ORDER("Customer has placed another order buying different product"),
142
        USER_WANTS_DELAYED_DELIVERY("Customer wants order to be delivered after promised and expected date"),
143
        COLOR_OUT_OF_STOCK("Order Item(s) not present in the requested color"),
4689 anupam.sin 144
        CUSTOMER_WANTS_OPEN_DELIVERY("Customer wants to pay money after seeing the product"),
6543 anupam.sin 145
        CUSTOMER_DENIED_PLACING_ORDER("Customer denied placing any order on our site"),
7956 anupam.sin 146
        PAYMENT_FLAGGED_BY_GATEWAY("This payment is flagged"),
4681 amar.kumar 147
        OTHER("Order cancelled because of some miscellaneous reason");
4241 anupam.sin 148
 
149
        private String description;
150
 
151
        CODCancelMatrix(String description) {
152
            this.description = description;
153
        }
154
 
155
        public String getDescription() {
156
            return description;
157
        }
158
    };
5203 amar.kumar 159
 
160
    public static enum ActivityCommonDescriptionMatrix{
161
    	BULK_INQUIRY("Customer wanted to know about bulk order"),
162
    	CALL_HUNGUP_DISCONNECTED("Call got disconnected or was hung up by customer"),
163
    	COD_VERIFICATION("Call to customer to verify COD"),
164
        COMPLAINT_OR_DELIVERY_ISSUE("Call for complaint or delivery issue from customer"),
165
        COURIER_PARTNER_DETAIL("Customer wanted to know about courier partner"),
166
        ORDER_CANCELLATION("Customer wanted to cancel order"),
167
        ORDER_STATUS("Customer wanted to know status of order"),
168
        PAYMENT_MODE_QUERY("Customer wantedinformation about payment mode"),
169
        PRODUCT_QUERY("Customer wanted to ask questions about product"),
170
        PROMOTION_CALL("Promotion call"),
171
        RETURN_OR_REFUND("Return or Refund"),
172
        TEST_CALL("test call"),
173
        VOICE_ISSUE_OR_TECHNICAL_ISSUE("voice issue or technical issue"),
174
        WRONG_CALL("wrong call");
175
 
176
        private String description;
177
 
178
        ActivityCommonDescriptionMatrix(String description) {
179
            this.description = description;
180
        }
181
 
182
        public String getDescription() {
183
            return description;
184
        }
185
 
186
    };
187
 
16208 manish.sha 188
    public static enum ActivityPMCommonDescriptionMatrix{
189
    	CASH_BACK_INQUIRY("Customer wanted to know about cash back"),
190
    	RECHARGE_FAILED_OR_COMPLAINT("Customer complaint about recharge"),
191
    	WALLET_AMOUNT_ISSUE("Some issue in wallet amount"),
192
    	ORDER_NOT_SHOWING("Customer Order not showing at App"),
193
    	BULK_INQUIRY("Customer wanted to know about bulk purchase inquiry"),
194
    	TAX_INVOICE_ISSUE("Customer wanted to complaint about tax invoice"),
195
        ORDER_STATUS_SAHOLIC_ORDER("Customer wanted to know status of order"),
196
        PRODUCT_DEMAND("Customer wanted information about any product demand"),
197
        PRICING_ERROR("Customer wanted to ask questions about some error in pricing"),
16215 manish.sha 198
        TECHNICAL_ISSUE("Some technical issue at app");
16208 manish.sha 199
 
200
        private String description;
201
 
202
        ActivityPMCommonDescriptionMatrix(String description) {
203
            this.description = description;
204
        }
205
 
206
        public String getDescription() {
207
            return description;
208
        }
209
 
210
    };
16244 manish.sha 211
 
3206 mandeep.dh 212
}