update: remove dollor from wallet and unit

This commit is contained in:
mahyargdz
2024-12-30 16:03:02 +03:30
parent 0d8ba394b1
commit cd61741d06
13 changed files with 462 additions and 490 deletions
+45 -47
View File
@@ -1,58 +1,56 @@
const mongoose = require('mongoose')
const BankSchema = mongoose.Schema({
holderName: String,
PAN: {
type: Number,
},
IBAN: {
type: String,
}
holderName: String,
PAN: {
type: Number
},
IBAN: {
type: String
}
})
const UserSchema = mongoose.Schema({
first_name: String,
last_name: String,
national_code: String,
province_name: Object,
city_name: Object,
address: String,
mobile_number: String,
cell_number:String,
password: String,
profilePic: {
type: String,
default: "noPic"
},
shopName: String,
birthDate: String,
lastIP:String,
walletBalance: {
type: Number,
min: 0,
default: 0
},
dollarBalance: {
type: Number,
min: 0,
default: 0
},
score: {
type: Number,
min: 0,
default: 0
},
cardBank: [BankSchema],
active:{ type: Boolean, default: false },
first_name: String,
last_name: String,
national_code: String,
province_name: Object,
city_name: Object,
address: String,
mobile_number: String,
cell_number: String,
password: String,
profilePic: {
type: String,
default: 'noPic'
},
shopName: String,
birthDate: String,
lastIP: String,
walletBalance: {
type: Number,
min: 0,
default: 0
},
// dollarBalance: {
// type: Number,
// min: 0,
// default: 0
// },
score: {
type: Number,
min: 0,
default: 0
},
cardBank: [BankSchema],
active: { type: Boolean, default: false },
/// //////////////////////////////// user confirmations
seenByAdmin: { type: Boolean, default: false },
/// //////////////////////////////// user confirmations
seenByAdmin: { type: Boolean, default: false },
/// /////////////
token: String,
otp:String
/// /////////////
token: String,
otp: String
})
module.exports = mongoose.model('UserGPS', UserSchema)