fix all error 3

This commit is contained in:
2026-08-22 16:50:49 +03:30
parent 7bdb2c91a0
commit 89014821c5
25 changed files with 3371 additions and 2618 deletions
+382 -333
View File
@@ -98,12 +98,14 @@ WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'server_url' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'key', 'demogold', 'کلید داخلی اپ', 1, 1, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'key' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'balance_report_exclude_customer_id', '', 'حذف مشتری از تراز ادمین', 0, 0, NULL, 'number'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'balance_report_exclude_customer_id' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'send_to_tahesab', 'false', 'ارسال ته‌حساب', 0, 1, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'send_to_tahesab' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'balance_report_exclude_customer_id', '', 'حذف مشتری از تراز ادمین', 0, 0, NULL, 'number'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'balance_report_exclude_customer_id' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'send_to_tahesab', 'false', 'ارسال ته‌حساب', 0, 1, NULL, 'switch'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'send_to_tahesab' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'test*', '', '', 1, 0, 'تستی است', 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'test*' LIMIT 1);
@@ -125,9 +127,10 @@ WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'min_first_buy' LIMIT 1
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montify_name', '', 'نام فروشگاه', 1, 0, 'RequestsController — اختیاری', 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montify_name' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'profit_gold_api_enabled', '', 'API سود طلا', 0, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'profit_gold_api_enabled' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'profit_gold_api_enabled', '', 'API سود طلا', 0, 0, NULL, 'switch'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'profit_gold_api_enabled' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'open_register', 'true', 'ثبت‌نام باز', 1, 1, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'open_register' LIMIT 1);
@@ -143,9 +146,10 @@ WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'buy_fee' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'sell_fee', '', 'سود/اختلاف فروش (ریال)', 1, 0, 'اگر خالی باشد از fee_single', 'number'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'sell_fee' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'referral_id', '', 'الزام کد معرف', 0, 0, 'required,', 'select'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'referral_id' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'referral_id', '', 'الزام کد معرف', 0, 0, 'required,', 'select'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'referral_id' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'fee_service_charge_percentage', '0.005', 'درصد کارمزد سفارش', 1, 1, 'مقدار نمونه: 0.07', 'number'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'fee_service_charge_percentage' LIMIT 1);
@@ -164,12 +168,14 @@ WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'payping_gateway_name'
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'payping_gateway_items', '', 'لیست item (چرخشی)', 1, 0, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'payping_gateway_items' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'payping_round_toman', '', 'گرد کردن مبلغ به تومان', 0, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'payping_round_toman' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'payping_strict_failed_withdraw', '', 'اولویت تراکنش ناموفق', 0, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'payping_strict_failed_withdraw' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'payping_round_toman', '', 'گرد کردن مبلغ به تومان', 0, 0, NULL, 'switch'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'payping_round_toman' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'payping_strict_failed_withdraw', '', 'اولویت تراکنش ناموفق', 0, 0, NULL, 'switch'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'payping_strict_failed_withdraw' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_closed', '', 'بسته بودن همکار', 1, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_closed' LIMIT 1);
@@ -212,30 +218,36 @@ WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_product_id' LI
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_base_url', '', 'آدرس سرور همکار', 1, 0, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_base_url' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_token', '', 'توکن همکار (خودکار)', 0, 0, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_token' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'montzar_token', '', 'توکن همکار (خودکار)', 0, 0, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_token' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_open_buy', '', 'باز بودن خرید همکار', 1, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_open_buy' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_open_sell', '', 'باز بودن فروش همکار', 1, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_open_sell' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_diff', '', 'اختلاف قیمت همکار', 0, 0, 'سیستم پر می‌کند', 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_diff' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_live_price', '', 'قیمت لحظه‌ای همکار', 0, 0, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_live_price' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_mazaneh', '', 'مظنه همکار', 0, 0, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_mazaneh' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_truly_buy_mazaneh', '', 'مظنه خرید همکار', 0, 0, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_truly_buy_mazaneh' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'montzar_truly_sell_mazaneh', '', 'مظنه فروش همکار', 0, 0, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_truly_sell_mazaneh' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'montzar_diff', '', 'اختلاف قیمت همکار', 0, 0, 'سیستم پر می‌کند', 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_diff' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'montzar_live_price', '', 'قیمت لحظه‌ای همکار', 0, 0, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_live_price' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'montzar_mazaneh', '', 'مظنه همکار', 0, 0, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_mazaneh' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'montzar_truly_buy_mazaneh', '', 'مظنه خرید همکار', 0, 0, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_truly_buy_mazaneh' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'montzar_truly_sell_mazaneh', '', 'مظنه فروش همکار', 0, 0, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'montzar_truly_sell_mazaneh' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'display_montzar', 'true', 'نمایش بلوک همکار در UI', 1, 1, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'display_montzar' LIMIT 1);
@@ -290,30 +302,36 @@ WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'tahesab_db' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'tahesab_bank_account', 'کشاورزي قلک', 'حساب بانکی ته‌حساب', 1, 1, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'tahesab_bank_account' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'telegram_bot_token', '8140615853:AAGQj0yUIcWTTn1_exz2vn5TsgiUJFnVom8', 'توکن بات تلگرام', 0, 1, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'telegram_bot_token' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'bale_bot_token', '1212891021:F2IPeXI_oCA55pRDKkE300bd8DbkbqS0HGk', 'توکن بات بله', 0, 1, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'bale_bot_token' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'up_price', '22567500', 'بیشترین قیمت امروز', 0, 1, 'ReportController', 'number'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'up_price' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'down_price', '22567500', 'کمترین قیمت امروز', 0, 1, NULL, 'number'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'down_price' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'price_extreme_date', '2026-06-05', 'تاریخ min/max روز', 0, 1, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'price_extreme_date' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'telegram_bot_token', '8140615853:AAGQj0yUIcWTTn1_exz2vn5TsgiUJFnVom8', 'توکن بات تلگرام', 0, 1, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'telegram_bot_token' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'bale_bot_token', '1212891021:F2IPeXI_oCA55pRDKkE300bd8DbkbqS0HGk', 'توکن بات بله', 0, 1, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'bale_bot_token' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'up_price', '22567500', 'بیشترین قیمت امروز', 0, 1, 'ReportController', 'number'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'up_price' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'down_price', '22567500', 'کمترین قیمت امروز', 0, 1, NULL, 'number'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'down_price' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'price_extreme_date', '2026-06-05', 'تاریخ min/max روز', 0, 1, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'price_extreme_date' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'product_update_price_on_list', '', 'بروز قیمت در لیست محصول', 1, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'product_update_price_on_list' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'product_auto_close_open_on_list', '', 'باز/بسته خودکار محصول', 1, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'product_auto_close_open_on_list' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'metal_type', 'کاتد مس', 'عنوان فلز در UI', 0, 1, NULL, 'text'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'metal_type' LIMIT 1);
-- [super-admin can_edit=0]
-- INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
-- SELECT 'metal_type', 'کاتد مس', 'عنوان فلز در UI', 0, 1, NULL, 'text'
-- WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'metal_type' LIMIT 1);
INSERT INTO `settings` (`key`, `value`, `title_fa`, `can_edit`, `is_active`, `description`, `type`)
SELECT 'payping_fin_sync_enabled', '', 'همگام‌سازی fin لیمان', 1, 0, NULL, 'switch'
WHERE NOT EXISTS (SELECT 1 FROM `settings` WHERE `key` = 'payping_fin_sync_enabled' LIMIT 1);
@@ -380,51 +398,56 @@ UPDATE `settings` SET
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'bace_url';
UPDATE `settings` SET
`title_fa` = '',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = 'logo_login',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'logo_login';
UPDATE `settings` SET
`title_fa` = 'لوگوی صفحه ورود',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = 'logo_register',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'logo_register';
UPDATE `settings` SET
`title_fa` = 'آدرس پنل ادمین',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = 'https://kh.montzar.ir/admin/',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'admin_url';
UPDATE `settings` SET
`title_fa` = 'عنوان PWA',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'title_pwa';
UPDATE `settings` SET
`title_fa` = 'عنوان favicon',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'title_fav';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = '',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = 'logo_login',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'logo_login';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'لوگوی صفحه ورود',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = 'logo_register',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'logo_register';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'آدرس پنل ادمین',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = 'https://kh.montzar.ir/admin/',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'admin_url';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'عنوان PWA',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'title_pwa';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'عنوان favicon',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'title_fav';
UPDATE `settings` SET
`title_fa` = 'متن قوانین',
`can_edit` = 1,
@@ -452,15 +475,16 @@ UPDATE `settings` SET
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'is_requaire_referral';
UPDATE `settings` SET
`title_fa` = 'صفحه کسب درآمد',
`can_edit` = 1,
`type` = 'switch',
`description` = 'in server',
`value` = 'true',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'has_page_earn_money';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'صفحه کسب درآمد',
-- `can_edit` = 1,
-- `type` = 'switch',
-- `description` = 'in server',
-- `value` = 'true',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'has_page_earn_money';
UPDATE `settings` SET
`title_fa` = 'صفحه صندوق',
`can_edit` = 1,
@@ -479,15 +503,16 @@ UPDATE `settings` SET
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'has_page_permission';
UPDATE `settings` SET
`title_fa` = 'صفحه هشدار قیمت',
`can_edit` = 1,
`type` = 'switch',
`description` = NULL,
`value` = 'true',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'has_page_price_trigger';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'صفحه هشدار قیمت',
-- `can_edit` = 1,
-- `type` = 'switch',
-- `description` = NULL,
-- `value` = 'true',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'has_page_price_trigger';
UPDATE `settings` SET
`title_fa` = 'صفحه طلای فیزیکی',
`can_edit` = 1,
@@ -551,15 +576,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'balance_report_exclude_customer_id';
UPDATE `settings` SET
`title_fa` = 'ارسال ته‌حساب',
`can_edit` = 0,
`type` = 'switch',
`description` = NULL,
`value` = 'false',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'send_to_tahesab';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'ارسال ته‌حساب',
-- `can_edit` = 0,
-- `type` = 'switch',
-- `description` = NULL,
-- `value` = 'false',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'send_to_tahesab';
UPDATE `settings` SET
`title_fa` = '',
`can_edit` = 1,
@@ -587,15 +613,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'referral_count_for_gift';
UPDATE `settings` SET
`title_fa` = 'مبلغ پاداش معرف',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'referral_bonus_amount';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'مبلغ پاداش معرف',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'referral_bonus_amount';
UPDATE `settings` SET
`title_fa` = 'حداقل برداشت (ریال)',
`can_edit` = 1,
@@ -614,15 +641,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'min_first_buy';
UPDATE `settings` SET
`title_fa` = 'نام فروشگاه',
`can_edit` = 1,
`type` = 'text',
`description` = 'RequestsController — اختیاری',
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'montify_name';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'نام فروشگاه',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = 'RequestsController — اختیاری',
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'montify_name';
UPDATE `settings` SET
`title_fa` = 'API سود طلا',
`can_edit` = 0,
@@ -641,15 +669,16 @@ UPDATE `settings` SET
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'open_register';
UPDATE `settings` SET
`title_fa` = 'منبع قیمت',
`can_edit` = 1,
`type` = 'select',
`description` = 'montzar,zaarbox,main_product,etehadie,taban_gohar',
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'price_provider';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'منبع قیمت',
-- `can_edit` = 1,
-- `type` = 'select',
-- `description` = 'montzar,zaarbox,main_product,etehadie,taban_gohar',
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'price_provider';
UPDATE `settings` SET
`title_fa` = 'اختلاف قیمت پایه (ریال)',
`can_edit` = 1,
@@ -731,24 +760,26 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'payping_gateway_name';
UPDATE `settings` SET
`title_fa` = 'لیست item (چرخشی)',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'payping_gateway_items';
UPDATE `settings` SET
`title_fa` = 'گرد کردن مبلغ به تومان',
`can_edit` = 0,
`type` = 'switch',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'payping_round_toman';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'لیست item (چرخشی)',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'payping_gateway_items';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'گرد کردن مبلغ به تومان',
-- `can_edit` = 0,
-- `type` = 'switch',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'payping_round_toman';
UPDATE `settings` SET
`title_fa` = 'اولویت تراکنش ناموفق',
`can_edit` = 0,
@@ -767,24 +798,26 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'montzar_closed';
UPDATE `settings` SET
`title_fa` = 'قیمت صفحه اصلی',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'main_product';
UPDATE `settings` SET
`title_fa` = 'url زرباکس',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'zaarbox_api_url';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'قیمت صفحه اصلی',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'main_product';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'url زرباکس',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'zaarbox_api_url';
UPDATE `settings` SET
`title_fa` = 'کد محصول زرباکس',
`can_edit` = 1,
@@ -794,15 +827,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'zaarbox_price_key';
UPDATE `settings` SET
`title_fa` = 'UUID نمودار Zaarbox',
`can_edit` = 1,
`type` = 'text',
`description` = 'خالی = ca3800a0-1f57-3528-b963-178f9168e04f',
`value` = '8c19e06a-446e-3d56-9cc0-750f7c6cd767',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'chart_id';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'UUID نمودار Zaarbox',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = 'خالی = ca3800a0-1f57-3528-b963-178f9168e04f',
-- `value` = '8c19e06a-446e-3d56-9cc0-750f7c6cd767',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'chart_id';
UPDATE `settings` SET
`title_fa` = 'آدرس API اتحادیه (پشتیبان)',
`can_edit` = 1,
@@ -875,15 +909,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'montzar_product_id';
UPDATE `settings` SET
`title_fa` = 'آدرس سرور همکار',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'montzar_base_url';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'آدرس سرور همکار',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'montzar_base_url';
UPDATE `settings` SET
`title_fa` = 'توکن همکار (خودکار)',
`can_edit` = 0,
@@ -1082,87 +1117,96 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'referral_limit';
UPDATE `settings` SET
`title_fa` = 'پیامک گروهی',
`can_edit` = 1,
`type` = 'switch',
`description` = NULL,
`value` = 'false',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'group_sms';
UPDATE `settings` SET
`title_fa` = 'توکن ته‌حساب',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = 'X4V2Q8J1C4P1A7P7P5K2E6X2U1L8D4E4Y8N5Q4O6N2R6L2H1W1S1W1N1E5F6A8F7N4U2X4J4B4R2R2W2',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'tahesab_token';
UPDATE `settings` SET
`title_fa` = 'دیتابیس ته‌حساب',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = 'TahesabDB5',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'tahesab_db';
UPDATE `settings` SET
`title_fa` = 'حساب بانکی ته‌حساب',
`can_edit` = 1,
`type` = 'text',
`description` = NULL,
`value` = 'کشاورزي قلک',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'tahesab_bank_account';
UPDATE `settings` SET
`title_fa` = 'توکن بات تلگرام',
`can_edit` = 0,
`type` = 'text',
`description` = NULL,
`value` = '8140615853:AAGQj0yUIcWTTn1_exz2vn5TsgiUJFnVom8',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'telegram_bot_token';
UPDATE `settings` SET
`title_fa` = 'توکن بات بله',
`can_edit` = 0,
`type` = 'text',
`description` = NULL,
`value` = '1212891021:F2IPeXI_oCA55pRDKkE300bd8DbkbqS0HGk',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'bale_bot_token';
UPDATE `settings` SET
`title_fa` = 'بیشترین قیمت امروز',
`can_edit` = 0,
`type` = 'number',
`description` = 'ReportController',
`value` = '22567500',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'up_price';
UPDATE `settings` SET
`title_fa` = 'کمترین قیمت امروز',
`can_edit` = 0,
`type` = 'number',
`description` = NULL,
`value` = '22567500',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'down_price';
UPDATE `settings` SET
`title_fa` = 'تاریخ min/max روز',
`can_edit` = 0,
`type` = 'text',
`description` = NULL,
`value` = '2026-06-05',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'price_extreme_date';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'پیامک گروهی',
-- `can_edit` = 1,
-- `type` = 'switch',
-- `description` = NULL,
-- `value` = 'false',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'group_sms';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'توکن ته‌حساب',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = 'X4V2Q8J1C4P1A7P7P5K2E6X2U1L8D4E4Y8N5Q4O6N2R6L2H1W1S1W1N1E5F6A8F7N4U2X4J4B4R2R2W2',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'tahesab_token';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'دیتابیس ته‌حساب',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = 'TahesabDB5',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'tahesab_db';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'حساب بانکی ته‌حساب',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = 'کشاورزي قلک',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'tahesab_bank_account';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'توکن بات تلگرام',
-- `can_edit` = 0,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '8140615853:AAGQj0yUIcWTTn1_exz2vn5TsgiUJFnVom8',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'telegram_bot_token';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'توکن بات بله',
-- `can_edit` = 0,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '1212891021:F2IPeXI_oCA55pRDKkE300bd8DbkbqS0HGk',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'bale_bot_token';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'بیشترین قیمت امروز',
-- `can_edit` = 0,
-- `type` = 'number',
-- `description` = 'ReportController',
-- `value` = '22567500',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'up_price';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'کمترین قیمت امروز',
-- `can_edit` = 0,
-- `type` = 'number',
-- `description` = NULL,
-- `value` = '22567500',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'down_price';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'تاریخ min/max روز',
-- `can_edit` = 0,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = '2026-06-05',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'price_extreme_date';
UPDATE `settings` SET
`title_fa` = 'بروز قیمت در لیست محصول',
`can_edit` = 1,
@@ -1181,24 +1225,26 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'product_auto_close_open_on_list';
UPDATE `settings` SET
`title_fa` = 'عنوان فلز در UI',
`can_edit` = 0,
`type` = 'text',
`description` = NULL,
`value` = 'کاتد مس',
`is_active` = 1,
`updated_at` = NOW()
WHERE `key` = 'metal_type';
UPDATE `settings` SET
`title_fa` = 'همگام‌سازی fin لیمان',
`can_edit` = 1,
`type` = 'switch',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'payping_fin_sync_enabled';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'عنوان فلز در UI',
-- `can_edit` = 0,
-- `type` = 'text',
-- `description` = NULL,
-- `value` = 'کاتد مس',
-- `is_active` = 1,
-- `updated_at` = NOW()
-- WHERE `key` = 'metal_type';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'همگام‌سازی fin لیمان',
-- `can_edit` = 1,
-- `type` = 'switch',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'payping_fin_sync_enabled';
UPDATE `settings` SET
`title_fa` = 'URL fin',
`can_edit` = 1,
@@ -1217,15 +1263,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'payping_fin_token';
UPDATE `settings` SET
`title_fa` = 'customer_id fin',
`can_edit` = 1,
`type` = 'number',
`description` = NULL,
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'payping_fin_customer_id';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'customer_id fin',
-- `can_edit` = 1,
-- `type` = 'number',
-- `description` = NULL,
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'payping_fin_customer_id';
UPDATE `settings` SET
`title_fa` = 'item تکی (legacy)',
`can_edit` = 1,
@@ -1235,15 +1282,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'payping_gateway_item';
UPDATE `settings` SET
`title_fa` = 'شناسه کلاینت API خارجی (X-Client-Id)',
`can_edit` = 1,
`type` = 'text',
`description` = 'مقدار قبلی .env: NODE_CLIENT_ID',
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'node_client_id';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'شناسه کلاینت API خارجی (X-Client-Id)',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = 'مقدار قبلی .env: NODE_CLIENT_ID',
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'node_client_id';
UPDATE `settings` SET
`title_fa` = 'کلید امضای HMAC API خارجی',
`can_edit` = 1,
@@ -1253,15 +1301,16 @@ UPDATE `settings` SET
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'node_shared_secret';
UPDATE `settings` SET
`title_fa` = 'فعال‌سازی API سفارش خارجی (get_wallet / order)',
`can_edit` = 1,
`type` = 'text',
`description` = 'true + node_client_id + node_shared_secret',
`value` = '',
`is_active` = 0,
`updated_at` = NOW()
WHERE `key` = 'external_order_api_enabled';
-- [super-admin can_edit=0]
-- UPDATE `settings` SET
-- `title_fa` = 'فعال‌سازی API سفارش خارجی (get_wallet / order)',
-- `can_edit` = 1,
-- `type` = 'text',
-- `description` = 'true + node_client_id + node_shared_secret',
-- `value` = '',
-- `is_active` = 0,
-- `updated_at` = NOW()
-- WHERE `key` = 'external_order_api_enabled';
-- =============================================================================
-- 3) اصلاح کلید خراب logo_login (در صورت وجود)