Remove logs
This commit is contained in:
parent
6070164150
commit
c307fcb18f
4 changed files with 0 additions and 26 deletions
|
|
@ -167,7 +167,6 @@ const CharacterGrid = (props: Props) => {
|
||||||
|
|
||||||
// Methods: Saving job and job skills
|
// Methods: Saving job and job skills
|
||||||
const saveJob = function (job: Job) {
|
const saveJob = function (job: Job) {
|
||||||
console.log("Save job!")
|
|
||||||
if (party.id && appState.party.editable) {
|
if (party.id && appState.party.editable) {
|
||||||
api.endpoints.parties.update(
|
api.endpoints.parties.update(
|
||||||
party.id,
|
party.id,
|
||||||
|
|
|
||||||
|
|
@ -47,7 +47,6 @@ const JobSection = (props: Props) => {
|
||||||
}, [job])
|
}, [job])
|
||||||
|
|
||||||
function receiveJob(job?: Job) {
|
function receiveJob(job?: Job) {
|
||||||
console.log(`Receiving job! Row ${job?.row}: ${job?.name.en}`)
|
|
||||||
if (job) {
|
if (job) {
|
||||||
setJob(job)
|
setJob(job)
|
||||||
props.saveJob(job)
|
props.saveJob(job)
|
||||||
|
|
|
||||||
|
|
@ -42,9 +42,6 @@ const Party = (props: Props) => {
|
||||||
|
|
||||||
// Set up states
|
// Set up states
|
||||||
const { party } = useSnapshot(appState)
|
const { party } = useSnapshot(appState)
|
||||||
const jobState = party.job
|
|
||||||
|
|
||||||
const [job, setJob] = useState<Job>()
|
|
||||||
const [currentTab, setCurrentTab] = useState<GridType>(GridType.Weapon)
|
const [currentTab, setCurrentTab] = useState<GridType>(GridType.Weapon)
|
||||||
|
|
||||||
// Reset state on first load
|
// Reset state on first load
|
||||||
|
|
@ -54,14 +51,6 @@ const Party = (props: Props) => {
|
||||||
if (props.team) storeParty(props.team)
|
if (props.team) storeParty(props.team)
|
||||||
}, [])
|
}, [])
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
setJob(jobState)
|
|
||||||
}, [jobState])
|
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
jobChanged()
|
|
||||||
}, [job])
|
|
||||||
|
|
||||||
// Methods: Creating a new party
|
// Methods: Creating a new party
|
||||||
async function createParty(extra: boolean = false) {
|
async function createParty(extra: boolean = false) {
|
||||||
let body = {
|
let body = {
|
||||||
|
|
@ -89,18 +78,6 @@ const Party = (props: Props) => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function jobChanged() {
|
|
||||||
if (party.id && appState.party.editable) {
|
|
||||||
api.endpoints.parties.update(
|
|
||||||
party.id,
|
|
||||||
{
|
|
||||||
party: { job_id: job ? job.id : "" },
|
|
||||||
},
|
|
||||||
headers
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateDetails(name?: string, description?: string, raid?: Raid) {
|
function updateDetails(name?: string, description?: string, raid?: Raid) {
|
||||||
if (
|
if (
|
||||||
appState.party.name !== name ||
|
appState.party.name !== name ||
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,6 @@ const NewRoute: React.FC<Props> = (props: Props) => {
|
||||||
}, [persistStaticData])
|
}, [persistStaticData])
|
||||||
|
|
||||||
function persistStaticData() {
|
function persistStaticData() {
|
||||||
console.log("Persisting static data...")
|
|
||||||
appState.raids = props.raids
|
appState.raids = props.raids
|
||||||
appState.jobs = props.jobs
|
appState.jobs = props.jobs
|
||||||
appState.jobSkills = props.jobSkills
|
appState.jobSkills = props.jobSkills
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue