Skip to content

Commit

Permalink
feat: удалить перенос контента из сметы
Browse files Browse the repository at this point in the history
  • Loading branch information
popstas committed May 20, 2020
1 parent ca6d17c commit eda712d
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/smeta.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,24 @@ const pffSmeta = {
realizeLink.remove();
});

// удаление переноса контента
const contentServices = smetaTable.find(PFF.fields.smeta.name).filter(function() {
const text = $(this).text();
return text.match(/Перенос контента/) || text.match(/Редиректы URL/);
});
if(contentServices.length > 0) {
const link = PFF.addAnaliticAction(
`Удалить перенос контента`,
() => {
contentServices.each(function(){
const row = $(this).parents('tr');
row.find('[data-acr="delete"]').trigger('click');
});
link.remove();
}, smetaAid,
);
}

// удаление аналитик по блокам (этапам)
const sections = {};
smetaTable.find(PFF.fields.smeta.block).each(function() {
Expand Down

0 comments on commit eda712d

Please sign in to comment.