Skip to content

Commit

Permalink
اصلاح الإدخال اليدوي لخطوط الطول والعرض
Browse files Browse the repository at this point in the history
  • Loading branch information
islamiaat committed Dec 30, 2023
1 parent 112f07a commit 9bd28f4
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 11 deletions.
2 changes: 1 addition & 1 deletion config.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<widget id="com.rn0x.altaqwaa" version="1.2.2" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<widget id="com.rn0x.altaqwaa" version="1.2.3" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>التقوى</name>
<description>تطبيق إسلامي سهل الإستخدام و جامع للكثير من الميزات التي يحتاجها المسلم في يومه</description>
<author email="[email protected]" href="https://altaqwaa.org">Altaqwaa</author>
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "com.rn0x.altaqwaa",
"displayName": "التقوى",
"version": "1.2.2",
"version": "1.2.3",
"description": "تطبيق إسلامي سهل الإستخدام و جامع للكثير من الميزات التي يحتاجها المسلم في يومه",
"main": "index.js",
"scripts": {
Expand Down
8 changes: 4 additions & 4 deletions www/js/notification.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ export default async () => {
let Setasr = storage.getItem('asr');
let Setmaghrib = storage.getItem('maghrib');
let Setisha = storage.getItem('isha');
let Getlatitude = storage.getItem('latitude');
let Getlongitude = storage.getItem('longitude');
let Getlatitude = storage.getItem('latitude_settings');
let Getlongitude = storage.getItem('longitude_settings');
let notification = storage.getItem('notification');

if (Getlongitude === null || Getlatitude === null) {

let GPS = await getGPS();
Getlatitude = GPS.latitude;
Getlongitude = GPS.longitude;
storage.setItem("latitude", Getlatitude);
storage.setItem("longitude", Getlongitude);
storage.setItem("latitude_settings", Getlatitude);
storage.setItem("longitude_settings", Getlongitude);

}

Expand Down
9 changes: 5 additions & 4 deletions www/js/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ const setDefaultValues = () => {

Object.entries(DEFAULT_VALUES).forEach(([key, value]) => {
const element = getElementById(key);

if (element) {
const storedValue = storage.getItem(key);

Expand All @@ -55,8 +56,8 @@ const setDefaultValues = () => {
} else if (key === 'notifications_adhan') {
element.checked = storedValue !== null && storedValue !== undefined ? bool(storedValue) : true;
} else if (key === 'longitude_settings' || key === 'latitude_settings') {
const longitudeValue = storage.getItem('longitude');
const latitudeValue = storage.getItem('latitude');
const longitudeValue = storage.getItem('longitude_settings');
const latitudeValue = storage.getItem('latitude_settings');
if (longitudeValue && latitudeValue) {
element.value = key === 'longitude_settings' ? longitudeValue : latitudeValue;
}
Expand All @@ -79,8 +80,8 @@ const handleRefreshLocation = async () => {
const { latitude, longitude } = await getGPS();
const storage = window.localStorage;

storage.setItem('latitude', latitude);
storage.setItem('longitude', longitude);
storage.setItem('latitude_settings', latitude);
storage.setItem('longitude_settings', longitude);

const alertEl = getElementById('alert');
if (alertEl) {
Expand Down
2 changes: 1 addition & 1 deletion www/pages/info.html
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ <h3 id="app_name">
<span><a href="https://t.me/tqw24h" target="_blank">@tqw24h</a></span> مجموعتنا على تيليجرام
</p>

<p id="app_version">الإصدار: <span>v1.2.2</span></p>
<p id="app_version">الإصدار: <span>v1.2.3</span></p>

<p id="license">الترخيص : GPL-3.0</p>

Expand Down

0 comments on commit 9bd28f4

Please sign in to comment.