CMS MADE SIMPLE FORGE

Company Directory

 

[#9769] Add/Edit a Frontend Edit Album Template sort and delete not working

avatar
Created By: Jack Skiba (nidus)
Date Submitted: Thu Jan 09 12:19:15 -0500 2014

Assigned To:
Version: 1.20
CMSMS Version: 1.11.9
Severity: Major
Resolution: None
State: Open
Summary:
Add/Edit a Frontend Edit Album Template sort and delete not working
Detailed Description:
<script type="text/javascript"
src="http://flyer.nidi.net/modules/JQueryTools/lib/jquery.lib/jquery-1.8.3.min.js"></script>
<script type="text/javascript"
src="http://flyer.nidi.net/modules/JQueryTools/lib/ui.lib/js/jquery-ui-1.9.2.custom.js"></script>
<script type="text/javascript"
src="http://flyer.nidi.net/modules/JQueryTools/lib/fancybox.lib/jquery.fancybox.pack.js"></script>
<script type="text/javascript"
src="http://flyer.nidi.net/modules/JQueryTools/lib/fancybox.lib/jquery.mousewheel-3.0.6.pack.js"></script>
<script type="text/javascript"
src="http://flyer.nidi.net/modules/JQueryTools/lib/fileupload.lib/js/jquery.iframe-transport.js"></script>
<script type="text/javascript"
src="http://flyer.nidi.net/modules/JQueryTools/lib/fileupload.lib/js/jquery.fileupload.js"></script>
<link rel="stylesheet" type="text/css"
href="http://flyer.nidi.net/modules/JQueryTools/lib/fancybox.lib/jquery.fancybox.css"
media="screen" />
<link rel="stylesheet" type="text/css"
href="http://flyer.nidi.net/modules/JQueryTools/lib/ui.lib/css/smoothness/jquery-ui-1.9.2.custom.min.css"
media="screen" />
<!-- JQueryTools version 1.2.5 -->
{literal}<script type="text/javascript">//<![CDATA[
jQuery(document).ready(function($){jQuery('a.fancybox').fancybox();});//]]></script>
{/literal}

the above scripts are in the header

standard template used

while uploading files no progress bar and following js error:
Object function (e,t){return new v.fn.init(e,t,n)} has no method 'progressbar'

but images are uploaded and displayed

dragging image on the delete drop zone doesn't remove the image

dragging images to sort doesn't work.


History

Comments
avatar
Date: 2014-01-15 13:48
Posted By: Jack Skiba (nidus)

Here is fix for the delete problem:
now in template:
$('#cd_album_dropzone').droppable({
     drop: function(event,ui) {
       ui.draggable.fadeOut('slow');
       var x = ui.draggable.attr('id');
       var idx = x.split('_',3)[2];

       $.ajax({
url: '{module_action_link module=CompanyDirectory
action=$actionparams.action companyid=$companyid cd_fldid=$actionparams.cd_fldid
cd_subaction=delete urlonly=1 jsfriendly=1}&showtemplate=false',
         type: 'POST',
         data: { cntnt01cd_idx: idx },
	 error: function (jqXHR, textStatus, errorThrown) {
           alert('upload failed: '.errorThrown);
         },
         success: function( data, textStatus, jqXHR ) {
           _refresh_gallery();
         }
       });

     }
  });

should be:

$('#cd_album_delzone').droppable({ ...
     
      
Updates

Updated: 2014-01-15 13:48
resolution_id: => 5