-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathepricing.js.cfm
57 lines (45 loc) · 1.97 KB
/
epricing.js.cfm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
// get search values
getLname = function(){
var s = ColdFusion.getElementValue('searchLname');
return s;
}
getEmail = function(){
var s = ColdFusion.getElementValue('searchEmail');
return s;
}
getFromDate = function(){
var s = ColdFusion.getElementValue('searchFromDate');
return s;
}
getToDate = function(){
var s = ColdFusion.getElementValue('searchToDate');
return s;
}
getTitle = function(){
var s = ColdFusion.getElementValue('searchTitle');
return s;
}
// unique to epricing module - shows seller email if not null
function gridChange(uid,customer_email,seller_email) {
document.getElementById('artImg').innerHTML = '<a href="http://<cfoutput>#server_name#</cfoutput>/img/'+uid+'.jpg" target="_blank"><img src="http://<cfoutput>#server_name#</cfoutput>/img/thumbnails/'+uid+'.jpg" border="0"></a>';
document.getElementById('emailLink').innerHTML = '<a href="mailto:'+customer_email+'" style="color: #000000; text-decoration: none;">[SEND EMAIL]</a>';
document.getElementById('mailLog').innerHTML = '<a href="#" onclick="openMailLogWindow(<cfoutput>#session.userinfo.pk_employees#</cfoutput>,4,' + uid + ',\'' + customer_email + '\');" style="color: #000000; text-decoration: none;">[VIEW EMAIL LOG]</a>';
if(seller_email == 'null'){
document.getElementById('emailLinkSeller').innerHTML = '';
document.getElementById('displaySellerInfo').style.display = 'none';
}
else{
document.getElementById('emailLinkSeller').innerHTML = '<a href="mailto:'+seller_email+'" style="color: #000000; text-decoration: none;">[SEND EMAIL]</a>';
document.getElementById('displaySellerInfo').style.display = 'block';
}
}
// edit form functions
function doEdit(type) {
var edit = new admin.models.epricing();
edit.setForm("editForm");
if ( edit.deleteEpricing()) {
ColdFusion.Grid.refresh('data',true);
}
else { alert( 'There was a problem in the processing.')}
document.getElementById('delete').style.display = '';
}