تطوير تطبيق المهندس مصطفى عبده

Замовник: AI | Опубліковано: 27.02.2026
Бюджет: 750 $

import kivy from kivy.app import App from kivy.uix.boxlayout import BoxLayout from kivy.uix.textinput import TextInput from kivy.uix.button import Button from kivy.uix.label import Label from kivy.uix.popup import Popup from kivy.storage.jsonstore import JsonStore from datetime import datetime اسم التطبيق: المهندس مصطفى عبده كلمة السر: 20003 تخزين البيانات محليًا بصيغة JSON store = JsonStore('clients_data.json') class MainScreen(BoxLayout): def init(self, **kwargs): super().init(**kwargs) self.orientation = 'vertical' self.password_input = TextInput(password=True, hint_text='ادخل كلمة السر') self.add_widget(self.password_input) self.login_btn = Button(text='تسجيل الدخول') self.login_btn.bind(on_press=self.check_password) self.add_widget(self.login_btn) def check_password(self, instance): if self.password_input.text == '20003': self.clear_widgets() self.show_main_interface() else: popup = Popup(title='خطأ', content=Label(text='كلمة السر خطأ'), size_hint=(0.5,0.5)) popup.open() def show_main_interface(self): # الواجهة الرئيسية self.add_widget(Label(text='مرحبا بك في تطبيق المهندس مصطفى عبده')) self.client_name = TextInput(hint_text='اسم العميل') self.add_widget(self.client_name) self.operation_type = TextInput(hint_text='نوع البيان') self.add_widget(self.operation_type) self.notes = TextInput(hint_text='ملاحظات') self.add_widget(self.notes) self.save_btn = Button(text='حفظ العملية') self.save_btn.bind(on_press=self.save_operation) self.add_widget(self.save_btn) def save_operation(self, instance): name = self.client_name.text operation = self.operation_type.text notes = self.notes.text if name == '' or operation == '': popup = Popup(title='خطأ', content=Label(text='الاسم أو نوع البيان مطلوب'), size_hint=(0.5,0.5)) popup.open() return now = datetime.now() date_str = now.strftime('%Y-%m-%d') time_str = now.strftime('%H:%M:%S') entry = {'operation': operation, 'notes': notes, 'date': date_str, 'time': time_str} if store.exists(name): data = store.get(name)['operations'] data.append(entry) store.put(name, operations=data)