Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions actions.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
export { actions as taskPlans } from './tasks/dux/plans'
export { actions as taskWorks } from './tasks/dux/works'
export { default as ordering } from './ordering/actions'
export { actions as products } from './supply/dux/products'
export { actions as priceSpecs } from './supply/dux/priceSpecs'
export { actions as resourceTypes } from './resources/dux/resourceTypes'
1 change: 1 addition & 0 deletions agents/components/Profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ function Profile (props) {
})
])
]),

h('div', {
className: styles.buttonContainer
}, [
Expand Down
12 changes: 6 additions & 6 deletions app/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,18 +32,17 @@
"agents.member": "member",
"agents.admin": "admin",
"resources.resourceType": "resource type",
"resources.resourceTypeName": "resource type name",
"resources.isResourceTypeReducible": "does this resource contain other resources?",
"resources.resourceTypeIsReducible": "resource contains other resources",
"resources.resourceTypeIsNotReducible": "resource doesn't contain other resources",
"resources.resourceTypeName": "Resource name",
"resources.saveResourceType": "save resource type",
"resources.addResourceTypeItem": "add part",
"resources.removeResourceTypeItem": "remove part",
"resources.resourceTypeDescription": "Resource description",
"resources.resourceTypeImage": "Paste image link",
"resources.resourceTypes": "Add Resource",
"supply.quantity": "quantity",
"supply.unit": "unit",
"unit.litres": "litres",
"unit.kg": "kg",
"unit.each": "each (discrete)",
"supply.createProduct": "create new product",
"supply.resourceName": "resource name",
"supply.isReducible": "has sub-items",
"supply.products": "products",
Expand All @@ -68,6 +67,7 @@
"tasks.recipes.createProfile": "create your profile",
"tasks.steps.groupProfile": "enter your group profile information",
"tasks.steps.supplierProfile": "enter your supplier profile information",
"tasks.steps.supplierProducts": "enter your supplier product list",
"tasks.steps.memberInvites": "invite group members",
"tasks.recipes.setupSupplier": "setup supplier profile and products"
}
14 changes: 14 additions & 0 deletions db/migrations/20170905141222_create-resource-type-table.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@

exports.up = function(knex, Promise) {
return knex.schema.createTableIfNotExists('resourceTypes', function (table){
table.increments('id')
table.string('name')
table.text('description')
table.text('image')

})
};

exports.down = function(knex, Promise) {
return knex.schema.dropTableIfExists('resourceTypes')
};
14 changes: 14 additions & 0 deletions db/migrations/20170905144728_create-price-spec-table.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@

exports.up = function(knex, Promise) {
return knex.schema.createTableIfNotExists('priceSpecs', function (table){
table.increments('id')
table.integer('productId').references('products.id')
table.string('minimum')
table.string('price')
table.string('currency')
})
};

exports.down = function(knex, Promise) {
return knex.schema.dropTableIfExists('priceSpecs')
};
12 changes: 12 additions & 0 deletions db/migrations/20170906110508_create-products-table.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@

exports.up = function(knex, Promise) {
return knex.schema.createTableIfNotExists('products', function (table){
table.increments('id')
table.integer('resourceTypeId').references('resourceTypes.id')
table.integer('supplierAgentId').references('agents.id')
})
};

exports.down = function(knex, Promise) {
return knex.schema.dropTableIfExists('products')
};
8 changes: 7 additions & 1 deletion epic.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,16 @@ import { epic as agents } from 'dogstack-agents'
import { epic as taskPlans } from './tasks/dux/plans'
import { epic as taskWorks } from './tasks/dux/works'
import { epic as orders } from './ordering/dux/orders'
import { epic as products } from './supply/dux/products'
import { epic as priceSpecs } from './supply/dux/priceSpecs'
import { epic as resourceTypes } from './resources/dux/resourceTypes'

export default combineEpics(
agents,
orders,
taskPlans,
taskWorks
taskWorks,
products,
priceSpecs,
resourceTypes
)
Loading