search for autocomplate of category

This commit is contained in:
Parsa Nazer
2026-02-14 11:25:50 +03:30
parent 89bd93204d
commit 0414335181
2 changed files with 5 additions and 30 deletions
+3 -28
View File
@@ -14,34 +14,6 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4
- name: Compress repository
run: |
TIMESTAMP=$(date +%Y%m%d-%H%M%S)
ARCHIVE_NAME="repo-backup-${TIMESTAMP}.tar.gz"
tar -czf "../${ARCHIVE_NAME}" \
--exclude='.git' \
--exclude='node_modules' \
--exclude='*.log' \
.
mv "../${ARCHIVE_NAME}" .
echo "ARCHIVE_NAME=${ARCHIVE_NAME}" >> $GITHUB_ENV
- name: Send compressed file via email
run: |
sudo apt-get update
sudo apt-get install -y sendemail libio-socket-ssl-perl libnet-ssleay-perl
sendemail \
-f ftp.notif.manager@gmail.com \
-t byeto.net@gmail.com \
-u "🚀 Deployment Backup - $(date +%Y-%m-%d)" \
-m "Deployment backup from commit: ${{ github.sha }}\nBranch: ${{ github.ref_name }}\nRepository: ${{ github.repository }}\nTimestamp: $(date)" \
-s smtp.gmail.com:587 \
-xu ftp.notif.manager@gmail.com \
-xp ldufbjmidlsosmgq \
-o tls=yes \
-a "${{ env.ARCHIVE_NAME }}"
- name: Copy files to server
uses: appleboy/scp-action@v0.1.6
with:
@@ -65,6 +37,7 @@ jobs:
mkdir -p /root/hshop/frontend/
printf "%s" "${{ secrets.FRONTEND_ENV }}" > /root/hshop/frontend/.env
- name: Build and start Docker containers
uses: appleboy/ssh-action@v0.1.6
with:
@@ -95,5 +68,7 @@ jobs:
username: ${{ secrets.SSH_USER }}
password: ${{ secrets.SSH_PASSWORD }}
script: |
docker image prune -af --filter "until=48h" || { echo "ERROR: ارور در پاک کردن images";}
docker builder prune -af --filter "until=48h" || { echo "ERROR: ارور در پاک کردن builder cache";}
+1 -1
View File
@@ -297,7 +297,7 @@ class ProductModelAdmin(ProductAdminPermission, ModelAdmin, ImportExportModelAdm
search_fields = ['name', 'description', ]
list_filter = ['show', ('category', RelatedDropdownFilter), 'show_in_bot', ('category__parent', RelatedDropdownFilter)]
list_filter_submit = True
autocomplete_fields = ['related_products', 'shop']
autocomplete_fields = ['related_products', 'shop', 'category']
# compressed_fields = True
warn_unsaved_form = True
# list_per_page = 2