mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-18 15:33:15 +00:00
Fix publication creation, edition, sorting
This commit is contained in:
@@ -54,7 +54,7 @@ class FeedController extends Controller
|
||||
|
||||
$user = $this->getAuthenticatedUser();
|
||||
$publisher = $this->getFeedPublisherRepository()->findOneBy([
|
||||
'feed' => $feed,
|
||||
'feed' => $feed,
|
||||
'user' => $user,
|
||||
]);
|
||||
|
||||
@@ -148,7 +148,7 @@ class FeedController extends Controller
|
||||
$entry->setFeed($new_feed);
|
||||
}
|
||||
|
||||
$items = explode(';', $request->request->get('sorted_lst'));
|
||||
$items = explode(';', $request->request->get('lst'));
|
||||
|
||||
$item_repository = $this->getFeedItemRepository();
|
||||
$manager = $this->getEntityManager();
|
||||
@@ -167,7 +167,7 @@ class FeedController extends Controller
|
||||
|
||||
return $this->app->json([
|
||||
'error' => false,
|
||||
'message' => 'succes',
|
||||
'message' => 'success',
|
||||
'datas' => $this->render('prod/results/entry.html.twig', ['entry' => $entry]),
|
||||
]);
|
||||
}
|
||||
|
@@ -33,6 +33,6 @@
|
||||
"postinstall": "./node_modules/.bin/gulp install;"
|
||||
},
|
||||
"dependencies": {
|
||||
"phraseanet-production-client": "~0.3.0"
|
||||
"phraseanet-production-client": "~0.4.0"
|
||||
}
|
||||
}
|
||||
|
@@ -1,5 +1,14 @@
|
||||
|
||||
#modal_feed {
|
||||
.record_list .ui-state-highlight {
|
||||
width: 112px;
|
||||
height: 118px;
|
||||
position: relative;
|
||||
float: left;
|
||||
background: none;
|
||||
background-color: $darkBackgroundColor;
|
||||
border-color: $mediumBackgroundColor;
|
||||
}
|
||||
form {
|
||||
.feeds {
|
||||
color: $darkerTextColor;
|
||||
|
@@ -5,18 +5,9 @@
|
||||
</div>
|
||||
{% endmacro %}
|
||||
|
||||
<style type="text/css">
|
||||
.record_list .sortable.ui-sortable-placeholder{
|
||||
width:112px;
|
||||
height:118px;
|
||||
position:relative;
|
||||
float:left;
|
||||
}
|
||||
</style>
|
||||
|
||||
<div id="modal_feed">
|
||||
<div class="row-fluid" style="height:120px">
|
||||
<div class="span12" style="overflow:auto;">
|
||||
<div class="span12 record_list" style="overflow:auto;">
|
||||
{% for record in publishing %}
|
||||
<div class="sortable" style="position:relative;float:left;">
|
||||
{{ _self.format_diapo(record) }}
|
||||
@@ -83,16 +74,3 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function(){
|
||||
$('#modal_feed .record_list').sortable({
|
||||
stop:function(event, ui){
|
||||
var lst = [];
|
||||
$('#modal_feed .record_list .sortable form').each(function(i, el){
|
||||
lst.push($('input[name="sbas_id"]', el).val()+'_'+$('input[name="record_id"]', el).val());
|
||||
});
|
||||
$('#modal_feed form.main_form input[name="lst"]').val(lst.join(';'));
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
@@ -5,18 +5,9 @@
|
||||
</div>
|
||||
{% endmacro %}
|
||||
|
||||
<style type="text/css">
|
||||
.record_list .sortable.ui-sortable-placeholder{
|
||||
width:112px;
|
||||
height:118px;
|
||||
position:relative;
|
||||
float:left;
|
||||
}
|
||||
</style>
|
||||
|
||||
<div id="modal_feed">
|
||||
<div class="row-fluid" style="height:120px">
|
||||
<div class="span12" style="overflow:auto;">
|
||||
<div class="span12 record_list" style="overflow:auto;">
|
||||
{% for content in entry.getItems() %}
|
||||
<div class="sortable" style="position:relative;float:left;">
|
||||
{{ _self.format_diapo(content.getRecord(app)) }}
|
||||
@@ -31,7 +22,7 @@
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<form class="main_form" method="post" action="{{ path('prod_feeds_entry_update', {'id': entry.getId()}) }}">
|
||||
<input type="hidden" name="sorted_lst" value="" />
|
||||
<input type="hidden" name="lst" value="" />
|
||||
<div class="row-fluid">
|
||||
<div class="span6">
|
||||
<h1>{{ 'Editer' | trans }}</h1>
|
||||
@@ -68,16 +59,3 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function(){
|
||||
$('#modal_feed .record_list').sortable({
|
||||
stop:function(event, ui){
|
||||
var lst = [];
|
||||
$('#modal_feed .record_list form').each(function(i, el){
|
||||
lst.push($('input[name="item_id"]', el).val()+'_'+(i+1));
|
||||
});
|
||||
$('#modal_feed form.main_form input[name="sorted_lst"]').val(lst.join(';'));
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
Reference in New Issue
Block a user