PageSourceSearch

https://www.aracneeditrice.eu/js/carrello-step-3.js

js aracneeditrice.eu collected 2026-10-01 12:27:17 UTC 12,285 bytes, 297 lines download raw bytes

1$(document).ready(function(){
2
3	$('#modalita-pagamento').submit(function(e) { // modalita-pagamento
4        var console_control = $("#console_v").val();
5        var alert_control = $("#alert_v").val();
6        var ordine = $('#ordine').val();
7        var userid = $('#userid').val();
8        var error = "";
9        var val_payment_method = $('input[name="pm"]').val();
10        var val_state_id = $('#val_state_id').val();
11        var data2 = {"state": val_state_id , "payment_method": val_payment_method }
12        var userid = $('#userid').val();
13        var pm = $("input[name='pm']:checked").val();
14        var id_gruppo = $('#guorpid').val();
15        var next_step_4 = $('#next_step_4').val();
16        var data2 = {"state": val_state_id , "payment_method": val_payment_method }
17        var userid = $('#userid').val();
18        var pm = $("input[name='pm']:checked").val();
19        var id_gruppo = $('#guorpid').val();
20        var Paymet_Tol = 0;
21
22        var Totale_conSconto = 0;
23
24        var that = $(this),
25            url = that.attr('action'),
26            type = that.attr('method'),
27            data = {"ordine": ordine , "pm":pm, "userid": userid , "next_step_4":next_step_4};
28
29//        var price_total = parseFloat($("#price_total").text());
30
31        if($("input[name='pm']").is(":checked") == true)
32        {
33            $("#pagamento_M").empty();
34            $("#contrassegno").empty();
35            if($("input[name='pm']:checked").val() == "1")
36            {
37                if($("#after_discount").text() == "")
38                {
39                    $("#pagamento_M").append("Carta di credito");
40                    $.ajax({
41                        url : "step-method-payment.php",
42                        type  :"POST",
43                        data : {"ordine_id": ordine ,'total_payment': ($("#price_total").text()) , "error": error},
44                        success: function(response)
45                        { 
46                            if(console_control > 0)
47                            {
48                                //console.log(response);
49                            }
50                        }
51                    })
52                }else
53                {
54                    $("#pagamento_M").append("Carta di credito");
55                    $.ajax({
56                        url : "step-method-payment.php",
57                        type  :"POST",
58                        data : {"ordine_id": ordine ,'total_payment': ($("#after_discount").text()) , "error": error},
59                        success: function(response)
60                        { 
61                            if(console_control > 0)
62                            {
63                                //console.log(response);
64                            }
65                        }
66                    })
67                }
68                 
69            }else if($("input[name='pm']:checked").val() == "2")
70            {
71                if($("#after_discount").text() == "")
72                {
73                    $("#pagamento_M").append("Contrassegno");
74                    $("#contrassegno").append($("#cost-contra").val()+".00");
75                    var price_total = parseFloat($("#price_total").text());
76                    var conta = parseFloat($("#cost-contra").val());
77                    Paymet_Tol = price_total+conta;
78                    $("#Totale_Parziale").empty();
79                    $("#Totale_Parziale").append(parseFloat(price_total+conta).toFixed(2));
80                    $("#drop_price_total").empty();
81                    $("#drop_price_total").append(parseFloat(price_total+conta).toFixed(2)+" €");
82                    $("#Total_order").val(Paymet_Tol);
83                    $.ajax({
84                        url : "step-method-payment.php",
85                        type  :"POST",
86                        data : {"ordine_id": ordine ,'total_payment': Paymet_Tol , "error": error},
87                        success: function(response)
88                        { 
89                            if(console_control > 0)
90                            {
91                                //console.log(response);
92                            }
93                        }
94                    })
95                }else{
96                    $("#pagamento_M").append("Contrassegno");
97                    $("#contrassegno").append($("#cost-contra").val()+".00");
98                    var price_total = parseFloat($("#after_discount").text());
99                    var conta = parseFloat($("#cost-contra").val());
100                    Paymet_Tol = price_total+conta;
101                    $("#Totale_Parziale").empty();
102                    $("#Totale_Parziale").append(parseFloat(price_total+conta).toFixed(2));
103                    $("#drop_price_total").empty();
104                    $("#drop_price_total").append(parseFloat(price_total+conta).toFixed(2)+" €");
105                    $("#Total_order").val(Paymet_Tol);
106                    $.ajax({
107                        url : "step-method-payment.php",
108                        type  :"POST",
109                        data : {"ordine_id": ordine ,'total_payment': Paymet_Tol , "error": error},
110                        success: function(response)
111                        { 
112                            if(console_control > 0)
113                            {
114                                //console.log(response);
115                            }
116                        }
117                    })
118                }
119
120            }else if($("input[name='pm']:checked").val() == "3")
121            {
122                if($("#after_discount").text() == "")
123                {
124                    $("#pagamento_M").append("Bonifico bancario");   
125                    $.ajax({
126                        url : "step-method-payment.php",
127                        type  :"POST",
128                        data : {"ordine_id": ordine ,'total_payment': ($("#price_total").text()) , "error": error},
129                        success: function(response)
130                        { 
131                            if(console_control > 0)
132                            {
133                                //console.log(response);
134                            }
135                        }
136                    })
137                }else
138                {
139                    $("#pagamento_M").append("Bonifico bancario");   
140                    $.ajax({
141                        url : "step-method-payment.php",
142                        type  :"POST",
143                        data : {"ordine_id": ordine ,'total_payment': ($("#after_discount").text()) , "error": error},
144                        success: function(response)
145                        { 
146                            if(console_control > 0)
147                            {
148                                //console.log(response);
149                            }
150                        }
151                    })
152                }
153            }
154
155            $.ajax({
156                url : "step-method-payment.php",
157                type : "POST",
158                async: false,
159                data : {"userid": userid , "ordine": ordine , "address_type": 1 },
160                success: function(data)
161                {
162
163                    if(alert_control >0)
164                    {
165                       //alert("0"); 
166                    }
167                    
168                    var zone_id = jQuery.parseJSON(data);
169                    if(zone_id != null)
170                    {
171                       $('#zona_id').val(zone_id['id_zona']); 
172                       if(console_control >0)
173                        {
174                            //console.log("!!!!!!!!!!")
175                            //console.log( $('#zona_id').val());
176                        }
177                       
178                    }else
179                    {
180                        $.ajax({
181                                url : "step-method-payment.php",
182                                type : "POST",
183                                 async: false,   
184                                data : {"userid": userid , "ordine": ordine , "address_type": 0 },
185                                success: function(data)
186                                {
187                       
188                                    if(alert_control >0)
189                                    {
190                                       //alert("1") 
191                                    }
192                                    var zone_id = jQuery.parseJSON(data);
193                                    $('#zona_id').val(zone_id['id_zona']);
194                                    if(console_control >0)
195                                    {
196                                        //console.log("!!!!!!!!!!")
197                                        //console.log( $('#zona_id').val());
198                                    }
199                                    
200                                },
201                                
202                            })
203                    }
204                    
205                    
206                },
207                                
208            })
209
210            //e.preventDefault();
211
212            //+++++++++++++++++++++++++++++++++++++++++++++++++++++
213            //
214            //                  Ajax per SaveAdress in step 4
215            //
216            $.ajax({
217                url : "step-method-payment.php",
218                type  :"POST",
219                data : data,
220                success: function(data)
221                {      
222                    //+++++++++++++++++++++++++++++++++++++++++++++++++++++
223                    //
224                    //                  Ajax per SavePaymentMethod in step 4
225                    //  
226
227                    $.ajax({
228                        url : "step-method-payment.php",
229                        type  :"POST",
230                        data : {"ordineMp": ordine ,"errorMp": error},
231                        success: function(data)
232                        {                     
233                            var Newps1 = jQuery.parseJSON(data);
234                            $('#val_payment_method').val(Newps1["id"]);
235                            $('#MpNum').val(Newps1["name"]); 
236                            $('#MpN').val(Newps1["id"]); 
237                            if(console_control > 0)
238                            {
239                                //console.log(Newps1["id"]);
240                                //console.log(Newps1["name"]);
241                            }
242       
243                        } 
244                    })  
245                    //                     fine 
246                    //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++          
247                }
248            }).done(function(){
249                
250                // show the response
251                /*var Newps = jQuery.parseJSON(data);
252                $('#val_payment_method').val(Newps["pm"]);
253                console.log(Newps["pm"]);*/
254
255            }).fail(function() {
256                 
257                // just in case posting your form failed
258                // alert( "Posting failed." );
259                 
260            })
261            //                     fine 
262            //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
263
264            $.ajax({
265                url : "step-riepilogo-concludi.php",
266                type  :"POST",
267                data : {"ordine": ordine , "current_step": 3},
268                success: function(response)
269                {
270                    
271                }
272            })
273            
274            $("#field_coupon").show("slow");
275            $("#slide_modalita_pagamenteo").hide("slow");
276        }else
277        
278        e.preventDefault();
279        return false;
280          
281    })
282    //                     fine 
283    //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
284
285    //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
286    //                    Step 4 Torna indietro 
287    //
288   /* $('#next_step_6-1').on('click', function(e) {
289        $('#method-spedizione input[type="radio"]').remove();
290        $('#method-spedizione span').remove();
291        $('#method-spedizione select').remove();
292        $("#field_method_spedizione").hide("slow");
293        $("#slide_modalita_pagamenteo").show("slow");
294        e.preventDefault();
295    })*/ 
296
297})

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.