phpBMS

Changeset 384 for trunk/phpbms/common

Show
Ignore:
Timestamp:
05/04/08 17:18:08 (4 years ago)
Author:
brieb
Message:

Pre v0.96 check in:

  • Added support for multiple addresses
  • Added link to google maps for addresses on client and sales order screens.
  • Added obfuscation ability to sensitive payment information when voiding/deleting or posting receipts and sales orders.
  • Replaced autofill fields with new smartsearch technologies
  • Fixed recurring invoice bug
  • Switched several sales order AJAX calls to use JSON
  • Reorganized quickView screens

Left to do:

  • Finish BMS update/install scripts with address and addressto record tabledef/table support information
  • Re-code delete prospect code
  • Finish BMS update/install scripts with new client/client dup tabledef/table support information.
Location:
trunk/phpbms/common
Files:
7 added
8 modified

Legend:

Unmodified
Added
Removed
  • trunk/phpbms/common/javascript/common.js

    r383 r384  
    108108            } 
    109109        } 
    110     }//endfunction       
    111          
     110    },//endfunction 
     111         
     112         
     113        htmlDecode: function(string){ 
     114 
     115                        var ret, tarea = document.createElement('textarea'); 
     116                        tarea.innerHTML = string; 
     117                        ret = tarea.value; 
     118                        return ret; 
     119 
     120        },//end function 
     121 
     122 
     123        reportError: function(error){ 
     124                 
     125                if(console){ 
     126                        if(console.log) 
     127                                console.log(error); 
     128                } else 
     129                        alert(error); 
     130                 
     131        }//end method - reportError 
     132 
     133 
    112134});//end update 
    113135 
     
    115137        "update", 
    116138        "nameFunctions", 
    117         "loadXMLDoc" 
     139        "loadXMLDoc", 
     140        "htmlDecode", 
     141        "reportError" 
    118142]; 
    119143 
     
    171195                return retVal; 
    172196        }//endMethod     
    173  
     197         
    174198})//end update 
    175199 
     
    297321        _listener: function(srcObj, func){ 
    298322        var E = phpBMS.signal.e; 
     323                 
     324                if(!srcObj || !func){ 
     325                         
     326                        reportError("ListnerError srcObj:" + srcObj + " func:" + func); 
     327                        return false; 
     328                         
     329                }//endif 
     330                         
    299331                return function (nativeEvent) { 
    300332                        return func.apply(srcObj, [new E(srcObj, nativeEvent)]); 
     
    304336 
    305337        connect: function(srcObj, eventName, func){ 
     338                 
     339                if(!srcObj || !eventName || !func){ 
     340                         
     341                        var err = "Invalid Entry for connect: srcObj:" + srcObj + " eventName:" + eventName + " func:" + func 
     342                        reportError(err);                        
     343                         
     344                        return false; 
     345                         
     346                }//endif  
     347                 
    306348        var self = phpBMS.signal; 
    307349                 
     
    316358        var ident = [srcObj, eventName, listener]; 
    317359        self._observers.push(ident); 
    318                 
    319360        return ident; 
    320361                 
     
    339380        var self = phpBMS.signal; 
    340381        var observers = self._observers; 
    341  
    342                 self._disconnect(ident); 
    343                 observers.splice(ident, 1); 
    344                  
    345                 return true; 
    346         } 
     382                 
     383        for (var i = 0; i < observers.length; i++) { 
     384            var pident = observers[i]; 
     385                        if(pident == ident){ 
     386 
     387 
     388                                self._disconnect(ident); 
     389                                observers.splice(i, 1) 
     390                                return true; 
     391                        } 
     392                } 
     393                return false; 
     394        }, 
     395 
     396        trigger: function(src, sig){ 
     397                 
     398        var self = phpBMS.signal; 
     399        var observers = self._observers; 
     400 
     401        var E = phpBMS.signal.e; 
     402        for (var i = 0; i < observers.length; i++) { 
     403            var ident = observers[i]; 
     404            if (ident[0] === src && ident[1] === sig) { 
     405                try { 
     406                    ident[2].apply([new E(src, sig)]); 
     407                } catch (err) { 
     408                                        reportError(err) 
     409                } 
     410            }//endif 
     411        }//endfor 
     412                 
     413        }//end method - signal 
    347414         
    348415})//end class 
     
    351418        "connect", 
    352419        "disconnect", 
    353         "getIdent" 
     420        "getIdent", 
     421        "trigger" 
    354422] 
    355423 
     
    856924        showModal(text,"Alert",250); 
    857925} 
     926 
     927/* Function Overloads and Extensions --------------------- */ 
     928/* ------------------------------------------------------- */ 
     929String.prototype.trim = function() { 
     930        a = this.replace(/^\s+/, ''); 
     931        return a.replace(/\s+$/, ''); 
     932}; 
     933 
    858934window.alert = function(txt) {modalAlert(txt);} 
    859935 
  • trunk/phpbms/common/javascript/datepicker.js

    r311 r384  
    101101        var thedate=new Date(parseInt(year,10),parseInt(month,10)-1,parseInt(day,10)); 
    102102        thefield.value=dateToString(thedate); 
     103 
    103104        if(thefield.onchange) thefield.onchange.call(thefield); 
     105        trigger(thefield,"onchange"); 
     106         
    104107        closeDPBox(); 
    105108} 
  • trunk/phpbms/common/stylesheet/mozilla/base.css

    r308 r384  
    8686        #saveButton1,#saveButton2{width:68px;margin-right:3px;} 
    8787        #cancelButton1,#cancelButton2{width:68px;} 
     88         
     89/* ============================================================================== */ 
     90/* Smart Searches                                                                 */ 
     91/* ============================================================================== */ 
     92.inputSmartSearch{ 
     93        background-image:url("image/magnify.gif"); 
     94        background-position:right; 
     95        background-repeat:no-repeat; 
     96        padding-right:10px; 
     97} 
     98 
     99.smartSearchBox{ 
     100        border:1px solid #999999; 
     101        background:white; 
     102        position:absolute; 
     103} 
     104 
     105.SBResults{ 
     106 overflow:auto; 
     107} 
     108 
     109.SBResults DIV{ 
     110         color:#666666; 
     111         padding:5px; 
     112         font-style:italic; 
     113} 
     114 
     115.SBResults A{ 
     116/*      width:245px;/* 295 - 5 - 30 */ 
     117        display:block; 
     118        color:#663366; 
     119        font-weight:normal; 
     120        padding:6px 5px 6px 5px; 
     121        background-repeat:no-repeat; 
     122        background-position:8px 8px; 
     123} 
     124 
     125.SBResults A:hover, .SBResults A.SBSelected{ 
     126        text-decoration:none; 
     127        background-color:#663366; 
     128        color:white; 
     129} 
     130 
     131.SBAddNewButton{ 
     132        width:70px; 
     133        text-align:right; 
     134} 
     135 
     136.SBResults SPAN{ 
     137        display:block; 
     138} 
     139 
     140.SBMain{ 
     141        font-weight:bold; 
     142} 
     143 
     144.SBExtra{ 
     145        font-size:9px; 
     146        padding-left:5px; 
     147} 
     148 
     149.SBHeader{ 
     150        background:#EEEEEE; 
     151        text-align:right;        
     152        padding:5px; 
     153        height:16px; 
     154} 
     155 
     156.SBFooter{ 
     157        background:#EEEEEE; 
     158        text-align:right; 
     159        font-size:10px; 
     160        padding:5px; 
     161} 
  • trunk/phpbms/common/stylesheet/mozilla/forms.css

    r375 r384  
    9393.buttonDown{background:url(image/button-down.png) 0 0 no-repeat;} 
    9494.buttonDownDisabled{background:url(image/button-down-disabled.png) 0 0 no-repeat;} 
     95.buttonMap{background:url(image/button-map.png) 0 0 no-repeat;} 
    9596.buttonWWW{background:url(image/button-www.png) 0 0 no-repeat;} 
    9697.buttonX{background:url(image/button-x.png) 0 0 no-repeat;} 
  • trunk/phpbms/common/stylesheet/mozilla/pages/client.css

    r219 r384  
    88#leftSideDiv{padding-top:1px;margin-right:210px;} 
    99 
    10 #id, #becameclient, #ds-salesmanagerid, #ccnumber, #ds-taxareaid, #comments{width:98%} 
     10#id, #becameclient, #ccnumber, #ds-taxareaid, #comments{width:98%} 
    1111#type, #category, #leadsource,#paymentmethodid,#shippingmethodid,#discountid,#taxareaid{width:99%} 
     12#ds-salesmanagerid{ 
     13        width:90% 
     14} 
    1215 
    1316#backtoorderP{padding-top:9px;} 
     
    1720 
    1821.phonelefts{float:left} 
    19 #address1,#shiptoaddress1{margin-bottom:2px;} 
     22#address1{margin-bottom:2px;} 
    2023 
    2124.csz{float:left} 
  • trunk/phpbms/common/stylesheet/mozilla/pages/invoice.css

    r375 r384  
    22/* $LastChangedDate$ */ 
    33 
    4 #clientdisplay{ 
    5         background-image:url("../image/search.gif"); 
    6         background-repeat:no-repeat; 
    7         background-position:left; 
    8         padding-left:17px; 
    9 } 
    10  
    11 #clientSearchBox{ 
    12         border:1px solid #999999; 
    13         background:white; 
    14         width:300px; 
    15         position:absolute; 
    16 } 
    17  
    18 #CSBResults{ 
    19  overflow:auto; 
    20 } 
    21  
    22 #CSBResults DIV{ 
    23          color:#666666; 
    24          padding:5px; 
    25          font-style:italic; 
    26 } 
    27  
    28 #CSBResults A{ 
    29         width:245px;/* 295 - 5 - 30 */ 
    30         display:block; 
    31         color:#663366; 
    32         font-weight:normal; 
    33         padding:5px 3px 5px 30px; 
    34         background-repeat:no-repeat; 
    35         background-position:8px 8px; 
    36 } 
    37  
    38 #CSBResults A:hover, #CSBResults A.CSBSelected{ 
    39         text-decoration:none; 
    40         background-color:#663366; 
    41         color:white; 
    42 } 
    43  
    44 #CSBAddNewButton{ 
    45         width:70px; 
    46         text-align:right; 
    47 } 
    48  
    49 .client{ 
     4.SBResults A.client{ 
     5        padding-left:30px; 
    506        background-image:url("../image/client.png"); 
    517} 
    528 
    53 .prospect{ 
     9.SBResults A.prospect{ 
     10        padding-left:30px; 
    5411        background-image:url("../image/prospect.png"); 
    55 } 
    56  
    57 #CSBResults SPAN{ 
    58         display:block; 
    59 } 
    60  
    61 .CSBMain{ 
    62         font-weight:bold; 
    63 } 
    64  
    65 .CSBExtra{ 
    66         font-size:9px; 
    67 } 
    68  
    69 #CSBHeader{ 
    70         background:#EEEEEE; 
    71         text-align:right;        
    72         padding:5px; 
    73         height:16px; 
    74 } 
    75  
    76 #CSBFooter{ 
    77         background:#EEEEEE; 
    78         text-align:right; 
    79         font-size:10px; 
    80         padding:5px; 
    8112} 
    8213 
     
    8718#printButton{ text-align:right;float:left;} 
    8819#printButton input{width:75px;} 
    89  
    90 #address1,#address2,#country,#leadsource{width:364px;} 
    9120 
    9221#fsAttributes{clear:both;float:right;width:260px;} 
     
    9423#type{width:90px} 
    9524#statusid{width:98%} 
    96 #ds-assignedtoid{width:99%} 
     25#leadsource{ 
     26        width:98% 
     27} 
    9728 
    9829 
    9930#fsTops{margin-right:270px;} 
    100 #address1{margin-bottom:2px;} 
    101 .cszP{float:left;} 
    102 #countryP{clear:left;} 
     31 
     32#billingAddressDiv, #shiptoAddressDiv{ 
     33        clear:left; 
     34        border:1px solid #ACB7C4; 
     35        padding:8px; 
     36        margin:0 4px 4px; 
     37} 
     38 
     39.addressButtons{ 
     40        width:75px; 
     41} 
     42 
     43#shiptoAddressDiv{ 
     44        display:none; 
     45} 
     46 
     47#address1, #shiptoaddress1{ 
     48        margin-top:2px; 
     49        margin-bottom:2px; 
     50} 
     51 
     52#fsAddresses{ 
     53        display:block; 
     54        border:0; 
     55        margin:0; 
     56        padding:0; 
     57} 
     58 
     59#fsAddresses legend{ 
     60        display:none; 
     61} 
     62 
     63.cityState{ 
     64        float:left; 
     65} 
     66 
     67 
     68.showoptions{ 
     69        width:100px; 
     70} 
     71 
     72.showoptions span{ 
     73        display:inline; 
     74        padding-left:15px; 
     75        color : #455372;  
     76        font-weight:bold; 
     77} 
     78 
     79#addressOptionsDivBilling, #addressOptionsDivShipTo { 
     80        display:none; 
     81} 
     82 
     83#LAPickDiv{ 
     84        height:200px; 
     85        overflow:auto; 
     86        background:white; 
     87        border:1px solid #abb1b1;; 
     88} 
     89 
     90.LAPickAs { 
     91        display:block; 
     92        padding:8px; 
     93        border-bottom:1px solid #CCCCCC; 
     94        font-weight:normal; 
     95        color:black; 
     96} 
     97 
     98.LAPickAs:hover{ 
     99        text-decoration:none; 
     100        background: #CCCCCC; 
     101} 
     102 
     103.LASel{ 
     104        color:white; 
     105        background:black; 
     106} 
     107 
     108.LASel:Hover{ 
     109        background:black; 
     110} 
    103111 
    104112#lineItemsFS{clear:both;} 
     
    120128#ds-partname{width:135px;} 
    121129 
    122 #partnameHeader div{width:120px;} 
    123 #memoHeader{width:100%} 
     130#memoHeader{ 
     131        width:100%; 
     132} 
     133 
    124134 
    125135#memo, .lineitemMemos{width:100%;padding-right:0;border-right:0;} 
     
    177187.invoiceTotalLabels div{height:24px; line-height:24px;vertical-align:bottom;} 
    178188 
    179 #parenInfo div{height:25px;clear:right;} 
    180 #parenInfo div span{ 
    181         display:block; 
    182         float:right; 
    183         line-height:24px;height:24px; 
    184         padding:0 4px; 
     189#parenInfo{ 
     190        margin:0; 
     191        padding:0; 
     192        border:0; 
     193        border-collapse:separate; 
     194} 
     195 
     196#parenInfo td{ 
     197        text-align:right; 
     198        line-height:24px; 
    185199        color:#666666; 
     200        padding:0 4px 0 4px; 
     201        border:0; 
     202        border-bottom:1px solid #CCCCCC; 
     203} 
     204 
     205#parenInfo td.blanks{ 
     206        line-height:25px; 
     207        border:0; 
     208} 
     209 
     210#parenInfo td#parenSpacer{ 
     211        height:55px; 
    186212} 
    187213 
    188214#totalSpacer{height:55px;line-height:55px;border:0;} 
    189215#totalSpacer span{border:0;} 
    190 div #parenSpacer{height:55px;clear:right} 
    191 div #parenSpacer span{height:55px;line-height:55px;border:0;} 
    192  
    193216 
    194217.vTabs,.vTabsHover{cursor:pointer;color:#455372;background:url(../image/button-rew.png) 5px 4px no-repeat;} 
  • trunk/phpbms/common/stylesheet/mozilla/pages/quickview.css

    r146 r384  
    22/* $LastChangedDate$ */ 
    33 
    4 #lookupByP{float:left; width:100px;padding-top:2px;} 
    5 #lookupButtonsP{float:right;width:148px;padding-top:12px;text-align:right;} 
    6 #dolookup,#addnew{width:70px} 
    7 #lookupWhatP{margin:0 154px 0 108px;} 
    8 .lookupWhats{width:90%;} 
     4.SBResults A.client{ 
     5        padding-left:30px; 
     6        background-image:url("../image/client.png"); 
     7} 
     8 
     9.SBResults A.prospect{ 
     10        padding-left:30px; 
     11        background-image:url("../image/prospect.png"); 
     12} 
     13 
     14#viewButton, #addButton{ 
     15        width:70px 
     16} 
     17 
     18#clientIDDiv{ 
     19        width:100%; 
     20        margin-right:200px; 
     21        margin-left: 170px; 
     22        background:red; 
     23} 
     24#ds-clientid{ 
     25        width:55%; 
     26} 
     27 
     28 
     29 
     30 
     31#crTile.fsclient{ 
     32        background-image:url("../image/client.png"); 
     33} 
     34 
     35#crTile.fsprospect{ 
     36        background-image:url("../image/prospect.png"); 
     37} 
     38 
     39#crTile{ 
     40        background:white no-repeat 13px 13px; 
     41} 
     42 
     43#crTile H1 { 
     44        background:none; 
     45        padding-left:26px; 
     46        font-weight:bold; 
     47} 
     48 
     49#crTile P{ 
     50        margin: 5px 0 5px 42px; 
     51        padding: 0; 
     52} 
     53 
     54#crName{ 
     55        font-size:14px; 
     56        font-weight:bold; 
     57        margin-top:0; 
     58} 
     59 
     60#crLocation{ 
     61        font-size:10px; 
     62} 
     63 
     64.RDNames{ 
     65        float:left;  
     66        width:100px; 
     67        text-align:right; 
     68        font-weight:bold; 
     69} 
     70 
     71.RDData{ 
     72        margin-left:120px; 
     73} 
     74 
     75.RDData UL { 
     76        margin:0; 
     77        padding:0; 
     78        padding-left:15px; 
     79} 
     80 
     81.RDData LI { 
     82        margin:0; 
     83        padding:0px 0px 5px 0; 
     84} 
     85 
     86#theclear{ 
     87        clear:both; 
     88} 
     89 
     90 
    991.disabledP{display:none;} 
    1092 
    1193#theDetails{margin-top:15px;} 
    1294#rightSideDiv{float:right;width:300px;margin-top:0;} 
    13 #leftSideDiv{margin-right:328px;padding-top:1px;} 
     95#leftSideDiv{margin-right:308px;padding-top:1px;} 
    1496 
    1597H2{margin-top:5px;} 
     
    1799.RDNames{float:left; width:100px;text-align:right;} 
    18100.RDData{margin-left:120px;} 
    19 .Uppers{font-size:15px;} 
    20 #RDMemo{height:100px;overflow:auto;} 
    21101 
    22102#editClient{display:block;width:75px;float:right;} 
     
    31111} 
    32112 
    33 #salesTable{height:190px;overflow:auto;} 
    34 #notesTable{height:150px;overflow:auto;} 
     113#salesTable{height:140px;overflow:auto;} 
     114#notesTable{height:140px;overflow:auto;} 
phpBMS vulnerability assesment provided by Orvant Inc. Copyright © 2010 Kreotek, LLC. All Rights reserved.